This post originated from an RSS feed registered with Java Buzz
by Tim Vernum.
Original Post: Image Magick - Montage with Transparency
Feed Title: A word used to describe something
Feed URL: http://blog.adjective.org/feed/category/Development/rss2
Feed Description: Tim's random musings on software development, java, jetty and other such frivolities.
I wrestled with this problem for a long time before I found the solution, so
I'm posting it here.
I had a series of PNG images that I wanted to montage together to I could
use them as a single background-image in some css. However, the output montage
appeared to lose all the transparency from the input images - the result kept
coming out with white where it should be transparent.
I spent a lot of time trying to work out why IM was ignoring my alpha
channel - but that's not what was happening.
The problem was that montage by default creates a white background over the
whole of the output image. So in fact IM was "correctly" tiling my alpha-aware
images on top of a white background.