Converting PDF files

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
michaelmuller

Converting PDF files

Post by michaelmuller »

I am having trouble getting vector-based PDF files to convert to PNG without horrible aliasing going on when setting a transparency color. I can provide examples if needed.

-fuzz 10% -transparent white -resize 200

Anyone have any switch advice?

Mik
User avatar
fmw42
Posts: 25562
Joined: 2007-07-02T17:14:51-07:00
Authentication code: 1152
Location: Sunnyvale, California, USA

Re: Converting PDF files

Post by fmw42 »

if your pdf is cmyk, then

convert -colorspace rgb image.pdf .... result.png

To get higher quality, do supersampling by reading in the pdf at higher resolution, then resizing afterwards, e.g.

convert -density 288 image.pdf -resize 25% ... result.png

density 288 = 4*72 dpi, so you need to resize by 1/4=25% to compensate back again.
Post Reply