The morass of compose and alpha
Posted: 2013-12-12T07:50:04-07:00
I wish to do something pretty simple;
I have an RGB image (let's call it a character, say "snoopy");
I wish to make an animation of small snoopy moving (sliding, really) across a large RGB background image, so a programmed sequence
of blits to successive (x,y) coordinates on the background will suit. ffmpeg can then make my frames into a video.
I would like snoopy not to be rectangular, so I have a gray scale mask (snoopy_shape).
I think all I need to do is first add the "snoopy_shape" to "snoopy" to make
an alpha'd snoopy ("snoopy_with_a_shape"), and then composite
snoopy_with_a_shape onto background at an x,y offset.
But I have just spent an hour reading manuals and (principally)
Anthony Thyssen's "Examples of ImageMagick Usage", and while
I now know quite a lot about the history of ImageMagick's handling
of transparency, various workrounds, old command line options, new
command line options, I'm no nearer knowing
the 2 commands I indeed to perform a masked blit operation.
Can anyone help?
I have an RGB image (let's call it a character, say "snoopy");
I wish to make an animation of small snoopy moving (sliding, really) across a large RGB background image, so a programmed sequence
of blits to successive (x,y) coordinates on the background will suit. ffmpeg can then make my frames into a video.
I would like snoopy not to be rectangular, so I have a gray scale mask (snoopy_shape).
I think all I need to do is first add the "snoopy_shape" to "snoopy" to make
an alpha'd snoopy ("snoopy_with_a_shape"), and then composite
snoopy_with_a_shape onto background at an x,y offset.
But I have just spent an hour reading manuals and (principally)
Anthony Thyssen's "Examples of ImageMagick Usage", and while
I now know quite a lot about the history of ImageMagick's handling
of transparency, various workrounds, old command line options, new
command line options, I'm no nearer knowing
the 2 commands I indeed to perform a masked blit operation.
Can anyone help?