Enlightenment CVS committal
Author : raster
Project : e17
Module : libs/evas
Dir : e17/libs/evas/src/modules/loaders/gif
Modified Files:
evas_image_load_gif.c
Log Message:
cedric's cache changes patch
===================================================================
RCS file: /cvs/e/e17/libs/evas/src/modules/loaders/gif/evas_image_load_gif.c,v
retrieving revision 1.5
retrieving revision 1.6
diff -u -3 -r1.5 -r1.6
--- evas_image_load_gif.c 5 Nov 2006 05:07:52 -0000 1.5
+++ evas_image_load_gif.c 12 Apr 2008 00:32:29 -0000 1.6
@@ -94,15 +94,8 @@
} while (rec != TERMINATE_RECORD_TYPE);
if (alpha >= 0) im->flags |= RGBA_IMAGE_HAS_ALPHA;
- if (!im->image)
- im->image = evas_common_image_surface_new(im);
- if (!im->image)
- {
- DGifCloseFile(gif);
- return 0;
- }
- im->image->w = w;
- im->image->h = h;
+ im->cache_entry.w = w;
+ im->cache_entry.h = h;
DGifCloseFile(gif);
return 1;
@@ -241,20 +234,9 @@
} while (rec != TERMINATE_RECORD_TYPE);
if (alpha >= 0) im->flags |= RGBA_IMAGE_HAS_ALPHA;
- if (!im->image)
- im->image = evas_common_image_surface_new(im);
- if (!im->image)
- {
- DGifCloseFile(gif);
- return 0;
- }
- im->image->w = w;
- im->image->h = h;
-
- evas_common_image_surface_alloc(im->image);
- if (!im->image->data)
+ evas_cache_image_surface_alloc(&im->cache_entry, w, h);
+ if (!im->image.data)
{
- evas_common_image_surface_free(im->image);
DGifCloseFile(gif);
for (i = 0; i < h; i++)
{
@@ -267,7 +249,7 @@
bg = gif->SBackGroundColor;
cmap = (gif->Image.ColorMap ? gif->Image.ColorMap : gif->SColorMap);
- ptr = im->image->data;
+ ptr = im->image.data;
per_inc = 100.0 / (((double)w) * h);
for (i = 0; i < h; i++)
-------------------------------------------------------------------------
This SF.net email is sponsored by the 2008 JavaOne(SM) Conference
Don't miss this year's exciting event. There's still time to save $100.
Use priority code J8TL2D2.
http://ad.doubleclick.net/clk;198757673;13503038;p?http://java.sun.com/javaone
_______________________________________________
enlightenment-cvs mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/enlightenment-cvs