GraphicsMagick: JPEG: Ignore C_LOSSLESS_SUPPORTED/D_LOSSLESS_SUP...
GraphicsMagick Commits <[email protected]>
| Newsgroups | gmane.comp.video.graphicsmagick.cvs |
|---|---|
| Message-ID | <mailman.11091.1675522433.1507.graphicsmagick-commit@lists.sourceforge.net> |
changeset 166bc6d3500d in /hg/GraphicsMagick details: http://hg.GraphicsMagick.org/hg/GraphicsMagick?cmd=changeset;node=166bc6d3500d summary: JPEG: Ignore C_LOSSLESS_SUPPORTED/D_LOSSLESS_SUPPORTED defined by JPEG-Turbo diffstat: ChangeLog | 4 ++++ coders/jpeg.c | 10 ++++++---- www/Changelog.html | 3 +++ 3 files changed, 13 insertions(+), 4 deletions(-) diffs (65 lines): diff -r 8c82d3be7869 -r 166bc6d3500d ChangeLog --- a/ChangeLog Sat Feb 04 08:19:21 2023 -0600 +++ b/ChangeLog Sat Feb 04 08:53:40 2023 -0600 @@ -1,5 +1,9 @@ 2023-02-04 Bob Friesenhahn <[email protected]> + * coders/jpeg.c: Block out existing code for C_LOSSLESS_SUPPORTED + and D_LOSSLESS_SUPPORTED when compiling with JPEG-Turbo since it + is not compatible with it. + * coders/wpg.c (ApproveFormatForWPG): Pass in existing ExceptionInfo pointer. diff -r 8c82d3be7869 -r 166bc6d3500d coders/jpeg.c --- a/coders/jpeg.c Sat Feb 04 08:19:21 2023 -0600 +++ b/coders/jpeg.c Sat Feb 04 08:53:40 2023 -0600 @@ -1,5 +1,5 @@ /* -% Copyright (C) 2003-2022 GraphicsMagick Group +% Copyright (C) 2003-2023 GraphicsMagick Group % Copyright (C) 2002 ImageMagick Studio % Copyright 1991-1999 E. I. du Pont de Nemours and Company % @@ -954,7 +954,7 @@ i; save_quality=0; -#ifdef D_LOSSLESS_SUPPORTED +#if !defined(LIBJPEG_TURBO_VERSION_NUMBER) && defined(D_LOSSLESS_SUPPORTED) if (image->compression==LosslessJPEGCompression) { save_quality=100; @@ -1461,7 +1461,9 @@ } #endif #if (JPEG_LIB_VERSION >= 61) && defined(D_PROGRESSIVE_SUPPORTED) -#ifdef D_LOSSLESS_SUPPORTED +#if !defined(LIBJPEG_TURBO_VERSION_NUMBER) && defined(D_LOSSLESS_SUPPORTED) + /* This code is based on a patch to IJG JPEG 6b, or somesuch. Standard + library does not have a 'process' member. */ image->interlace= jpeg_info.process == JPROC_PROGRESSIVE ? LineInterlace : NoInterlace; image->compression=jpeg_info.process == JPROC_LOSSLESS ? @@ -2896,7 +2898,7 @@ if ((image->compression == LosslessJPEGCompression) || (quality > 100)) { -#if defined(C_LOSSLESS_SUPPORTED) +#if !defined(LIBJPEG_TURBO_VERSION_NUMBER) && defined(C_LOSSLESS_SUPPORTED) if (quality < 100) ThrowException(&image->exception,CoderWarning, LosslessToLossyJPEGConversion,(char *) NULL); diff -r 8c82d3be7869 -r 166bc6d3500d www/Changelog.html --- a/www/Changelog.html Sat Feb 04 08:19:21 2023 -0600 +++ b/www/Changelog.html Sat Feb 04 08:53:40 2023 -0600 @@ -40,6 +40,9 @@ <p>2023-02-04 Bob Friesenhahn <<a class="reference external" href="mailto:bfriesen%40simple.dallas.tx.us">bfriesen<span>@</span>simple<span>.</span>dallas<span>.</span>tx<span>.</span>us</a>></p> <blockquote> <ul class="simple"> +<li><p>coders/jpeg.c: Block out existing code for C_LOSSLESS_SUPPORTED +and D_LOSSLESS_SUPPORTED when compiling with JPEG-Turbo since it +is not compatible with it.</p></li> <li><p>coders/wpg.c (ApproveFormatForWPG): Pass in existing ExceptionInfo pointer.</p></li> </ul>