aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/libraries/evas/src/modules/loaders/ico
diff options
context:
space:
mode:
Diffstat (limited to 'libraries/evas/src/modules/loaders/ico')
-rw-r--r--libraries/evas/src/modules/loaders/ico/Makefile.am5
-rw-r--r--libraries/evas/src/modules/loaders/ico/Makefile.in11
-rw-r--r--libraries/evas/src/modules/loaders/ico/evas_image_load_ico.c28
3 files changed, 21 insertions, 23 deletions
diff --git a/libraries/evas/src/modules/loaders/ico/Makefile.am b/libraries/evas/src/modules/loaders/ico/Makefile.am
index 044dd0d..5f9b313 100644
--- a/libraries/evas/src/modules/loaders/ico/Makefile.am
+++ b/libraries/evas/src/modules/loaders/ico/Makefile.am
@@ -8,8 +8,7 @@ AM_CPPFLAGS = \
8@FREETYPE_CFLAGS@ \ 8@FREETYPE_CFLAGS@ \
9@PIXMAN_CFLAGS@ \ 9@PIXMAN_CFLAGS@ \
10@EINA_CFLAGS@ \ 10@EINA_CFLAGS@ \
11@EVIL_CFLAGS@ \ 11@EVIL_CFLAGS@
12@WIN32_CPPFLAGS@
13 12
14if BUILD_LOADER_ICO 13if BUILD_LOADER_ICO
15if !EVAS_STATIC_BUILD_ICO 14if !EVAS_STATIC_BUILD_ICO
@@ -27,7 +26,7 @@ else
27 26
28noinst_LTLIBRARIES = libevas_loader_ico.la 27noinst_LTLIBRARIES = libevas_loader_ico.la
29libevas_loader_ico_la_SOURCES = evas_image_load_ico.c 28libevas_loader_ico_la_SOURCES = evas_image_load_ico.c
30libevas_loader_ico_la_LIBADD = 29libevas_loader_ico_la_LIBADD =
31 30
32endif 31endif
33endif 32endif
diff --git a/libraries/evas/src/modules/loaders/ico/Makefile.in b/libraries/evas/src/modules/loaders/ico/Makefile.in
index f65ace0..2c9c95f 100644
--- a/libraries/evas/src/modules/loaders/ico/Makefile.in
+++ b/libraries/evas/src/modules/loaders/ico/Makefile.in
@@ -181,6 +181,8 @@ EVAS_SSE3_CFLAGS = @EVAS_SSE3_CFLAGS@
181EVIL_CFLAGS = @EVIL_CFLAGS@ 181EVIL_CFLAGS = @EVIL_CFLAGS@
182EVIL_LIBS = @EVIL_LIBS@ 182EVIL_LIBS = @EVIL_LIBS@
183EXEEXT = @EXEEXT@ 183EXEEXT = @EXEEXT@
184EXOTIC_CFLAGS = @EXOTIC_CFLAGS@
185EXOTIC_LIBS = @EXOTIC_LIBS@
184FGREP = @FGREP@ 186FGREP = @FGREP@
185FONTCONFIG_CFLAGS = @FONTCONFIG_CFLAGS@ 187FONTCONFIG_CFLAGS = @FONTCONFIG_CFLAGS@
186FONTCONFIG_LIBS = @FONTCONFIG_LIBS@ 188FONTCONFIG_LIBS = @FONTCONFIG_LIBS@
@@ -231,6 +233,8 @@ PATH_SEPARATOR = @PATH_SEPARATOR@
231PIXMAN_CFLAGS = @PIXMAN_CFLAGS@ 233PIXMAN_CFLAGS = @PIXMAN_CFLAGS@
232PIXMAN_LIBS = @PIXMAN_LIBS@ 234PIXMAN_LIBS = @PIXMAN_LIBS@
233PKG_CONFIG = @PKG_CONFIG@ 235PKG_CONFIG = @PKG_CONFIG@
236PKG_CONFIG_LIBDIR = @PKG_CONFIG_LIBDIR@
237PKG_CONFIG_PATH = @PKG_CONFIG_PATH@
234PNG_CFLAGS = @PNG_CFLAGS@ 238PNG_CFLAGS = @PNG_CFLAGS@
235PNG_LIBS = @PNG_LIBS@ 239PNG_LIBS = @PNG_LIBS@
236RANLIB = @RANLIB@ 240RANLIB = @RANLIB@
@@ -249,8 +253,6 @@ VERSION = @VERSION@
249VMAJ = @VMAJ@ 253VMAJ = @VMAJ@
250WAYLAND_EGL_CFLAGS = @WAYLAND_EGL_CFLAGS@ 254WAYLAND_EGL_CFLAGS = @WAYLAND_EGL_CFLAGS@
251WAYLAND_EGL_LIBS = @WAYLAND_EGL_LIBS@ 255WAYLAND_EGL_LIBS = @WAYLAND_EGL_LIBS@
252WIN32_CFLAGS = @WIN32_CFLAGS@
253WIN32_CPPFLAGS = @WIN32_CPPFLAGS@
254XCB_CFLAGS = @XCB_CFLAGS@ 256XCB_CFLAGS = @XCB_CFLAGS@
255XCB_GL_CFLAGS = @XCB_GL_CFLAGS@ 257XCB_GL_CFLAGS = @XCB_GL_CFLAGS@
256XCB_GL_LIBS = @XCB_GL_LIBS@ 258XCB_GL_LIBS = @XCB_GL_LIBS@
@@ -324,8 +326,6 @@ evas_engine_software_ddraw_cflags = @evas_engine_software_ddraw_cflags@
324evas_engine_software_ddraw_libs = @evas_engine_software_ddraw_libs@ 326evas_engine_software_ddraw_libs = @evas_engine_software_ddraw_libs@
325evas_engine_software_gdi_cflags = @evas_engine_software_gdi_cflags@ 327evas_engine_software_gdi_cflags = @evas_engine_software_gdi_cflags@
326evas_engine_software_gdi_libs = @evas_engine_software_gdi_libs@ 328evas_engine_software_gdi_libs = @evas_engine_software_gdi_libs@
327evas_engine_software_sdl_cflags = @evas_engine_software_sdl_cflags@
328evas_engine_software_sdl_libs = @evas_engine_software_sdl_libs@
329evas_engine_software_xcb_cflags = @evas_engine_software_xcb_cflags@ 329evas_engine_software_xcb_cflags = @evas_engine_software_xcb_cflags@
330evas_engine_software_xcb_libs = @evas_engine_software_xcb_libs@ 330evas_engine_software_xcb_libs = @evas_engine_software_xcb_libs@
331evas_engine_software_xlib_cflags = @evas_engine_software_xlib_cflags@ 331evas_engine_software_xlib_cflags = @evas_engine_software_xlib_cflags@
@@ -416,8 +416,7 @@ AM_CPPFLAGS = \
416@FREETYPE_CFLAGS@ \ 416@FREETYPE_CFLAGS@ \
417@PIXMAN_CFLAGS@ \ 417@PIXMAN_CFLAGS@ \
418@EINA_CFLAGS@ \ 418@EINA_CFLAGS@ \
419@EVIL_CFLAGS@ \ 419@EVIL_CFLAGS@
420@WIN32_CPPFLAGS@
421 420
422@BUILD_LOADER_ICO_TRUE@@EVAS_STATIC_BUILD_ICO_FALSE@pkgdir = $(libdir)/evas/modules/loaders/ico/$(MODULE_ARCH) 421@BUILD_LOADER_ICO_TRUE@@EVAS_STATIC_BUILD_ICO_FALSE@pkgdir = $(libdir)/evas/modules/loaders/ico/$(MODULE_ARCH)
423@BUILD_LOADER_ICO_TRUE@@EVAS_STATIC_BUILD_ICO_FALSE@pkg_LTLIBRARIES = module.la 422@BUILD_LOADER_ICO_TRUE@@EVAS_STATIC_BUILD_ICO_FALSE@pkg_LTLIBRARIES = module.la
diff --git a/libraries/evas/src/modules/loaders/ico/evas_image_load_ico.c b/libraries/evas/src/modules/loaders/ico/evas_image_load_ico.c
index 6e31191..4239407 100644
--- a/libraries/evas/src/modules/loaders/ico/evas_image_load_ico.c
+++ b/libraries/evas/src/modules/loaders/ico/evas_image_load_ico.c
@@ -88,7 +88,7 @@ evas_image_load_file_head_ico(Image_Entry *ie, const char *file, const char *key
88 unsigned short word; 88 unsigned short word;
89 unsigned char byte; 89 unsigned char byte;
90 int wanted_w = 0, wanted_h = 0, w, h, cols, i, planes = 0, 90 int wanted_w = 0, wanted_h = 0, w, h, cols, i, planes = 0,
91 hot_x = 0, hot_y = 0, bpp = 0, pdelta, search = -1, have_choice = 0, 91 bpp = 0, pdelta, search = -1, have_choice = 0,
92 hasa = 1; 92 hasa = 1;
93 unsigned int bmoffset, bmsize, fsize; 93 unsigned int bmoffset, bmsize, fsize;
94 unsigned short reserved, type, count; 94 unsigned short reserved, type, count;
@@ -182,10 +182,10 @@ evas_image_load_file_head_ico(Image_Entry *ie, const char *file, const char *key
182 if (!read_uchar(map, fsize, &position, &byte)) goto close_file; 182 if (!read_uchar(map, fsize, &position, &byte)) goto close_file;
183 if (!read_ushort(map, fsize, &position, &word)) goto close_file; 183 if (!read_ushort(map, fsize, &position, &word)) goto close_file;
184 if (type == CURSOR) planes = word; 184 if (type == CURSOR) planes = word;
185 else hot_x = word; 185 //else hot_x = word;
186 if (!read_ushort(map, fsize, &position, &word)) goto close_file; 186 if (!read_ushort(map, fsize, &position, &word)) goto close_file;
187 if (type == CURSOR) bpp = word; 187 if (type == CURSOR) bpp = word;
188 else hot_y = word; 188 //else hot_y = word;
189 if (!read_uint(map, fsize, &position, &bmsize)) goto close_file; 189 if (!read_uint(map, fsize, &position, &bmsize)) goto close_file;
190 if (!read_uint(map, fsize, &position, &bmoffset)) goto close_file; 190 if (!read_uint(map, fsize, &position, &bmoffset)) goto close_file;
191 if ((bmsize <= 0) || (bmoffset <= 0) || (bmoffset >= fsize)) goto close_file; 191 if ((bmsize <= 0) || (bmoffset <= 0) || (bmoffset >= fsize)) goto close_file;
@@ -315,11 +315,11 @@ evas_image_load_file_data_ico(Image_Entry *ie, const char *file, const char *key
315 unsigned char byte; 315 unsigned char byte;
316 unsigned int dword; 316 unsigned int dword;
317 int wanted_w = 0, wanted_h = 0, w, h, cols, i, planes = 0, 317 int wanted_w = 0, wanted_h = 0, w, h, cols, i, planes = 0,
318 hot_x = 0, hot_y = 0, bpp = 0, pdelta, search = -1, have_choice = 0, 318 bpp = 0, pdelta, search = -1, have_choice = 0,
319 stride, pstride, j, right_way_up = 0, diff_size = 0, cols2; 319 stride, pstride, j, right_way_up = 0, diff_size = 0, cols2;
320 unsigned int bmoffset, bmsize, bitcount, compression, imagesize, fsize, 320 unsigned int bmoffset, bmsize, bitcount, fsize,
321 colorsused, colorsimportant, *pal, *surface, *pix, none_zero_alpha = 0; 321 *pal, *surface, *pix, none_zero_alpha = 0;
322 unsigned short reserved, type, count, planes2; 322 unsigned short reserved, type, count;
323 unsigned char *maskbuf, *pixbuf, *p; 323 unsigned char *maskbuf, *pixbuf, *p;
324 struct { 324 struct {
325 int pdelta; 325 int pdelta;
@@ -411,10 +411,10 @@ evas_image_load_file_data_ico(Image_Entry *ie, const char *file, const char *key
411 if (!read_uchar(map, fsize, &position, &byte)) goto close_file; 411 if (!read_uchar(map, fsize, &position, &byte)) goto close_file;
412 if (!read_ushort(map, fsize, &position, &word)) goto close_file; 412 if (!read_ushort(map, fsize, &position, &word)) goto close_file;
413 if (type == 1) planes = word; 413 if (type == 1) planes = word;
414 else hot_x = word; 414 //else hot_x = word;
415 if (!read_ushort(map, fsize, &position, &word)) goto close_file; 415 if (!read_ushort(map, fsize, &position, &word)) goto close_file;
416 if (type == 1) bpp = word; 416 if (type == 1) bpp = word;
417 else hot_y = word; 417 //else hot_y = word;
418 if (!read_uint(map, fsize, &position, &bmsize)) goto close_file; 418 if (!read_uint(map, fsize, &position, &bmsize)) goto close_file;
419 if (!read_uint(map, fsize, &position, &bmoffset)) goto close_file; 419 if (!read_uint(map, fsize, &position, &bmoffset)) goto close_file;
420 if ((bmsize <= 0) || (bmoffset <= 0) || (bmoffset >= fsize)) goto close_file; 420 if ((bmsize <= 0) || (bmoffset <= 0) || (bmoffset >= fsize)) goto close_file;
@@ -540,19 +540,19 @@ evas_image_load_file_data_ico(Image_Entry *ie, const char *file, const char *key
540 file, ie->w, ie->h, w, h); 540 file, ie->w, ie->h, w, h);
541 } 541 }
542 if (!read_ushort(map, fsize, &position, &word)) goto close_file; // planes 542 if (!read_ushort(map, fsize, &position, &word)) goto close_file; // planes
543 planes2 = word; 543 //planes2 = word;
544 if (!read_ushort(map, fsize, &position, &word)) goto close_file; // bitcount 544 if (!read_ushort(map, fsize, &position, &word)) goto close_file; // bitcount
545 bitcount = word; 545 bitcount = word;
546 if (!read_uint(map, fsize, &position, &dword)) goto close_file; // compression 546 if (!read_uint(map, fsize, &position, &dword)) goto close_file; // compression
547 compression = dword; 547 //compression = dword;
548 if (!read_uint(map, fsize, &position, &dword)) goto close_file; // imagesize 548 if (!read_uint(map, fsize, &position, &dword)) goto close_file; // imagesize
549 imagesize = dword; 549 //imagesize = dword;
550 if (!read_uint(map, fsize, &position, &dword)) goto close_file; // z pixels per m 550 if (!read_uint(map, fsize, &position, &dword)) goto close_file; // z pixels per m
551 if (!read_uint(map, fsize, &position, &dword)) goto close_file; // y pizels per m 551 if (!read_uint(map, fsize, &position, &dword)) goto close_file; // y pizels per m
552 if (!read_uint(map, fsize, &position, &dword)) goto close_file; // colors used 552 if (!read_uint(map, fsize, &position, &dword)) goto close_file; // colors used
553 colorsused = dword; 553 //colorsused = dword;
554 if (!read_uint(map, fsize, &position, &dword)) goto close_file; // colors important 554 if (!read_uint(map, fsize, &position, &dword)) goto close_file; // colors important
555 colorsimportant = dword; 555 //colorsimportant = dword;
556 556
557 evas_cache_image_surface_alloc(ie, ie->w, ie->h); 557 evas_cache_image_surface_alloc(ie, ie->w, ie->h);
558 surface = evas_cache_image_pixels(ie); 558 surface = evas_cache_image_pixels(ie);