Skip to content

Instantly share code, notes, and snippets.

@alfredwesterveld
Created January 19, 2020 22:17
Show Gist options
  • Save alfredwesterveld/f611e5e277cd55ab2ac27c0fde309598 to your computer and use it in GitHub Desktop.
Save alfredwesterveld/f611e5e277cd55ab2ac27c0fde309598 to your computer and use it in GitHub Desktop.
ssim
const Jimp = require("jimp")
const {ssim} = require('ssim.js')
Jimp.read("./ref.gif", function (err, image) {
if (err) {
console.log(err)
} else {
const buf = image.getBuffer();
const out = ssim(buf, buf);
console.log(out);
}
})
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment