Граф коммитов

128 Коммитов

Автор SHA1 Сообщение Дата
Kornel 8217fd5478 Merge tag '2.0.0'
* tag '2.0.0': (160 commits)
  Clarify Android Windows build instructions
  Bump revision to 2.0.0
  Build: Don't use @rpath with OS X 10.4 builds
  Fix JPEG spec references per ISO/ITU-T suggestions
  Fix int overflow when decompr. corrupt prog. JPEG
  cjpeg: Fix OOB read caused by malformed 8-bit BMP
  Build: Preserve CMake exe suffix from cmd line
  Honor CMake exe suffix when inst. static builds
  README.ijg: Clarification regarding JPEG 2000/XR
  BUILDING.md: Correct iOS/Android examples
  Build: Detect whether compiler supports DSPr2
  Fix jpeg_skip_scanlines() segfault w/merged upsamp
  Fix infinite loop in partial image decompression
  tjLoadImage(): Fix FPE triggered by malformed BMP
  TurboJPEG: Handle JERR_BMP*,JERR_PPM* error codes
  Fix CVE-2018-11813
  Travis: Use SKS keyserver pool
  Additional code formatting tweaks
  Java: Further style refinements
  Java: Reformat code per checkstyle recommendations
  ...
2018-11-11 16:13:59 +00:00
Kornel Lesiński ec333d5bbd Merge remote-tracking branch 'libjpeg-turbo/master' into libjpeg-turbo
* libjpeg-turbo/master: (140 commits)
  Increase severity of tjDecompressToYUV2() bug desc
  Catch libjpeg errors in tjDecompressToYUV2()
  BUILDING.md: Fix "... OR ..." indentation again
  BUILDING.md: Fix confusing Windows build reqs
  ChangeLog.md: Improve readability of plain text
  change.log: Refer users to ChangeLog.md
  Markdown version of ChangeLog.txt
  Rename ChangeLog.txt
  README.md: Link to BUILDING.md
  BUILDING.md and README.md: Cosmetic tweaks
  ChangeLog: "1.5 beta1" --> "1.4.90 (1.5 beta1)"
  Java: Fix parallel make with autotools
  Win/x64: Fix improper callee save of xmm8-xmm11
  Bump TurboJPEG C API revision to 1.5
  ChangeLog: Mention jpeg_crop_scanline() function
  1.5 beta1
  Fix v7/v8-compatible build
  libjpeg API: Partial scanline decompression
  Build: Make the NASM autoconf variable persistent
  Use consistent/modern code formatting for dbl ptrs
  ...
2016-04-28 01:08:01 +01:00
Kornel Lesiński 4d8f239872 Merge remote-tracking branch 'libjpeg-turbo/1.4.x' into libjpeg-turbo
* libjpeg-turbo/1.4.x: (94 commits)
  CMakeLists.txt: Clarify that Un*x isn't supported
  Catch libjpeg errors in tjDecompressToYUV2()
  cjpeg: Fix buf overrun caused by bad bin PPM input
  Add version/build info to global string table
  Ensure that default Huffman tables are initialized
  Fix memory leak when running tjunittest -yuv
  Prevent overread when decoding malformed JPEG
  Guard against wrap-around in alloc functions
  Fix Visual C++ compiler warnings
  rdppm.c: formatting tweaks
  jmemmgr.c: formatting tweaks
  TurboJPEG: Avoid dangling pointers
  Update Android build instr. for ARMv8, PIE, etc.
  Makefile.am: formatting tweak
  Update build instructions for new autoconf, GitHub
  1.4.3
  Regression: Allow co-install of 32-bit/64-bit RPMs
  Build: Use FILEPATH type for NASM CMake variable
  Comment formatting tweaks
  Fix 'make dist'
  ...
2016-04-28 00:50:50 +01:00
Kornel Lesiński 667fb53e3f Merge tag '1.4.1' into libjpeg-turbo
Tag 1.4.1 release

* tag '1.4.1': (427 commits)
  Now that the TurboJPEG API is reporting libjpeg warnings as errors, an "Invalid SOS parameters for sequential JPEG" warning surfaced in tjDecodeYUV*().  This was caused by the Se member of jpeg_decompress_struct being set to 0 (it is normally set to a non-zero value when the start-of-scan markers are read, but there are no SOS markers in this case, because we're not actually decompressing a JPEG file.)
  Fix a segfault that occured in the MIPS DSPr2 fancy upsampling routine when downsampled_width==3.  Because the DSPr2 code unrolls the loop for the middle columns (refer to jdsample.c), it has the effect of performing two column iterations, and that only works properly if the number of columns (minus the first and last) is >= 2.  For the specific case of downsampled_width==3, this patch skips to the second iteration of the unrolled column loop.
  If a warning (such as "Premature end of JPEG file") is triggered in the underlying libjpeg API, make sure that the TurboJPEG API function returns -1.  Unlike errors, however, libjpeg warnings do not make the TurboJPEG functions abort.
  Back out r1555 and r1548.  Using setenv() didn't fix the iOS simulator issue.  It just replaced an undefined _putenv$UNIX2003 symbol with an undefined _setenv$UNIX2003 symbol.  The correct solution seems to be to use -D_NONSTD_SOURCE when generating our official builds.
  Fix the Windows build.  I remember now why I used putenv() originally-- because Windows doesn't have setenv().  We could use _putenv_s(), but older versions of MinGW don't have that either.  Fortunately, since all of the environment values we're setting in turbojpeg.c are static, we can just map setenv() to putenv() using a macro.  NOTE: we still have to use _putenv_s() in turbojpeg-jni.c, but at least people who may need to build with an older version of MinGW can still do so by disabling the Java build.
  Allow building only static or only shared libraries on Windows
  __WORDSIZE doesn't seem to be available on platforms other than Mac or Linux, and best practices are for user-level code not to rely on it anyhow, since it's meant to be an internal macro.  Fortunately, autoconf already has a way of determining the word size at configure time, so it can be passed into the compiler.  This should work on any platform and has been tested on all of the Un*x platforms we support (Linux, Mac, FreeBSD, Solaris.)
  Unless you define _ANSI_SOURCE, then putenv() on Mac is renamed to putenv$UNIX2003(), and this causes problems when trying to link an i386 iOS application (for the simulator) against the TurboJPEG static library.  It's easiest to just use setenv() instead.
  Fix a bug in the 64-bit Huffman encoder that Google discovered when encoding some very specific (and proprietary) aerial images using quality=98, an optimized Huffman table, and the ISLOW DCT.  These images were causing the Huffman bit buffer to overflow, because the code for encoding the DC coefficient was using the equivalent of the 32-bit version of EMIT_BITS().  Thus, when 64-bit code was used, the DC coefficient code was not properly checking how many bits were in the buffer before attempting to add more bits to it.  This issue appears to have existed in all versions of libjpeg-turbo.
  Restore backward compatibility with MSVC < 2010 (broken by r1541)
  Oops.  OS X doesn't define __WORDSIZE unless you include stdint.h, so apparently the Huffman codec hasn't ever been fully accelerated on 64-bit OS X.
  Allow the executables and libraries outside of the sharedlib/ directory to be linked against msvcr*.dll instead of libcmt*.lib.  This is reported to be necessary when building libjpeg-turbo for use with C#.
  Surround the usage of getenv() in the TurboJPEG API with #ifndef NO_GETENV so that developers can add -DNO_GETENV to the C flags when building for platforms that don't have getenv().  Currently this is known to be necessary when building for Windows Phone.
  If libjpeg-turbo is configured with a non-default prefix, such as /usr, then use the docdir variable defined by autoconf 2.60 and later, if available.  This will, for instance, install the documentation under /usr/share/doc/libjpeg-turbo by default if prefix=/usr, unless docdir is overridden.  When using earlier versions of autoconf, docdir is set to ${datadir}/doc, as it always has been.
  Enable silent build rules for the NASM objects, if the source is configured with automake 1.11 or later.  NOTE: the build still spits out "error: ignoring unknown tag NASM" for each object, but unfortunately, if we remove "--tag NASM" from the command line, the build breaks under older versions of automake (it aborts with "unable to infer tagged configuration.")
  Set the RPM and deb architecture properly on non-x86 platforms.
  Come on, Cohaagen, you got what you want.  Give these people air!
  Oops.  Need to set the alpha channel when using TYPE_4BYTE_ABGR*.  This has no bearing on the actual tests, but it prevents the PNG pre-encode reference images for those tests from being blank.
  Oops.  The MIPS SIMD implementations of h2v1 and h2v2 upsampling were not checking for DSPr2 support, so running 'djpeg -nosmooth' on a non-DSPr2-enabled platform caused an "illegal instruction" error.
  Introduce fast paths to speed up NULL color conversion somewhat, particularly when using 64-bit code;  on the decompression side, the "slow path" also now use an approach similar to that of the compression side (with the component loop outside of the column loop rather than inside.)  This is faster when using 32-bit code.
  ...
2016-04-28 00:45:08 +01:00
DRC 7e3acc0e0a Rename README, LICENSE, BUILDING text files
The IJG README file has been renamed to README.ijg, in order to avoid
confusion (many people were assuming that that was our project's README
file and weren't reading README-turbo.txt) and to lay the groundwork for
markdown versions of the libjpeg-turbo README and build instructions.
2015-10-10 10:31:33 -05:00
DRC b4922b42e7 Merge branch '1.4.x' 2015-09-08 19:02:18 -05:00
DRC 465a9fe0cb Add file that explains the libjpeg-turbo licenses
Previously this information was found in a page on libjpeg-turbo.org,
but there was still some confusion, because README-turbo.txt wasn't
clear as to which license applied to what.
2015-09-08 18:59:37 -05:00
DRC 3f7608348d Come on, Cohaagen, you got what you want. Give these people air!
git-svn-id: svn+ssh://svn.code.sf.net/p/libjpeg-turbo/code/trunk@1527 632fc199-4ca6-4c93-a231-07263d6284db
2015-01-28 00:25:43 +00:00
DRC 7a2bb989f2 Some clarifications (actually MIPS doesn't implement the float DCT/IDCT using SIMD instructions)
git-svn-id: svn+ssh://svn.code.sf.net/p/libjpeg-turbo/code/branches/1.4.x@1517 632fc199-4ca6-4c93-a231-07263d6284db
2015-01-16 07:16:53 +00:00
DRC c60d662ee4 Some clarifications (actually MIPS doesn't implement the float DCT/IDCT using SIMD instructions)
git-svn-id: svn+ssh://svn.code.sf.net/p/libjpeg-turbo/code/branches/1.4.x@1517 632fc199-4ca6-4c93-a231-07263d6284db
2015-01-16 07:16:53 +00:00
DRC a614b4af9f Make the floating point regression tests optional. It has been known for quite some time that these tests do not always generate the same results unless there is full SIMD coverage of the floating point algorithms in libjpeg-turbo. Further research reveals that there are basically three expected results: the results from our SSE SIMD extensions (which are slightly more accurate than the C code), results from the C code when running on a 32-bit FPU (or when using SSE instructions on an x86-64 CPU, which is the default with GCC), and results from the C code when running on a 64-bit FPU (which presumably uses double-precision arithmetic by default.) There is basically no way to determine which type of math will be used prior to run time, so it's best to just let the developers specify which result they expect on their particular system.
git-svn-id: svn+ssh://svn.code.sf.net/p/libjpeg-turbo/code/branches/1.4.x@1515 632fc199-4ca6-4c93-a231-07263d6284db
2015-01-16 06:53:36 +00:00
DRC 3af282df3c Make the floating point regression tests optional. It has been known for quite some time that these tests do not always generate the same results unless there is full SIMD coverage of the floating point algorithms in libjpeg-turbo. Further research reveals that there are basically three expected results: the results from our SSE SIMD extensions (which are slightly more accurate than the C code), results from the C code when running on a 32-bit FPU (or when using SSE instructions on an x86-64 CPU, which is the default with GCC), and results from the C code when running on a 64-bit FPU (which presumably uses double-precision arithmetic by default.) There is basically no way to determine which type of math will be used prior to run time, so it's best to just let the developers specify which result they expect on their particular system.
git-svn-id: svn+ssh://svn.code.sf.net/p/libjpeg-turbo/code/branches/1.4.x@1515 632fc199-4ca6-4c93-a231-07263d6284db
2015-01-16 06:53:36 +00:00
DRC 2e2ea8e02c Document AltiVec extensions
git-svn-id: svn+ssh://svn.code.sf.net/p/libjpeg-turbo/code/trunk@1508 632fc199-4ca6-4c93-a231-07263d6284db
2015-01-16 03:21:05 +00:00
Josh Aas 6d172465cc Drop executable bit for README-turbo.txt 2014-12-08 13:28:32 -06:00
Kornel Lesiński 564022ebda Merge mozjpeg into libjpeg-turbo
* commit '1aa50b71d9453328ad30cce85baaf7ef87864197':
  Use precomputed table
  Improve floating point DCT
  Update doc re: various DCT implementations
  Fix build for wrjpgcom

Conflicts:
	jchuff.c
2014-09-07 16:51:55 +01:00
Frank Bossen 3adc64a4cb Improve floating point DCT
From libjpeg-turbo r1288
Port the more accurate (and slightly faster) floating point IDCT
implementation from jpeg-8a and later.  New research revealed that the
SSE/SSE2 floating point IDCT implementation was actually more accurate
than the jpeg-6b implementation, not less, which is why its
mathematical results have always differed from those of the jpeg-6b
implementation.  This patch brings the accuracy of the C code in line
with that of the SSE/SSE2 code.
2014-07-23 10:26:46 -04:00
Frank Bossen ccb1d12f53 Update doc re: various DCT implementations
From libjpeg-turbo r1287
2014-07-23 10:23:24 -04:00
DRC 715bb41ead Port the more accurate (and slightly faster) floating point IDCT implementation from jpeg-8a and later. New research revealed that the SSE/SSE2 floating point IDCT implementation was actually more accurate than the jpeg-6b implementation, not less, which is why its mathematical results have always differed from those of the jpeg-6b implementation. This patch brings the accuracy of the C code in line with that of the SSE/SSE2 code.
git-svn-id: svn+ssh://svn.code.sf.net/p/libjpeg-turbo/code/trunk@1288 632fc199-4ca6-4c93-a231-07263d6284db
2014-05-11 10:09:07 +00:00
DRC 7f3a5c18e6 Port the more accurate (and slightly faster) floating point IDCT implementation from jpeg-8a and later. New research revealed that the SSE/SSE2 floating point IDCT implementation was actually more accurate than the jpeg-6b implementation, not less, which is why its mathematical results have always differed from those of the jpeg-6b implementation. This patch brings the accuracy of the C code in line with that of the SSE/SSE2 code.
git-svn-id: svn+ssh://svn.code.sf.net/p/libjpeg-turbo/code/trunk@1288 632fc199-4ca6-4c93-a231-07263d6284db
2014-05-11 10:09:07 +00:00
DRC a758460175 Provide a more thorough description of the trade-offs between the various DCT/IDCT algorithms, based on new resarch
git-svn-id: svn+ssh://svn.code.sf.net/p/libjpeg-turbo/code/trunk@1287 632fc199-4ca6-4c93-a231-07263d6284db
2014-05-11 09:48:11 +00:00
DRC eb590a6e25 Provide a more thorough description of the trade-offs between the various DCT/IDCT algorithms, based on new resarch
git-svn-id: svn+ssh://svn.code.sf.net/p/libjpeg-turbo/code/trunk@1287 632fc199-4ca6-4c93-a231-07263d6284db
2014-05-11 09:48:11 +00:00
DRC 8940e6ca86 Provide a more thorough description of the trade-offs between the various DCT/IDCT algorithms, based on new resarch
git-svn-id: svn+ssh://svn.code.sf.net/p/libjpeg-turbo/code/branches/1.3.x@1286 632fc199-4ca6-4c93-a231-07263d6284db
2014-05-11 09:46:28 +00:00
DRC 6b48fbd229 Provide a more thorough description of the trade-offs between the various DCT/IDCT algorithms, based on new resarch
git-svn-id: svn+ssh://svn.code.sf.net/p/libjpeg-turbo/code/branches/1.3.x@1286 632fc199-4ca6-4c93-a231-07263d6284db
2014-05-11 09:46:28 +00:00
DRC fdc2954e79 Remove the sections about replacing libjpeg at run time and compile time. These were written before O/S distributions started shipping libjpeg-turbo, and they are either pedantic or no longer relevant. Also remove any text that assumes the use of our official project binaries. Notes specific to the official binaries have been moved into the project wiki. 2014-03-23 15:21:20 +00:00
DRC 832b1fc5d3 Remove the sections about replacing libjpeg at run time and compile time. These were written before O/S distributions started shipping libjpeg-turbo, and they are either pedantic or no longer relevant. Also remove any text that assumes the use of our official project binaries. Notes specific to the official binaries have been moved into the project wiki.
git-svn-id: svn+ssh://svn.code.sf.net/p/libjpeg-turbo/code/trunk@1210 632fc199-4ca6-4c93-a231-07263d6284db
2014-03-23 15:21:20 +00:00
DRC 3b8d4263fc Remove the sections about replacing libjpeg at run time and compile time. These were written before O/S distributions started shipping libjpeg-turbo, and they are either pedantic or no longer relevant. Also remove any text that assumes the use of our official project binaries. Notes specific to the official binaries have been moved into the project wiki.
git-svn-id: svn+ssh://svn.code.sf.net/p/libjpeg-turbo/code/trunk@1210 632fc199-4ca6-4c93-a231-07263d6284db
2014-03-23 15:21:20 +00:00
Josh Aas 72b66f9c77 Initial commit of libjpeg-turbo plus readme edits. 2014-01-13 18:28:20 -06:00
DRC a0d29e0364 Wordsmith the project description 2013-01-23 01:32:25 +00:00
DRC 0f7ff719a1 Wordsmith the project description
git-svn-id: svn+ssh://svn.code.sf.net/p/libjpeg-turbo/code/trunk@921 632fc199-4ca6-4c93-a231-07263d6284db
2013-01-23 01:32:25 +00:00
DRC 8e43940920 Wordsmith the project description
git-svn-id: svn+ssh://svn.code.sf.net/p/libjpeg-turbo/code/trunk@921 632fc199-4ca6-4c93-a231-07263d6284db
2013-01-23 01:32:25 +00:00
DRC 9f8a003137 Eliminated the awkward and confusing "TurboJPEG/OSS" designation, since there are no other active implementations of the TurboJPEG API anymore; don't refer to the libjpeg API library as "libjpeg-turbo" anymore, since that can be confusing; ARM v7s build instructions 2013-01-21 23:42:12 +00:00
DRC 5039d734d5 Eliminated the awkward and confusing "TurboJPEG/OSS" designation, since there are no other active implementations of the TurboJPEG API anymore; don't refer to the libjpeg API library as "libjpeg-turbo" anymore, since that can be confusing; ARM v7s build instructions
git-svn-id: svn+ssh://svn.code.sf.net/p/libjpeg-turbo/code/trunk@919 632fc199-4ca6-4c93-a231-07263d6284db
2013-01-21 23:42:12 +00:00
DRC 34be67477f Eliminated the awkward and confusing "TurboJPEG/OSS" designation, since there are no other active implementations of the TurboJPEG API anymore; don't refer to the libjpeg API library as "libjpeg-turbo" anymore, since that can be confusing; ARM v7s build instructions
git-svn-id: svn+ssh://svn.code.sf.net/p/libjpeg-turbo/code/trunk@919 632fc199-4ca6-4c93-a231-07263d6284db
2013-01-21 23:42:12 +00:00
DRC 81de93c8a5 Since Windows doesn't use lazy loading, clarify that a Windows application that uses jpeg_mem_dest() or jpeg_mem_src() must use the DLL containing those functions at run time. Other wordsmithing 2013-01-19 00:13:57 +00:00
DRC dc4645d422 Since Windows doesn't use lazy loading, clarify that a Windows application that uses jpeg_mem_dest() or jpeg_mem_src() must use the DLL containing those functions at run time. Other wordsmithing
git-svn-id: svn+ssh://svn.code.sf.net/p/libjpeg-turbo/code/trunk@915 632fc199-4ca6-4c93-a231-07263d6284db
2013-01-19 00:13:57 +00:00
DRC a30a027128 Since Windows doesn't use lazy loading, clarify that a Windows application that uses jpeg_mem_dest() or jpeg_mem_src() must use the DLL containing those functions at run time. Other wordsmithing
git-svn-id: svn+ssh://svn.code.sf.net/p/libjpeg-turbo/code/trunk@915 632fc199-4ca6-4c93-a231-07263d6284db
2013-01-19 00:13:57 +00:00
DRC ba4a6c32f8 Implement in-memory source/destination managers even when not emulating the libjpeg v8 API/ABI 2013-01-18 23:42:31 +00:00
DRC ab70623eb2 Implement in-memory source/destination managers even when not emulating the libjpeg v8 API/ABI
git-svn-id: svn+ssh://svn.code.sf.net/p/libjpeg-turbo/code/trunk@913 632fc199-4ca6-4c93-a231-07263d6284db
2013-01-18 23:42:31 +00:00
DRC dc3556a0a1 Implement in-memory source/destination managers even when not emulating the libjpeg v8 API/ABI
git-svn-id: svn+ssh://svn.code.sf.net/p/libjpeg-turbo/code/trunk@913 632fc199-4ca6-4c93-a231-07263d6284db
2013-01-18 23:42:31 +00:00
DRC 6a9229ae96 Include justification for not supporting SmartScale, DCT scaling, and the libjpeg v9 ABI 2013-01-18 06:12:51 +00:00
DRC b87136c2c7 Include justification for not supporting SmartScale, DCT scaling, and the libjpeg v9 ABI
git-svn-id: svn+ssh://svn.code.sf.net/p/libjpeg-turbo/code/trunk@912 632fc199-4ca6-4c93-a231-07263d6284db
2013-01-18 06:12:51 +00:00
DRC 0d605d57f4 Include justification for not supporting SmartScale, DCT scaling, and the libjpeg v9 ABI
git-svn-id: svn+ssh://svn.code.sf.net/p/libjpeg-turbo/code/trunk@912 632fc199-4ca6-4c93-a231-07263d6284db
2013-01-18 06:12:51 +00:00
DRC 8adaa68d4b Subtle point, but the libjpeg v7+ API is not backward incompatible. That is, programs that were built against jpeg-6b can still build against jpeg-7+ with no issues. It's only the ABI that is backward incompatible, so the primary justification for implementing the emulation feature was to provide run-time (ABI) compatibility. 2013-01-18 06:02:10 +00:00
DRC eff4f956fe Subtle point, but the libjpeg v7+ API is not backward incompatible. That is, programs that were built against jpeg-6b can still build against jpeg-7+ with no issues. It's only the ABI that is backward incompatible, so the primary justification for implementing the emulation feature was to provide run-time (ABI) compatibility.
git-svn-id: svn+ssh://svn.code.sf.net/p/libjpeg-turbo/code/trunk@911 632fc199-4ca6-4c93-a231-07263d6284db
2013-01-18 06:02:10 +00:00
DRC 6ae33e0848 Subtle point, but the libjpeg v7+ API is not backward incompatible. That is, programs that were built against jpeg-6b can still build against jpeg-7+ with no issues. It's only the ABI that is backward incompatible, so the primary justification for implementing the emulation feature was to provide run-time (ABI) compatibility.
git-svn-id: svn+ssh://svn.code.sf.net/p/libjpeg-turbo/code/trunk@911 632fc199-4ca6-4c93-a231-07263d6284db
2013-01-18 06:02:10 +00:00
DRC 1e7853c0cc In all fairness, breaking backward ABI compatibility was necessary in jpeg-7 and jpeg-8 due to the fact that the caller allocates the struct. 2013-01-13 11:05:25 +00:00
DRC 5815699bff In all fairness, breaking backward ABI compatibility was necessary in jpeg-7 and jpeg-8 due to the fact that the caller allocates the struct.
git-svn-id: svn+ssh://svn.code.sf.net/p/libjpeg-turbo/code/trunk@901 632fc199-4ca6-4c93-a231-07263d6284db
2013-01-13 11:05:25 +00:00
DRC ffdedb5963 In all fairness, breaking backward ABI compatibility was necessary in jpeg-7 and jpeg-8 due to the fact that the caller allocates the struct.
git-svn-id: svn+ssh://svn.code.sf.net/p/libjpeg-turbo/code/trunk@901 632fc199-4ca6-4c93-a231-07263d6284db
2013-01-13 11:05:25 +00:00
DRC 33fb70b328 2013-01-11 11:07:37 +00:00
DRC dad4d2e76c git-svn-id: svn+ssh://svn.code.sf.net/p/libjpeg-turbo/code/trunk@894 632fc199-4ca6-4c93-a231-07263d6284db 2013-01-11 11:07:37 +00:00