# 2dpixels-canvas

> render pixels to a canvas element

Latest version **1.0.2** (published 2016-03-28) · Apache-2.0 license · 0 weekly downloads

> **Deprecated.** This package is deprecated.

## Install

```sh
npm install 2dpixels-canvas
pnpm add 2dpixels-canvas
yarn add 2dpixels-canvas
bun add 2dpixels-canvas
```

## Health

**Score 10/100 (F)** — status: deprecated.

Negative: deprecated.

## Facts

| | |
|---|---|
| Version | 1.0.2 |
| Published | 2016-03-28 |
| First published | 2015-07-30 |
| Weekly downloads | 0 |
| License | Apache-2.0 |
| TypeScript types | none |
| Module format | CommonJS |
| Dependencies | 2 |
| Known vulnerabilities | 0 |
| Install scripts | no |
| GitHub stars | 1 |
| Author | ahdinosaur |
| Maintainers | ahdinosaur |

## Links

- npm: https://www.npmjs.com/package/2dpixels-canvas
- Repository: https://github.com/livejs/pixels-canvas
- Issues: https://github.com/livejs/pixels-canvas/issues
- npm.io page: https://npm.io/package/2dpixels-canvas

## Dependencies (2)

- [generate-function](https://npm.io/package/generate-function.md) ^2.0.0
- [pixel-to-css-color](https://npm.io/package/pixel-to-css-color.md) ^1.0.0

## Recent versions

- 1.0.2 (latest) — 2016-03-28
- 1.0.1 — 2015-07-30

## README

# pixels-canvas

canvas renderer for [pixels](https://github.com/livejs/pixels)

```shell
npm install --save pixels-canvas
```

## usage

### `toCanvas = require('pixels-canvas')`

### `pixelsToCanvas = toCanvas(canvas)`

`canvas`: required canvas dom element

### `pixelsToCanvas(pixels)`

`pixels`: required [2d pixels](https://github.com/livejs/ndpixels)

## example

```js
var toCanvas = require('pixels-canvas')

var pixelsToCanvas = toCanvas(canvas)

document.body.appendChild(canvas)

pixelsToCanvas(pixels)
```

for a full example, see [./example](http://livejs.github.io/pixels-canvas)

## License

The Apache License

Copyright &copy; 2016 Michael Williams (@ahdinosaur)

Licensed under the Apache License, Version 2.0 (the "License");
you may not use this file except in compliance with the License.
You may obtain a copy of the License at

    http://www.apache.org/licenses/LICENSE-2.0

Unless required by applicable law or agreed to in writing, software
distributed under the License is distributed on an "AS IS" BASIS,
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
See the License for the specific language governing permissions and
limitations under the License.

---
_Source: https://npm.io/package/2dpixels-canvas · Machine-readable twin of the npm.io package page. Health data is recomputed on every publish._
