Questions and postings pertaining to the usage of ImageMagick regardless of the interface. This includes the command-line utilities, as well as the C and C++ APIs. Usage questions are like "How do I use ImageMagick to create drop shadows?".
Unfortunately there are a very few isolated white pixels (groups of 1or 2 generally) in the background that are preventing a complete trimming of the pictures... I'm trying to remove these. I tried to adapt some code I found online using connected-components:
It works fine on text pages but it produces very large files (60 Mo vs 3.9 Mo for the normal files) and it does not work on the plates of the book I scanned because objects are drawn with lots of small dots...
There are many way to denoise an image. When the noise is small dark marks on a light background, we can blur then threshold. This finds the trimmed parameters from a denoised image, and uses those parameters on the input image.
Unfortunately, as these are monochromatic images with only black and white pixels, the blur did not have much effect on the white pixels on the black borders I want to remove... I would like to remove these so that I could just use make an automatic crop with -trim.