diff --git a/.mailmap b/.mailmap index cf26f1df..376fd583 100644 --- a/.mailmap +++ b/.mailmap @@ -17,3 +17,4 @@ Roberto Alanis Brian Ledger Maryla Ustarroz-Calonge Yannis Guyon +Henner Zeller diff --git a/AUTHORS b/AUTHORS index 6772bcd1..6fe9552c 100644 --- a/AUTHORS +++ b/AUTHORS @@ -10,9 +10,11 @@ Contributors: - Christian Duvivier (cduvivier at google dot com) - Christopher Degawa (ccom at randomderp dot com) - Clement Courbet (courbet at google dot com) +- devtools-clrobot at google dot com (devtools-clrobot@google dot com) - Djordje Pesut (djordje dot pesut at imgtec dot com) - Frank (1433351828 at qq dot com) - Frank Barchard (fbarchard at google dot com) +- Henner Zeller (hzeller at google dot com) - Hui Su (huisu at google dot com) - H. Vetinari (h dot vetinari at gmx dot com) - Ilya Kurdyukov (jpegqs at gmail dot com) diff --git a/CMakeLists.txt b/CMakeLists.txt index 2222b36c..39d3d8f6 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -84,6 +84,15 @@ if(WEBP_BUILD_WEBP_JS) message(NOTICE "wasm2js does not support SIMD, disabling webp.js generation.") endif() + + if(NOT EMSCRIPTEN_VERSION) + message( + WARNING + "EMSCRIPTEN_VERSION not detected!\n" + "WEBP_BUILD_WEBP_JS is only supported with emcmake/emmake.\n" + "The build may fail if those tools are not used. See webp_js/README.md." + ) + endif() endif() set(SHARPYUV_DEP_LIBRARIES) diff --git a/ChangeLog b/ChangeLog index 4b07e231..0d53a320 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,65 @@ +370aa581 webp_js/README.md: add some more code formatting (``) +f83c6b32 CMakeLists: add warning for incorrect emscripten config +6a3e656b update ChangeLog (tag: v1.6.0-rc1) +bf0bf1e7 api.md: add WebPValidateDecoderConfig to pseudocode +e8ae210d update NEWS +ce53efd7 bump version to 1.6.0 +1c333170 update AUTHORS +85e098e5 webpmux: fix heap overflow w/-get/-set +418340d8 Merge "Make histogram allocation and access more readable and type-safe." into main +23ce76fa Merge "VP8BitReaderSetBuffer: move NULL check to call site" into main +bbf3cbb1 VP8BitReaderSetBuffer: move NULL check to call site +f6b87e03 Fix const style guide +8852f89a Have lossless return the same results with/without -mt +e015dcc0 Make histogram allocation and access more readable and type-safe. +753ed11e enc_neon.c: fix aarch64 compilation w/gcc < 8.5.0 +0cd0b7a7 enc_fuzzer.cc: remove duplicate include +2209ffba swig,cosmetics: normalize includes +15e2e1ee analysis_enc.c: remove unused include +98c27801 IWYU: Include all headers for symbols used in files. +eb3ff781 Only use valid histograms in VP8LHistogramSet +57e324e2 Refactor VP8LHistogram histogram_enc.cc +7191a602 Merge "Generalize trivial histograms" into main +19696e0a Merge "alpha_processing_sse2: quiet signed conv warning" into main +89b01ecc Merge "cwebp: add `-resize_mode`" into main +52a430a7 Generalize trivial histograms +e53e2130 Cache all costs in the histograms +f8b360c4 alpha_processing_sse2: quiet signed conv warning +eb4f8137 cwebp: add `-resize_mode` +ad52d5fc dec/dsp/enc/utils,cosmetics: rm struct member '_' suffix +ed7cd6a7 utils.c,cosmetics: rm struct member '_' suffix +3a23b0f0 random_utils.[hc],cosmetics: rm struct member '_' suffix +a99d0e6f quant_levels_dec_utils.c,cosmetics: rm struct member '_' suffix +1ed4654d huffman_encode_utils.[hc],cosmetics: rm struct member '_' suffix +f0689e48 config_enc.c,cosmetics: rm struct member '_' suffix +24262266 mux,cosmetics: rm struct member '_' suffix +3f54b1aa demux,cosmetics: rm struct member '_' suffix +295804e4 examples,cosmetics: rm struct member '_' suffix +5225592f Refactor VP8LHistogram to hide initializations from the user. +00338240 Remove some computations in histogram clustering +44f91b0d Speed DispatchAlpha_SSE2 up +ee8e8c62 Fix member naming for VP8LHistogram +a1ad3f1e Merge "Remove now unused ExtraCostCombined" into main +321561b4 Remove now unused ExtraCostCombined +e0ae21d2 WebPMemoryWriterClear: use WebPMemoryWriterInit +a4183d94 Remove the computation of ExtraCost when comparing histograms +f2b3f527 Get AVX2 into WebP lossless +7c70ff7a Clean dsp/lossless includes +9dd5ae81 Use the full register in PredictorSub13_SSE2 +613be8fc Makefile.vc: add /MP to CFLAGS +1d86819f Merge changes I1437390a,I10a20de5,I1ac777d1 into main +743a5f09 enc_neon: enable vld1q_u8_x4 for clang & msvc +565da148 pngdec.c: add support for 'eXIf' tag +319860e9 pngdec.c: support ImageMagick app1 exif text data +815fc1e1 pngdec.c: add missing #ifdef for png_get_iCCP +980b708e enc_neon: fix build w/aarch64 gcc < 9.4.0 +73b728cb cmake: bump minimum version to 3.16 +6a22b670 Add a function to validate a WebPDecoderConfig +7ed2b10e Use consistently signed stride types. +654bfb04 Avoid nullptr arithmetic in VP8BitReaderSetBuffer +f8f24107 Fix potential "divide by zero" in examples found by coverity +2af6c034 Merge tag 'v1.5.0' +a4d7a715 update ChangeLog (tag: v1.5.0, origin/1.5.0) c3d85ce4 update NEWS ad14e811 tests/fuzzer/*: add missing include 74cd026e fuzz_utils.cc: fix build error w/WEBP_REDUCE_SIZE diff --git a/NEWS b/NEWS index 7ad3df03..fa4f977a 100644 --- a/NEWS +++ b/NEWS @@ -1,3 +1,16 @@ +- 6/30/2025 version 1.6.0 + This is a binary compatible release. + API changes: + - libwebp: WebPValidateDecoderConfig + * additional x86 (AVX2, SSE2), general optimizations and compression + improvements for lossless + * `-mt` returns same results as single-threaded lossless (regressed in + 1.5.0, #426506716) + * miscellaneous warning, bug & build fixes (#393104377, #397130631, + #398288323, #398066379, #427503509) + Tool updates: + * cwebp can restrict the use of `-resize` with `-resize_mode` (#405437935) + - 12/19/2024 version 1.5.0 This is a binary compatible release. API changes: diff --git a/README.md b/README.md index 8ae1ab79..90f2b059 100644 --- a/README.md +++ b/README.md @@ -7,7 +7,7 @@ \__\__/\____/\_____/__/ ____ ___ / _/ / \ \ / _ \/ _/ / \_/ / / \ \ __/ \__ - \____/____/\_____/_____/____/v1.5.0 + \____/____/\_____/_____/____/v1.6.0 ``` WebP codec is a library to encode and decode images in WebP format. This package diff --git a/configure.ac b/configure.ac index d6d634f6..a9a82a04 100644 --- a/configure.ac +++ b/configure.ac @@ -1,4 +1,4 @@ -AC_INIT([libwebp], [1.5.0], +AC_INIT([libwebp], [1.6.0], [https://issues.webmproject.org],, [https://developers.google.com/speed/webp]) AC_CANONICAL_HOST diff --git a/doc/api.md b/doc/api.md index c5d83dbb..1193f00d 100644 --- a/doc/api.md +++ b/doc/api.md @@ -202,6 +202,7 @@ config.output.u.RGBA.rgba = (uint8_t*) memory_buffer; config.output.u.RGBA.stride = scanline_stride; config.output.u.RGBA.size = total_size_of_the_memory_buffer; config.output.is_external_memory = 1; +config_error = WebPValidateDecoderConfig(&config); // not mandatory, but useful // E) Decode the WebP image. There are two variants w.r.t decoding image. // The first one (E.1) decodes the full image and the second one (E.2) is diff --git a/extras/extras.c b/extras/extras.c index 4f38ab50..b679a750 100644 --- a/extras/extras.c +++ b/extras/extras.c @@ -25,7 +25,7 @@ #include "webp/types.h" #define XTRA_MAJ_VERSION 1 -#define XTRA_MIN_VERSION 5 +#define XTRA_MIN_VERSION 6 #define XTRA_REV_VERSION 0 //------------------------------------------------------------------------------ diff --git a/sharpyuv/Makefile.am b/sharpyuv/Makefile.am index bd5b22dc..92baca9c 100644 --- a/sharpyuv/Makefile.am +++ b/sharpyuv/Makefile.am @@ -33,7 +33,7 @@ libsharpyuv_la_SOURCES += sharpyuv_gamma.c sharpyuv_gamma.h libsharpyuv_la_SOURCES += sharpyuv.c sharpyuv.h libsharpyuv_la_CPPFLAGS = $(AM_CPPFLAGS) -libsharpyuv_la_LDFLAGS = -no-undefined -version-info 1:1:1 -lm +libsharpyuv_la_LDFLAGS = -no-undefined -version-info 1:2:1 -lm libsharpyuv_la_LIBADD = libsharpyuv_la_LIBADD += libsharpyuv_sse2.la libsharpyuv_la_LIBADD += libsharpyuv_neon.la diff --git a/sharpyuv/libsharpyuv.rc b/sharpyuv/libsharpyuv.rc index 93fd1b8c..9ab784cf 100644 --- a/sharpyuv/libsharpyuv.rc +++ b/sharpyuv/libsharpyuv.rc @@ -6,8 +6,8 @@ LANGUAGE LANG_ENGLISH, SUBLANG_ENGLISH_US VS_VERSION_INFO VERSIONINFO - FILEVERSION 0,0,4,1 - PRODUCTVERSION 0,0,4,1 + FILEVERSION 0,0,4,2 + PRODUCTVERSION 0,0,4,2 FILEFLAGSMASK 0x3fL #ifdef _DEBUG FILEFLAGS 0x1L @@ -24,12 +24,12 @@ BEGIN BEGIN VALUE "CompanyName", "Google, Inc." VALUE "FileDescription", "libsharpyuv DLL" - VALUE "FileVersion", "0.4.1" + VALUE "FileVersion", "0.4.2" VALUE "InternalName", "libsharpyuv.dll" - VALUE "LegalCopyright", "Copyright (C) 2024" + VALUE "LegalCopyright", "Copyright (C) 2025" VALUE "OriginalFilename", "libsharpyuv.dll" VALUE "ProductName", "SharpYuv Library" - VALUE "ProductVersion", "0.4.1" + VALUE "ProductVersion", "0.4.2" END END BLOCK "VarFileInfo" diff --git a/sharpyuv/sharpyuv.h b/sharpyuv/sharpyuv.h index 0317fd49..f04bf121 100644 --- a/sharpyuv/sharpyuv.h +++ b/sharpyuv/sharpyuv.h @@ -52,7 +52,7 @@ extern "C" { // SharpYUV API version following the convention from semver.org #define SHARPYUV_VERSION_MAJOR 0 #define SHARPYUV_VERSION_MINOR 4 -#define SHARPYUV_VERSION_PATCH 1 +#define SHARPYUV_VERSION_PATCH 2 // Version as a uint32_t. The major number is the high 8 bits. // The minor number is the middle 8 bits. The patch number is the low 16 bits. #define SHARPYUV_MAKE_VERSION(MAJOR, MINOR, PATCH) \ diff --git a/src/Makefile.am b/src/Makefile.am index b4473450..5945ad9f 100644 --- a/src/Makefile.am +++ b/src/Makefile.am @@ -36,7 +36,7 @@ libwebp_la_LIBADD += utils/libwebputils.la # other than the ones listed on the command line, i.e., after linking, it will # not have unresolved symbols. Some platforms (Windows among them) require all # symbols in shared libraries to be resolved at library creation. -libwebp_la_LDFLAGS = -no-undefined -version-info 8:10:1 +libwebp_la_LDFLAGS = -no-undefined -version-info 9:0:2 libwebpincludedir = $(includedir)/webp pkgconfig_DATA = libwebp.pc @@ -48,7 +48,7 @@ if BUILD_LIBWEBPDECODER libwebpdecoder_la_LIBADD += dsp/libwebpdspdecode.la libwebpdecoder_la_LIBADD += utils/libwebputilsdecode.la - libwebpdecoder_la_LDFLAGS = -no-undefined -version-info 4:10:1 + libwebpdecoder_la_LDFLAGS = -no-undefined -version-info 5:0:2 pkgconfig_DATA += libwebpdecoder.pc endif diff --git a/src/dec/vp8i_dec.h b/src/dec/vp8i_dec.h index 1e806b90..6d4c092b 100644 --- a/src/dec/vp8i_dec.h +++ b/src/dec/vp8i_dec.h @@ -36,7 +36,7 @@ extern "C" { // version numbers #define DEC_MAJ_VERSION 1 -#define DEC_MIN_VERSION 5 +#define DEC_MIN_VERSION 6 #define DEC_REV_VERSION 0 // YUV-cache parameters. Cache is 32-bytes wide (= one cacheline). diff --git a/src/demux/Makefile.am b/src/demux/Makefile.am index 30ecd0e7..113ea8ed 100644 --- a/src/demux/Makefile.am +++ b/src/demux/Makefile.am @@ -13,6 +13,6 @@ noinst_HEADERS = noinst_HEADERS += ../webp/format_constants.h libwebpdemux_la_LIBADD = ../libwebp.la -libwebpdemux_la_LDFLAGS = -no-undefined -version-info 2:16:0 +libwebpdemux_la_LDFLAGS = -no-undefined -version-info 2:17:0 libwebpdemuxincludedir = $(includedir)/webp pkgconfig_DATA = libwebpdemux.pc diff --git a/src/demux/demux.c b/src/demux/demux.c index 54734420..7d4e23e2 100644 --- a/src/demux/demux.c +++ b/src/demux/demux.c @@ -27,7 +27,7 @@ #include "src/webp/types.h" #define DMUX_MAJ_VERSION 1 -#define DMUX_MIN_VERSION 5 +#define DMUX_MIN_VERSION 6 #define DMUX_REV_VERSION 0 typedef struct { diff --git a/src/demux/libwebpdemux.rc b/src/demux/libwebpdemux.rc index f01ad2ac..8ae9feab 100644 --- a/src/demux/libwebpdemux.rc +++ b/src/demux/libwebpdemux.rc @@ -6,8 +6,8 @@ LANGUAGE LANG_ENGLISH, SUBLANG_ENGLISH_US VS_VERSION_INFO VERSIONINFO - FILEVERSION 1,0,5,0 - PRODUCTVERSION 1,0,5,0 + FILEVERSION 1,0,6,0 + PRODUCTVERSION 1,0,6,0 FILEFLAGSMASK 0x3fL #ifdef _DEBUG FILEFLAGS 0x1L @@ -24,12 +24,12 @@ BEGIN BEGIN VALUE "CompanyName", "Google, Inc." VALUE "FileDescription", "libwebpdemux DLL" - VALUE "FileVersion", "1.5.0" + VALUE "FileVersion", "1.6.0" VALUE "InternalName", "libwebpdemux.dll" - VALUE "LegalCopyright", "Copyright (C) 2024" + VALUE "LegalCopyright", "Copyright (C) 2025" VALUE "OriginalFilename", "libwebpdemux.dll" VALUE "ProductName", "WebP Image Demuxer" - VALUE "ProductVersion", "1.5.0" + VALUE "ProductVersion", "1.6.0" END END BLOCK "VarFileInfo" diff --git a/src/enc/vp8i_enc.h b/src/enc/vp8i_enc.h index 8c186079..22a2d87b 100644 --- a/src/enc/vp8i_enc.h +++ b/src/enc/vp8i_enc.h @@ -34,7 +34,7 @@ extern "C" { // version numbers #define ENC_MAJ_VERSION 1 -#define ENC_MIN_VERSION 5 +#define ENC_MIN_VERSION 6 #define ENC_REV_VERSION 0 enum { MAX_LF_LEVELS = 64, // Maximum loop filter level diff --git a/src/libwebp.rc b/src/libwebp.rc index 92fd893a..2ffd6c5d 100644 --- a/src/libwebp.rc +++ b/src/libwebp.rc @@ -6,8 +6,8 @@ LANGUAGE LANG_ENGLISH, SUBLANG_ENGLISH_US VS_VERSION_INFO VERSIONINFO - FILEVERSION 1,0,5,0 - PRODUCTVERSION 1,0,5,0 + FILEVERSION 1,0,6,0 + PRODUCTVERSION 1,0,6,0 FILEFLAGSMASK 0x3fL #ifdef _DEBUG FILEFLAGS 0x1L @@ -24,12 +24,12 @@ BEGIN BEGIN VALUE "CompanyName", "Google, Inc." VALUE "FileDescription", "libwebp DLL" - VALUE "FileVersion", "1.5.0" + VALUE "FileVersion", "1.6.0" VALUE "InternalName", "libwebp.dll" - VALUE "LegalCopyright", "Copyright (C) 2024" + VALUE "LegalCopyright", "Copyright (C) 2025" VALUE "OriginalFilename", "libwebp.dll" VALUE "ProductName", "WebP Image Codec" - VALUE "ProductVersion", "1.5.0" + VALUE "ProductVersion", "1.6.0" END END BLOCK "VarFileInfo" diff --git a/src/libwebpdecoder.rc b/src/libwebpdecoder.rc index 8e6e4c71..8584e8e2 100644 --- a/src/libwebpdecoder.rc +++ b/src/libwebpdecoder.rc @@ -6,8 +6,8 @@ LANGUAGE LANG_ENGLISH, SUBLANG_ENGLISH_US VS_VERSION_INFO VERSIONINFO - FILEVERSION 1,0,5,0 - PRODUCTVERSION 1,0,5,0 + FILEVERSION 1,0,6,0 + PRODUCTVERSION 1,0,6,0 FILEFLAGSMASK 0x3fL #ifdef _DEBUG FILEFLAGS 0x1L @@ -24,12 +24,12 @@ BEGIN BEGIN VALUE "CompanyName", "Google, Inc." VALUE "FileDescription", "libwebpdecoder DLL" - VALUE "FileVersion", "1.5.0" + VALUE "FileVersion", "1.6.0" VALUE "InternalName", "libwebpdecoder.dll" - VALUE "LegalCopyright", "Copyright (C) 2024" + VALUE "LegalCopyright", "Copyright (C) 2025" VALUE "OriginalFilename", "libwebpdecoder.dll" VALUE "ProductName", "WebP Image Decoder" - VALUE "ProductVersion", "1.5.0" + VALUE "ProductVersion", "1.6.0" END END BLOCK "VarFileInfo" diff --git a/src/mux/Makefile.am b/src/mux/Makefile.am index 0512b649..f6c87d73 100644 --- a/src/mux/Makefile.am +++ b/src/mux/Makefile.am @@ -17,6 +17,6 @@ noinst_HEADERS = noinst_HEADERS += ../webp/format_constants.h libwebpmux_la_LIBADD = ../libwebp.la -libwebpmux_la_LDFLAGS = -no-undefined -version-info 4:1:1 -lm +libwebpmux_la_LDFLAGS = -no-undefined -version-info 4:2:1 -lm libwebpmuxincludedir = $(includedir)/webp pkgconfig_DATA = libwebpmux.pc diff --git a/src/mux/libwebpmux.rc b/src/mux/libwebpmux.rc index 60be5efc..dc60dfb5 100644 --- a/src/mux/libwebpmux.rc +++ b/src/mux/libwebpmux.rc @@ -6,8 +6,8 @@ LANGUAGE LANG_ENGLISH, SUBLANG_ENGLISH_US VS_VERSION_INFO VERSIONINFO - FILEVERSION 1,0,5,0 - PRODUCTVERSION 1,0,5,0 + FILEVERSION 1,0,6,0 + PRODUCTVERSION 1,0,6,0 FILEFLAGSMASK 0x3fL #ifdef _DEBUG FILEFLAGS 0x1L @@ -24,12 +24,12 @@ BEGIN BEGIN VALUE "CompanyName", "Google, Inc." VALUE "FileDescription", "libwebpmux DLL" - VALUE "FileVersion", "1.5.0" + VALUE "FileVersion", "1.6.0" VALUE "InternalName", "libwebpmux.dll" - VALUE "LegalCopyright", "Copyright (C) 2024" + VALUE "LegalCopyright", "Copyright (C) 2025" VALUE "OriginalFilename", "libwebpmux.dll" VALUE "ProductName", "WebP Image Muxer" - VALUE "ProductVersion", "1.5.0" + VALUE "ProductVersion", "1.6.0" END END BLOCK "VarFileInfo" diff --git a/src/mux/muxi.h b/src/mux/muxi.h index b0c10af7..f277758a 100644 --- a/src/mux/muxi.h +++ b/src/mux/muxi.h @@ -32,7 +32,7 @@ extern "C" { // Defines and constants. #define MUX_MAJ_VERSION 1 -#define MUX_MIN_VERSION 5 +#define MUX_MIN_VERSION 6 #define MUX_REV_VERSION 0 // Chunk object. diff --git a/webp_js/README.md b/webp_js/README.md index ae9ce8f0..64da0d2e 100644 --- a/webp_js/README.md +++ b/webp_js/README.md @@ -13,7 +13,7 @@ Emscripten and CMake. - install the Emscripten SDK following the procedure described at: https://emscripten.org/docs/getting_started/downloads.html#installation-instructions-using-the-emsdk-recommended After installation, you should have some global variable positioned to the - location of the SDK. In particular, $EMSDK should point to the top-level + location of the SDK. In particular, `$EMSDK` should point to the top-level directory containing Emscripten tools. - configure the project 'WEBP_JS' with CMake using: @@ -23,12 +23,12 @@ Emscripten and CMake. emcmake cmake -DWEBP_BUILD_WEBP_JS=ON ../ ``` -- compile webp.js using 'emmake make'. +- compile webp.js using `emmake make`. - that's it! Upon completion, you should have the 'webp.js', 'webp.js.mem', 'webp_wasm.js' and 'webp_wasm.wasm' files generated. -The callable JavaScript function is WebPToSDL(), which decodes a raw WebP +The callable JavaScript function is `WebPToSDL()`, which decodes a raw WebP bitstream into a canvas. See webp_js/index.html for a simple usage sample (see below for instructions).