PixelPng
Parse PNG to ImageData in cross-platform.
Installation
$ npm install pixel-png --save
var pixelPng= ;console; //function
API
file
) -> promise.then(images
)
pixelPng.parse(return images
is Array contains one or more ImageData
.
Return the
object
instead ofImageData
at Node.js
var file= 'https://59naga.github.io/fixtures/animated.PNG'; pixelPng;// { width: 73, height: 73, left: 0, top: 0, delay: 1000, disposeOp: 0, blendOp: 0, data: <Uint8Array ..> }// { width: 14, height: 24, left: 48, top: 23, delay: 900, disposeOp: 2, blendOp: 1}// { width: 1, height: 1, left: 0, top: 0, delay: 800, disposeOp: 0, blendOp: 0}// ...