{"_id":"get-pixels-frame-info-update","_rev":"1-e0dc81fa9aee46186e0f5993caf7aae2","name":"get-pixels-frame-info-update","dist-tags":{"latest":"3.3.2"},"versions":{"3.3.2":{"name":"get-pixels-frame-info-update","version":"3.3.2","description":"Reads the pixels of an image as an ndarray","main":"node-pixels.js","directories":{"test":"test"},"dependencies":{"data-uri-to-buffer":"0.0.3","jpeg-js":"^0.3.2","mime-types":"^2.0.1","ndarray":"^1.0.13","ndarray-pack":"^1.1.1","node-bitmap":"0.0.1","omggif":"^1.0.5","parse-data-uri":"^0.2.0","pngjs":"^3.3.3","request":"^2.44.0","through":"^2.3.4"},"devDependencies":{"beefy":"^2.1.8","brfs":"^1.2.0","browserify":"^3.44.0","tap":"^10.7.0","tape":"^2.12.3"},"scripts":{"test":"tap test/*.js","test-browser":"beefy test/test.js --open  -- -t brfs"},"repository":{"type":"git","url":"git://github.com/scijs/get-pixels.git"},"keywords":["ndarray","pixel","get","read","pixel","image","png","jpeg","jpg","jpe","gif","decode","buffer","data","parse","dom","node","browserify"],"browser":"dom-pixels.js","author":{"name":"Mikola Lysenko"},"license":"MIT","gitHead":"380bbda330666e4a4066c48ef5a42770d13bcd5c","bugs":{"url":"https://github.com/scijs/get-pixels/issues"},"homepage":"https://github.com/scijs/get-pixels#readme","_id":"get-pixels-frame-info-update@3.3.2","_npmVersion":"6.4.1","_nodeVersion":"8.9.0","_npmUser":{"name":"benwiley4000","email":"therealbenwiley@gmail.com"},"dist":{"integrity":"sha512-LzVij57X/gK4Y6LpcDdqj+R9WCpD6Sv3ZH85GMA+S3xgPGCz81mHql4GiSnF4GijRjk7TE0ja2sDr8FFYKLe2g==","shasum":"8b549efcb570454094e5a9dc51d61cb9a62cdb4f","tarball":"https://registry.npmjs.org/get-pixels-frame-info-update/-/get-pixels-frame-info-update-3.3.2.tgz","fileCount":5,"unpackedSize":12337,"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v3.0.4\r\nComment: https://openpgpjs.org\r\n\r\nwsFcBAEBCAAQBQJbxJSVCRA9TVsSAnZWagAAmywP/iU14D48e8rNWY6uY5fC\nuI3tond5CVxWw15hVozlRsn3pVy1x6vvvr53ibC/ltXi20jucKknIRhrCoZY\nBFJO6vKB0o8py1DT8dQjF61/+JrOqQ35EgS5K9L+zAg6+LBQ05UFRplE147j\nooejKl8q3IvZvDcV3df5MyX2peH6qGf7tpICdfooC9dxK+WiCoXFwN1sK+k0\nS49xQbyTj2r06kU/mz8IrqEx5pIVN6+qCGdOgDCFz3+ZUA0GNlvMhh0OHXUF\n+GB5kpdEiFTizO04c5IKfgPZb1yJbKSla/Nnnsw9NpIOLyTxODTdZpm7d1r4\n3v09yMgOGcsh6TCLivDZMT35eGwLJsQQHlHaVuVCfG2NEbqb58TB9WSA90J/\nbjcs538FPCoPNJXghPzpXWttZbtDI7hpsHqxU7MLNjuUjdkiv8+JsBTv+voO\nJ2WGPhCVArOcPsX5WNqj7nYdFhf0BGu50jl2ii9tfxVh+3BuB3FL6xgX95Hb\nGkJlR9nzbhChxWyDTtCO19x98ovePW6CfuRIN/EhsK0ZoJe9gueLqCjhSwAi\nQfUtFyurLLbe02cjCEO7ycjuF0smpYqJz+48qDWpl2jZBeQx994Ri51pHKRG\nsVBh7H3mxzjFUGdOx/LUO4RzrQ7Y2xbv71mFsE6+4669Gyzv1+16IU040p6L\ncOY1\r\n=Rcq2\r\n-----END PGP SIGNATURE-----\r\n","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEUCIBILvttXoMcEt2R4HmtsIrhHj/4qQB1TEpuJnmW7uePQAiEAo7gHuNPGeaBxgOzP3Hs50leThCUIGLoLIEIBpEJm/BA="}]},"maintainers":[{"name":"benwiley4000","email":"therealbenwiley@gmail.com"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/get-pixels-frame-info-update_3.3.2_1539609748970_0.2070214486579136"},"_hasShrinkwrap":false}},"time":{"created":"2018-10-15T13:22:28.969Z","3.3.2":"2018-10-15T13:22:29.080Z","modified":"2022-05-03T14:54:52.529Z"},"maintainers":[{"name":"benwiley4000","email":"therealbenwiley@gmail.com"}],"description":"Reads the pixels of an image as an ndarray","homepage":"https://github.com/scijs/get-pixels#readme","keywords":["ndarray","pixel","get","read","pixel","image","png","jpeg","jpg","jpe","gif","decode","buffer","data","parse","dom","node","browserify"],"repository":{"type":"git","url":"git://github.com/scijs/get-pixels.git"},"author":{"name":"Mikola Lysenko"},"bugs":{"url":"https://github.com/scijs/get-pixels/issues"},"license":"MIT","readme":"get-pixels\n==========\nGiven a URL/path, grab all the pixels in an image and return the result as an [ndarray](https://github.com/mikolalysenko/ndarray).  Written in 100% JavaScript, works both in browserify and in node.js and has no external native dependencies.\n\nCurrently the following file formats are supported:\n\n* `PNG`\n* `JPEG`\n* `GIF`\n\nExample\n=======\n\n```javascript\nvar getPixels = require(\"get-pixels\")\n\ngetPixels(\"lena.png\", function(err, pixels, frameInfo) {\n  if(err) {\n    console.log(\"Bad image path\")\n    return\n  }\n  console.log(\"got pixels\", pixels.shape.slice())\n})\n```\n\nInstall\n=======\n\n    npm install get-pixels\n\n### `require(\"get-pixels\")(url[, type], cb(err, pixels, frameInfo))`\nReads all the pixels from url into an ndarray.\n\n* `url` is the path to the file.  It can be a relative path, an http url, a data url, or an [in-memory Buffer](http://nodejs.org/api/buffer.html).\n* `type` is an optional mime type for the image (required when using a Buffer)\n* `cb(err, pixels, framesInfo)` is a callback which gets triggered once the image is loaded.\n\n**Returns** An ndarray of pixels in raster order having shape equal to `[width, height, channels]` and **frameInfo** param if available (for animated GIFs).\n\n**Note** For animated GIFs, a 4D array is returned with shape `[numFrames, width, height, 4]`, where each frame is a slice of the final array.\n\n**frameInfo** is an Array of Objects with these fields:\n\nName|Type|Description\n----|-----|-----------\nx | Integer | Image Left Position\ny | Integer | Image Top Position\nwidth | Integer | Image Width\nheight | Integer | Image Height\nhas_local_palette | Boolean | Image local palette presentation flag\npalette_offset | Integer | Image palette offset\npalette_size | Integer | Image palette size\ndata_offset | Integer | Image data offset\ndata_length | Integer | Image data length\ntransparent_index | Integer | Transparent Color Index\ninterlaced | Boolean | Interlace Flag\ndelay | Integer | Delay Time (1/100ths of a second)\ndisposal | Integer | Disposal method\n\nSee GIF spec for details. Summary http://www.onicos.com/staff/iz/formats/gif.html\n\n\nCredits\n=======\n(c) 2013-2014 Mikola Lysenko. MIT License\n","readmeFilename":"README.md"}