Replace transparency in PNG images with white background

后端 未结 16 709
再見小時候
再見小時候 2020-11-29 14:48

I\'ve got some PNG images with transparency, and I need to create versions with the image layer composed onto a white background. I\'ve tried various things with Image Magi

16条回答
  •  时光取名叫无心
    2020-11-29 15:27

    Flattening image and applying background image is straight forward in ImageMagick

    However, order of the commands is very important

    To apply any background on a transparent image and flatten it, first apply the background than flatten it. The reverse doesn't work.

    $ convert sourceimage.png -background BackgroundColor -flatten destinationimage.png
    

提交回复
热议问题