Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

bayer

Package Overview
Dependencies
Maintainers
0
Versions
5
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

bayer

Compute the bayer matrix for powers of two. Useful for ordered dithering algorithms.

  • 1.0.4
  • latest
  • Source
  • npm
  • Socket score

Version published
Weekly downloads
0
decreased by-100%
Maintainers
0
Weekly downloads
 
Created
Source

bayer

npm version stability-stable npm minzipped size dependencies types Conventional Commits styled with prettier linted with eslint license

Compute the bayer matrix for powers of two. Useful for ordered dithering algorithms.

paypal coinbase twitter

Installation

npm install bayer

Usage

import bayer from "bayer";

const matrix = bayer();
// => [
//   [0, 2],
//   [3, 1],
// ];

API

bayer(size) ⇒ Array.<Array>

Compute the bayer matrix for powers of two.

Kind: global function Returns: Array.<Array> - A 2D array containing the matrix.

ParamTypeDefaultDescription
sizenumber2Needs to be a power of two otherwise will throw a "Maximum call stack size exceeded" Error.

License

MIT. See license file.

Keywords

FAQs

Package last updated on 06 Jul 2024

Did you know?

Socket

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc