Page 1 of 1

feature request: splicing with transparency

Posted: 2006-11-04T15:24:49-07:00
by RetroJ
Hi,
I would like to be able to -splice with a transparent color when the image I am operating on does not necessarily already have an alpha channel. What are your thoughts on this patch:

http://jjfoerch.com/bitbucket/splice-transparency.diff

Code: Select all

--- ImageMagick-6.3.0/magick/transform.c	2006-07-03 13:23:05.000000000 -0400
+++ ImageMagick-6.3.0-tmp/magick/transform.c	2006-11-04 14:46:47.000000000 -0500
@@ -1210,6 +1210,8 @@
       splice_image=DestroyImage(splice_image);
       return((Image *) NULL);
     }
+  if (splice_image->background_color.opacity != OpaqueOpacity)
+      splice_image->matte=MagickTrue;
   /*
     Splice image.
   */

Posted: 2006-11-04T16:21:39-07:00
by magick
We'll get your patch into ImageMagick 6.3.0-3 Beta. Thanks.

Posted: 2006-11-04T16:39:06-07:00
by RetroJ
Thanks!