From 07274513e984f0b5544586c74508ccd16e7dcafa Mon Sep 17 00:00:00 2001 From: David Walter Seikel Date: Sun, 13 Jan 2013 17:29:19 +1000 Subject: Remove EFL, since it's been released now. --- .../evas/src/modules/loaders/jpeg/Makefile.am | 33 - .../evas/src/modules/loaders/jpeg/Makefile.in | 762 ------------ .../modules/loaders/jpeg/evas_image_load_jpeg.c | 1275 -------------------- 3 files changed, 2070 deletions(-) delete mode 100644 libraries/evas/src/modules/loaders/jpeg/Makefile.am delete mode 100644 libraries/evas/src/modules/loaders/jpeg/Makefile.in delete mode 100644 libraries/evas/src/modules/loaders/jpeg/evas_image_load_jpeg.c (limited to 'libraries/evas/src/modules/loaders/jpeg') diff --git a/libraries/evas/src/modules/loaders/jpeg/Makefile.am b/libraries/evas/src/modules/loaders/jpeg/Makefile.am deleted file mode 100644 index a7a19ab..0000000 --- a/libraries/evas/src/modules/loaders/jpeg/Makefile.am +++ /dev/null @@ -1,33 +0,0 @@ - -MAINTAINERCLEANFILES = Makefile.in - -AM_CPPFLAGS = \ --I. \ --I$(top_srcdir)/src/lib \ --I$(top_srcdir)/src/lib/include \ -@FREETYPE_CFLAGS@ \ -@PIXMAN_CFLAGS@ \ -@EINA_CFLAGS@ \ -@evas_image_loader_jpeg_cflags@ \ -@EVIL_CFLAGS@ - -if BUILD_LOADER_JPEG -if !EVAS_STATIC_BUILD_JPEG - -pkgdir = $(libdir)/evas/modules/loaders/jpeg/$(MODULE_ARCH) -pkg_LTLIBRARIES = module.la - -module_la_SOURCES = evas_image_load_jpeg.c - -module_la_LIBADD = @EINA_LIBS@ @EVIL_LIBS@ @evas_image_loader_jpeg_libs@ $(top_builddir)/src/lib/libevas.la -module_la_LDFLAGS = -no-undefined @lt_enable_auto_import@ -module -avoid-version -module_la_LIBTOOLFLAGS = --tag=disable-static - -else - -noinst_LTLIBRARIES = libevas_loader_jpeg.la -libevas_loader_jpeg_la_SOURCES = evas_image_load_jpeg.c -libevas_loader_jpeg_la_LIBADD = @evas_image_loader_jpeg_libs@ - -endif -endif diff --git a/libraries/evas/src/modules/loaders/jpeg/Makefile.in b/libraries/evas/src/modules/loaders/jpeg/Makefile.in deleted file mode 100644 index 4945f85..0000000 --- a/libraries/evas/src/modules/loaders/jpeg/Makefile.in +++ /dev/null @@ -1,762 +0,0 @@ -# Makefile.in generated by automake 1.11.1 from Makefile.am. -# @configure_input@ - -# Copyright (C) 1994, 1995, 1996, 1997, 1998, 1999, 2000, 2001, 2002, -# 2003, 2004, 2005, 2006, 2007, 2008, 2009 Free Software Foundation, -# Inc. -# This Makefile.in is free software; the Free Software Foundation -# gives unlimited permission to copy and/or distribute it, -# with or without modifications, as long as this notice is preserved. - -# This program is distributed in the hope that it will be useful, -# but WITHOUT ANY WARRANTY, to the extent permitted by law; without -# even the implied warranty of MERCHANTABILITY or FITNESS FOR A -# PARTICULAR PURPOSE. - -@SET_MAKE@ - -VPATH = @srcdir@ -pkgdatadir = $(datadir)/@PACKAGE@ -pkgincludedir = $(includedir)/@PACKAGE@ -pkglibdir = $(libdir)/@PACKAGE@ -pkglibexecdir = $(libexecdir)/@PACKAGE@ -am__cd = CDPATH="$${ZSH_VERSION+.}$(PATH_SEPARATOR)" && cd -install_sh_DATA = $(install_sh) -c -m 644 -install_sh_PROGRAM = $(install_sh) -c -install_sh_SCRIPT = $(install_sh) -c -INSTALL_HEADER = $(INSTALL_DATA) -transform = $(program_transform_name) -NORMAL_INSTALL = : -PRE_INSTALL = : -POST_INSTALL = : -NORMAL_UNINSTALL = : -PRE_UNINSTALL = : -POST_UNINSTALL = : -build_triplet = @build@ -host_triplet = @host@ -subdir = src/modules/loaders/jpeg -DIST_COMMON = $(srcdir)/Makefile.am $(srcdir)/Makefile.in -ACLOCAL_M4 = $(top_srcdir)/aclocal.m4 -am__aclocal_m4_deps = $(top_srcdir)/m4/efl_attribute.m4 \ - $(top_srcdir)/m4/efl_coverage.m4 \ - $(top_srcdir)/m4/efl_doxygen.m4 \ - $(top_srcdir)/m4/efl_fnmatch.m4 \ - $(top_srcdir)/m4/efl_path_max.m4 $(top_srcdir)/m4/efl_tests.m4 \ - $(top_srcdir)/m4/evas_check_engine.m4 \ - $(top_srcdir)/m4/evas_check_loader.m4 \ - $(top_srcdir)/m4/evas_converter.m4 \ - $(top_srcdir)/m4/evas_dither.m4 \ - $(top_srcdir)/m4/evas_scaler.m4 $(top_srcdir)/m4/libtool.m4 \ - $(top_srcdir)/m4/ltoptions.m4 $(top_srcdir)/m4/ltsugar.m4 \ - $(top_srcdir)/m4/ltversion.m4 $(top_srcdir)/m4/lt~obsolete.m4 \ - $(top_srcdir)/configure.ac -am__configure_deps = $(am__aclocal_m4_deps) $(CONFIGURE_DEPENDENCIES) \ - $(ACLOCAL_M4) -mkinstalldirs = $(install_sh) -d -CONFIG_HEADER = $(top_builddir)/config.h -CONFIG_CLEAN_FILES = -CONFIG_CLEAN_VPATH_FILES = -am__vpath_adj_setup = srcdirstrip=`echo "$(srcdir)" | sed 's|.|.|g'`; -am__vpath_adj = case $$p in \ - $(srcdir)/*) f=`echo "$$p" | sed "s|^$$srcdirstrip/||"`;; \ - *) f=$$p;; \ - esac; -am__strip_dir = f=`echo $$p | sed -e 's|^.*/||'`; -am__install_max = 40 -am__nobase_strip_setup = \ - srcdirstrip=`echo "$(srcdir)" | sed 's/[].[^$$\\*|]/\\\\&/g'` -am__nobase_strip = \ - for p in $$list; do echo "$$p"; done | sed -e "s|$$srcdirstrip/||" -am__nobase_list = $(am__nobase_strip_setup); \ - for p in $$list; do echo "$$p $$p"; done | \ - sed "s| $$srcdirstrip/| |;"' / .*\//!s/ .*/ ./; s,\( .*\)/[^/]*$$,\1,' | \ - $(AWK) 'BEGIN { files["."] = "" } { files[$$2] = files[$$2] " " $$1; \ - if (++n[$$2] == $(am__install_max)) \ - { print $$2, files[$$2]; n[$$2] = 0; files[$$2] = "" } } \ - END { for (dir in files) print dir, files[dir] }' -am__base_list = \ - sed '$$!N;$$!N;$$!N;$$!N;$$!N;$$!N;$$!N;s/\n/ /g' | \ - sed '$$!N;$$!N;$$!N;$$!N;s/\n/ /g' -am__installdirs = "$(DESTDIR)$(pkgdir)" -LTLIBRARIES = $(noinst_LTLIBRARIES) $(pkg_LTLIBRARIES) -libevas_loader_jpeg_la_DEPENDENCIES = -am__libevas_loader_jpeg_la_SOURCES_DIST = evas_image_load_jpeg.c -@BUILD_LOADER_JPEG_TRUE@@EVAS_STATIC_BUILD_JPEG_TRUE@am_libevas_loader_jpeg_la_OBJECTS = evas_image_load_jpeg.lo -libevas_loader_jpeg_la_OBJECTS = $(am_libevas_loader_jpeg_la_OBJECTS) -AM_V_lt = $(am__v_lt_$(V)) -am__v_lt_ = $(am__v_lt_$(AM_DEFAULT_VERBOSITY)) -am__v_lt_0 = --silent -@BUILD_LOADER_JPEG_TRUE@@EVAS_STATIC_BUILD_JPEG_TRUE@am_libevas_loader_jpeg_la_rpath = -@BUILD_LOADER_JPEG_TRUE@@EVAS_STATIC_BUILD_JPEG_FALSE@module_la_DEPENDENCIES = $(top_builddir)/src/lib/libevas.la -am__module_la_SOURCES_DIST = evas_image_load_jpeg.c -@BUILD_LOADER_JPEG_TRUE@@EVAS_STATIC_BUILD_JPEG_FALSE@am_module_la_OBJECTS = module_la-evas_image_load_jpeg.lo -module_la_OBJECTS = $(am_module_la_OBJECTS) -module_la_LINK = $(LIBTOOL) $(AM_V_lt) --tag=CC \ - $(module_la_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=link $(CCLD) \ - $(AM_CFLAGS) $(CFLAGS) $(module_la_LDFLAGS) $(LDFLAGS) -o $@ -@BUILD_LOADER_JPEG_TRUE@@EVAS_STATIC_BUILD_JPEG_FALSE@am_module_la_rpath = \ -@BUILD_LOADER_JPEG_TRUE@@EVAS_STATIC_BUILD_JPEG_FALSE@ -rpath \ -@BUILD_LOADER_JPEG_TRUE@@EVAS_STATIC_BUILD_JPEG_FALSE@ $(pkgdir) -DEFAULT_INCLUDES = -I.@am__isrc@ -I$(top_builddir) -depcomp = $(SHELL) $(top_srcdir)/depcomp -am__depfiles_maybe = depfiles -am__mv = mv -f -COMPILE = $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) \ - $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -LTCOMPILE = $(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) \ - $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) \ - $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) \ - $(AM_CFLAGS) $(CFLAGS) -AM_V_CC = $(am__v_CC_$(V)) -am__v_CC_ = $(am__v_CC_$(AM_DEFAULT_VERBOSITY)) -am__v_CC_0 = @echo " CC " $@; -AM_V_at = $(am__v_at_$(V)) -am__v_at_ = $(am__v_at_$(AM_DEFAULT_VERBOSITY)) -am__v_at_0 = @ -CCLD = $(CC) -LINK = $(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) \ - $(LIBTOOLFLAGS) --mode=link $(CCLD) $(AM_CFLAGS) $(CFLAGS) \ - $(AM_LDFLAGS) $(LDFLAGS) -o $@ -AM_V_CCLD = $(am__v_CCLD_$(V)) -am__v_CCLD_ = $(am__v_CCLD_$(AM_DEFAULT_VERBOSITY)) -am__v_CCLD_0 = @echo " CCLD " $@; -AM_V_GEN = $(am__v_GEN_$(V)) -am__v_GEN_ = $(am__v_GEN_$(AM_DEFAULT_VERBOSITY)) -am__v_GEN_0 = @echo " GEN " $@; -SOURCES = $(libevas_loader_jpeg_la_SOURCES) $(module_la_SOURCES) -DIST_SOURCES = $(am__libevas_loader_jpeg_la_SOURCES_DIST) \ - $(am__module_la_SOURCES_DIST) -ETAGS = etags -CTAGS = ctags -DISTFILES = $(DIST_COMMON) $(DIST_SOURCES) $(TEXINFOS) $(EXTRA_DIST) -ACLOCAL = @ACLOCAL@ -ALLOCA = @ALLOCA@ -AMTAR = @AMTAR@ -AM_DEFAULT_VERBOSITY = @AM_DEFAULT_VERBOSITY@ -AR = @AR@ -AS = @AS@ -AUTOCONF = @AUTOCONF@ -AUTOHEADER = @AUTOHEADER@ -AUTOMAKE = @AUTOMAKE@ -AWK = @AWK@ -CC = @CC@ -CCDEPMODE = @CCDEPMODE@ -CFLAGS = @CFLAGS@ -CHECK_CFLAGS = @CHECK_CFLAGS@ -CHECK_LIBS = @CHECK_LIBS@ -CPP = @CPP@ -CPPFLAGS = @CPPFLAGS@ -CXX = @CXX@ -CXXCPP = @CXXCPP@ -CXXDEPMODE = @CXXDEPMODE@ -CXXFLAGS = @CXXFLAGS@ -CYGPATH_W = @CYGPATH_W@ -DEFS = @DEFS@ -DEPDIR = @DEPDIR@ -DIRECTFB_CFLAGS = @DIRECTFB_CFLAGS@ -DIRECTFB_LIBS = @DIRECTFB_LIBS@ -DLLTOOL = @DLLTOOL@ -DSYMUTIL = @DSYMUTIL@ -DUMPBIN = @DUMPBIN@ -ECHO_C = @ECHO_C@ -ECHO_N = @ECHO_N@ -ECHO_T = @ECHO_T@ -ECORE_EVAS_CFLAGS = @ECORE_EVAS_CFLAGS@ -ECORE_EVAS_LIBS = @ECORE_EVAS_LIBS@ -EDB_CFLAGS = @EDB_CFLAGS@ -EDB_LIBS = @EDB_LIBS@ -EDJE_CFLAGS = @EDJE_CFLAGS@ -EDJE_LIBS = @EDJE_LIBS@ -EET_CFLAGS = @EET_CFLAGS@ -EET_LIBS = @EET_LIBS@ -EFL_COVERAGE_CFLAGS = @EFL_COVERAGE_CFLAGS@ -EFL_COVERAGE_LIBS = @EFL_COVERAGE_LIBS@ -EFL_FNMATCH_LIBS = @EFL_FNMATCH_LIBS@ -EGREP = @EGREP@ -EINA_CFLAGS = @EINA_CFLAGS@ -EINA_LIBS = @EINA_LIBS@ -EVAS_CFLAGS = @EVAS_CFLAGS@ -EVAS_LIBS = @EVAS_LIBS@ -EVAS_SSE3_CFLAGS = @EVAS_SSE3_CFLAGS@ -EVIL_CFLAGS = @EVIL_CFLAGS@ -EVIL_LIBS = @EVIL_LIBS@ -EXEEXT = @EXEEXT@ -EXOTIC_CFLAGS = @EXOTIC_CFLAGS@ -EXOTIC_LIBS = @EXOTIC_LIBS@ -FGREP = @FGREP@ -FONTCONFIG_CFLAGS = @FONTCONFIG_CFLAGS@ -FONTCONFIG_LIBS = @FONTCONFIG_LIBS@ -FREETYPE_CFLAGS = @FREETYPE_CFLAGS@ -FREETYPE_LIBS = @FREETYPE_LIBS@ -FRIBIDI_CFLAGS = @FRIBIDI_CFLAGS@ -FRIBIDI_LIBS = @FRIBIDI_LIBS@ -GL_EET_CFLAGS = @GL_EET_CFLAGS@ -GL_EET_LIBS = @GL_EET_LIBS@ -GREP = @GREP@ -HARFBUZZ_CFLAGS = @HARFBUZZ_CFLAGS@ -HARFBUZZ_LIBS = @HARFBUZZ_LIBS@ -INSTALL = @INSTALL@ -INSTALL_DATA = @INSTALL_DATA@ -INSTALL_PROGRAM = @INSTALL_PROGRAM@ -INSTALL_SCRIPT = @INSTALL_SCRIPT@ -INSTALL_STRIP_PROGRAM = @INSTALL_STRIP_PROGRAM@ -LD = @LD@ -LDFLAGS = @LDFLAGS@ -LIBOBJS = @LIBOBJS@ -LIBS = @LIBS@ -LIBTOOL = @LIBTOOL@ -LINEBREAK_CFLAGS = @LINEBREAK_CFLAGS@ -LINEBREAK_LIBS = @LINEBREAK_LIBS@ -LIPO = @LIPO@ -LN_S = @LN_S@ -LTLIBOBJS = @LTLIBOBJS@ -MAKEINFO = @MAKEINFO@ -MKDIR_P = @MKDIR_P@ -MODULE_ARCH = @MODULE_ARCH@ -NM = @NM@ -NMEDIT = @NMEDIT@ -OBJC = @OBJC@ -OBJCDEPMODE = @OBJCDEPMODE@ -OBJCFLAGS = @OBJCFLAGS@ -OBJDUMP = @OBJDUMP@ -OBJEXT = @OBJEXT@ -OTOOL = @OTOOL@ -OTOOL64 = @OTOOL64@ -PACKAGE = @PACKAGE@ -PACKAGE_BUGREPORT = @PACKAGE_BUGREPORT@ -PACKAGE_NAME = @PACKAGE_NAME@ -PACKAGE_STRING = @PACKAGE_STRING@ -PACKAGE_TARNAME = @PACKAGE_TARNAME@ -PACKAGE_URL = @PACKAGE_URL@ -PACKAGE_VERSION = @PACKAGE_VERSION@ -PATH_SEPARATOR = @PATH_SEPARATOR@ -PIXMAN_CFLAGS = @PIXMAN_CFLAGS@ -PIXMAN_LIBS = @PIXMAN_LIBS@ -PKG_CONFIG = @PKG_CONFIG@ -PKG_CONFIG_LIBDIR = @PKG_CONFIG_LIBDIR@ -PKG_CONFIG_PATH = @PKG_CONFIG_PATH@ -PNG_CFLAGS = @PNG_CFLAGS@ -PNG_LIBS = @PNG_LIBS@ -RANLIB = @RANLIB@ -SDL_CFLAGS = @SDL_CFLAGS@ -SDL_LIBS = @SDL_LIBS@ -SED = @SED@ -SET_MAKE = @SET_MAKE@ -SHELL = @SHELL@ -SHM_OPEN_LINK = @SHM_OPEN_LINK@ -STRIP = @STRIP@ -SVG_CFLAGS = @SVG_CFLAGS@ -SVG_LIBS = @SVG_LIBS@ -VALGRIND_CFLAGS = @VALGRIND_CFLAGS@ -VALGRIND_LIBS = @VALGRIND_LIBS@ -VERSION = @VERSION@ -VMAJ = @VMAJ@ -WAYLAND_EGL_CFLAGS = @WAYLAND_EGL_CFLAGS@ -WAYLAND_EGL_LIBS = @WAYLAND_EGL_LIBS@ -XCB_CFLAGS = @XCB_CFLAGS@ -XCB_GL_CFLAGS = @XCB_GL_CFLAGS@ -XCB_GL_LIBS = @XCB_GL_LIBS@ -XCB_LIBS = @XCB_LIBS@ -XEXT_CFLAGS = @XEXT_CFLAGS@ -XEXT_LIBS = @XEXT_LIBS@ -XMKMF = @XMKMF@ -X_CFLAGS = @X_CFLAGS@ -X_EXTRA_LIBS = @X_EXTRA_LIBS@ -X_LIBS = @X_LIBS@ -X_PRE_LIBS = @X_PRE_LIBS@ -abs_builddir = @abs_builddir@ -abs_srcdir = @abs_srcdir@ -abs_top_builddir = @abs_top_builddir@ -abs_top_srcdir = @abs_top_srcdir@ -ac_ct_CC = @ac_ct_CC@ -ac_ct_CXX = @ac_ct_CXX@ -ac_ct_DUMPBIN = @ac_ct_DUMPBIN@ -ac_ct_OBJC = @ac_ct_OBJC@ -altivec_cflags = @altivec_cflags@ -am__include = @am__include@ -am__leading_dot = @am__leading_dot@ -am__quote = @am__quote@ -am__tar = @am__tar@ -am__untar = @am__untar@ -bindir = @bindir@ -build = @build@ -build_alias = @build_alias@ -build_cpu = @build_cpu@ -build_os = @build_os@ -build_vendor = @build_vendor@ -builddir = @builddir@ -datadir = @datadir@ -datarootdir = @datarootdir@ -dlopen_libs = @dlopen_libs@ -docdir = @docdir@ -dvidir = @dvidir@ -edje_cc = @edje_cc@ -efl_doxygen = @efl_doxygen@ -efl_have_doxygen = @efl_have_doxygen@ -evas_engine_buffer_cflags = @evas_engine_buffer_cflags@ -evas_engine_buffer_libs = @evas_engine_buffer_libs@ -evas_engine_direct3d_cflags = @evas_engine_direct3d_cflags@ -evas_engine_direct3d_libs = @evas_engine_direct3d_libs@ -evas_engine_directfb_cflags = @evas_engine_directfb_cflags@ -evas_engine_directfb_libs = @evas_engine_directfb_libs@ -evas_engine_fb_cflags = @evas_engine_fb_cflags@ -evas_engine_fb_libs = @evas_engine_fb_libs@ -evas_engine_gl_cocoa_cflags = @evas_engine_gl_cocoa_cflags@ -evas_engine_gl_cocoa_libs = @evas_engine_gl_cocoa_libs@ -evas_engine_gl_common_libs = @evas_engine_gl_common_libs@ -evas_engine_gl_sdl_cflags = @evas_engine_gl_sdl_cflags@ -evas_engine_gl_sdl_libs = @evas_engine_gl_sdl_libs@ -evas_engine_gl_xcb_cflags = @evas_engine_gl_xcb_cflags@ -evas_engine_gl_xcb_libs = @evas_engine_gl_xcb_libs@ -evas_engine_gl_xlib_cflags = @evas_engine_gl_xlib_cflags@ -evas_engine_gl_xlib_libs = @evas_engine_gl_xlib_libs@ -evas_engine_psl1ght_cflags = @evas_engine_psl1ght_cflags@ -evas_engine_psl1ght_libs = @evas_engine_psl1ght_libs@ -evas_engine_software_16_ddraw_cflags = @evas_engine_software_16_ddraw_cflags@ -evas_engine_software_16_ddraw_libs = @evas_engine_software_16_ddraw_libs@ -evas_engine_software_16_sdl_cflags = @evas_engine_software_16_sdl_cflags@ -evas_engine_software_16_sdl_libs = @evas_engine_software_16_sdl_libs@ -evas_engine_software_16_wince_cflags = @evas_engine_software_16_wince_cflags@ -evas_engine_software_16_wince_libs = @evas_engine_software_16_wince_libs@ -evas_engine_software_16_x11_cflags = @evas_engine_software_16_x11_cflags@ -evas_engine_software_16_x11_libs = @evas_engine_software_16_x11_libs@ -evas_engine_software_8_x11_cflags = @evas_engine_software_8_x11_cflags@ -evas_engine_software_8_x11_libs = @evas_engine_software_8_x11_libs@ -evas_engine_software_ddraw_cflags = @evas_engine_software_ddraw_cflags@ -evas_engine_software_ddraw_libs = @evas_engine_software_ddraw_libs@ -evas_engine_software_gdi_cflags = @evas_engine_software_gdi_cflags@ -evas_engine_software_gdi_libs = @evas_engine_software_gdi_libs@ -evas_engine_software_xcb_cflags = @evas_engine_software_xcb_cflags@ -evas_engine_software_xcb_libs = @evas_engine_software_xcb_libs@ -evas_engine_software_xlib_cflags = @evas_engine_software_xlib_cflags@ -evas_engine_software_xlib_libs = @evas_engine_software_xlib_libs@ -evas_engine_wayland_egl_cflags = @evas_engine_wayland_egl_cflags@ -evas_engine_wayland_egl_libs = @evas_engine_wayland_egl_libs@ -evas_engine_wayland_shm_cflags = @evas_engine_wayland_shm_cflags@ -evas_engine_wayland_shm_libs = @evas_engine_wayland_shm_libs@ -evas_image_loader_bmp_cflags = @evas_image_loader_bmp_cflags@ -evas_image_loader_bmp_libs = @evas_image_loader_bmp_libs@ -evas_image_loader_edb_cflags = @evas_image_loader_edb_cflags@ -evas_image_loader_edb_libs = @evas_image_loader_edb_libs@ -evas_image_loader_eet_cflags = @evas_image_loader_eet_cflags@ -evas_image_loader_eet_libs = @evas_image_loader_eet_libs@ -evas_image_loader_generic_cflags = @evas_image_loader_generic_cflags@ -evas_image_loader_generic_libs = @evas_image_loader_generic_libs@ -evas_image_loader_gif_cflags = @evas_image_loader_gif_cflags@ -evas_image_loader_gif_libs = @evas_image_loader_gif_libs@ -evas_image_loader_ico_cflags = @evas_image_loader_ico_cflags@ -evas_image_loader_ico_libs = @evas_image_loader_ico_libs@ -evas_image_loader_jpeg_cflags = @evas_image_loader_jpeg_cflags@ -evas_image_loader_jpeg_libs = @evas_image_loader_jpeg_libs@ -evas_image_loader_pmaps_cflags = @evas_image_loader_pmaps_cflags@ -evas_image_loader_pmaps_libs = @evas_image_loader_pmaps_libs@ -evas_image_loader_png_cflags = @evas_image_loader_png_cflags@ -evas_image_loader_png_libs = @evas_image_loader_png_libs@ -evas_image_loader_psd_cflags = @evas_image_loader_psd_cflags@ -evas_image_loader_psd_libs = @evas_image_loader_psd_libs@ -evas_image_loader_svg_cflags = @evas_image_loader_svg_cflags@ -evas_image_loader_svg_libs = @evas_image_loader_svg_libs@ -evas_image_loader_tga_cflags = @evas_image_loader_tga_cflags@ -evas_image_loader_tga_libs = @evas_image_loader_tga_libs@ -evas_image_loader_tiff_cflags = @evas_image_loader_tiff_cflags@ -evas_image_loader_tiff_libs = @evas_image_loader_tiff_libs@ -evas_image_loader_wbmp_cflags = @evas_image_loader_wbmp_cflags@ -evas_image_loader_wbmp_libs = @evas_image_loader_wbmp_libs@ -evas_image_loader_xpm_cflags = @evas_image_loader_xpm_cflags@ -evas_image_loader_xpm_libs = @evas_image_loader_xpm_libs@ -exec_prefix = @exec_prefix@ -have_evas_engine_gl_x11 = @have_evas_engine_gl_x11@ -have_evas_engine_gl_xcb = @have_evas_engine_gl_xcb@ -have_evas_engine_gl_xlib = @have_evas_engine_gl_xlib@ -have_evas_engine_software_x11 = @have_evas_engine_software_x11@ -have_evas_engine_software_xcb = @have_evas_engine_software_xcb@ -have_evas_engine_software_xlib = @have_evas_engine_software_xlib@ -have_lcov = @have_lcov@ -host = @host@ -host_alias = @host_alias@ -host_cpu = @host_cpu@ -host_os = @host_os@ -host_vendor = @host_vendor@ -htmldir = @htmldir@ -includedir = @includedir@ -infodir = @infodir@ -install_sh = @install_sh@ -libdir = @libdir@ -libexecdir = @libexecdir@ -localedir = @localedir@ -localstatedir = @localstatedir@ -lt_ECHO = @lt_ECHO@ -lt_enable_auto_import = @lt_enable_auto_import@ -mandir = @mandir@ -mkdir_p = @mkdir_p@ -oldincludedir = @oldincludedir@ -pdfdir = @pdfdir@ -pkgconfig_requires_private = @pkgconfig_requires_private@ -prefix = @prefix@ -program_transform_name = @program_transform_name@ -psdir = @psdir@ -pthread_cflags = @pthread_cflags@ -pthread_libs = @pthread_libs@ -release_info = @release_info@ -requirement_evas = @requirement_evas@ -sbindir = @sbindir@ -sharedstatedir = @sharedstatedir@ -srcdir = @srcdir@ -sysconfdir = @sysconfdir@ -target_alias = @target_alias@ -top_build_prefix = @top_build_prefix@ -top_builddir = @top_builddir@ -top_srcdir = @top_srcdir@ -version_info = @version_info@ -MAINTAINERCLEANFILES = Makefile.in -AM_CPPFLAGS = \ --I. \ --I$(top_srcdir)/src/lib \ --I$(top_srcdir)/src/lib/include \ -@FREETYPE_CFLAGS@ \ -@PIXMAN_CFLAGS@ \ -@EINA_CFLAGS@ \ -@evas_image_loader_jpeg_cflags@ \ -@EVIL_CFLAGS@ - -@BUILD_LOADER_JPEG_TRUE@@EVAS_STATIC_BUILD_JPEG_FALSE@pkgdir = $(libdir)/evas/modules/loaders/jpeg/$(MODULE_ARCH) -@BUILD_LOADER_JPEG_TRUE@@EVAS_STATIC_BUILD_JPEG_FALSE@pkg_LTLIBRARIES = module.la -@BUILD_LOADER_JPEG_TRUE@@EVAS_STATIC_BUILD_JPEG_FALSE@module_la_SOURCES = evas_image_load_jpeg.c -@BUILD_LOADER_JPEG_TRUE@@EVAS_STATIC_BUILD_JPEG_FALSE@module_la_LIBADD = @EINA_LIBS@ @EVIL_LIBS@ @evas_image_loader_jpeg_libs@ $(top_builddir)/src/lib/libevas.la -@BUILD_LOADER_JPEG_TRUE@@EVAS_STATIC_BUILD_JPEG_FALSE@module_la_LDFLAGS = -no-undefined @lt_enable_auto_import@ -module -avoid-version -@BUILD_LOADER_JPEG_TRUE@@EVAS_STATIC_BUILD_JPEG_FALSE@module_la_LIBTOOLFLAGS = --tag=disable-static -@BUILD_LOADER_JPEG_TRUE@@EVAS_STATIC_BUILD_JPEG_TRUE@noinst_LTLIBRARIES = libevas_loader_jpeg.la -@BUILD_LOADER_JPEG_TRUE@@EVAS_STATIC_BUILD_JPEG_TRUE@libevas_loader_jpeg_la_SOURCES = evas_image_load_jpeg.c -@BUILD_LOADER_JPEG_TRUE@@EVAS_STATIC_BUILD_JPEG_TRUE@libevas_loader_jpeg_la_LIBADD = @evas_image_loader_jpeg_libs@ -all: all-am - -.SUFFIXES: -.SUFFIXES: .c .lo .o .obj -$(srcdir)/Makefile.in: $(srcdir)/Makefile.am $(am__configure_deps) - @for dep in $?; do \ - case '$(am__configure_deps)' in \ - *$$dep*) \ - ( cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh ) \ - && { if test -f $@; then exit 0; else break; fi; }; \ - exit 1;; \ - esac; \ - done; \ - echo ' cd $(top_srcdir) && $(AUTOMAKE) --gnu src/modules/loaders/jpeg/Makefile'; \ - $(am__cd) $(top_srcdir) && \ - $(AUTOMAKE) --gnu src/modules/loaders/jpeg/Makefile -.PRECIOUS: Makefile -Makefile: $(srcdir)/Makefile.in $(top_builddir)/config.status - @case '$?' in \ - *config.status*) \ - cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh;; \ - *) \ - echo ' cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ $(am__depfiles_maybe)'; \ - cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ $(am__depfiles_maybe);; \ - esac; - -$(top_builddir)/config.status: $(top_srcdir)/configure $(CONFIG_STATUS_DEPENDENCIES) - cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh - -$(top_srcdir)/configure: $(am__configure_deps) - cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh -$(ACLOCAL_M4): $(am__aclocal_m4_deps) - cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh -$(am__aclocal_m4_deps): - -clean-noinstLTLIBRARIES: - -test -z "$(noinst_LTLIBRARIES)" || rm -f $(noinst_LTLIBRARIES) - @list='$(noinst_LTLIBRARIES)'; for p in $$list; do \ - dir="`echo $$p | sed -e 's|/[^/]*$$||'`"; \ - test "$$dir" != "$$p" || dir=.; \ - echo "rm -f \"$${dir}/so_locations\""; \ - rm -f "$${dir}/so_locations"; \ - done -install-pkgLTLIBRARIES: $(pkg_LTLIBRARIES) - @$(NORMAL_INSTALL) - test -z "$(pkgdir)" || $(MKDIR_P) "$(DESTDIR)$(pkgdir)" - @list='$(pkg_LTLIBRARIES)'; test -n "$(pkgdir)" || list=; \ - list2=; for p in $$list; do \ - if test -f $$p; then \ - list2="$$list2 $$p"; \ - else :; fi; \ - done; \ - test -z "$$list2" || { \ - echo " $(LIBTOOL) $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=install $(INSTALL) $(INSTALL_STRIP_FLAG) $$list2 '$(DESTDIR)$(pkgdir)'"; \ - $(LIBTOOL) $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=install $(INSTALL) $(INSTALL_STRIP_FLAG) $$list2 "$(DESTDIR)$(pkgdir)"; \ - } - -uninstall-pkgLTLIBRARIES: - @$(NORMAL_UNINSTALL) - @list='$(pkg_LTLIBRARIES)'; test -n "$(pkgdir)" || list=; \ - for p in $$list; do \ - $(am__strip_dir) \ - echo " $(LIBTOOL) $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=uninstall rm -f '$(DESTDIR)$(pkgdir)/$$f'"; \ - $(LIBTOOL) $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=uninstall rm -f "$(DESTDIR)$(pkgdir)/$$f"; \ - done - -clean-pkgLTLIBRARIES: - -test -z "$(pkg_LTLIBRARIES)" || rm -f $(pkg_LTLIBRARIES) - @list='$(pkg_LTLIBRARIES)'; for p in $$list; do \ - dir="`echo $$p | sed -e 's|/[^/]*$$||'`"; \ - test "$$dir" != "$$p" || dir=.; \ - echo "rm -f \"$${dir}/so_locations\""; \ - rm -f "$${dir}/so_locations"; \ - done -libevas_loader_jpeg.la: $(libevas_loader_jpeg_la_OBJECTS) $(libevas_loader_jpeg_la_DEPENDENCIES) - $(AM_V_CCLD)$(LINK) $(am_libevas_loader_jpeg_la_rpath) $(libevas_loader_jpeg_la_OBJECTS) $(libevas_loader_jpeg_la_LIBADD) $(LIBS) -module.la: $(module_la_OBJECTS) $(module_la_DEPENDENCIES) - $(AM_V_CCLD)$(module_la_LINK) $(am_module_la_rpath) $(module_la_OBJECTS) $(module_la_LIBADD) $(LIBS) - -mostlyclean-compile: - -rm -f *.$(OBJEXT) - -distclean-compile: - -rm -f *.tab.c - -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/evas_image_load_jpeg.Plo@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/module_la-evas_image_load_jpeg.Plo@am__quote@ - -.c.o: -@am__fastdepCC_TRUE@ $(AM_V_CC)$(COMPILE) -MT $@ -MD -MP -MF $(DEPDIR)/$*.Tpo -c -o $@ $< -@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/$*.Tpo $(DEPDIR)/$*.Po -@am__fastdepCC_FALSE@ $(AM_V_CC) @AM_BACKSLASH@ -@AMDEP_TRUE@@am__fastdepCC_FALSE@ source='$<' object='$@' libtool=no @AMDEPBACKSLASH@ -@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ -@am__fastdepCC_FALSE@ $(COMPILE) -c $< - -.c.obj: -@am__fastdepCC_TRUE@ $(AM_V_CC)$(COMPILE) -MT $@ -MD -MP -MF $(DEPDIR)/$*.Tpo -c -o $@ `$(CYGPATH_W) '$<'` -@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/$*.Tpo $(DEPDIR)/$*.Po -@am__fastdepCC_FALSE@ $(AM_V_CC) @AM_BACKSLASH@ -@AMDEP_TRUE@@am__fastdepCC_FALSE@ source='$<' object='$@' libtool=no @AMDEPBACKSLASH@ -@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ -@am__fastdepCC_FALSE@ $(COMPILE) -c `$(CYGPATH_W) '$<'` - -.c.lo: -@am__fastdepCC_TRUE@ $(AM_V_CC)$(LTCOMPILE) -MT $@ -MD -MP -MF $(DEPDIR)/$*.Tpo -c -o $@ $< -@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/$*.Tpo $(DEPDIR)/$*.Plo -@am__fastdepCC_FALSE@ $(AM_V_CC) @AM_BACKSLASH@ -@AMDEP_TRUE@@am__fastdepCC_FALSE@ source='$<' object='$@' libtool=yes @AMDEPBACKSLASH@ -@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ -@am__fastdepCC_FALSE@ $(LTCOMPILE) -c -o $@ $< - -module_la-evas_image_load_jpeg.lo: evas_image_load_jpeg.c -@am__fastdepCC_TRUE@ $(AM_V_CC)$(LIBTOOL) $(AM_V_lt) --tag=CC $(module_la_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT module_la-evas_image_load_jpeg.lo -MD -MP -MF $(DEPDIR)/module_la-evas_image_load_jpeg.Tpo -c -o module_la-evas_image_load_jpeg.lo `test -f 'evas_image_load_jpeg.c' || echo '$(srcdir)/'`evas_image_load_jpeg.c -@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/module_la-evas_image_load_jpeg.Tpo $(DEPDIR)/module_la-evas_image_load_jpeg.Plo -@am__fastdepCC_FALSE@ $(AM_V_CC) @AM_BACKSLASH@ -@AMDEP_TRUE@@am__fastdepCC_FALSE@ source='evas_image_load_jpeg.c' object='module_la-evas_image_load_jpeg.lo' libtool=yes @AMDEPBACKSLASH@ -@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ -@am__fastdepCC_FALSE@ $(LIBTOOL) $(AM_V_lt) --tag=CC $(module_la_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o module_la-evas_image_load_jpeg.lo `test -f 'evas_image_load_jpeg.c' || echo '$(srcdir)/'`evas_image_load_jpeg.c - -mostlyclean-libtool: - -rm -f *.lo - -clean-libtool: - -rm -rf .libs _libs - -ID: $(HEADERS) $(SOURCES) $(LISP) $(TAGS_FILES) - list='$(SOURCES) $(HEADERS) $(LISP) $(TAGS_FILES)'; \ - unique=`for i in $$list; do \ - if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \ - done | \ - $(AWK) '{ files[$$0] = 1; nonempty = 1; } \ - END { if (nonempty) { for (i in files) print i; }; }'`; \ - mkid -fID $$unique -tags: TAGS - -TAGS: $(HEADERS) $(SOURCES) $(TAGS_DEPENDENCIES) \ - $(TAGS_FILES) $(LISP) - set x; \ - here=`pwd`; \ - list='$(SOURCES) $(HEADERS) $(LISP) $(TAGS_FILES)'; \ - unique=`for i in $$list; do \ - if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \ - done | \ - $(AWK) '{ files[$$0] = 1; nonempty = 1; } \ - END { if (nonempty) { for (i in files) print i; }; }'`; \ - shift; \ - if test -z "$(ETAGS_ARGS)$$*$$unique"; then :; else \ - test -n "$$unique" || unique=$$empty_fix; \ - if test $$# -gt 0; then \ - $(ETAGS) $(ETAGSFLAGS) $(AM_ETAGSFLAGS) $(ETAGS_ARGS) \ - "$$@" $$unique; \ - else \ - $(ETAGS) $(ETAGSFLAGS) $(AM_ETAGSFLAGS) $(ETAGS_ARGS) \ - $$unique; \ - fi; \ - fi -ctags: CTAGS -CTAGS: $(HEADERS) $(SOURCES) $(TAGS_DEPENDENCIES) \ - $(TAGS_FILES) $(LISP) - list='$(SOURCES) $(HEADERS) $(LISP) $(TAGS_FILES)'; \ - unique=`for i in $$list; do \ - if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \ - done | \ - $(AWK) '{ files[$$0] = 1; nonempty = 1; } \ - END { if (nonempty) { for (i in files) print i; }; }'`; \ - test -z "$(CTAGS_ARGS)$$unique" \ - || $(CTAGS) $(CTAGSFLAGS) $(AM_CTAGSFLAGS) $(CTAGS_ARGS) \ - $$unique - -GTAGS: - here=`$(am__cd) $(top_builddir) && pwd` \ - && $(am__cd) $(top_srcdir) \ - && gtags -i $(GTAGS_ARGS) "$$here" - -distclean-tags: - -rm -f TAGS ID GTAGS GRTAGS GSYMS GPATH tags - -distdir: $(DISTFILES) - @srcdirstrip=`echo "$(srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \ - topsrcdirstrip=`echo "$(top_srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \ - list='$(DISTFILES)'; \ - dist_files=`for file in $$list; do echo $$file; done | \ - sed -e "s|^$$srcdirstrip/||;t" \ - -e "s|^$$topsrcdirstrip/|$(top_builddir)/|;t"`; \ - case $$dist_files in \ - */*) $(MKDIR_P) `echo "$$dist_files" | \ - sed '/\//!d;s|^|$(distdir)/|;s,/[^/]*$$,,' | \ - sort -u` ;; \ - esac; \ - for file in $$dist_files; do \ - if test -f $$file || test -d $$file; then d=.; else d=$(srcdir); fi; \ - if test -d $$d/$$file; then \ - dir=`echo "/$$file" | sed -e 's,/[^/]*$$,,'`; \ - if test -d "$(distdir)/$$file"; then \ - find "$(distdir)/$$file" -type d ! -perm -700 -exec chmod u+rwx {} \;; \ - fi; \ - if test -d $(srcdir)/$$file && test $$d != $(srcdir); then \ - cp -fpR $(srcdir)/$$file "$(distdir)$$dir" || exit 1; \ - find "$(distdir)/$$file" -type d ! -perm -700 -exec chmod u+rwx {} \;; \ - fi; \ - cp -fpR $$d/$$file "$(distdir)$$dir" || exit 1; \ - else \ - test -f "$(distdir)/$$file" \ - || cp -p $$d/$$file "$(distdir)/$$file" \ - || exit 1; \ - fi; \ - done -check-am: all-am -check: check-am -all-am: Makefile $(LTLIBRARIES) -installdirs: - for dir in "$(DESTDIR)$(pkgdir)"; do \ - test -z "$$dir" || $(MKDIR_P) "$$dir"; \ - done -install: install-am -install-exec: install-exec-am -install-data: install-data-am -uninstall: uninstall-am - -install-am: all-am - @$(MAKE) $(AM_MAKEFLAGS) install-exec-am install-data-am - -installcheck: installcheck-am -install-strip: - $(MAKE) $(AM_MAKEFLAGS) INSTALL_PROGRAM="$(INSTALL_STRIP_PROGRAM)" \ - install_sh_PROGRAM="$(INSTALL_STRIP_PROGRAM)" INSTALL_STRIP_FLAG=-s \ - `test -z '$(STRIP)' || \ - echo "INSTALL_PROGRAM_ENV=STRIPPROG='$(STRIP)'"` install -mostlyclean-generic: - -clean-generic: - -distclean-generic: - -test -z "$(CONFIG_CLEAN_FILES)" || rm -f $(CONFIG_CLEAN_FILES) - -test . = "$(srcdir)" || test -z "$(CONFIG_CLEAN_VPATH_FILES)" || rm -f $(CONFIG_CLEAN_VPATH_FILES) - -maintainer-clean-generic: - @echo "This command is intended for maintainers to use" - @echo "it deletes files that may require special tools to rebuild." - -test -z "$(MAINTAINERCLEANFILES)" || rm -f $(MAINTAINERCLEANFILES) -clean: clean-am - -clean-am: clean-generic clean-libtool clean-noinstLTLIBRARIES \ - clean-pkgLTLIBRARIES mostlyclean-am - -distclean: distclean-am - -rm -rf ./$(DEPDIR) - -rm -f Makefile -distclean-am: clean-am distclean-compile distclean-generic \ - distclean-tags - -dvi: dvi-am - -dvi-am: - -html: html-am - -html-am: - -info: info-am - -info-am: - -install-data-am: install-pkgLTLIBRARIES - -install-dvi: install-dvi-am - -install-dvi-am: - -install-exec-am: - -install-html: install-html-am - -install-html-am: - -install-info: install-info-am - -install-info-am: - -install-man: - -install-pdf: install-pdf-am - -install-pdf-am: - -install-ps: install-ps-am - -install-ps-am: - -installcheck-am: - -maintainer-clean: maintainer-clean-am - -rm -rf ./$(DEPDIR) - -rm -f Makefile -maintainer-clean-am: distclean-am maintainer-clean-generic - -mostlyclean: mostlyclean-am - -mostlyclean-am: mostlyclean-compile mostlyclean-generic \ - mostlyclean-libtool - -pdf: pdf-am - -pdf-am: - -ps: ps-am - -ps-am: - -uninstall-am: uninstall-pkgLTLIBRARIES - -.MAKE: install-am install-strip - -.PHONY: CTAGS GTAGS all all-am check check-am clean clean-generic \ - clean-libtool clean-noinstLTLIBRARIES clean-pkgLTLIBRARIES \ - ctags distclean distclean-compile distclean-generic \ - distclean-libtool distclean-tags distdir dvi dvi-am html \ - html-am info info-am install install-am install-data \ - install-data-am install-dvi install-dvi-am install-exec \ - install-exec-am install-html install-html-am install-info \ - install-info-am install-man install-pdf install-pdf-am \ - install-pkgLTLIBRARIES install-ps install-ps-am install-strip \ - installcheck installcheck-am installdirs maintainer-clean \ - maintainer-clean-generic mostlyclean mostlyclean-compile \ - mostlyclean-generic mostlyclean-libtool pdf pdf-am ps ps-am \ - tags uninstall uninstall-am uninstall-pkgLTLIBRARIES - - -# Tell versions [3.59,3.63) of GNU make to not export all variables. -# Otherwise a system limit (for SysV at least) may be exceeded. -.NOEXPORT: diff --git a/libraries/evas/src/modules/loaders/jpeg/evas_image_load_jpeg.c b/libraries/evas/src/modules/loaders/jpeg/evas_image_load_jpeg.c deleted file mode 100644 index 73a7310..0000000 --- a/libraries/evas/src/modules/loaders/jpeg/evas_image_load_jpeg.c +++ /dev/null @@ -1,1275 +0,0 @@ -#ifdef HAVE_CONFIG_H -# include -#endif - -#include - -#ifdef HAVE_EVIL -# include -#endif - -#include -#include - -#include "evas_common.h" -#include "evas_private.h" - - -typedef struct _JPEG_error_mgr *emptr; -struct _JPEG_error_mgr -{ - struct jpeg_error_mgr pub; - jmp_buf setjmp_buffer; -}; - -static void _JPEGFatalErrorHandler(j_common_ptr cinfo); -static void _JPEGErrorHandler(j_common_ptr cinfo); -static void _JPEGErrorHandler2(j_common_ptr cinfo, int msg_level); - -static Eina_Bool evas_image_load_file_head_jpeg_internal(Image_Entry *ie, - void *map, - size_t len, - int *error) EINA_ARG_NONNULL(1, 2, 4); -static Eina_Bool evas_image_load_file_data_jpeg_internal(Image_Entry *ie, - void *map, - size_t len, - int *error) EINA_ARG_NONNULL(1, 2, 4); -#if 0 /* not used at the moment */ -static int evas_image_load_file_data_jpeg_alpha_internal(Image_Entry *ie, FILE *f) EINA_ARG_NONNULL(1, 2); -#endif - -static Eina_Bool evas_image_load_file_head_jpeg(Image_Entry *ie, const char *file, const char *key, int *error) EINA_ARG_NONNULL(1, 2, 4); -static Eina_Bool evas_image_load_file_data_jpeg(Image_Entry *ie, const char *file, const char *key, int *error) EINA_ARG_NONNULL(1, 2, 4); - -static Evas_Image_Load_Func evas_image_load_jpeg_func = -{ - EINA_TRUE, - evas_image_load_file_head_jpeg, - evas_image_load_file_data_jpeg, - NULL, - EINA_TRUE -}; - - -static void -_JPEGFatalErrorHandler(j_common_ptr cinfo) -{ - emptr errmgr; - - errmgr = (emptr) cinfo->err; - /* cinfo->err->output_message(cinfo);*/ - longjmp(errmgr->setjmp_buffer, 1); - return; -} - -static void -_JPEGErrorHandler(j_common_ptr cinfo __UNUSED__) -{ -/* emptr errmgr; */ - -/* errmgr = (emptr) cinfo->err; */ - /* cinfo->err->output_message(cinfo);*/ - /* longjmp(errmgr->setjmp_buffer, 1);*/ - return; -} - -static void -_JPEGErrorHandler2(j_common_ptr cinfo __UNUSED__, int msg_level __UNUSED__) -{ -/* emptr errmgr; */ - -/* errmgr = (emptr) cinfo->err; */ - /* cinfo->err->output_message(cinfo);*/ - /* longjmp(errmgr->setjmp_buffer, 1);*/ - return; -} - -struct jpeg_membuf_src -{ - struct jpeg_source_mgr pub; - - const unsigned char *buf; - size_t len; - struct jpeg_membuf_src *self; -}; - -static void -_evas_jpeg_membuf_src_init(j_decompress_ptr cinfo __UNUSED__) -{ -} - -static boolean -_evas_jpeg_membuf_src_fill(j_decompress_ptr cinfo) -{ - static const JOCTET jpeg_eoi[2] = { 0xFF, JPEG_EOI }; - struct jpeg_membuf_src *src = (struct jpeg_membuf_src *)cinfo->src; - - src->pub.bytes_in_buffer = sizeof(jpeg_eoi); - src->pub.next_input_byte = jpeg_eoi; - - return TRUE; -} - -static void -_evas_jpeg_membuf_src_skip(j_decompress_ptr cinfo, - long num_bytes) -{ - struct jpeg_membuf_src *src = (struct jpeg_membuf_src *)cinfo->src; - - if ((((long)src->pub.bytes_in_buffer - (long)src->len) > num_bytes) || - ((long)src->pub.bytes_in_buffer < num_bytes)) - { - (*(cinfo)->err->error_exit) ((j_common_ptr) (cinfo)); - return; - } - src->pub.bytes_in_buffer -= num_bytes; - src->pub.next_input_byte += num_bytes; -} - -static void -_evas_jpeg_membuf_src_term(j_decompress_ptr cinfo) -{ - struct jpeg_membuf_src *src = (struct jpeg_membuf_src *)cinfo->src; - if (!src) return; - free(src); - cinfo->src = NULL; -} - -static int -_evas_jpeg_membuf_src(j_decompress_ptr cinfo, - void *map, size_t length) -{ - struct jpeg_membuf_src *src; - - src = calloc(1, sizeof(*src)); - if (!src) - return -1; - - src->self = src; - - cinfo->src = &src->pub; - src->buf = map; - src->len = length; - src->pub.init_source = _evas_jpeg_membuf_src_init; - src->pub.fill_input_buffer = _evas_jpeg_membuf_src_fill; - src->pub.skip_input_data = _evas_jpeg_membuf_src_skip; - src->pub.resync_to_restart = jpeg_resync_to_restart; - src->pub.term_source = _evas_jpeg_membuf_src_term; - src->pub.bytes_in_buffer = src->len; - src->pub.next_input_byte = src->buf; - - return 0; -} - -/*! Magic number for EXIF header & App1*/ -static const unsigned char ExifHeader[] = {0x45, 0x78, 0x69, 0x66, 0x00, 0x00}; -static const unsigned char App1[] = {0xff, 0xe1}; -typedef enum { - EXIF_BYTE_ALIGN_II, - EXIF_BYTE_ALIGN_MM -} ExifByteAlign; - -static int -_get_orientation(void *map, size_t length) -{ - char *buf; - char orientation[2]; - ExifByteAlign byte_align; - unsigned int num_directory = 0; - unsigned int i, j; - int direction; - - /* open file and get 22 byte frome file */ - if (!map) return 0; - /* 1. read 22byte */ - if (length < 22) return 0; - buf = (char *)map; - - /* 2. check 2,3 bypte with APP1(0xFFE1) */ - if (memcmp(buf + 2, App1, sizeof (App1))) return 0; - - /* 3. check 6~11bype with Exif Header (0x45786966 0000) */ - if (memcmp(buf + 6, ExifHeader, sizeof (ExifHeader))) return 0; - - /* 4. get 12&13 byte get info of "II(0x4949)" or "MM(0x4d4d)" */ - /* 5. get [20]&[21] get directory entry # */ - if (!strncmp(buf + 12, "MM", 2)) - { - byte_align = EXIF_BYTE_ALIGN_MM; - num_directory = ((*(buf + 20) << 8) + *(buf + 21)); - orientation[0] = 0x01; - orientation[1] = 0x12; - } - else if (!strncmp(buf + 12, "II", 2)) - { - byte_align = EXIF_BYTE_ALIGN_II; - num_directory = ((*(buf + 21) << 8) + *(buf + 20)); - orientation[0] = 0x12; - orientation[1] = 0x01; - } - else return 0; - - buf = map + 22; - - if (length < (12 * num_directory + 22)) return 0; - - j = 0; - - for (i = 0; i < num_directory; i++ ) - { - if (!strncmp(buf + j, orientation, 2)) - { - /*get orientation tag */ - if (byte_align == EXIF_BYTE_ALIGN_MM) - direction = *(buf+ j + 11); - else direction = *(buf+ j + 8); - switch (direction) - { - case 3: - case 4: - return 180; - case 6: - case 7: - return 90; - case 5: - case 8: - return 270; - default: - return 0; - } - } - else - j = j + 12; - } - return 0; -} - -static Eina_Bool -evas_image_load_file_head_jpeg_internal(Image_Entry *ie, - void *map, size_t length, - int *error) -{ - unsigned int w, h, scalew, scaleh; - struct jpeg_decompress_struct cinfo; - struct _JPEG_error_mgr jerr; - - /* for rotation decoding */ - int degree = 0; - Eina_Bool change_wh = EINA_FALSE; - unsigned int load_opts_w = 0, load_opts_h = 0; - - cinfo.err = jpeg_std_error(&(jerr.pub)); - jerr.pub.error_exit = _JPEGFatalErrorHandler; - jerr.pub.emit_message = _JPEGErrorHandler2; - jerr.pub.output_message = _JPEGErrorHandler; - if (setjmp(jerr.setjmp_buffer)) - { - jpeg_destroy_decompress(&cinfo); - _evas_jpeg_membuf_src_term(&cinfo); - if (cinfo.saw_JFIF_marker) - *error = EVAS_LOAD_ERROR_CORRUPT_FILE; - else - *error = EVAS_LOAD_ERROR_UNKNOWN_FORMAT; - return EINA_FALSE; - } - jpeg_create_decompress(&cinfo); - - if (_evas_jpeg_membuf_src(&cinfo, map, length)) - { - jpeg_destroy_decompress(&cinfo); - _evas_jpeg_membuf_src_term(&cinfo); - *error = EVAS_LOAD_ERROR_RESOURCE_ALLOCATION_FAILED; - return EINA_FALSE; - } - - jpeg_read_header(&cinfo, TRUE); - cinfo.do_fancy_upsampling = FALSE; - cinfo.do_block_smoothing = FALSE; - cinfo.dct_method = JDCT_ISLOW; // JDCT_FLOAT JDCT_IFAST(quality loss) - cinfo.dither_mode = JDITHER_ORDERED; - jpeg_start_decompress(&cinfo); - - /* rotation decoding */ - if (ie->load_opts.orientation) - { - degree = _get_orientation(map, length); - if (degree != 0) - { - ie->load_opts.degree = degree; - ie->flags.rotated = EINA_TRUE; - - if (degree == 90 || degree == 270) - change_wh = EINA_TRUE; - } - - } - - /* head decoding */ - w = cinfo.output_width; - h = cinfo.output_height; - if ((w < 1) || (h < 1) || (w > IMG_MAX_SIZE) || (h > IMG_MAX_SIZE) || - (IMG_TOO_BIG(w, h))) - { - jpeg_destroy_decompress(&cinfo); - _evas_jpeg_membuf_src_term(&cinfo); - if (IMG_TOO_BIG(w, h)) - *error = EVAS_LOAD_ERROR_RESOURCE_ALLOCATION_FAILED; - else - *error = EVAS_LOAD_ERROR_GENERIC; - return EINA_FALSE; - } - if (ie->load_opts.scale_down_by > 1) - { - w /= ie->load_opts.scale_down_by; - h /= ie->load_opts.scale_down_by; - } - else if (ie->load_opts.dpi > 0.0) - { - w = (w * ie->load_opts.dpi) / 90.0; - h = (h * ie->load_opts.dpi) / 90.0; - } - else if ((ie->load_opts.w > 0) && (ie->load_opts.h > 0)) - { - unsigned int w2 = w, h2 = h; - /* user set load_opts' w,h on the assumption - that image already rotated according to it's orientation info */ - if (change_wh) - { - load_opts_w = ie->load_opts.w; - load_opts_h = ie->load_opts.h; - ie->load_opts.w = load_opts_h; - ie->load_opts.h = load_opts_w; - } - - if (ie->load_opts.w > 0) - { - w2 = ie->load_opts.w; - h2 = (ie->load_opts.w * h) / w; - if ((ie->load_opts.h > 0) && (h2 > ie->load_opts.h)) - { - unsigned int w3; - h2 = ie->load_opts.h; - w3 = (ie->load_opts.h * w) / h; - if (w3 > w2) - w2 = w3; - } - } - else if (ie->load_opts.h > 0) - { - h2 = ie->load_opts.h; - w2 = (ie->load_opts.h * w) / h; - } - w = w2; - h = h2; - if (change_wh) - { - ie->load_opts.w = load_opts_w; - ie->load_opts.h = load_opts_h; - } - } - if (w < 1) w = 1; - if (h < 1) h = 1; - - if ((w != cinfo.output_width) || (h != cinfo.output_height)) - { - scalew = cinfo.output_width / w; - scaleh = cinfo.output_height / h; - - ie->scale = scalew; - if (scaleh < scalew) ie->scale = scaleh; - - if (ie->scale > 8) ie->scale = 8; - else if (ie->scale < 1) ie->scale = 1; - - if (ie->scale == 3) ie->scale = 2; - else if (ie->scale == 5) ie->scale = 4; - else if (ie->scale == 6) ie->scale = 4; - else if (ie->scale == 7) ie->scale = 4; - } - - if (ie->scale > 1) - { - jpeg_destroy_decompress(&cinfo); - _evas_jpeg_membuf_src_term(&cinfo); - jpeg_create_decompress(&cinfo); - - if (_evas_jpeg_membuf_src(&cinfo, map, length)) - { - jpeg_destroy_decompress(&cinfo); - _evas_jpeg_membuf_src_term(&cinfo); - *error = EVAS_LOAD_ERROR_RESOURCE_ALLOCATION_FAILED; - return EINA_FALSE; - } - - jpeg_read_header(&cinfo, TRUE); - cinfo.do_fancy_upsampling = FALSE; - cinfo.do_block_smoothing = FALSE; - cinfo.scale_num = 1; - cinfo.scale_denom = ie->scale; - jpeg_calc_output_dimensions(&(cinfo)); - jpeg_start_decompress(&cinfo); - } - - ie->w = cinfo.output_width; - ie->h = cinfo.output_height; - - // be nice and clip region to image. if its totally outside, fail load - if ((ie->load_opts.region.w > 0) && (ie->load_opts.region.h > 0)) - { - unsigned int load_region_x = 0, load_region_y = 0; - unsigned int load_region_w = 0, load_region_h = 0; - if (ie->flags.rotated) - { - load_region_x = ie->load_opts.region.x; - load_region_y = ie->load_opts.region.y; - load_region_w = ie->load_opts.region.w; - load_region_h = ie->load_opts.region.h; - - switch (degree) - { - case 90: - ie->load_opts.region.x = load_region_y; - ie->load_opts.region.y = h - (load_region_x + load_region_w); - ie->load_opts.region.w = load_region_h; - ie->load_opts.region.h = load_region_w; - break; - case 180: - ie->load_opts.region.x = w - (load_region_x+ load_region_w); - ie->load_opts.region.y = h - (load_region_y + load_region_h); - - break; - case 270: - ie->load_opts.region.x = w - (load_region_y + load_region_h); - ie->load_opts.region.y = load_region_x; - ie->load_opts.region.w = load_region_h; - ie->load_opts.region.h = load_region_w; - break; - default: - break; - } - - } - RECTS_CLIP_TO_RECT(ie->load_opts.region.x, ie->load_opts.region.y, - ie->load_opts.region.w, ie->load_opts.region.h, - 0, 0, ie->w, ie->h); - if ((ie->load_opts.region.w <= 0) || (ie->load_opts.region.h <= 0)) - { - jpeg_destroy_decompress(&cinfo); - _evas_jpeg_membuf_src_term(&cinfo); - *error = EVAS_LOAD_ERROR_GENERIC; - return EINA_FALSE; - } - ie->w = ie->load_opts.region.w; - ie->h = ie->load_opts.region.h; - if (ie->flags.rotated) - { - ie->load_opts.region.x = load_region_x; - ie->load_opts.region.y = load_region_y; - ie->load_opts.region.w = load_region_w; - ie->load_opts.region.h = load_region_h; - } - } -/* end head decoding */ - - if (change_wh) - { - unsigned int tmp; - tmp = ie->w; - ie->w = ie->h; - ie->h = tmp; - } - jpeg_destroy_decompress(&cinfo); - _evas_jpeg_membuf_src_term(&cinfo); - *error = EVAS_LOAD_ERROR_NONE; - return EINA_TRUE; -} - -/* -static double -get_time(void) -{ - struct timeval timev; - - gettimeofday(&timev, NULL); - return (double)timev.tv_sec + (((double)timev.tv_usec) / 1000000); -} -*/ - -static Eina_Bool -evas_image_load_file_data_jpeg_internal(Image_Entry *ie, - void *map, size_t size, - int *error) -{ - unsigned int w, h; - struct jpeg_decompress_struct cinfo; - struct _JPEG_error_mgr jerr; - DATA8 *ptr, *line[16], *data; - DATA32 *ptr2, *ptr_rotate = NULL; - unsigned int x, y, l, i, scans; - int region = 0; - /* rotation setting */ - unsigned int ie_w = 0, ie_h = 0; - unsigned int load_region_x = 0, load_region_y = 0; - unsigned int load_region_w = 0, load_region_h = 0; - volatile int degree = 0; - volatile Eina_Bool change_wh = EINA_FALSE; - Eina_Bool line_done = EINA_FALSE; - - if (ie->flags.rotated) - { - degree = ie->load_opts.degree; - if (degree == 90 || degree == 270) - change_wh = EINA_TRUE; - } - - cinfo.err = jpeg_std_error(&(jerr.pub)); - jerr.pub.error_exit = _JPEGFatalErrorHandler; - jerr.pub.emit_message = _JPEGErrorHandler2; - jerr.pub.output_message = _JPEGErrorHandler; - if (setjmp(jerr.setjmp_buffer)) - { - jpeg_destroy_decompress(&cinfo); - _evas_jpeg_membuf_src_term(&cinfo); - *error = EVAS_LOAD_ERROR_CORRUPT_FILE; - return EINA_FALSE; - } - jpeg_create_decompress(&cinfo); - - if (_evas_jpeg_membuf_src(&cinfo, map, size)) - { - jpeg_destroy_decompress(&cinfo); - _evas_jpeg_membuf_src_term(&cinfo); - *error = EVAS_LOAD_ERROR_RESOURCE_ALLOCATION_FAILED; - return 0; - } - - jpeg_read_header(&cinfo, TRUE); - cinfo.do_fancy_upsampling = FALSE; - cinfo.do_block_smoothing = FALSE; - cinfo.dct_method = JDCT_ISLOW; // JDCT_FLOAT JDCT_IFAST(quality loss) - cinfo.dither_mode = JDITHER_ORDERED; - - if (ie->scale > 1) - { - cinfo.scale_num = 1; - cinfo.scale_denom = ie->scale; - } - - /* Colorspace conversion options */ - /* libjpeg can do the following conversions: */ - /* GRAYSCLAE => RGB YCbCr => RGB and YCCK => CMYK */ - switch (cinfo.jpeg_color_space) - { - case JCS_UNKNOWN: - break; - case JCS_GRAYSCALE: - case JCS_RGB: - case JCS_YCbCr: - cinfo.out_color_space = JCS_RGB; - break; - case JCS_CMYK: - case JCS_YCCK: - cinfo.out_color_space = JCS_CMYK; - break; - } - -/* head decoding */ - jpeg_calc_output_dimensions(&(cinfo)); - jpeg_start_decompress(&cinfo); - - w = cinfo.output_width; - h = cinfo.output_height; - - if (change_wh) - { - ie_w = ie->h; - ie_h = ie->w; - } - else - { - ie_w = ie->w; - ie_h = ie->h; - } - - if ((ie->load_opts.region.w > 0) && (ie->load_opts.region.h > 0)) - { - region = 1; - - if (ie->flags.rotated) - { - load_region_x = ie->load_opts.region.x; - load_region_y = ie->load_opts.region.y; - load_region_w = ie->load_opts.region.w; - load_region_h = ie->load_opts.region.h; - - switch (degree) - { - case 90: - ie->load_opts.region.x = load_region_y; - ie->load_opts.region.y = h - (load_region_x + load_region_w); - ie->load_opts.region.w = load_region_h; - ie->load_opts.region.h = load_region_w; - break; - case 180: - ie->load_opts.region.x = w - (load_region_x+ load_region_w); - ie->load_opts.region.y = h - (load_region_y + load_region_h); - - break; - case 270: - ie->load_opts.region.x = w - (load_region_y + load_region_h); - ie->load_opts.region.y = load_region_x; - ie->load_opts.region.w = load_region_h; - ie->load_opts.region.h = load_region_w; - break; - default: - break; - } - - } -#ifdef BUILD_LOADER_JPEG_REGION - cinfo.region_x = ie->load_opts.region.x; - cinfo.region_y = ie->load_opts.region.y; - cinfo.region_w = ie->load_opts.region.w; - cinfo.region_h = ie->load_opts.region.h; -#endif - } - if ((!region) && ((w != ie_w) || (h != ie_h))) - { - // race condition, the file could have change from when we call header - // this test will not solve the problem with region code. - jpeg_destroy_decompress(&cinfo); - _evas_jpeg_membuf_src_term(&cinfo); - *error = EVAS_LOAD_ERROR_GENERIC; - return EINA_FALSE; - } - if ((region) && - ((ie_w != ie->load_opts.region.w) || (ie_h != ie->load_opts.region.h))) - { - ie_w = ie->load_opts.region.w; - ie_h = ie->load_opts.region.h; - if (change_wh) - { - ie->w = ie_h; - ie->h = ie_w; - } - else - { - ie->w = ie_w; - ie->h = ie_h; - } - - } - - if (!(((cinfo.out_color_space == JCS_RGB) && - ((cinfo.output_components == 3) || (cinfo.output_components == 1))) || - ((cinfo.out_color_space == JCS_CMYK) && (cinfo.output_components == 4)))) - { - jpeg_destroy_decompress(&cinfo); - _evas_jpeg_membuf_src_term(&cinfo); - *error = EVAS_LOAD_ERROR_UNKNOWN_FORMAT; - return EINA_FALSE; - } - -/* end head decoding */ -/* data decoding */ - if (cinfo.rec_outbuf_height > 16) - { - jpeg_destroy_decompress(&cinfo); - _evas_jpeg_membuf_src_term(&cinfo); - *error = EVAS_LOAD_ERROR_UNKNOWN_FORMAT; - return EINA_FALSE; - } - data = alloca(w * 16 * cinfo.output_components); - evas_cache_image_surface_alloc(ie, ie->w, ie->h); - if (ie->flags.loaded) - { - jpeg_destroy_decompress(&cinfo); - _evas_jpeg_membuf_src_term(&cinfo); - *error = EVAS_LOAD_ERROR_NONE; - if (region && ie->flags.rotated) - { - ie->load_opts.region.x = load_region_x; - ie->load_opts.region.y = load_region_y; - ie->load_opts.region.w = load_region_w; - ie->load_opts.region.h = load_region_h; - } - return EINA_TRUE; - } - if ((ie->flags.rotated) && change_wh) - { - ptr2 = malloc(ie->w * ie->h * sizeof(DATA32)); - ptr_rotate = ptr2; - } - else - ptr2 = evas_cache_image_pixels(ie); - - if (!ptr2) - { - *error = EVAS_LOAD_ERROR_RESOURCE_ALLOCATION_FAILED; - return EINA_FALSE; - } - - /* We handle first CMYK (4 components) */ - if (cinfo.output_components == 4) - { - // FIXME: handle region - for (i = 0; (int)i < cinfo.rec_outbuf_height; i++) - line[i] = data + (i * w * 4); - for (l = 0; l < h; l += cinfo.rec_outbuf_height) - { - jpeg_read_scanlines(&cinfo, line, cinfo.rec_outbuf_height); - scans = cinfo.rec_outbuf_height; - if ((h - l) < scans) scans = h - l; - ptr = data; - if (!region) - { - for (y = 0; y < scans; y++) - { - if (cinfo.saw_Adobe_marker) - { - for (x = 0; x < w; x++) - { - /* According to libjpeg doc, Photoshop inverse the values of C, M, Y and K, */ - /* that is C is replaces by 255 - C, etc...*/ - /* See the comment below for the computation of RGB values from CMYK ones. */ - *ptr2 = - (0xff000000) | - ((ptr[0] * ptr[3] / 255) << 16) | - ((ptr[1] * ptr[3] / 255) << 8) | - ((ptr[2] * ptr[3] / 255)); - ptr += 4; - ptr2++; - } - } - else - { - for (x = 0; x < w; x++) - { - /* Conversion from CMYK to RGB is done in 2 steps: */ - /* CMYK => CMY => RGB (see http://www.easyrgb.com/index.php?X=MATH) */ - /* after computation, if C, M, Y and K are between 0 and 1, we have: */ - /* R = (1 - C) * (1 - K) * 255 */ - /* G = (1 - M) * (1 - K) * 255 */ - /* B = (1 - Y) * (1 - K) * 255 */ - /* libjpeg stores CMYK values between 0 and 255, */ - /* so we replace C by C * 255 / 255, etc... and we obtain: */ - /* R = (255 - C) * (255 - K) / 255 */ - /* G = (255 - M) * (255 - K) / 255 */ - /* B = (255 - Y) * (255 - K) / 255 */ - /* with C, M, Y and K between 0 and 255. */ - *ptr2 = - (0xff000000) | - (((255 - ptr[0]) * (255 - ptr[3]) / 255) << 16) | - (((255 - ptr[1]) * (255 - ptr[3]) / 255) << 8) | - (((255 - ptr[2]) * (255 - ptr[3]) / 255)); - ptr += 4; - ptr2++; - } - } - } - } - else - { - // if line # > region last line, break - if (l >= (ie->load_opts.region.y + ie->load_opts.region.h)) - { - line_done = EINA_TRUE; - /* if rotation flag is set , we have to rotate image */ - goto done; - /*jpeg_destroy_decompress(&cinfo); - _evas_jpeg_membuf_src_term(&cinfo); - *error = EVAS_LOAD_ERROR_NONE; - return EINA_FALSE;*/ - } - // els if scan block intersects region start or later - else if ((l + scans) > - (ie->load_opts.region.y)) - { - for (y = 0; y < scans; y++) - { - if (((y + l) >= ie->load_opts.region.y) && - ((y + l) < (ie->load_opts.region.y + ie->load_opts.region.h))) - { - ptr += ie->load_opts.region.x; - if (cinfo.saw_Adobe_marker) - { - for (x = 0; x < ie->load_opts.region.w; x++) - { - /* According to libjpeg doc, Photoshop inverse the values of C, M, Y and K, */ - /* that is C is replaces by 255 - C, etc...*/ - /* See the comment below for the computation of RGB values from CMYK ones. */ - *ptr2 = - (0xff000000) | - ((ptr[0] * ptr[3] / 255) << 16) | - ((ptr[1] * ptr[3] / 255) << 8) | - ((ptr[2] * ptr[3] / 255)); - ptr += 4; - ptr2++; - } - } - else - { - for (x = 0; x < ie->load_opts.region.w; x++) - { - /* Conversion from CMYK to RGB is done in 2 steps: */ - /* CMYK => CMY => RGB (see http://www.easyrgb.com/index.php?X=MATH) */ - /* after computation, if C, M, Y and K are between 0 and 1, we have: */ - /* R = (1 - C) * (1 - K) * 255 */ - /* G = (1 - M) * (1 - K) * 255 */ - /* B = (1 - Y) * (1 - K) * 255 */ - /* libjpeg stores CMYK values between 0 and 255, */ - /* so we replace C by C * 255 / 255, etc... and we obtain: */ - /* R = (255 - C) * (255 - K) / 255 */ - /* G = (255 - M) * (255 - K) / 255 */ - /* B = (255 - Y) * (255 - K) / 255 */ - /* with C, M, Y and K between 0 and 255. */ - *ptr2 = - (0xff000000) | - (((255 - ptr[0]) * (255 - ptr[3]) / 255) << 16) | - (((255 - ptr[1]) * (255 - ptr[3]) / 255) << 8) | - (((255 - ptr[2]) * (255 - ptr[3]) / 255)); - ptr += 4; - ptr2++; - } - } - ptr += (4 * (w - (ie->load_opts.region.x + ie->load_opts.region.w))); - } - else - ptr += (4 * w); - } - } - } - } - } - /* We handle then RGB with 3 components */ - else if (cinfo.output_components == 3) - { -/* - double t; - if (region) - { - // debug for now - printf("R| %p %5ix%5i %s: %5i %5i %5ix%5i - ", - ie, - ie->w, ie->h, - ie->file, - ie->load_opts.region.x, - ie->load_opts.region.y, - ie->load_opts.region.w, - ie->load_opts.region.h); - } - t = get_time(); - */ - for (i = 0; (int)i < cinfo.rec_outbuf_height; i++) - line[i] = data + (i * w * 3); - for (l = 0; l < h; l += cinfo.rec_outbuf_height) - { - jpeg_read_scanlines(&cinfo, line, cinfo.rec_outbuf_height); - scans = cinfo.rec_outbuf_height; - if ((h - l) < scans) scans = h - l; - ptr = data; - if (!region) - { - for (y = 0; y < scans; y++) - { - for (x = 0; x < w; x++) - { - *ptr2 = ARGB_JOIN(0xff, ptr[0], ptr[1], ptr[2]); - ptr += 3; - ptr2++; - } - } - } - else - { - // if line # > region last line, break - // but not return immediately for rotation job - if (l >= (ie->load_opts.region.y + ie->load_opts.region.h)) - { - line_done = EINA_TRUE; - /* if rotation flag is set , we have to rotate image */ - goto done; - } - // else if scan block intersects region start or later - else if ((l + scans) > - (ie->load_opts.region.y)) - { - for (y = 0; y < scans; y++) - { - if (((y + l) >= ie->load_opts.region.y) && - ((y + l) < (ie->load_opts.region.y + ie->load_opts.region.h))) - { - ptr += (3 * ie->load_opts.region.x); - for (x = 0; x < ie->load_opts.region.w; x++) - { - *ptr2 = ARGB_JOIN(0xff, ptr[0], ptr[1], ptr[2]); - ptr += 3; - ptr2++; - } - ptr += (3 * (w - (ie->load_opts.region.x + ie->load_opts.region.w))); - } - else - ptr += (3 * w); - } - } - } - } -/* - t = get_time() - t; - printf("%3.3f\n", t); - */ - } - /* We finally handle RGB with 1 component */ - else if (cinfo.output_components == 1) - { - for (i = 0; (int)i < cinfo.rec_outbuf_height; i++) - line[i] = data + (i * w); - for (l = 0; l < h; l += cinfo.rec_outbuf_height) - { - jpeg_read_scanlines(&cinfo, line, cinfo.rec_outbuf_height); - scans = cinfo.rec_outbuf_height; - if ((h - l) < scans) scans = h - l; - ptr = data; - if (!region) - { - for (y = 0; y < scans; y++) - { - for (x = 0; x < w; x++) - { - *ptr2 = ARGB_JOIN(0xff, ptr[0], ptr[0], ptr[0]); - ptr++; - ptr2++; - } - } - } - else - { - // if line # > region last line, break - if (l >= (ie->load_opts.region.y + ie->load_opts.region.h)) - { - line_done = EINA_TRUE; - /* if rotation flag is set , we have to rotate image */ - goto done; - /*jpeg_destroy_decompress(&cinfo); - _evas_jpeg_membuf_src_term(&cinfo); - *error = EVAS_LOAD_ERROR_NONE; - return EINA_TRUE;*/ - } - // els if scan block intersects region start or later - else if ((l + scans) > - (ie->load_opts.region.y)) - { - for (y = 0; y < scans; y++) - { - if (((y + l) >= ie->load_opts.region.y) && - ((y + l) < (ie->load_opts.region.y + ie->load_opts.region.h))) - { - ptr += ie->load_opts.region.x; - for (x = 0; x < ie->load_opts.region.w; x++) - { - *ptr2 = ARGB_JOIN(0xff, ptr[0], ptr[0], ptr[0]); - ptr++; - ptr2++; - } - ptr += w - (ie->load_opts.region.x + ie->load_opts.region.w); - } - else - ptr += w; - } - } - } - } - } - /* if rotation operation need, rotate it */ -done: - - if (ie->flags.rotated) - { - DATA32 *data1, *data2, *to, *from; - int lx, ly, lw, lh, hw; - - lw = ie->w; - lh = ie->h; - hw =lw * lh; - - data1 = evas_cache_image_pixels(ie); - - if (degree == 180) - { - DATA32 tmpd; - - data2 = data1 + (lh * lw) -1; - for (lx = (lw * lh) / 2; --lx >= 0;) - { - tmpd = *data1; - *data1 = *data2; - *data2 = tmpd; - data1++; - data2--; - } - } - else - { - data2 = NULL; - to = NULL; - if (ptr_rotate) data2 = ptr_rotate; - - if (degree == 90) - { - to = data1 + lw - 1; - hw = -hw - 1; - } - else if (degree == 270) - { - to = data1 + hw - lw; - lw = -lw; - hw = hw + 1; - } - - if (to) - { - from = data2; - for (lx = ie->w; --lx >= 0;) - { - for (ly =ie->h; --ly >= 0;) - { - *to = *from; - from++; - to += lw; - } - to += hw; - } - } - if (ptr_rotate) - { - free(ptr_rotate); - ptr_rotate = NULL; - } - } - if (region) - { - ie->load_opts.region.x = load_region_x; - ie->load_opts.region.y = load_region_y; - ie->load_opts.region.w = load_region_w; - ie->load_opts.region.h = load_region_h; - } - } - - if (line_done) - { - jpeg_destroy_decompress(&cinfo); - _evas_jpeg_membuf_src_term(&cinfo); - *error = EVAS_LOAD_ERROR_NONE; - return EINA_FALSE; - } - /* end data decoding */ - jpeg_finish_decompress(&cinfo); - jpeg_destroy_decompress(&cinfo); - _evas_jpeg_membuf_src_term(&cinfo); - *error = EVAS_LOAD_ERROR_NONE; - return EINA_TRUE; -} - -#if 0 /* not used at the moment */ -static Eina_Bool -evas_image_load_file_data_jpeg_alpha_internal(Image_Entry *ie, FILE *f, int *error) -{ - int w, h; - struct jpeg_decompress_struct cinfo; - struct _JPEG_error_mgr jerr; - DATA8 *ptr, *line[16], *data; - DATA32 *ptr2; - int x, y, l, i, scans, prevy; - - if (!f) - { - *error = EVAS_LOAD_ERROR_DOES_NOT_EXIST; - return EINA_FALSE; - } - cinfo.err = jpeg_std_error(&(jerr.pub)); - jerr.pub.error_exit = _JPEGFatalErrorHandler; - jerr.pub.emit_message = _JPEGErrorHandler2; - jerr.pub.output_message = _JPEGErrorHandler; - if (setjmp(jerr.setjmp_buffer)) - { - jpeg_destroy_decompress(&cinfo); - *error = EVAS_LOAD_ERROR_CORRUPT_FILE; - return EINA_FALSE; - } - jpeg_create_decompress(&cinfo); - jpeg_stdio_src(&cinfo, f); - jpeg_read_header(&cinfo, TRUE); - cinfo.do_fancy_upsampling = FALSE; - cinfo.do_block_smoothing = FALSE; - jpeg_start_decompress(&cinfo); - -/* head decoding */ - ie->w = w = cinfo.output_width; - ie->h = h = cinfo.output_height; -/* end head decoding */ -/* data decoding */ - if (cinfo.rec_outbuf_height > 16) - { - jpeg_destroy_decompress(&cinfo); - *error = EVAS_LOAD_ERROR_UNKNOWN_FORMAT; - return EINA_FALSE;; - } - data = alloca(w * 16 * 3); - if (!ie->flags.loaded) - { - jpeg_destroy_decompress(&cinfo); - *error = EVAS_LOAD_ERROR_NONE; - return EINA_TRUE; - } - ptr2 = evas_cache_image_pixels(ie); - prevy = 0; - if (cinfo.output_components == 3) - { - for (i = 0; i < cinfo.rec_outbuf_height; i++) - line[i] = data + (i * w * 3); - for (l = 0; l < h; l += cinfo.rec_outbuf_height) - { - jpeg_read_scanlines(&cinfo, line, cinfo.rec_outbuf_height); - scans = cinfo.rec_outbuf_height; - if ((h - l) < scans) scans = h - l; - ptr = data; - for (y = 0; y < scans; y++) - { - for (x = 0; x < w; x++) - { - *ptr2 = - ((*ptr2) & 0x00ffffff) | - (((ptr[0] + ptr[1] + ptr[2]) / 3) << 24); - ptr += 3; - ptr2++; - } - } - } - } - else if (cinfo.output_components == 1) - { - for (i = 0; i < cinfo.rec_outbuf_height; i++) - line[i] = data + (i * w); - for (l = 0; l < h; l += cinfo.rec_outbuf_height) - { - jpeg_read_scanlines(&cinfo, line, cinfo.rec_outbuf_height); - scans = cinfo.rec_outbuf_height; - if ((h - l) < scans) scans = h - l; - ptr = data; - for (y = 0; y < scans; y++) - { - for (x = 0; x < w; x++) - { - *ptr2 = - ((*ptr2) & 0x00ffffff) | - ((ptr[0]) << 24); - ptr++; - ptr2++; - } - } - } - } -/* end data decoding */ - jpeg_finish_decompress(&cinfo); - jpeg_destroy_decompress(&cinfo); - *error = EVAS_LOAD_ERROR_NONE; - return EINA_TRUE; -} -#endif - -static Eina_Bool -evas_image_load_file_head_jpeg(Image_Entry *ie, - const char *file, const char *key __UNUSED__, - int *error) -{ - Eina_File *f; - void *map; - Eina_Bool val = EINA_FALSE; - - f = eina_file_open(file, EINA_FALSE); - if (!f) - { - *error = EVAS_LOAD_ERROR_DOES_NOT_EXIST; - return EINA_FALSE; - } - map = eina_file_map_all(f, EINA_FILE_WILLNEED); - if (!map) - { - *error = EVAS_LOAD_ERROR_DOES_NOT_EXIST; - goto on_error; - } - - val = evas_image_load_file_head_jpeg_internal(ie, - map, eina_file_size_get(f), - error); - - eina_file_map_free(f, map); - - on_error: - eina_file_close(f); - return val; -} - -static Eina_Bool -evas_image_load_file_data_jpeg(Image_Entry *ie, - const char *file, const char *key __UNUSED__, - int *error) -{ - Eina_File *f; - void *map; - Eina_Bool val = EINA_FALSE; - - f = eina_file_open(file, EINA_FALSE); - if (!f) - { - *error = EVAS_LOAD_ERROR_DOES_NOT_EXIST; - return EINA_FALSE; - } - map = eina_file_map_all(f, EINA_FILE_WILLNEED); - if (!map) - { - *error = EVAS_LOAD_ERROR_DOES_NOT_EXIST; - goto on_error; - } - - val = evas_image_load_file_data_jpeg_internal(ie, - map, eina_file_size_get(f), - error); - - eina_file_map_free(f, map); - - on_error: - eina_file_close(f); - return val; -} - -static int -module_open(Evas_Module *em) -{ - if (!em) return 0; - em->functions = (void *)(&evas_image_load_jpeg_func); - return 1; -} - -static void -module_close(Evas_Module *em __UNUSED__) -{ -} - -static Evas_Module_Api evas_modapi = -{ - EVAS_MODULE_API_VERSION, - "jpeg", - "none", - { - module_open, - module_close - } -}; - -EVAS_MODULE_DEFINE(EVAS_MODULE_TYPE_IMAGE_LOADER, image_loader, jpeg); - -#ifndef EVAS_STATIC_BUILD_JPEG -EVAS_EINA_MODULE_DEFINE(image_loader, jpeg); -#endif - -- cgit v1.1