jimp-dev/jimp

Autocrop not cropping surrounding black area

Open

#753 opened on Jun 18, 2019

View on GitHub
 (3 comments) (0 reactions) (0 assignees)JavaScript (13,218 stars) (785 forks)batch import
bughelp wantedsolution in issue

Description

Large Black borders should have cropped out. I have adjusted the tolerance and have see no change in results. They are simply not getting cropped.

Latest Node and Jimp on a Raspberry Pi

   Jimp.read( "./scanimage.jpg", (err, img) => {
        if (err) throw err;
        let clean = img
        .scale(0.5)
        .quality(50)
        .autocrop()
        .write('./croppedimage.jpg')

test

Contributor guide