diff options
author | David Walter Seikel | 2012-04-22 09:19:23 +1000 |
---|---|---|
committer | David Walter Seikel | 2012-04-22 09:19:23 +1000 |
commit | c963d75dfdeec11f82e79e727062fbf89afa2c04 (patch) | |
tree | 895633dbf641110be46f117c29890c49b3ffc0bd /libraries/evas/src/modules/loaders/psd | |
parent | Adding the new extantz viewer and grid manager. (diff) | |
download | SledjHamr-c963d75dfdeec11f82e79e727062fbf89afa2c04.zip SledjHamr-c963d75dfdeec11f82e79e727062fbf89afa2c04.tar.gz SledjHamr-c963d75dfdeec11f82e79e727062fbf89afa2c04.tar.bz2 SledjHamr-c963d75dfdeec11f82e79e727062fbf89afa2c04.tar.xz |
Update EFL to latest beta.
Diffstat (limited to 'libraries/evas/src/modules/loaders/psd')
-rw-r--r-- | libraries/evas/src/modules/loaders/psd/Makefile.am | 5 | ||||
-rw-r--r-- | libraries/evas/src/modules/loaders/psd/Makefile.in | 11 | ||||
-rw-r--r-- | libraries/evas/src/modules/loaders/psd/evas_image_load_psd.c | 16 |
3 files changed, 10 insertions, 22 deletions
diff --git a/libraries/evas/src/modules/loaders/psd/Makefile.am b/libraries/evas/src/modules/loaders/psd/Makefile.am index 8b06348..a87e492 100644 --- a/libraries/evas/src/modules/loaders/psd/Makefile.am +++ b/libraries/evas/src/modules/loaders/psd/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 | ||
14 | if BUILD_LOADER_PSD | 13 | if BUILD_LOADER_PSD |
15 | if !EVAS_STATIC_BUILD_PSD | 14 | if !EVAS_STATIC_BUILD_PSD |
@@ -27,7 +26,7 @@ else | |||
27 | 26 | ||
28 | noinst_LTLIBRARIES = libevas_loader_psd.la | 27 | noinst_LTLIBRARIES = libevas_loader_psd.la |
29 | libevas_loader_psd_la_SOURCES = evas_image_load_psd.c | 28 | libevas_loader_psd_la_SOURCES = evas_image_load_psd.c |
30 | libevas_loader_psd_la_LIBADD = | 29 | libevas_loader_psd_la_LIBADD = |
31 | 30 | ||
32 | endif | 31 | endif |
33 | endif | 32 | endif |
diff --git a/libraries/evas/src/modules/loaders/psd/Makefile.in b/libraries/evas/src/modules/loaders/psd/Makefile.in index 3dc9c38..b1987c6 100644 --- a/libraries/evas/src/modules/loaders/psd/Makefile.in +++ b/libraries/evas/src/modules/loaders/psd/Makefile.in | |||
@@ -181,6 +181,8 @@ EVAS_SSE3_CFLAGS = @EVAS_SSE3_CFLAGS@ | |||
181 | EVIL_CFLAGS = @EVIL_CFLAGS@ | 181 | EVIL_CFLAGS = @EVIL_CFLAGS@ |
182 | EVIL_LIBS = @EVIL_LIBS@ | 182 | EVIL_LIBS = @EVIL_LIBS@ |
183 | EXEEXT = @EXEEXT@ | 183 | EXEEXT = @EXEEXT@ |
184 | EXOTIC_CFLAGS = @EXOTIC_CFLAGS@ | ||
185 | EXOTIC_LIBS = @EXOTIC_LIBS@ | ||
184 | FGREP = @FGREP@ | 186 | FGREP = @FGREP@ |
185 | FONTCONFIG_CFLAGS = @FONTCONFIG_CFLAGS@ | 187 | FONTCONFIG_CFLAGS = @FONTCONFIG_CFLAGS@ |
186 | FONTCONFIG_LIBS = @FONTCONFIG_LIBS@ | 188 | FONTCONFIG_LIBS = @FONTCONFIG_LIBS@ |
@@ -231,6 +233,8 @@ PATH_SEPARATOR = @PATH_SEPARATOR@ | |||
231 | PIXMAN_CFLAGS = @PIXMAN_CFLAGS@ | 233 | PIXMAN_CFLAGS = @PIXMAN_CFLAGS@ |
232 | PIXMAN_LIBS = @PIXMAN_LIBS@ | 234 | PIXMAN_LIBS = @PIXMAN_LIBS@ |
233 | PKG_CONFIG = @PKG_CONFIG@ | 235 | PKG_CONFIG = @PKG_CONFIG@ |
236 | PKG_CONFIG_LIBDIR = @PKG_CONFIG_LIBDIR@ | ||
237 | PKG_CONFIG_PATH = @PKG_CONFIG_PATH@ | ||
234 | PNG_CFLAGS = @PNG_CFLAGS@ | 238 | PNG_CFLAGS = @PNG_CFLAGS@ |
235 | PNG_LIBS = @PNG_LIBS@ | 239 | PNG_LIBS = @PNG_LIBS@ |
236 | RANLIB = @RANLIB@ | 240 | RANLIB = @RANLIB@ |
@@ -249,8 +253,6 @@ VERSION = @VERSION@ | |||
249 | VMAJ = @VMAJ@ | 253 | VMAJ = @VMAJ@ |
250 | WAYLAND_EGL_CFLAGS = @WAYLAND_EGL_CFLAGS@ | 254 | WAYLAND_EGL_CFLAGS = @WAYLAND_EGL_CFLAGS@ |
251 | WAYLAND_EGL_LIBS = @WAYLAND_EGL_LIBS@ | 255 | WAYLAND_EGL_LIBS = @WAYLAND_EGL_LIBS@ |
252 | WIN32_CFLAGS = @WIN32_CFLAGS@ | ||
253 | WIN32_CPPFLAGS = @WIN32_CPPFLAGS@ | ||
254 | XCB_CFLAGS = @XCB_CFLAGS@ | 256 | XCB_CFLAGS = @XCB_CFLAGS@ |
255 | XCB_GL_CFLAGS = @XCB_GL_CFLAGS@ | 257 | XCB_GL_CFLAGS = @XCB_GL_CFLAGS@ |
256 | XCB_GL_LIBS = @XCB_GL_LIBS@ | 258 | XCB_GL_LIBS = @XCB_GL_LIBS@ |
@@ -324,8 +326,6 @@ evas_engine_software_ddraw_cflags = @evas_engine_software_ddraw_cflags@ | |||
324 | evas_engine_software_ddraw_libs = @evas_engine_software_ddraw_libs@ | 326 | evas_engine_software_ddraw_libs = @evas_engine_software_ddraw_libs@ |
325 | evas_engine_software_gdi_cflags = @evas_engine_software_gdi_cflags@ | 327 | evas_engine_software_gdi_cflags = @evas_engine_software_gdi_cflags@ |
326 | evas_engine_software_gdi_libs = @evas_engine_software_gdi_libs@ | 328 | evas_engine_software_gdi_libs = @evas_engine_software_gdi_libs@ |
327 | evas_engine_software_sdl_cflags = @evas_engine_software_sdl_cflags@ | ||
328 | evas_engine_software_sdl_libs = @evas_engine_software_sdl_libs@ | ||
329 | evas_engine_software_xcb_cflags = @evas_engine_software_xcb_cflags@ | 329 | evas_engine_software_xcb_cflags = @evas_engine_software_xcb_cflags@ |
330 | evas_engine_software_xcb_libs = @evas_engine_software_xcb_libs@ | 330 | evas_engine_software_xcb_libs = @evas_engine_software_xcb_libs@ |
331 | evas_engine_software_xlib_cflags = @evas_engine_software_xlib_cflags@ | 331 | evas_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_PSD_TRUE@@EVAS_STATIC_BUILD_PSD_FALSE@pkgdir = $(libdir)/evas/modules/loaders/psd/$(MODULE_ARCH) | 421 | @BUILD_LOADER_PSD_TRUE@@EVAS_STATIC_BUILD_PSD_FALSE@pkgdir = $(libdir)/evas/modules/loaders/psd/$(MODULE_ARCH) |
423 | @BUILD_LOADER_PSD_TRUE@@EVAS_STATIC_BUILD_PSD_FALSE@pkg_LTLIBRARIES = module.la | 422 | @BUILD_LOADER_PSD_TRUE@@EVAS_STATIC_BUILD_PSD_FALSE@pkg_LTLIBRARIES = module.la |
diff --git a/libraries/evas/src/modules/loaders/psd/evas_image_load_psd.c b/libraries/evas/src/modules/loaders/psd/evas_image_load_psd.c index 27f5f24..4449db0 100644 --- a/libraries/evas/src/modules/loaders/psd/evas_image_load_psd.c +++ b/libraries/evas/src/modules/loaders/psd/evas_image_load_psd.c | |||
@@ -509,12 +509,10 @@ get_single_channel(Image_Entry *ie __UNUSED__, | |||
509 | Eina_Bool compressed) | 509 | Eina_Bool compressed) |
510 | { | 510 | { |
511 | unsigned int i, bpc; | 511 | unsigned int i, bpc; |
512 | unsigned short *tmp; | ||
513 | char headbyte; | 512 | char headbyte; |
514 | int c; | 513 | int c; |
515 | int pixels_count; | 514 | int pixels_count; |
516 | 515 | ||
517 | tmp = (unsigned short*)buffer; | ||
518 | bpc = (head->depth / 8); | 516 | bpc = (head->depth / 8); |
519 | pixels_count = head->width * head->height; | 517 | pixels_count = head->width * head->height; |
520 | 518 | ||
@@ -569,7 +567,6 @@ read_psd_grey(Image_Entry *ie, PSD_Header *head, const unsigned char *map, size_ | |||
569 | { | 567 | { |
570 | unsigned int color_mode, resource_size, misc_info; | 568 | unsigned int color_mode, resource_size, misc_info; |
571 | unsigned short compressed; | 569 | unsigned short compressed; |
572 | unsigned int type; | ||
573 | void *surface = NULL; | 570 | void *surface = NULL; |
574 | 571 | ||
575 | *error = EVAS_LOAD_ERROR_CORRUPT_FILE; | 572 | *error = EVAS_LOAD_ERROR_CORRUPT_FILE; |
@@ -602,10 +599,7 @@ read_psd_grey(Image_Entry *ie, PSD_Header *head, const unsigned char *map, size_ | |||
602 | switch (head->depth) | 599 | switch (head->depth) |
603 | { | 600 | { |
604 | case 8: | 601 | case 8: |
605 | type = 1; | ||
606 | break; | ||
607 | case 16: | 602 | case 16: |
608 | type = 2; | ||
609 | break; | 603 | break; |
610 | default: | 604 | default: |
611 | *error = EVAS_LOAD_ERROR_UNKNOWN_FORMAT; | 605 | *error = EVAS_LOAD_ERROR_UNKNOWN_FORMAT; |
@@ -697,7 +691,6 @@ read_psd_rgb(Image_Entry *ie, PSD_Header *head, const unsigned char *map, size_t | |||
697 | { | 691 | { |
698 | unsigned int color_mode, resource_size, misc_info; | 692 | unsigned int color_mode, resource_size, misc_info; |
699 | unsigned short compressed; | 693 | unsigned short compressed; |
700 | unsigned int type; | ||
701 | void *surface; | 694 | void *surface; |
702 | 695 | ||
703 | #define CHECK_RET(Call) \ | 696 | #define CHECK_RET(Call) \ |
@@ -721,10 +714,7 @@ read_psd_rgb(Image_Entry *ie, PSD_Header *head, const unsigned char *map, size_t | |||
721 | switch (head->depth) | 714 | switch (head->depth) |
722 | { | 715 | { |
723 | case 8: | 716 | case 8: |
724 | type = 1; | ||
725 | break; | ||
726 | case 16: | 717 | case 16: |
727 | type = 2; | ||
728 | break; | 718 | break; |
729 | default: | 719 | default: |
730 | *error = EVAS_LOAD_ERROR_UNKNOWN_FORMAT; | 720 | *error = EVAS_LOAD_ERROR_UNKNOWN_FORMAT; |
@@ -758,7 +748,7 @@ read_psd_rgb(Image_Entry *ie, PSD_Header *head, const unsigned char *map, size_t | |||
758 | Eina_Bool | 748 | Eina_Bool |
759 | read_psd_cmyk(Image_Entry *ie, PSD_Header *head, const unsigned char *map, size_t length, size_t *position, int *error) | 749 | read_psd_cmyk(Image_Entry *ie, PSD_Header *head, const unsigned char *map, size_t length, size_t *position, int *error) |
760 | { | 750 | { |
761 | unsigned int color_mode, resource_size, misc_info, size, i, j, data_size; | 751 | unsigned int color_mode, resource_size, misc_info, size, j, data_size; |
762 | unsigned short compressed; | 752 | unsigned short compressed; |
763 | unsigned int format, type; | 753 | unsigned int format, type; |
764 | unsigned char *kchannel = NULL; | 754 | unsigned char *kchannel = NULL; |
@@ -841,7 +831,7 @@ read_psd_cmyk(Image_Entry *ie, PSD_Header *head, const unsigned char *map, size_ | |||
841 | unsigned char *tmp = surface; | 831 | unsigned char *tmp = surface; |
842 | const unsigned char *limit = tmp + data_size; | 832 | const unsigned char *limit = tmp + data_size; |
843 | 833 | ||
844 | for (i = 0, j = 0; tmp < limit; tmp++, j++) | 834 | for (j = 0; tmp < limit; tmp++, j++) |
845 | { | 835 | { |
846 | int k; | 836 | int k; |
847 | 837 | ||
@@ -857,7 +847,7 @@ read_psd_cmyk(Image_Entry *ie, PSD_Header *head, const unsigned char *map, size_ | |||
857 | const unsigned char *limit = tmp + data_size; | 847 | const unsigned char *limit = tmp + data_size; |
858 | 848 | ||
859 | // The KChannel array really holds the alpha channel on this one. | 849 | // The KChannel array really holds the alpha channel on this one. |
860 | for (i = 0, j = 0; tmp < limit; tmp += 4, j++) | 850 | for (j = 0; tmp < limit; tmp += 4, j++) |
861 | { | 851 | { |
862 | tmp[0] = (tmp[0] * tmp[3]) >> 8; | 852 | tmp[0] = (tmp[0] * tmp[3]) >> 8; |
863 | tmp[1] = (tmp[1] * tmp[3]) >> 8; | 853 | tmp[1] = (tmp[1] * tmp[3]) >> 8; |