epeg 1.0
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +7 -0
- data/Gemfile +4 -0
- data/MANIFEST +5 -0
- data/TODO +1 -0
- data/epeg/.dockerignore +4 -0
- data/epeg/.gitignore +5 -0
- data/epeg/CMakeLists.txt +30 -0
- data/epeg/Dockerfile +23 -0
- data/epeg/Epeg.h +90 -0
- data/epeg/README.md +42 -0
- data/epeg/epeg_main.c +1642 -0
- data/epeg/epeg_private.h +85 -0
- data/epeg/example/.gitignore +1 -0
- data/epeg/example/CMakeLists.txt +20 -0
- data/epeg/example/example.jpg +0 -0
- data/epeg/example/rotatetest.c +29 -0
- data/epeg/example/scaletest.c +48 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/BUILDING.md +828 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/CMakeLists.txt +1420 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/ChangeLog.md +1494 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/LICENSE.md +132 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/README.ijg +277 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/README.md +356 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/cderror.h +137 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/cdjpeg.c +145 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/cdjpeg.h +157 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/change.log +315 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/cjpeg.1 +354 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/cjpeg.c +695 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/cmakescripts/BuildPackages.cmake +182 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/cmakescripts/GNUInstallDirs.cmake +416 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/cmakescripts/cmake_uninstall.cmake.in +24 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/cmakescripts/testclean.cmake +41 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/cmyk.h +61 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/coderules.txt +78 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/djpeg.1 +296 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/djpeg.c +822 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/doc/html/annotated.html +104 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/doc/html/bc_s.png +0 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/doc/html/bdwn.png +0 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/doc/html/classes.html +106 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/doc/html/closed.png +0 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/doc/html/doxygen-extra.css +3 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/doc/html/doxygen.css +1184 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/doc/html/doxygen.png +0 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/doc/html/dynsections.js +97 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/doc/html/ftv2blank.png +0 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/doc/html/ftv2cl.png +0 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/doc/html/ftv2doc.png +0 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/doc/html/ftv2folderclosed.png +0 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/doc/html/ftv2folderopen.png +0 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/doc/html/ftv2lastnode.png +0 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/doc/html/ftv2link.png +0 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/doc/html/ftv2mlastnode.png +0 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/doc/html/ftv2mnode.png +0 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/doc/html/ftv2mo.png +0 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/doc/html/ftv2node.png +0 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/doc/html/ftv2ns.png +0 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/doc/html/ftv2plastnode.png +0 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/doc/html/ftv2pnode.png +0 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/doc/html/ftv2splitbar.png +0 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/doc/html/ftv2vertline.png +0 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/doc/html/functions.html +134 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/doc/html/functions_vars.html +134 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/doc/html/group___turbo_j_p_e_g.html +2775 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/doc/html/index.html +90 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/doc/html/jquery.js +8 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/doc/html/modules.html +95 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/doc/html/nav_f.png +0 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/doc/html/nav_g.png +0 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/doc/html/nav_h.png +0 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/doc/html/open.png +0 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/doc/html/search/all_63.html +26 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/doc/html/search/all_63.js +4 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/doc/html/search/all_64.html +26 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/doc/html/search/all_64.js +5 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/doc/html/search/all_68.html +26 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/doc/html/search/all_68.js +4 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/doc/html/search/all_6e.html +26 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/doc/html/search/all_6e.js +4 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/doc/html/search/all_6f.html +26 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/doc/html/search/all_6f.js +5 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/doc/html/search/all_72.html +26 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/doc/html/search/all_72.js +4 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/doc/html/search/all_74.html +26 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/doc/html/search/all_74.js +102 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/doc/html/search/all_77.html +26 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/doc/html/search/all_77.js +4 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/doc/html/search/all_78.html +26 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/doc/html/search/all_78.js +4 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/doc/html/search/all_79.html +26 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/doc/html/search/all_79.js +4 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/doc/html/search/classes_74.html +26 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/doc/html/search/classes_74.js +6 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/doc/html/search/close.png +0 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/doc/html/search/enums_74.html +26 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/doc/html/search/enums_74.js +8 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/doc/html/search/enumvalues_74.html +26 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/doc/html/search/enumvalues_74.js +37 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/doc/html/search/functions_74.html +26 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/doc/html/search/functions_74.js +31 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/doc/html/search/groups_74.html +26 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/doc/html/search/groups_74.js +4 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/doc/html/search/mag_sel.png +0 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/doc/html/search/nomatches.html +12 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/doc/html/search/search.css +271 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/doc/html/search/search.js +809 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/doc/html/search/search_l.png +0 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/doc/html/search/search_m.png +0 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/doc/html/search/search_r.png +0 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/doc/html/search/typedefs_74.html +26 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/doc/html/search/typedefs_74.js +5 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/doc/html/search/variables_63.html +26 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/doc/html/search/variables_63.js +4 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/doc/html/search/variables_64.html +26 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/doc/html/search/variables_64.js +5 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/doc/html/search/variables_68.html +26 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/doc/html/search/variables_68.js +4 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/doc/html/search/variables_6e.html +26 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/doc/html/search/variables_6e.js +4 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/doc/html/search/variables_6f.html +26 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/doc/html/search/variables_6f.js +5 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/doc/html/search/variables_72.html +26 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/doc/html/search/variables_72.js +4 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/doc/html/search/variables_74.html +26 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/doc/html/search/variables_74.js +10 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/doc/html/search/variables_77.html +26 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/doc/html/search/variables_77.js +4 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/doc/html/search/variables_78.html +26 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/doc/html/search/variables_78.js +4 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/doc/html/search/variables_79.html +26 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/doc/html/search/variables_79.js +4 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/doc/html/structtjregion.html +186 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/doc/html/structtjscalingfactor.html +148 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/doc/html/structtjtransform.html +212 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/doc/html/sync_off.png +0 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/doc/html/sync_on.png +0 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/doc/html/tab_a.png +0 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/doc/html/tab_b.png +0 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/doc/html/tab_h.png +0 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/doc/html/tab_s.png +0 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/doc/html/tabs.css +60 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/doxygen-extra.css +3 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/doxygen.config +16 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/example.txt +464 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/jaricom.c +157 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/java/CMakeLists.txt +88 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/java/MANIFEST.MF +2 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/java/README +52 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/java/TJBench.java +1021 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/java/TJExample.java +405 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/java/TJUnitTest.java +960 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/java/doc/allclasses-frame.html +24 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/java/doc/allclasses-noframe.html +24 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/java/doc/constant-values.html +532 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/java/doc/deprecated-list.html +252 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/java/doc/help-doc.html +210 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/java/doc/index-all.html +1029 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/java/doc/index.html +71 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/java/doc/org/libjpegturbo/turbojpeg/TJ.html +1356 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/java/doc/org/libjpegturbo/turbojpeg/TJCompressor.html +926 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/java/doc/org/libjpegturbo/turbojpeg/TJCustomFilter.html +241 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/java/doc/org/libjpegturbo/turbojpeg/TJDecompressor.html +1255 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/java/doc/org/libjpegturbo/turbojpeg/TJException.html +340 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/java/doc/org/libjpegturbo/turbojpeg/TJScalingFactor.html +343 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/java/doc/org/libjpegturbo/turbojpeg/TJTransform.html +751 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/java/doc/org/libjpegturbo/turbojpeg/TJTransformer.html +421 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/java/doc/org/libjpegturbo/turbojpeg/YUVImage.html +765 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/java/doc/org/libjpegturbo/turbojpeg/package-frame.html +31 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/java/doc/org/libjpegturbo/turbojpeg/package-summary.html +202 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/java/doc/org/libjpegturbo/turbojpeg/package-tree.html +160 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/java/doc/overview-tree.html +164 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/java/doc/package-list +1 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/java/doc/resources/background.gif +0 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/java/doc/resources/tab.gif +0 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/java/doc/resources/titlebar.gif +0 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/java/doc/resources/titlebar_end.gif +0 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/java/doc/script.js +30 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/java/doc/serialized-form.html +176 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/java/doc/stylesheet.css +474 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/java/org/libjpegturbo/turbojpeg/TJ.java +584 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/java/org/libjpegturbo/turbojpeg/TJCompressor.java +677 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/java/org/libjpegturbo/turbojpeg/TJCustomFilter.java +76 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/java/org/libjpegturbo/turbojpeg/TJDecompressor.java +931 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/java/org/libjpegturbo/turbojpeg/TJException.java +78 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/java/org/libjpegturbo/turbojpeg/TJLoader-unix.java.in +59 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/java/org/libjpegturbo/turbojpeg/TJLoader-win.java.in +35 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/java/org/libjpegturbo/turbojpeg/TJScalingFactor.java +115 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/java/org/libjpegturbo/turbojpeg/TJTransform.java +227 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/java/org/libjpegturbo/turbojpeg/TJTransformer.java +163 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/java/org/libjpegturbo/turbojpeg/YUVImage.java +445 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/java/org_libjpegturbo_turbojpeg_TJ.h +129 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/java/org_libjpegturbo_turbojpeg_TJCompressor.h +101 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/java/org_libjpegturbo_turbojpeg_TJDecompressor.h +101 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/java/org_libjpegturbo_turbojpeg_TJTransformer.h +29 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/jcapimin.c +295 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/jcapistd.c +162 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/jcarith.c +932 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/jccoefct.c +449 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/jccolext.c +144 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/jccolor.c +710 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/jcdctmgr.c +721 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/jchuff.c +1096 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/jchuff.h +42 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/jcicc.c +105 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/jcinit.c +77 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/jcmainct.c +162 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/jcmarker.c +664 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/jcmaster.c +640 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/jcomapi.c +109 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/jconfig.h.in +73 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/jconfig.txt +143 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/jconfigint.h.in +31 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/jcparam.c +541 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/jcphuff.c +1105 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/jcprepct.c +351 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/jcsample.c +539 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/jcstest.c +126 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/jctrans.c +400 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/jdapimin.c +407 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/jdapistd.c +639 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/jdarith.c +773 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/jdatadst-tj.c +203 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/jdatadst.c +293 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/jdatasrc-tj.c +194 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/jdatasrc.c +295 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/jdcoefct.c +692 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/jdcoefct.h +82 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/jdcol565.c +384 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/jdcolext.c +143 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/jdcolor.c +883 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/jdct.h +208 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/jddctmgr.c +352 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/jdhuff.c +831 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/jdhuff.h +238 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/jdicc.c +171 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/jdinput.c +408 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/jdmainct.c +460 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/jdmainct.h +71 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/jdmarker.c +1377 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/jdmaster.c +737 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/jdmaster.h +28 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/jdmerge.c +617 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/jdmrg565.c +354 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/jdmrgext.c +184 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/jdphuff.c +687 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/jdpostct.c +294 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/jdsample.c +518 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/jdsample.h +50 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/jdtrans.c +155 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/jerror.c +251 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/jerror.h +316 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/jfdctflt.c +169 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/jfdctfst.c +227 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/jfdctint.c +288 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/jidctflt.c +240 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/jidctfst.c +371 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/jidctint.c +2627 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/jidctred.c +409 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/jinclude.h +88 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/jmemmgr.c +1179 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/jmemnobs.c +115 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/jmemsys.h +178 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/jmorecfg.h +421 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/jpeg_nbits_table.h +4098 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/jpegcomp.h +31 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/jpegint.h +368 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/jpeglib.h +1132 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/jpegtran.1 +295 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/jpegtran.c +601 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/jquant1.c +859 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/jquant2.c +1285 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/jsimd.h +117 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/jsimd_none.c +418 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/jsimddct.h +70 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/jstdhuff.c +143 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/jutils.c +133 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/jversion.h +52 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/libjpeg.map.in +11 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/libjpeg.txt +3144 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/md5/CMakeLists.txt +1 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/md5/md5.c +275 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/md5/md5.h +57 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/md5/md5cmp.c +59 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/md5/md5hl.c +125 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/rdbmp.c +689 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/rdcolmap.c +254 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/rdgif.c +39 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/rdjpgcom.1 +63 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/rdjpgcom.c +510 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/rdppm.c +766 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/rdrle.c +389 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/rdswitch.c +424 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/rdtarga.c +509 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/release/Distribution.xml.in +24 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/release/License.rtf +20 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/release/ReadMe.txt +5 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/release/Welcome.rtf +17 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/release/deb-control.in +31 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/release/installer.nsi.in +191 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/release/libjpeg.pc.in +10 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/release/libturbojpeg.pc.in +10 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/release/makecygwinpkg.in +66 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/release/makedpkg.in +115 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/release/makemacpkg.in +284 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/release/makerpm.in +30 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/release/makesrpm.in +48 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/release/maketarball.in +51 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/release/rpm.spec.in +221 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/release/uninstall.in +113 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/sharedlib/CMakeLists.txt +99 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/simd/CMakeLists.txt +385 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/simd/arm/jsimd.c +721 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/simd/arm/jsimd_neon.S +2878 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/simd/arm64/jsimd.c +798 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/simd/arm64/jsimd_neon.S +3433 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/simd/gas-preprocessor.in +1 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/simd/i386/jccolext-avx2.asm +578 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/simd/i386/jccolext-mmx.asm +476 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/simd/i386/jccolext-sse2.asm +503 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/simd/i386/jccolor-avx2.asm +121 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/simd/i386/jccolor-mmx.asm +121 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/simd/i386/jccolor-sse2.asm +120 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/simd/i386/jcgray-avx2.asm +113 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/simd/i386/jcgray-mmx.asm +113 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/simd/i386/jcgray-sse2.asm +112 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/simd/i386/jcgryext-avx2.asm +457 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/simd/i386/jcgryext-mmx.asm +355 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/simd/i386/jcgryext-sse2.asm +382 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/simd/i386/jchuff-sse2.asm +424 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/simd/i386/jcphuff-sse2.asm +660 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/simd/i386/jcsample-avx2.asm +388 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/simd/i386/jcsample-mmx.asm +324 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/simd/i386/jcsample-sse2.asm +351 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/simd/i386/jdcolext-avx2.asm +515 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/simd/i386/jdcolext-mmx.asm +404 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/simd/i386/jdcolext-sse2.asm +458 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/simd/i386/jdcolor-avx2.asm +118 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/simd/i386/jdcolor-mmx.asm +117 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/simd/i386/jdcolor-sse2.asm +117 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/simd/i386/jdmerge-avx2.asm +136 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/simd/i386/jdmerge-mmx.asm +123 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/simd/i386/jdmerge-sse2.asm +135 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/simd/i386/jdmrgext-avx2.asm +575 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/simd/i386/jdmrgext-mmx.asm +460 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/simd/i386/jdmrgext-sse2.asm +517 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/simd/i386/jdsample-avx2.asm +760 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/simd/i386/jdsample-mmx.asm +731 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/simd/i386/jdsample-sse2.asm +724 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/simd/i386/jfdctflt-3dn.asm +318 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/simd/i386/jfdctflt-sse.asm +369 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/simd/i386/jfdctfst-mmx.asm +395 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/simd/i386/jfdctfst-sse2.asm +403 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/simd/i386/jfdctint-avx2.asm +331 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/simd/i386/jfdctint-mmx.asm +620 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/simd/i386/jfdctint-sse2.asm +633 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/simd/i386/jidctflt-3dn.asm +451 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/simd/i386/jidctflt-sse.asm +571 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/simd/i386/jidctflt-sse2.asm +497 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/simd/i386/jidctfst-mmx.asm +499 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/simd/i386/jidctfst-sse2.asm +501 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/simd/i386/jidctint-avx2.asm +453 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/simd/i386/jidctint-mmx.asm +851 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/simd/i386/jidctint-sse2.asm +858 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/simd/i386/jidctred-mmx.asm +704 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/simd/i386/jidctred-sse2.asm +592 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/simd/i386/jquant-3dn.asm +230 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/simd/i386/jquant-mmx.asm +276 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/simd/i386/jquant-sse.asm +208 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/simd/i386/jquantf-sse2.asm +168 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/simd/i386/jquanti-avx2.asm +188 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/simd/i386/jquanti-sse2.asm +201 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/simd/i386/jsimd.c +1253 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/simd/i386/jsimdcpu.asm +135 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/simd/jsimd.h +1083 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/simd/loongson/jccolext-mmi.c +483 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/simd/loongson/jccolor-mmi.c +148 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/simd/loongson/jcsample-mmi.c +100 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/simd/loongson/jcsample.h +28 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/simd/loongson/jdcolext-mmi.c +424 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/simd/loongson/jdcolor-mmi.c +139 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/simd/loongson/jdsample-mmi.c +245 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/simd/loongson/jfdctint-mmi.c +398 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/simd/loongson/jidctint-mmi.c +571 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/simd/loongson/jquanti-mmi.c +130 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/simd/loongson/jsimd.c +610 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/simd/loongson/jsimd_mmi.h +57 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/simd/loongson/loongson-mmintrin.h +1324 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/simd/mips/jsimd.c +1123 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/simd/mips/jsimd_dspr2.S +4479 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/simd/mips/jsimd_dspr2_asm.h +292 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/simd/nasm/jcolsamp.inc +135 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/simd/nasm/jdct.inc +31 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/simd/nasm/jpeg_nbits_table.inc +4097 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/simd/nasm/jsimdcfg.inc +93 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/simd/nasm/jsimdcfg.inc.h +131 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/simd/nasm/jsimdext.inc +479 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/simd/powerpc/jccolext-altivec.c +269 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/simd/powerpc/jccolor-altivec.c +116 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/simd/powerpc/jcgray-altivec.c +111 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/simd/powerpc/jcgryext-altivec.c +228 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/simd/powerpc/jcsample-altivec.c +159 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/simd/powerpc/jcsample.h +28 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/simd/powerpc/jdcolext-altivec.c +276 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/simd/powerpc/jdcolor-altivec.c +106 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/simd/powerpc/jdmerge-altivec.c +130 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/simd/powerpc/jdmrgext-altivec.c +329 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/simd/powerpc/jdsample-altivec.c +400 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/simd/powerpc/jfdctfst-altivec.c +154 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/simd/powerpc/jfdctint-altivec.c +258 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/simd/powerpc/jidctfst-altivec.c +255 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/simd/powerpc/jidctint-altivec.c +357 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/simd/powerpc/jquanti-altivec.c +250 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/simd/powerpc/jsimd.c +872 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/simd/powerpc/jsimd_altivec.h +98 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/simd/x86_64/jccolext-avx2.asm +558 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/simd/x86_64/jccolext-sse2.asm +483 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/simd/x86_64/jccolor-avx2.asm +121 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/simd/x86_64/jccolor-sse2.asm +120 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/simd/x86_64/jcgray-avx2.asm +113 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/simd/x86_64/jcgray-sse2.asm +112 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/simd/x86_64/jcgryext-avx2.asm +437 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/simd/x86_64/jcgryext-sse2.asm +362 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/simd/x86_64/jchuff-sse2.asm +346 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/simd/x86_64/jcphuff-sse2.asm +637 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/simd/x86_64/jcsample-avx2.asm +366 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/simd/x86_64/jcsample-sse2.asm +329 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/simd/x86_64/jdcolext-avx2.asm +495 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/simd/x86_64/jdcolext-sse2.asm +438 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/simd/x86_64/jdcolor-avx2.asm +118 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/simd/x86_64/jdcolor-sse2.asm +117 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/simd/x86_64/jdmerge-avx2.asm +136 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/simd/x86_64/jdmerge-sse2.asm +135 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/simd/x86_64/jdmrgext-avx2.asm +593 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/simd/x86_64/jdmrgext-sse2.asm +535 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/simd/x86_64/jdsample-avx2.asm +695 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/simd/x86_64/jdsample-sse2.asm +664 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/simd/x86_64/jfdctflt-sse.asm +355 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/simd/x86_64/jfdctfst-sse2.asm +389 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/simd/x86_64/jfdctint-avx2.asm +320 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/simd/x86_64/jfdctint-sse2.asm +619 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/simd/x86_64/jidctflt-sse2.asm +481 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/simd/x86_64/jidctfst-sse2.asm +490 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/simd/x86_64/jidctint-avx2.asm +417 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/simd/x86_64/jidctint-sse2.asm +846 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/simd/x86_64/jidctred-sse2.asm +573 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/simd/x86_64/jquantf-sse2.asm +154 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/simd/x86_64/jquanti-avx2.asm +162 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/simd/x86_64/jquanti-sse2.asm +187 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/simd/x86_64/jsimd.c +1076 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/simd/x86_64/jsimdcpu.asm +86 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/structure.txt +904 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/testimages/nightshot_iso_100.bmp +0 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/testimages/nightshot_iso_100.txt +25 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/testimages/test.scan +5 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/testimages/test1.icc +0 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/testimages/test1.icc.txt +20 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/testimages/test2.icc +0 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/testimages/test2.icc.txt +20 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/testimages/testimgari.jpg +0 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/testimages/testimgint.jpg +0 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/testimages/testorig.jpg +0 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/testimages/testorig.ppm +4 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/testimages/testorig12.jpg +0 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/testimages/vgl_5674_0098.bmp +0 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/testimages/vgl_6434_0018a.bmp +0 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/testimages/vgl_6548_0026a.bmp +0 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/tjbench.c +1031 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/tjbenchtest.in +256 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/tjbenchtest.java.in +215 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/tjexample.c +396 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/tjexampletest.in +149 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/tjexampletest.java.in +151 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/tjunittest.c +931 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/tjutil.c +70 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/tjutil.h +47 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/transupp.c +1628 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/transupp.h +210 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/turbojpeg-jni.c +1246 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/turbojpeg-mapfile +65 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/turbojpeg-mapfile.jni +101 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/turbojpeg.c +2152 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/turbojpeg.h +1744 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/usage.txt +635 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/win/jconfig.h.in +34 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/win/jpeg62-memsrcdst.def +108 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/win/jpeg62.def +106 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/win/jpeg7-memsrcdst.def +110 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/win/jpeg7.def +108 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/win/jpeg8.def +111 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/wizard.txt +212 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/wrbmp.c +558 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/wrgif.c +413 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/wrjpgcom.1 +103 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/wrjpgcom.c +591 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/wrppm.c +365 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/wrrle.c +309 -0
- data/epeg/vendor/libjpeg-turbo-2.0.4/wrtarga.c +261 -0
- data/epeg.c +131 -0
- data/epeg.gemspec +18 -0
- data/extconf.rb +80 -0
- data/test.jpg +0 -0
- data/test.rb +42 -0
- metadata +546 -0
@@ -0,0 +1,640 @@
|
|
1
|
+
/*
|
2
|
+
* jcmaster.c
|
3
|
+
*
|
4
|
+
* This file was part of the Independent JPEG Group's software:
|
5
|
+
* Copyright (C) 1991-1997, Thomas G. Lane.
|
6
|
+
* Modified 2003-2010 by Guido Vollbeding.
|
7
|
+
* libjpeg-turbo Modifications:
|
8
|
+
* Copyright (C) 2010, 2016, 2018, D. R. Commander.
|
9
|
+
* For conditions of distribution and use, see the accompanying README.ijg
|
10
|
+
* file.
|
11
|
+
*
|
12
|
+
* This file contains master control logic for the JPEG compressor.
|
13
|
+
* These routines are concerned with parameter validation, initial setup,
|
14
|
+
* and inter-pass control (determining the number of passes and the work
|
15
|
+
* to be done in each pass).
|
16
|
+
*/
|
17
|
+
|
18
|
+
#define JPEG_INTERNALS
|
19
|
+
#include "jinclude.h"
|
20
|
+
#include "jpeglib.h"
|
21
|
+
#include "jpegcomp.h"
|
22
|
+
#include "jconfigint.h"
|
23
|
+
|
24
|
+
|
25
|
+
/* Private state */
|
26
|
+
|
27
|
+
typedef enum {
|
28
|
+
main_pass, /* input data, also do first output step */
|
29
|
+
huff_opt_pass, /* Huffman code optimization pass */
|
30
|
+
output_pass /* data output pass */
|
31
|
+
} c_pass_type;
|
32
|
+
|
33
|
+
typedef struct {
|
34
|
+
struct jpeg_comp_master pub; /* public fields */
|
35
|
+
|
36
|
+
c_pass_type pass_type; /* the type of the current pass */
|
37
|
+
|
38
|
+
int pass_number; /* # of passes completed */
|
39
|
+
int total_passes; /* total # of passes needed */
|
40
|
+
|
41
|
+
int scan_number; /* current index in scan_info[] */
|
42
|
+
|
43
|
+
/*
|
44
|
+
* This is here so we can add libjpeg-turbo version/build information to the
|
45
|
+
* global string table without introducing a new global symbol. Adding this
|
46
|
+
* information to the global string table allows one to examine a binary
|
47
|
+
* object and determine which version of libjpeg-turbo it was built from or
|
48
|
+
* linked against.
|
49
|
+
*/
|
50
|
+
const char *jpeg_version;
|
51
|
+
|
52
|
+
} my_comp_master;
|
53
|
+
|
54
|
+
typedef my_comp_master *my_master_ptr;
|
55
|
+
|
56
|
+
|
57
|
+
/*
|
58
|
+
* Support routines that do various essential calculations.
|
59
|
+
*/
|
60
|
+
|
61
|
+
#if JPEG_LIB_VERSION >= 70
|
62
|
+
/*
|
63
|
+
* Compute JPEG image dimensions and related values.
|
64
|
+
* NOTE: this is exported for possible use by application.
|
65
|
+
* Hence it mustn't do anything that can't be done twice.
|
66
|
+
*/
|
67
|
+
|
68
|
+
GLOBAL(void)
|
69
|
+
jpeg_calc_jpeg_dimensions(j_compress_ptr cinfo)
|
70
|
+
/* Do computations that are needed before master selection phase */
|
71
|
+
{
|
72
|
+
/* Hardwire it to "no scaling" */
|
73
|
+
cinfo->jpeg_width = cinfo->image_width;
|
74
|
+
cinfo->jpeg_height = cinfo->image_height;
|
75
|
+
cinfo->min_DCT_h_scaled_size = DCTSIZE;
|
76
|
+
cinfo->min_DCT_v_scaled_size = DCTSIZE;
|
77
|
+
}
|
78
|
+
#endif
|
79
|
+
|
80
|
+
|
81
|
+
LOCAL(void)
|
82
|
+
initial_setup(j_compress_ptr cinfo, boolean transcode_only)
|
83
|
+
/* Do computations that are needed before master selection phase */
|
84
|
+
{
|
85
|
+
int ci;
|
86
|
+
jpeg_component_info *compptr;
|
87
|
+
long samplesperrow;
|
88
|
+
JDIMENSION jd_samplesperrow;
|
89
|
+
|
90
|
+
#if JPEG_LIB_VERSION >= 70
|
91
|
+
#if JPEG_LIB_VERSION >= 80
|
92
|
+
if (!transcode_only)
|
93
|
+
#endif
|
94
|
+
jpeg_calc_jpeg_dimensions(cinfo);
|
95
|
+
#endif
|
96
|
+
|
97
|
+
/* Sanity check on image dimensions */
|
98
|
+
if (cinfo->_jpeg_height <= 0 || cinfo->_jpeg_width <= 0 ||
|
99
|
+
cinfo->num_components <= 0 || cinfo->input_components <= 0)
|
100
|
+
ERREXIT(cinfo, JERR_EMPTY_IMAGE);
|
101
|
+
|
102
|
+
/* Make sure image isn't bigger than I can handle */
|
103
|
+
if ((long)cinfo->_jpeg_height > (long)JPEG_MAX_DIMENSION ||
|
104
|
+
(long)cinfo->_jpeg_width > (long)JPEG_MAX_DIMENSION)
|
105
|
+
ERREXIT1(cinfo, JERR_IMAGE_TOO_BIG, (unsigned int)JPEG_MAX_DIMENSION);
|
106
|
+
|
107
|
+
/* Width of an input scanline must be representable as JDIMENSION. */
|
108
|
+
samplesperrow = (long)cinfo->image_width * (long)cinfo->input_components;
|
109
|
+
jd_samplesperrow = (JDIMENSION)samplesperrow;
|
110
|
+
if ((long)jd_samplesperrow != samplesperrow)
|
111
|
+
ERREXIT(cinfo, JERR_WIDTH_OVERFLOW);
|
112
|
+
|
113
|
+
/* For now, precision must match compiled-in value... */
|
114
|
+
if (cinfo->data_precision != BITS_IN_JSAMPLE)
|
115
|
+
ERREXIT1(cinfo, JERR_BAD_PRECISION, cinfo->data_precision);
|
116
|
+
|
117
|
+
/* Check that number of components won't exceed internal array sizes */
|
118
|
+
if (cinfo->num_components > MAX_COMPONENTS)
|
119
|
+
ERREXIT2(cinfo, JERR_COMPONENT_COUNT, cinfo->num_components,
|
120
|
+
MAX_COMPONENTS);
|
121
|
+
|
122
|
+
/* Compute maximum sampling factors; check factor validity */
|
123
|
+
cinfo->max_h_samp_factor = 1;
|
124
|
+
cinfo->max_v_samp_factor = 1;
|
125
|
+
for (ci = 0, compptr = cinfo->comp_info; ci < cinfo->num_components;
|
126
|
+
ci++, compptr++) {
|
127
|
+
if (compptr->h_samp_factor <= 0 ||
|
128
|
+
compptr->h_samp_factor > MAX_SAMP_FACTOR ||
|
129
|
+
compptr->v_samp_factor <= 0 ||
|
130
|
+
compptr->v_samp_factor > MAX_SAMP_FACTOR)
|
131
|
+
ERREXIT(cinfo, JERR_BAD_SAMPLING);
|
132
|
+
cinfo->max_h_samp_factor = MAX(cinfo->max_h_samp_factor,
|
133
|
+
compptr->h_samp_factor);
|
134
|
+
cinfo->max_v_samp_factor = MAX(cinfo->max_v_samp_factor,
|
135
|
+
compptr->v_samp_factor);
|
136
|
+
}
|
137
|
+
|
138
|
+
/* Compute dimensions of components */
|
139
|
+
for (ci = 0, compptr = cinfo->comp_info; ci < cinfo->num_components;
|
140
|
+
ci++, compptr++) {
|
141
|
+
/* Fill in the correct component_index value; don't rely on application */
|
142
|
+
compptr->component_index = ci;
|
143
|
+
/* For compression, we never do DCT scaling. */
|
144
|
+
#if JPEG_LIB_VERSION >= 70
|
145
|
+
compptr->DCT_h_scaled_size = compptr->DCT_v_scaled_size = DCTSIZE;
|
146
|
+
#else
|
147
|
+
compptr->DCT_scaled_size = DCTSIZE;
|
148
|
+
#endif
|
149
|
+
/* Size in DCT blocks */
|
150
|
+
compptr->width_in_blocks = (JDIMENSION)
|
151
|
+
jdiv_round_up((long)cinfo->_jpeg_width * (long)compptr->h_samp_factor,
|
152
|
+
(long)(cinfo->max_h_samp_factor * DCTSIZE));
|
153
|
+
compptr->height_in_blocks = (JDIMENSION)
|
154
|
+
jdiv_round_up((long)cinfo->_jpeg_height * (long)compptr->v_samp_factor,
|
155
|
+
(long)(cinfo->max_v_samp_factor * DCTSIZE));
|
156
|
+
/* Size in samples */
|
157
|
+
compptr->downsampled_width = (JDIMENSION)
|
158
|
+
jdiv_round_up((long)cinfo->_jpeg_width * (long)compptr->h_samp_factor,
|
159
|
+
(long)cinfo->max_h_samp_factor);
|
160
|
+
compptr->downsampled_height = (JDIMENSION)
|
161
|
+
jdiv_round_up((long)cinfo->_jpeg_height * (long)compptr->v_samp_factor,
|
162
|
+
(long)cinfo->max_v_samp_factor);
|
163
|
+
/* Mark component needed (this flag isn't actually used for compression) */
|
164
|
+
compptr->component_needed = TRUE;
|
165
|
+
}
|
166
|
+
|
167
|
+
/* Compute number of fully interleaved MCU rows (number of times that
|
168
|
+
* main controller will call coefficient controller).
|
169
|
+
*/
|
170
|
+
cinfo->total_iMCU_rows = (JDIMENSION)
|
171
|
+
jdiv_round_up((long)cinfo->_jpeg_height,
|
172
|
+
(long)(cinfo->max_v_samp_factor * DCTSIZE));
|
173
|
+
}
|
174
|
+
|
175
|
+
|
176
|
+
#ifdef C_MULTISCAN_FILES_SUPPORTED
|
177
|
+
|
178
|
+
LOCAL(void)
|
179
|
+
validate_script(j_compress_ptr cinfo)
|
180
|
+
/* Verify that the scan script in cinfo->scan_info[] is valid; also
|
181
|
+
* determine whether it uses progressive JPEG, and set cinfo->progressive_mode.
|
182
|
+
*/
|
183
|
+
{
|
184
|
+
const jpeg_scan_info *scanptr;
|
185
|
+
int scanno, ncomps, ci, coefi, thisi;
|
186
|
+
int Ss, Se, Ah, Al;
|
187
|
+
boolean component_sent[MAX_COMPONENTS];
|
188
|
+
#ifdef C_PROGRESSIVE_SUPPORTED
|
189
|
+
int *last_bitpos_ptr;
|
190
|
+
int last_bitpos[MAX_COMPONENTS][DCTSIZE2];
|
191
|
+
/* -1 until that coefficient has been seen; then last Al for it */
|
192
|
+
#endif
|
193
|
+
|
194
|
+
if (cinfo->num_scans <= 0)
|
195
|
+
ERREXIT1(cinfo, JERR_BAD_SCAN_SCRIPT, 0);
|
196
|
+
|
197
|
+
/* For sequential JPEG, all scans must have Ss=0, Se=DCTSIZE2-1;
|
198
|
+
* for progressive JPEG, no scan can have this.
|
199
|
+
*/
|
200
|
+
scanptr = cinfo->scan_info;
|
201
|
+
if (scanptr->Ss != 0 || scanptr->Se != DCTSIZE2 - 1) {
|
202
|
+
#ifdef C_PROGRESSIVE_SUPPORTED
|
203
|
+
cinfo->progressive_mode = TRUE;
|
204
|
+
last_bitpos_ptr = &last_bitpos[0][0];
|
205
|
+
for (ci = 0; ci < cinfo->num_components; ci++)
|
206
|
+
for (coefi = 0; coefi < DCTSIZE2; coefi++)
|
207
|
+
*last_bitpos_ptr++ = -1;
|
208
|
+
#else
|
209
|
+
ERREXIT(cinfo, JERR_NOT_COMPILED);
|
210
|
+
#endif
|
211
|
+
} else {
|
212
|
+
cinfo->progressive_mode = FALSE;
|
213
|
+
for (ci = 0; ci < cinfo->num_components; ci++)
|
214
|
+
component_sent[ci] = FALSE;
|
215
|
+
}
|
216
|
+
|
217
|
+
for (scanno = 1; scanno <= cinfo->num_scans; scanptr++, scanno++) {
|
218
|
+
/* Validate component indexes */
|
219
|
+
ncomps = scanptr->comps_in_scan;
|
220
|
+
if (ncomps <= 0 || ncomps > MAX_COMPS_IN_SCAN)
|
221
|
+
ERREXIT2(cinfo, JERR_COMPONENT_COUNT, ncomps, MAX_COMPS_IN_SCAN);
|
222
|
+
for (ci = 0; ci < ncomps; ci++) {
|
223
|
+
thisi = scanptr->component_index[ci];
|
224
|
+
if (thisi < 0 || thisi >= cinfo->num_components)
|
225
|
+
ERREXIT1(cinfo, JERR_BAD_SCAN_SCRIPT, scanno);
|
226
|
+
/* Components must appear in SOF order within each scan */
|
227
|
+
if (ci > 0 && thisi <= scanptr->component_index[ci - 1])
|
228
|
+
ERREXIT1(cinfo, JERR_BAD_SCAN_SCRIPT, scanno);
|
229
|
+
}
|
230
|
+
/* Validate progression parameters */
|
231
|
+
Ss = scanptr->Ss;
|
232
|
+
Se = scanptr->Se;
|
233
|
+
Ah = scanptr->Ah;
|
234
|
+
Al = scanptr->Al;
|
235
|
+
if (cinfo->progressive_mode) {
|
236
|
+
#ifdef C_PROGRESSIVE_SUPPORTED
|
237
|
+
/* Rec. ITU-T T.81 | ISO/IEC 10918-1 simply gives the ranges 0..13 for Ah
|
238
|
+
* and Al, but that seems wrong: the upper bound ought to depend on data
|
239
|
+
* precision. Perhaps they really meant 0..N+1 for N-bit precision.
|
240
|
+
* Here we allow 0..10 for 8-bit data; Al larger than 10 results in
|
241
|
+
* out-of-range reconstructed DC values during the first DC scan,
|
242
|
+
* which might cause problems for some decoders.
|
243
|
+
*/
|
244
|
+
#if BITS_IN_JSAMPLE == 8
|
245
|
+
#define MAX_AH_AL 10
|
246
|
+
#else
|
247
|
+
#define MAX_AH_AL 13
|
248
|
+
#endif
|
249
|
+
if (Ss < 0 || Ss >= DCTSIZE2 || Se < Ss || Se >= DCTSIZE2 ||
|
250
|
+
Ah < 0 || Ah > MAX_AH_AL || Al < 0 || Al > MAX_AH_AL)
|
251
|
+
ERREXIT1(cinfo, JERR_BAD_PROG_SCRIPT, scanno);
|
252
|
+
if (Ss == 0) {
|
253
|
+
if (Se != 0) /* DC and AC together not OK */
|
254
|
+
ERREXIT1(cinfo, JERR_BAD_PROG_SCRIPT, scanno);
|
255
|
+
} else {
|
256
|
+
if (ncomps != 1) /* AC scans must be for only one component */
|
257
|
+
ERREXIT1(cinfo, JERR_BAD_PROG_SCRIPT, scanno);
|
258
|
+
}
|
259
|
+
for (ci = 0; ci < ncomps; ci++) {
|
260
|
+
last_bitpos_ptr = &last_bitpos[scanptr->component_index[ci]][0];
|
261
|
+
if (Ss != 0 && last_bitpos_ptr[0] < 0) /* AC without prior DC scan */
|
262
|
+
ERREXIT1(cinfo, JERR_BAD_PROG_SCRIPT, scanno);
|
263
|
+
for (coefi = Ss; coefi <= Se; coefi++) {
|
264
|
+
if (last_bitpos_ptr[coefi] < 0) {
|
265
|
+
/* first scan of this coefficient */
|
266
|
+
if (Ah != 0)
|
267
|
+
ERREXIT1(cinfo, JERR_BAD_PROG_SCRIPT, scanno);
|
268
|
+
} else {
|
269
|
+
/* not first scan */
|
270
|
+
if (Ah != last_bitpos_ptr[coefi] || Al != Ah - 1)
|
271
|
+
ERREXIT1(cinfo, JERR_BAD_PROG_SCRIPT, scanno);
|
272
|
+
}
|
273
|
+
last_bitpos_ptr[coefi] = Al;
|
274
|
+
}
|
275
|
+
}
|
276
|
+
#endif
|
277
|
+
} else {
|
278
|
+
/* For sequential JPEG, all progression parameters must be these: */
|
279
|
+
if (Ss != 0 || Se != DCTSIZE2 - 1 || Ah != 0 || Al != 0)
|
280
|
+
ERREXIT1(cinfo, JERR_BAD_PROG_SCRIPT, scanno);
|
281
|
+
/* Make sure components are not sent twice */
|
282
|
+
for (ci = 0; ci < ncomps; ci++) {
|
283
|
+
thisi = scanptr->component_index[ci];
|
284
|
+
if (component_sent[thisi])
|
285
|
+
ERREXIT1(cinfo, JERR_BAD_SCAN_SCRIPT, scanno);
|
286
|
+
component_sent[thisi] = TRUE;
|
287
|
+
}
|
288
|
+
}
|
289
|
+
}
|
290
|
+
|
291
|
+
/* Now verify that everything got sent. */
|
292
|
+
if (cinfo->progressive_mode) {
|
293
|
+
#ifdef C_PROGRESSIVE_SUPPORTED
|
294
|
+
/* For progressive mode, we only check that at least some DC data
|
295
|
+
* got sent for each component; the spec does not require that all bits
|
296
|
+
* of all coefficients be transmitted. Would it be wiser to enforce
|
297
|
+
* transmission of all coefficient bits??
|
298
|
+
*/
|
299
|
+
for (ci = 0; ci < cinfo->num_components; ci++) {
|
300
|
+
if (last_bitpos[ci][0] < 0)
|
301
|
+
ERREXIT(cinfo, JERR_MISSING_DATA);
|
302
|
+
}
|
303
|
+
#endif
|
304
|
+
} else {
|
305
|
+
for (ci = 0; ci < cinfo->num_components; ci++) {
|
306
|
+
if (!component_sent[ci])
|
307
|
+
ERREXIT(cinfo, JERR_MISSING_DATA);
|
308
|
+
}
|
309
|
+
}
|
310
|
+
}
|
311
|
+
|
312
|
+
#endif /* C_MULTISCAN_FILES_SUPPORTED */
|
313
|
+
|
314
|
+
|
315
|
+
LOCAL(void)
|
316
|
+
select_scan_parameters(j_compress_ptr cinfo)
|
317
|
+
/* Set up the scan parameters for the current scan */
|
318
|
+
{
|
319
|
+
int ci;
|
320
|
+
|
321
|
+
#ifdef C_MULTISCAN_FILES_SUPPORTED
|
322
|
+
if (cinfo->scan_info != NULL) {
|
323
|
+
/* Prepare for current scan --- the script is already validated */
|
324
|
+
my_master_ptr master = (my_master_ptr)cinfo->master;
|
325
|
+
const jpeg_scan_info *scanptr = cinfo->scan_info + master->scan_number;
|
326
|
+
|
327
|
+
cinfo->comps_in_scan = scanptr->comps_in_scan;
|
328
|
+
for (ci = 0; ci < scanptr->comps_in_scan; ci++) {
|
329
|
+
cinfo->cur_comp_info[ci] =
|
330
|
+
&cinfo->comp_info[scanptr->component_index[ci]];
|
331
|
+
}
|
332
|
+
cinfo->Ss = scanptr->Ss;
|
333
|
+
cinfo->Se = scanptr->Se;
|
334
|
+
cinfo->Ah = scanptr->Ah;
|
335
|
+
cinfo->Al = scanptr->Al;
|
336
|
+
} else
|
337
|
+
#endif
|
338
|
+
{
|
339
|
+
/* Prepare for single sequential-JPEG scan containing all components */
|
340
|
+
if (cinfo->num_components > MAX_COMPS_IN_SCAN)
|
341
|
+
ERREXIT2(cinfo, JERR_COMPONENT_COUNT, cinfo->num_components,
|
342
|
+
MAX_COMPS_IN_SCAN);
|
343
|
+
cinfo->comps_in_scan = cinfo->num_components;
|
344
|
+
for (ci = 0; ci < cinfo->num_components; ci++) {
|
345
|
+
cinfo->cur_comp_info[ci] = &cinfo->comp_info[ci];
|
346
|
+
}
|
347
|
+
cinfo->Ss = 0;
|
348
|
+
cinfo->Se = DCTSIZE2 - 1;
|
349
|
+
cinfo->Ah = 0;
|
350
|
+
cinfo->Al = 0;
|
351
|
+
}
|
352
|
+
}
|
353
|
+
|
354
|
+
|
355
|
+
LOCAL(void)
|
356
|
+
per_scan_setup(j_compress_ptr cinfo)
|
357
|
+
/* Do computations that are needed before processing a JPEG scan */
|
358
|
+
/* cinfo->comps_in_scan and cinfo->cur_comp_info[] are already set */
|
359
|
+
{
|
360
|
+
int ci, mcublks, tmp;
|
361
|
+
jpeg_component_info *compptr;
|
362
|
+
|
363
|
+
if (cinfo->comps_in_scan == 1) {
|
364
|
+
|
365
|
+
/* Noninterleaved (single-component) scan */
|
366
|
+
compptr = cinfo->cur_comp_info[0];
|
367
|
+
|
368
|
+
/* Overall image size in MCUs */
|
369
|
+
cinfo->MCUs_per_row = compptr->width_in_blocks;
|
370
|
+
cinfo->MCU_rows_in_scan = compptr->height_in_blocks;
|
371
|
+
|
372
|
+
/* For noninterleaved scan, always one block per MCU */
|
373
|
+
compptr->MCU_width = 1;
|
374
|
+
compptr->MCU_height = 1;
|
375
|
+
compptr->MCU_blocks = 1;
|
376
|
+
compptr->MCU_sample_width = DCTSIZE;
|
377
|
+
compptr->last_col_width = 1;
|
378
|
+
/* For noninterleaved scans, it is convenient to define last_row_height
|
379
|
+
* as the number of block rows present in the last iMCU row.
|
380
|
+
*/
|
381
|
+
tmp = (int)(compptr->height_in_blocks % compptr->v_samp_factor);
|
382
|
+
if (tmp == 0) tmp = compptr->v_samp_factor;
|
383
|
+
compptr->last_row_height = tmp;
|
384
|
+
|
385
|
+
/* Prepare array describing MCU composition */
|
386
|
+
cinfo->blocks_in_MCU = 1;
|
387
|
+
cinfo->MCU_membership[0] = 0;
|
388
|
+
|
389
|
+
} else {
|
390
|
+
|
391
|
+
/* Interleaved (multi-component) scan */
|
392
|
+
if (cinfo->comps_in_scan <= 0 || cinfo->comps_in_scan > MAX_COMPS_IN_SCAN)
|
393
|
+
ERREXIT2(cinfo, JERR_COMPONENT_COUNT, cinfo->comps_in_scan,
|
394
|
+
MAX_COMPS_IN_SCAN);
|
395
|
+
|
396
|
+
/* Overall image size in MCUs */
|
397
|
+
cinfo->MCUs_per_row = (JDIMENSION)
|
398
|
+
jdiv_round_up((long)cinfo->_jpeg_width,
|
399
|
+
(long)(cinfo->max_h_samp_factor * DCTSIZE));
|
400
|
+
cinfo->MCU_rows_in_scan = (JDIMENSION)
|
401
|
+
jdiv_round_up((long)cinfo->_jpeg_height,
|
402
|
+
(long)(cinfo->max_v_samp_factor * DCTSIZE));
|
403
|
+
|
404
|
+
cinfo->blocks_in_MCU = 0;
|
405
|
+
|
406
|
+
for (ci = 0; ci < cinfo->comps_in_scan; ci++) {
|
407
|
+
compptr = cinfo->cur_comp_info[ci];
|
408
|
+
/* Sampling factors give # of blocks of component in each MCU */
|
409
|
+
compptr->MCU_width = compptr->h_samp_factor;
|
410
|
+
compptr->MCU_height = compptr->v_samp_factor;
|
411
|
+
compptr->MCU_blocks = compptr->MCU_width * compptr->MCU_height;
|
412
|
+
compptr->MCU_sample_width = compptr->MCU_width * DCTSIZE;
|
413
|
+
/* Figure number of non-dummy blocks in last MCU column & row */
|
414
|
+
tmp = (int)(compptr->width_in_blocks % compptr->MCU_width);
|
415
|
+
if (tmp == 0) tmp = compptr->MCU_width;
|
416
|
+
compptr->last_col_width = tmp;
|
417
|
+
tmp = (int)(compptr->height_in_blocks % compptr->MCU_height);
|
418
|
+
if (tmp == 0) tmp = compptr->MCU_height;
|
419
|
+
compptr->last_row_height = tmp;
|
420
|
+
/* Prepare array describing MCU composition */
|
421
|
+
mcublks = compptr->MCU_blocks;
|
422
|
+
if (cinfo->blocks_in_MCU + mcublks > C_MAX_BLOCKS_IN_MCU)
|
423
|
+
ERREXIT(cinfo, JERR_BAD_MCU_SIZE);
|
424
|
+
while (mcublks-- > 0) {
|
425
|
+
cinfo->MCU_membership[cinfo->blocks_in_MCU++] = ci;
|
426
|
+
}
|
427
|
+
}
|
428
|
+
|
429
|
+
}
|
430
|
+
|
431
|
+
/* Convert restart specified in rows to actual MCU count. */
|
432
|
+
/* Note that count must fit in 16 bits, so we provide limiting. */
|
433
|
+
if (cinfo->restart_in_rows > 0) {
|
434
|
+
long nominal = (long)cinfo->restart_in_rows * (long)cinfo->MCUs_per_row;
|
435
|
+
cinfo->restart_interval = (unsigned int)MIN(nominal, 65535L);
|
436
|
+
}
|
437
|
+
}
|
438
|
+
|
439
|
+
|
440
|
+
/*
|
441
|
+
* Per-pass setup.
|
442
|
+
* This is called at the beginning of each pass. We determine which modules
|
443
|
+
* will be active during this pass and give them appropriate start_pass calls.
|
444
|
+
* We also set is_last_pass to indicate whether any more passes will be
|
445
|
+
* required.
|
446
|
+
*/
|
447
|
+
|
448
|
+
METHODDEF(void)
|
449
|
+
prepare_for_pass(j_compress_ptr cinfo)
|
450
|
+
{
|
451
|
+
my_master_ptr master = (my_master_ptr)cinfo->master;
|
452
|
+
|
453
|
+
switch (master->pass_type) {
|
454
|
+
case main_pass:
|
455
|
+
/* Initial pass: will collect input data, and do either Huffman
|
456
|
+
* optimization or data output for the first scan.
|
457
|
+
*/
|
458
|
+
select_scan_parameters(cinfo);
|
459
|
+
per_scan_setup(cinfo);
|
460
|
+
if (!cinfo->raw_data_in) {
|
461
|
+
(*cinfo->cconvert->start_pass) (cinfo);
|
462
|
+
(*cinfo->downsample->start_pass) (cinfo);
|
463
|
+
(*cinfo->prep->start_pass) (cinfo, JBUF_PASS_THRU);
|
464
|
+
}
|
465
|
+
(*cinfo->fdct->start_pass) (cinfo);
|
466
|
+
(*cinfo->entropy->start_pass) (cinfo, cinfo->optimize_coding);
|
467
|
+
(*cinfo->coef->start_pass) (cinfo,
|
468
|
+
(master->total_passes > 1 ?
|
469
|
+
JBUF_SAVE_AND_PASS : JBUF_PASS_THRU));
|
470
|
+
(*cinfo->main->start_pass) (cinfo, JBUF_PASS_THRU);
|
471
|
+
if (cinfo->optimize_coding) {
|
472
|
+
/* No immediate data output; postpone writing frame/scan headers */
|
473
|
+
master->pub.call_pass_startup = FALSE;
|
474
|
+
} else {
|
475
|
+
/* Will write frame/scan headers at first jpeg_write_scanlines call */
|
476
|
+
master->pub.call_pass_startup = TRUE;
|
477
|
+
}
|
478
|
+
break;
|
479
|
+
#ifdef ENTROPY_OPT_SUPPORTED
|
480
|
+
case huff_opt_pass:
|
481
|
+
/* Do Huffman optimization for a scan after the first one. */
|
482
|
+
select_scan_parameters(cinfo);
|
483
|
+
per_scan_setup(cinfo);
|
484
|
+
if (cinfo->Ss != 0 || cinfo->Ah == 0 || cinfo->arith_code) {
|
485
|
+
(*cinfo->entropy->start_pass) (cinfo, TRUE);
|
486
|
+
(*cinfo->coef->start_pass) (cinfo, JBUF_CRANK_DEST);
|
487
|
+
master->pub.call_pass_startup = FALSE;
|
488
|
+
break;
|
489
|
+
}
|
490
|
+
/* Special case: Huffman DC refinement scans need no Huffman table
|
491
|
+
* and therefore we can skip the optimization pass for them.
|
492
|
+
*/
|
493
|
+
master->pass_type = output_pass;
|
494
|
+
master->pass_number++;
|
495
|
+
#endif
|
496
|
+
/*FALLTHROUGH*/
|
497
|
+
case output_pass:
|
498
|
+
/* Do a data-output pass. */
|
499
|
+
/* We need not repeat per-scan setup if prior optimization pass did it. */
|
500
|
+
if (!cinfo->optimize_coding) {
|
501
|
+
select_scan_parameters(cinfo);
|
502
|
+
per_scan_setup(cinfo);
|
503
|
+
}
|
504
|
+
(*cinfo->entropy->start_pass) (cinfo, FALSE);
|
505
|
+
(*cinfo->coef->start_pass) (cinfo, JBUF_CRANK_DEST);
|
506
|
+
/* We emit frame/scan headers now */
|
507
|
+
if (master->scan_number == 0)
|
508
|
+
(*cinfo->marker->write_frame_header) (cinfo);
|
509
|
+
(*cinfo->marker->write_scan_header) (cinfo);
|
510
|
+
master->pub.call_pass_startup = FALSE;
|
511
|
+
break;
|
512
|
+
default:
|
513
|
+
ERREXIT(cinfo, JERR_NOT_COMPILED);
|
514
|
+
}
|
515
|
+
|
516
|
+
master->pub.is_last_pass = (master->pass_number == master->total_passes - 1);
|
517
|
+
|
518
|
+
/* Set up progress monitor's pass info if present */
|
519
|
+
if (cinfo->progress != NULL) {
|
520
|
+
cinfo->progress->completed_passes = master->pass_number;
|
521
|
+
cinfo->progress->total_passes = master->total_passes;
|
522
|
+
}
|
523
|
+
}
|
524
|
+
|
525
|
+
|
526
|
+
/*
|
527
|
+
* Special start-of-pass hook.
|
528
|
+
* This is called by jpeg_write_scanlines if call_pass_startup is TRUE.
|
529
|
+
* In single-pass processing, we need this hook because we don't want to
|
530
|
+
* write frame/scan headers during jpeg_start_compress; we want to let the
|
531
|
+
* application write COM markers etc. between jpeg_start_compress and the
|
532
|
+
* jpeg_write_scanlines loop.
|
533
|
+
* In multi-pass processing, this routine is not used.
|
534
|
+
*/
|
535
|
+
|
536
|
+
METHODDEF(void)
|
537
|
+
pass_startup(j_compress_ptr cinfo)
|
538
|
+
{
|
539
|
+
cinfo->master->call_pass_startup = FALSE; /* reset flag so call only once */
|
540
|
+
|
541
|
+
(*cinfo->marker->write_frame_header) (cinfo);
|
542
|
+
(*cinfo->marker->write_scan_header) (cinfo);
|
543
|
+
}
|
544
|
+
|
545
|
+
|
546
|
+
/*
|
547
|
+
* Finish up at end of pass.
|
548
|
+
*/
|
549
|
+
|
550
|
+
METHODDEF(void)
|
551
|
+
finish_pass_master(j_compress_ptr cinfo)
|
552
|
+
{
|
553
|
+
my_master_ptr master = (my_master_ptr)cinfo->master;
|
554
|
+
|
555
|
+
/* The entropy coder always needs an end-of-pass call,
|
556
|
+
* either to analyze statistics or to flush its output buffer.
|
557
|
+
*/
|
558
|
+
(*cinfo->entropy->finish_pass) (cinfo);
|
559
|
+
|
560
|
+
/* Update state for next pass */
|
561
|
+
switch (master->pass_type) {
|
562
|
+
case main_pass:
|
563
|
+
/* next pass is either output of scan 0 (after optimization)
|
564
|
+
* or output of scan 1 (if no optimization).
|
565
|
+
*/
|
566
|
+
master->pass_type = output_pass;
|
567
|
+
if (!cinfo->optimize_coding)
|
568
|
+
master->scan_number++;
|
569
|
+
break;
|
570
|
+
case huff_opt_pass:
|
571
|
+
/* next pass is always output of current scan */
|
572
|
+
master->pass_type = output_pass;
|
573
|
+
break;
|
574
|
+
case output_pass:
|
575
|
+
/* next pass is either optimization or output of next scan */
|
576
|
+
if (cinfo->optimize_coding)
|
577
|
+
master->pass_type = huff_opt_pass;
|
578
|
+
master->scan_number++;
|
579
|
+
break;
|
580
|
+
}
|
581
|
+
|
582
|
+
master->pass_number++;
|
583
|
+
}
|
584
|
+
|
585
|
+
|
586
|
+
/*
|
587
|
+
* Initialize master compression control.
|
588
|
+
*/
|
589
|
+
|
590
|
+
GLOBAL(void)
|
591
|
+
jinit_c_master_control(j_compress_ptr cinfo, boolean transcode_only)
|
592
|
+
{
|
593
|
+
my_master_ptr master;
|
594
|
+
|
595
|
+
master = (my_master_ptr)
|
596
|
+
(*cinfo->mem->alloc_small) ((j_common_ptr)cinfo, JPOOL_IMAGE,
|
597
|
+
sizeof(my_comp_master));
|
598
|
+
cinfo->master = (struct jpeg_comp_master *)master;
|
599
|
+
master->pub.prepare_for_pass = prepare_for_pass;
|
600
|
+
master->pub.pass_startup = pass_startup;
|
601
|
+
master->pub.finish_pass = finish_pass_master;
|
602
|
+
master->pub.is_last_pass = FALSE;
|
603
|
+
|
604
|
+
/* Validate parameters, determine derived values */
|
605
|
+
initial_setup(cinfo, transcode_only);
|
606
|
+
|
607
|
+
if (cinfo->scan_info != NULL) {
|
608
|
+
#ifdef C_MULTISCAN_FILES_SUPPORTED
|
609
|
+
validate_script(cinfo);
|
610
|
+
#else
|
611
|
+
ERREXIT(cinfo, JERR_NOT_COMPILED);
|
612
|
+
#endif
|
613
|
+
} else {
|
614
|
+
cinfo->progressive_mode = FALSE;
|
615
|
+
cinfo->num_scans = 1;
|
616
|
+
}
|
617
|
+
|
618
|
+
if (cinfo->progressive_mode && !cinfo->arith_code) /* TEMPORARY HACK ??? */
|
619
|
+
cinfo->optimize_coding = TRUE; /* assume default tables no good for progressive mode */
|
620
|
+
|
621
|
+
/* Initialize my private state */
|
622
|
+
if (transcode_only) {
|
623
|
+
/* no main pass in transcoding */
|
624
|
+
if (cinfo->optimize_coding)
|
625
|
+
master->pass_type = huff_opt_pass;
|
626
|
+
else
|
627
|
+
master->pass_type = output_pass;
|
628
|
+
} else {
|
629
|
+
/* for normal compression, first pass is always this type: */
|
630
|
+
master->pass_type = main_pass;
|
631
|
+
}
|
632
|
+
master->scan_number = 0;
|
633
|
+
master->pass_number = 0;
|
634
|
+
if (cinfo->optimize_coding)
|
635
|
+
master->total_passes = cinfo->num_scans * 2;
|
636
|
+
else
|
637
|
+
master->total_passes = cinfo->num_scans;
|
638
|
+
|
639
|
+
master->jpeg_version = PACKAGE_NAME " version " VERSION " (build " BUILD ")";
|
640
|
+
}
|