ImageMagick 6.2.7 and background/gravity
Posted: 2008-04-30T01:33:49-07:00
Hello,
I'm having problems with the following command:
convert /var/www/html/ocmwbm00/admin/pdf2swf/tmp/easystar.pdf -resize 400x400 -background white -gravity center -extent 400x400 /var/www/html/ocmwbm00/admin/pdf2swf/tmp/easystar%d.gif
I call this instruction through the exec command in php.
This is our version of imagemagick:
Version: ImageMagick 6.2.7 07/26/06 Q16 http://www.imagemagick.org
Copyright: Copyright (C) 1999-2006 ImageMagick Studio LLC
An example:
I have an image of 800*600. After resize this is 400*300 since I want to keep the aspect ratio. However the actual image has to be 400*400. Therefore I want a background colored white and I want to position the result image in the center of my new image. I have a multipage pdf that I want to convert to a multipage gif.
My result however is an image of 400*400 with a black background and a result image positioned in the top left corner.
Any ideas?
Kind regards,
Roel
I'm having problems with the following command:
convert /var/www/html/ocmwbm00/admin/pdf2swf/tmp/easystar.pdf -resize 400x400 -background white -gravity center -extent 400x400 /var/www/html/ocmwbm00/admin/pdf2swf/tmp/easystar%d.gif
I call this instruction through the exec command in php.
This is our version of imagemagick:
Version: ImageMagick 6.2.7 07/26/06 Q16 http://www.imagemagick.org
Copyright: Copyright (C) 1999-2006 ImageMagick Studio LLC
An example:
I have an image of 800*600. After resize this is 400*300 since I want to keep the aspect ratio. However the actual image has to be 400*400. Therefore I want a background colored white and I want to position the result image in the center of my new image. I have a multipage pdf that I want to convert to a multipage gif.
My result however is an image of 400*400 with a black background and a result image positioned in the top left corner.
Any ideas?
Kind regards,
Roel