Enlightenment CVS committal
Author : raster
Project : e17
Module : libs/evas
Dir : e17/libs/evas/src/modules/loaders/tiff
Modified Files:
evas_image_load_tiff.c
Log Message:
more commit....
===================================================================
RCS file: /cvs/e/e17/libs/evas/src/modules/loaders/tiff/evas_image_load_tiff.c,v
retrieving revision 1.4
retrieving revision 1.5
diff -u -3 -r1.4 -r1.5
--- evas_image_load_tiff.c 6 Sep 2006 07:28:46 -0000 1.4
+++ evas_image_load_tiff.c 30 Sep 2006 10:21:23 -0000 1.5
@@ -97,11 +97,11 @@
r = TIFFGetR(pixel_value);
g = TIFFGetG(pixel_value);
b = TIFFGetB(pixel_value);
- if ((a > 0) && (a < 255) && (alpha_premult))
+ if (!alpha_premult && (a < 255))
{
- r = (r * 255) / a;
- g = (g * 255) / a;
- b = (b * 255) / a;
+ r = (r * (a + 1)) >> 8;
+ g = (g * (a + 1)) >> 8;
+ b = (b * (a + 1)) >> 8;
}
(*(buffer_pixel++)) = (a << 24) | (r << 16) | (g << 8) | b;
}
@@ -313,6 +313,7 @@
TIFFClose(tif);
+ evas_common_image_set_alpha_sparse(im);
return 1;
}
-------------------------------------------------------------------------
Take Surveys. Earn Cash. Influence the Future of IT
Join SourceForge.net's Techsay panel and you'll get the chance to share your
opinions on IT & business topics through brief surveys -- and earn cash
http://www.techsay.com/default.php?page=join.php&p=sourceforge&CID=DEVDEV
_______________________________________________
enlightenment-cvs mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/enlightenment-cvs