문제

I am using Imagemagick to convert a single page PDF into a GIF image. Here is my exec command that I run from PHP:

exec("convert -density 600x600 -background white ".$filenamePDF."[0] -scale 700x989 ".$filenameJPG."[0]");

Source PDF: http://www.buzzbuzzbingo.com/images/pdf/185/InternetSafety-4185.pdf

Resultant GIF: http://www.buzzbuzzbingo.com/images/pdf/screenshot/185/InternetSafety-4185.gif

All that works fine but when I pin this image to Pinterest, it appears "snowy" like an old black and white TV that is broken.

Here's the "snowy" image on the pinned page: http://pinterest.com/pin/559783428652943247/

Is this a problem with how I am converting the PDF or an issue with the source PDF? Or could this be a problem with how Pinterest generates their version?

I should add that while pinning, it looks fine as a thumbnail but it appears "snowy" on it's pinned page, and clicking through to the full size it looks perfect.

도움이 되었습니까?

해결책

I solved my issue by converting it into a JPG instead of a GIF.

Pinterest replied to my bug report with:

"It looks like this issue is related to how you are converting this image using Imagemagick. Unfortunately, we do not offer support around using this program, so you will need to fool around in Imagemagick to see if you can create a file that works."

I can confirm that by using a JPG instead, Pinterest no longer has the snowy image issue.

라이센스 : CC-BY-SA ~와 함께 속성
제휴하지 않습니다 StackOverflow
scroll top