{"_id":"@canvas/image-data","_rev":"3212341","name":"@canvas/image-data","description":"An `ImageData` implementation for usage outside of the browser.","dist-tags":{"latest":"1.0.0"},"maintainers":[{"name":"linusu","email":""}],"time":{"modified":"2024-02-22T02:25:17.000Z","created":"2018-11-20T20:04:30.525Z","1.0.0":"2018-11-20T20:04:30.525Z"},"users":{},"repository":{"type":"git","url":"git+https://github.com/node-gfx/image-data.git"},"versions":{"1.0.0":{"name":"@canvas/image-data","version":"1.0.0","license":"MIT","repository":{"type":"git","url":"git+https://github.com/node-gfx/image-data.git"},"browser":"browser.js","scripts":{"test":"standard && nyc --check-coverage --lines=100 node test"},"devDependencies":{"nyc":"^13.1.0","standard":"^12.0.1"},"gitHead":"73a842f9f0baa499869304e450d6dcdac72c2101","description":"An `ImageData` implementation for usage outside of the browser.","bugs":{"url":"https://github.com/node-gfx/image-data/issues"},"homepage":"https://github.com/node-gfx/image-data#readme","_id":"@canvas/image-data@1.0.0","_npmVersion":"6.4.1","_nodeVersion":"11.1.0","_npmUser":{"name":"linusu","email":"linus@folkdatorn.se"},"dist":{"shasum":"3bd2cd856e13fc9e2c25feff360a4056857b0367","size":3034,"noattachment":false,"key":"/@canvas/image-data/-/@canvas/image-data-1.0.0.tgz","tarball":"http://registry.cnpm.dingdandao.com/@canvas/image-data/download/@canvas/image-data-1.0.0.tgz"},"maintainers":[{"name":"linusu","email":""}],"directories":{},"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/image-data_1.0.0_1542744270418_0.4642184265344771"},"_hasShrinkwrap":false,"publish_time":1542744270525,"_cnpm_publish_time":1542744270525,"_cnpmcore_publish_time":"2021-12-16T23:42:50.562Z"}},"readme":"# ImageData\n\nAn `ImageData` implementation for usage outside of the browser.\n\n## Installation\n\n```sh\nnpm install --save @canvas/image-data\n```\n\n## Usage\n\n```js\nconst ImageData = require('@canvas/image-data')\n\nconst img = new ImageData(2, 4)\n\nconsole.log(img.width)\n//=> 2\n\nconsole.log(img.height)\n//=> 4\n\nconsole.log(img.data)\n//=> Uint8ClampedArray [ 0, 0, 0, 0, 0, ... ]\n```\n\n## Hacking\n\nThe tests are made to be run against both this implementation and Chrome's implementation to make sure that we behave in the same way. You can run the tests in Chrome by spinning up a local web server and open `test.html`.\n","_attachments":{},"homepage":"https://github.com/node-gfx/image-data#readme","bugs":{"url":"https://github.com/node-gfx/image-data/issues"},"license":"MIT"}