Post any defects you find in the released or beta versions of the ImageMagick software here. Include the ImageMagick version, OS, and any command-line required to reproduce the problem. Got a patch for a bug? Post it here.
Use the +repage option to get rid of the offset information left over from the cropping operation. Also it's best to put the processing options after reading the input image:
How should I have know to do this? I have gone over the doc for -extract and crop many times now and see no indication that there is some residual information nor of the need to "repage".
How should I have know to do this? I have gone over the doc for -extract and crop many times now and see no indication that there is some residual information nor of the need to "repage".
I suppose it's easy to miss, but the last paragraph under the -crop section of the command-line options says
It might be necessary to +repage the image prior to cropping the image to ensure
the crop coordinate frame is relocated to the upper-left corner of the visible image.
I don't know if it will help much, but I'm adding
This is especially true when you are going to write to an image format such
as PNG that supports an image offset.