{"_id":"@bouzuya/compare-images","_rev":"3-e01bd973ac44e75866c1917a44f32e8b","name":"@bouzuya/compare-images","description":"A library to compare images for Node.js","dist-tags":{"latest":"0.2.0"},"versions":{"0.1.0":{"name":"@bouzuya/compare-images","description":"A library to compare images for Node.js","version":"0.1.0","author":{"name":"bouzuya","email":"m@bouzuya.net","url":"http://bouzuya.net/"},"babel":{"presets":["power-assert"]},"bugs":{"url":"https://github.com/bouzuya/node-compare-images/issues"},"devDependencies":{"@types/node":"^8.5.2","@types/power-assert":"^1.4.29","babel-cli":"^6.26.0","babel-preset-power-assert":"^1.0.0","beater":"^5.0.1","cpx":"^1.5.0","npm-run-all":"^4.1.2","power-assert":"^1.4.4","rimraf":"^2.6.2","tap-dot-b":"^0.1.0","tslint":"^5.8.0","typescript":"^2.6.2","watch":"^1.0.2"},"files":["lib/"],"homepage":"https://github.com/bouzuya/node-compare-images#readme","keywords":[],"license":"MIT","main":"lib/index.js","repository":{"type":"git","url":"git+https://github.com/bouzuya/node-compare-images.git"},"scripts":{"build":"npm-run-all -s \"build:lint\" \"build:es2015\" \"build:es5\" \"build:lib\"","build:es2015":"tsc","build:es5":"babel -q -d \".tmp/es5/\" \".tmp/es2015/\"","build:lib":"cpx \".tmp/es2015/src/**/*.{js,ts}\" \"lib/\"","build:lint":"tslint --project tsconfig.json","clean":"rimraf \".tmp\" \"lib\"","prepare":"npm-run-all -s \"clean\" \"build\"","test":"node .tmp/es5/test/index.js | tap-dot-b","watch":"npm-run-all -p \"watch:*\"","watch:es2015":"npm run build:es2015 -- --watch","watch:es5":"npm run build:es5 -- --watch","watch:test":"watch \"npm run test\" \".tmp/es5/\""},"gitHead":"d18808afe8a02bfc0ee41bf1cfcee60c15e66418","_id":"@bouzuya/compare-images@0.1.0","_npmVersion":"5.6.0","_nodeVersion":"8.9.3","_npmUser":{"name":"bouzuya","email":"m@bouzuya.net"},"dist":{"integrity":"sha512-TY8UAALxb36eSANtZIrxSEb2mQkOnsLMKI01kpawQnOgiwgQAmGvuF13gzYcnh/shtUzSnL9Sm2Yf/yxGrJW/w==","shasum":"580c087ec4203860ecb1e5a8093816e1234cb302","tarball":"https://registry.npmjs.org/@bouzuya/compare-images/-/compare-images-0.1.0.tgz","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEUCIQDxZ9zI1ZPpTxO3SdGkiXGwJlrG4KGvrL7Rp7oBQfXIQAIgTuvIwJveoeDIkiDanMn/PArgqUe7Sjj4KB/EYKrFGXg="}]},"maintainers":[{"name":"bouzuya","email":"m@bouzuya.net"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/compare-images-0.1.0.tgz_1514989016432_0.7018528468906879"}},"0.1.1":{"name":"@bouzuya/compare-images","description":"A library to compare images for Node.js","version":"0.1.1","author":{"name":"bouzuya","email":"m@bouzuya.net","url":"http://bouzuya.net/"},"babel":{"presets":["power-assert"]},"bugs":{"url":"https://github.com/bouzuya/node-compare-images/issues"},"devDependencies":{"@types/node":"^8.5.2","@types/power-assert":"^1.4.29","babel-cli":"^6.26.0","babel-preset-power-assert":"^1.0.0","beater":"^5.0.1","cpx":"^1.5.0","npm-run-all":"^4.1.2","power-assert":"^1.4.4","rimraf":"^2.6.2","tap-dot-b":"^0.1.0","tslint":"^5.8.0","typescript":"^2.6.2","watch":"^1.0.2"},"files":["lib/"],"homepage":"https://github.com/bouzuya/node-compare-images#readme","keywords":[],"license":"MIT","main":"lib/index.js","repository":{"type":"git","url":"git+https://github.com/bouzuya/node-compare-images.git"},"scripts":{"build":"npm-run-all -s \"build:lint\" \"build:es2015\" \"build:es5\" \"build:lib\"","build:es2015":"tsc","build:es5":"babel -q -d \".tmp/es5/\" \".tmp/es2015/\"","build:lib":"cpx \".tmp/es2015/src/**/*.{js,ts}\" \"lib/\"","build:lint":"tslint --project tsconfig.json","clean":"rimraf \".tmp\" \"lib\"","prepare":"npm-run-all -s \"clean\" \"build\"","test":"node .tmp/es5/test/index.js | tap-dot-b","watch":"npm-run-all -p \"watch:*\"","watch:es2015":"npm run build:es2015 -- --watch","watch:es5":"npm run build:es5 -- --watch","watch:test":"watch \"npm run test\" \".tmp/es5/\""},"types":"lib/index.d.ts","gitHead":"e8e6c59e4d310dd6ac7c4c0b62e628f1cc61d93b","_id":"@bouzuya/compare-images@0.1.1","_npmVersion":"5.6.0","_nodeVersion":"8.9.3","_npmUser":{"name":"bouzuya","email":"m@bouzuya.net"},"dist":{"integrity":"sha512-B/h6w2Js/ESJS+uC+mn6DADCRh+DV+GEYbg4ct8oxTpQYYssr+UiRkn/102+glDItrpcyDg8mTiCsxVWPvX8dA==","shasum":"464d0508b919ad3977ce1616dc8ad7e680ca4d71","tarball":"https://registry.npmjs.org/@bouzuya/compare-images/-/compare-images-0.1.1.tgz","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEQCICs7roPVq+41EKAsn7WF/0IvjxwIYLvvXlWZpFVThIhxAiBE87vjdaiN+zaCqS1ASBLnkY1unr+Abfrq/J9aL0TZAA=="}]},"maintainers":[{"name":"bouzuya","email":"m@bouzuya.net"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/compare-images-0.1.1.tgz_1515300332062_0.790260111913085"}},"0.2.0":{"name":"@bouzuya/compare-images","description":"A library to compare images for Node.js","version":"0.2.0","author":{"name":"bouzuya","email":"m@bouzuya.net","url":"http://bouzuya.net/"},"babel":{"presets":["power-assert"]},"bugs":{"url":"https://github.com/bouzuya/node-compare-images/issues"},"devDependencies":{"@types/node":"^8.5.2","@types/power-assert":"^1.4.29","babel-cli":"^6.26.0","babel-preset-power-assert":"^1.0.0","beater":"^5.0.1","cpx":"^1.5.0","npm-run-all":"^4.1.2","power-assert":"^1.4.4","rimraf":"^2.6.2","tap-dot-b":"^0.1.0","tslint":"^5.8.0","typescript":"^2.6.2","watch":"^1.0.2"},"files":["lib/"],"homepage":"https://github.com/bouzuya/node-compare-images#readme","keywords":[],"license":"MIT","main":"lib/index.js","repository":{"type":"git","url":"git+https://github.com/bouzuya/node-compare-images.git"},"scripts":{"build":"npm-run-all -s \"build:lint\" \"build:es2015\" \"build:es5\" \"build:lib\"","build:es2015":"tsc","build:es5":"babel -q -d \".tmp/es5/\" \".tmp/es2015/\"","build:lib":"cpx \".tmp/es2015/src/**/*.{js,ts}\" \"lib/\"","build:lint":"tslint --project tsconfig.json","clean":"rimraf \".tmp\" \"lib\"","prepare":"npm-run-all -s \"clean\" \"build\"","test":"node .tmp/es5/test/index.js | tap-dot-b","watch":"npm-run-all -p \"watch:*\"","watch:es2015":"npm run build:es2015 -- --watch","watch:es5":"npm run build:es5 -- --watch","watch:test":"watch \"npm run test\" \".tmp/es5/\""},"types":"lib/index.d.ts","gitHead":"1d94ceb72f6de783c65511b5be615dc55a71d972","_id":"@bouzuya/compare-images@0.2.0","_npmVersion":"5.6.0","_nodeVersion":"8.9.3","_npmUser":{"name":"bouzuya","email":"m@bouzuya.net"},"dist":{"integrity":"sha512-H2MhBvgIyR83DXP/hIBOo+kOG6+c6H8TKI4festcEou/vQEp+2cMcNsO0xvLZvaq68tmanpNIqq9MpgWQEh+dg==","shasum":"6576c83783f9edb16ad9a62aa3cce341db37e1f4","tarball":"https://registry.npmjs.org/@bouzuya/compare-images/-/compare-images-0.2.0.tgz","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEUCIDZmhDcH7oja1+cBJXEqMRCYXrD/8N45M/rCsowIlMQ2AiEAzdRSYZG214bQHdG1jyB3tDsWyMsHcjZWfFSm5OnJTLU="}]},"maintainers":[{"name":"bouzuya","email":"m@bouzuya.net"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/compare-images-0.2.0.tgz_1515623382351_0.695612195180729"}}},"readme":"# node-compare-images\n\nA library to compare images for Node.js.\n\n## Installation\n\n```sh\nnpm install @bouzuya/compare-images\n```\n\n## Usage\n\n```js\nimport * as assert from 'assert';\nimport {\n  compareImages,\n  getDiffImage,\n  isSame\n} from '@bouzuya/compare-images';\n\n// image1: { data: Buffer; height: number; width: number; }\nconst image1 = /* ... */;\nconst image2 = /* ... */;\nconst result = compareImages(image1, image2);\nassert(isSame(result) === false);\n// diffImage: { data: Buffer; height: number; width: number; }\nconst diffImage = getDiffImage(result);\n```\n\n```js\nimport * as assert from 'assert';\nimport {\n  compareImages,\n  getDiffDimension,\n  isSameDimension\n} from '@bouzuya/compare-images';\n\n// image1: { data: Buffer; height: number; width: number; }\nconst image1 = /* ... */;\nconst image2 = /* ... */;\nconst result = compareImages(image1, image2);\nassert(isSameDimension(result) === false);\n// diffDimension: {\n//   height: number; // image1.height - image2.height\n//   width: number; // image1.width - image2.width\n// }\nconst diffDimension = getDiffDimension(result);\n```\n\n## Badges\n\n[![npm version][npm-badge-url]][npm-url]\n[![Travis CI][travisci-badge-url]][travisci-url]\n\n[npm-badge-url]: https://img.shields.io/npm/v/@bouzuya/compare-images.svg\n[npm-url]: https://www.npmjs.com/package/@bouzuya/compare-images\n[travisci-badge-url]: https://img.shields.io/travis/bouzuya/node-compare-images.svg?branch=master\n[travisci-url]: https://travis-ci.org/bouzuya/node-compare-images\n\n## License\n\n[MIT](LICENSE)\n\n## Author\n\n[bouzuya][user] &lt;[m@bouzuya.net][email]&gt; ([http://bouzuya.net][url])\n\n[user]: https://github.com/bouzuya\n[email]: mailto:m@bouzuya.net\n[url]: http://bouzuya.net\n","maintainers":[{"name":"bouzuya","email":"m@bouzuya.net"}],"time":{"modified":"2022-04-04T20:16:20.768Z","created":"2018-01-03T14:16:56.509Z","0.1.0":"2018-01-03T14:16:56.509Z","0.1.1":"2018-01-07T04:45:32.293Z","0.2.0":"2018-01-10T22:29:42.467Z"},"homepage":"https://github.com/bouzuya/node-compare-images#readme","keywords":[],"repository":{"type":"git","url":"git+https://github.com/bouzuya/node-compare-images.git"},"author":{"name":"bouzuya","email":"m@bouzuya.net","url":"http://bouzuya.net/"},"bugs":{"url":"https://github.com/bouzuya/node-compare-images/issues"},"license":"MIT","readmeFilename":"README.md"}