Hi!
Hope someone can help me with that...
I would like to resize a pic to fill a given space with a certain background image. Its working fine with a color, but how can I do this with a background image (gif)?
With color it works fine:
convert myimage.gif -resize 300x300 -size 300x300 xc:#fff +swap -gravity center -composite mynewimage.gif
but if you would like to have a background image... can someone help me with that please?
Resizing to Fill a Given Space
- anthony
- Posts: 8883
- Joined: 2004-05-31T19:27:03-07:00
- Authentication code: 8675308
- Location: Brisbane, Australia
Re: Resizing to Fill a Given Space
IM Examples, Thumbnails...
Anthony Thyssen -- Webmaster for ImageMagick Example Pages
https://imagemagick.org/Usage/
https://imagemagick.org/Usage/
Re: Resizing to Fill a Given Space
hmm, I did already searching for an example... but I did not find one! that's the reason, why I am posting here.
Can you give me a hint?
Regards
Can you give me a hint?
Regards
- anthony
- Posts: 8883
- Joined: 2004-05-31T19:27:03-07:00
- Authentication code: 8675308
- Location: Brisbane, Australia
Re: Resizing to Fill a Given Space
The example used gradient: for the background image...
Last example in 'padding out an image'
http://www.imagemagick.org/Usage/thumbnails/#pad
Just replace gradient: with the background GIF image
Last example in 'padding out an image'
http://www.imagemagick.org/Usage/thumbnails/#pad
Just replace gradient: with the background GIF image
Anthony Thyssen -- Webmaster for ImageMagick Example Pages
https://imagemagick.org/Usage/
https://imagemagick.org/Usage/