imagejs/imagejs.github.com — pull request #14 by agrueneberg (2012-04-11 22:07:16+00:00)
Title: Fix crash on certain images.

canvas.toDataURL crashes for certain images and there doesn't seem to be a way to fix that. An alternative is to use canvas.toBlob, however, it requires a different way to save the file. I decided to use the simple FileSaver API.
Neither canvas.toBlob nor the FileSaver API are currently natively supported in Chrome, but polyfills exist.