{"_id":"save-pixels-jpeg-js-upgrade","_rev":"1-df9e0c66e213ad50b31bd22cd2773b1d","name":"save-pixels-jpeg-js-upgrade","description":"Saves an ndarray as an image to a file","dist-tags":{"latest":"2.3.4-jpeg-js-upgrade.0"},"versions":{"2.3.4-jpeg-js-upgrade.0":{"name":"save-pixels-jpeg-js-upgrade","version":"2.3.4-jpeg-js-upgrade.0","description":"Saves an ndarray as an image to a file","main":"save-pixels.js","directories":{"example":"example","test":"test"},"dependencies":{"contentstream":"^1.0.0","gif-encoder":"~0.4.1","jpeg-js":"^0.3.2","ndarray":"^1.0.18","ndarray-ops":"^1.2.2","pngjs-nozlib":"^1.0.0","through":"^2.3.4"},"devDependencies":{"get-pixels":"^3.0.1","ndarray-scratch":"^1.1.1","tap":"^10.7.0","tape":"^3.0.1"},"scripts":{"test":"tap test/*.js"},"repository":{"type":"git","url":"git://github.com/mikolalysenko/save-pixels.git"},"keywords":["save","pixel","image","png","ndarray"],"author":{"name":"Mikola Lysenko"},"license":"MIT","gitHead":"fda0977a1a5f2797d66f1557ffecc8c2dc759a47","bugs":{"url":"https://github.com/mikolalysenko/save-pixels/issues"},"homepage":"https://github.com/mikolalysenko/save-pixels#readme","_id":"save-pixels-jpeg-js-upgrade@2.3.4-jpeg-js-upgrade.0","_npmVersion":"5.1.0","_nodeVersion":"8.1.2","_npmUser":{"name":"benwiley4000","email":"therealbenwiley@gmail.com"},"dist":{"integrity":"sha512-mFeQrydaAVTYQjywMvuNtjHmYZwAXZlo96Xouh3I7wTYDdUhMttoEPQsfk6EP+Wxt+fo/B8SW/A8dfhBImhKIw==","shasum":"1385d0872883f7db161fc48130df72b6684dc68c","tarball":"https://registry.npmjs.org/save-pixels-jpeg-js-upgrade/-/save-pixels-jpeg-js-upgrade-2.3.4-jpeg-js-upgrade.0.tgz","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEYCIQCn9pabfTfgp9E8fxeHmkydbQy1btv5tF7afqV8BZqx+gIhAIs7tTLVIfnuugwiy13hvSvTKydZVIjN+mrQ4RrQI+SW"}]},"maintainers":[{"name":"benwiley4000","email":"therealbenwiley@gmail.com"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/save-pixels-jpeg-js-upgrade-2.3.4-jpeg-js-upgrade.0.tgz_1499918394525_0.48098282259888947"}}},"readme":"save-pixels\n===========\n**WILL NOT BE MAINTAINED; published fork pending update of main save-pixels package.**\n\nSaves an ndarray to an image.\n\nExample\n=======\n```javascript\nvar zeros = require(\"zeros\")\nvar savePixels = require(\"save-pixels\")\n\n//Create an image\nvar x = zeros([32, 32])\nx.set(16, 16, 255)\n\n//Save to a file\nsavePixels(x, \"png\").pipe(process.stdout)\n```\n\nThis writes the foll owing image to stdout:\n\n<img src=https://raw.github.com/mikolalysenko/save-pixels/master/example/example.png>\n\nInstall\n=======\n\n    npm install save-pixels\n\n### `require(\"save-pixels\")(array, type[, options])`\nSaves an ndarray as an image with the given format\n\n* `array` is an `ndarray` of pixels.  Assumes that shape is `[width, height, channels]`\n* `type` is the type of the image to save.  Currently supported formats:\n\n  + `\"jpeg\"`, `\"jpg\"` - Joint Photographic Experts Group format\n  + `\"gif\"` - Graphics Interchange Format\n  + `\"png\"` - Portable Network Graphics format\n  + `\"canvas\"` - A canvas element\n\n* `options` is an object that alters saving behavior\n\n  + `quality` is the `Number` to use for saved image quality\n\n    + This can only be used with a `\"jpeg\"` image\n    + It range between 1 (low quality) and 100 (high quality) inclusively\n\n**Returns** A stream that you can pipe to serialize the result, or a canvas element if the `type` is `\"canvas\"`.\n\n# Credits\n(c) 2013 Mikola Lysenko. MIT License\n","maintainers":[{"name":"benwiley4000","email":"therealbenwiley@gmail.com"}],"time":{"modified":"2022-05-17T04:08:11.443Z","created":"2017-07-13T03:59:55.459Z","2.3.4-jpeg-js-upgrade.0":"2017-07-13T03:59:55.459Z"},"homepage":"https://github.com/mikolalysenko/save-pixels#readme","keywords":["save","pixel","image","png","ndarray"],"repository":{"type":"git","url":"git://github.com/mikolalysenko/save-pixels.git"},"author":{"name":"Mikola Lysenko"},"bugs":{"url":"https://github.com/mikolalysenko/save-pixels/issues"},"license":"MIT","readmeFilename":"README.md"}