timotgl / inspector-bokeh

Canvas-based blur detection with JavaScript
MIT License
45 stars 13 forks source link

Inspector Bokeh

Experimental JavaScript library to measure blur in images. Try out the live demo or read this blog post to find out more.

Setup

  1. You need Node.js.
  2. Make sure Cairo is installed in your system, the canvas module requires this. How to install node-canvas.
    • On OS X or macOS with Homebrew: brew install pkg-config cairo pango libpng jpeg giflib librsvg
  3. npm install

Usage

Simply run npm start path/to/image/file.jpg

Troubleshooting

On macOS 12 Monterey: canvas.node can’t be opened

Full error message:

“canvas.node” can’t be opened because Apple cannot check it for malicious software.

This software needs to be updated. Contact the developer for more information.

This possibly happens only if you cloned this repo onto a Volume mounted from a disk image file (.dmg). The reason is macOS' Gatekeeper trying to protect you from running software from an "unidentified developer".