When converting a PDF with images with transparency, the output ends up with a black background
convert -density 300 -background white -alpha off \
-resize 80x80 -strip -quality 70 file.pdf[0] thumb.jpg[0]
Have tried to set the background to white and deactivate alpha, but the background still ends up black!?
Test file
http://www.bluemachines.dk/pdf/trans.pdf
Have tested on these two versions so it looks like a generel "issue"
ImageMagick-6.8.8-10
ImageMagick-6.7.7-10
# /var/bin/ImageMagick-6.8.8-10/utilities/convert
Version: ImageMagick 6.8.8-10 Q16 x86_64 2014-04-10
# gs -v
GPL Ghostscript 9.14 (2014-03-26)
Here is the output file
http://www.bluemachines.dk/pdf/thumb.jpg
Can't post that much in the body so the output is pasted into this txt file
http://www.bluemachines.dk/pdf/debug.txt
You should use -alpha remove instead of -alpha off. And I would advise you to change the order of your arguments to this:
convert -density 300 file.pdf[0] -resize 80x80 -background white -alpha remove \
-strip -quality 70 thumb.jpg
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With