using -shave or -trim drastically reduces image quality

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?".
Post Reply
bastardo
Posts: 5
Joined: 2011-11-29T20:27:32-07:00
Authentication code: 8675308

using -shave or -trim drastically reduces image quality

Post by bastardo »

I have a pdf file which is a book scanned at 300 dpi black & white, 1 bit per pixel. I can never get the paper aligned just so in the scanner, so I get a bit of a border I'd like to trim off. So, I run:

convert in.pdf -shave 20x20 out.pdf

which certainly does shave 20 pixels off of each side of each page in the pdf. However, the resulting images are seriously degraded. After the shave the text is so degraded it is unreadable.

How can I do the convert and maintain the image quality?
User avatar
fmw42
Posts: 25562
Joined: 2007-07-02T17:14:51-07:00
Authentication code: 1152
Location: Sunnyvale, California, USA

Re: using -shave or -trim drastically reduces image quality

Post by fmw42 »

what is your version of IM an platform? can you post a link to your input image?
Post Reply