From 2b9539c1ff80299b076dae102fc430786a86bae9 Mon Sep 17 00:00:00 2001 From: scuri Date: Tue, 18 Aug 2009 05:13:18 +0000 Subject: *** empty log message *** --- src/im_convertcolor.cpp | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) (limited to 'src') diff --git a/src/im_convertcolor.cpp b/src/im_convertcolor.cpp index 8e96ccc..e68730f 100644 --- a/src/im_convertcolor.cpp +++ b/src/im_convertcolor.cpp @@ -2,7 +2,7 @@ * \brief Image Conversion * * See Copyright Notice in im_lib.h - * $Id: im_convertcolor.cpp,v 1.2 2009/08/18 02:23:33 scuri Exp $ + * $Id: im_convertcolor.cpp,v 1.3 2009/08/18 05:13:18 scuri Exp $ */ #include "im.h" @@ -963,6 +963,8 @@ int imConvertColorSpace(const imImage* src_image, imImage* dst_image) imbyte* transp_color = (imbyte*)imImageGetAttribute(src_image, "TransparencyColor", NULL, NULL); if (transp_color) iConvertSetTranspColor((imbyte**)dst_image->data, dst_image->count, *(transp_color+0), *(transp_color+1), *(transp_color+2)); + else + memset(dst_image->data[3], 255, dst_image->count); } else { @@ -973,6 +975,8 @@ int imConvertColorSpace(const imImage* src_image, imImage* dst_image) iConvertSetTranspMap((imbyte*)src_image->data[0], (imbyte*)dst_image->data[3], dst_image->count, transp_map, transp_count); else if (transp_index) iConvertSetTranspIndex((imbyte*)src_image->data[0], (imbyte*)dst_image->data[3], dst_image->count, *transp_index); + else + memset(dst_image->data[3], 255, dst_image->count); } } -- cgit v1.2.3