Skip to content

Releases: AOMediaCodec/libavif

v1.1.1

30 Jul 19:26
Compare
Choose a tag to compare

1.1.1 - 2024-07-30

Changed since 1.1.0

  • In avif.h, change "AVIF_API AVIF_NODISCARD" back to "AVIF_NODISCARD AVIF_API"
    to fix clang-cl and MSVC compilation errors in the shared library build on
    Windows.
  • Fix -DAVIF_GTEST=SYSTEM, #2258.
  • Fix infe_type and codec_config_type wrongly read as byte-aligned fields in the
    experimental feature AVIF_ENABLE_EXPERIMENTAL_METAV1.
  • When building aom as a local dependency, runtime CPU detection
    (CONFIG_RUNTIME_CPU_DETECT) is now always ON; in 1.1.0 it had been
    disabled for non-native builds.
  • Fix CMake config shared library leaks
    #2264.
  • Fix clang-cl compilation.
  • Update gain map metadata to current ISO 21496-1 draft.
  • cmake: Only search for ASM_NASM language on x86_64 platforms.
  • Fix "No known features for CXX compiler" CMake error.
  • Fix aom link flags so that transitive library link flags are included when
    aom is a static library
    #2274.
  • Fix out-of-order 'dimg' grid associations
    #2311.
  • Report files with an item used in multiple 'dimg' boxes with
    AVIF_RESULT_NOT_IMPLEMENTED instead of AVIF_RESULT_INVALID_IMAGE_GRID.

v1.1.0

11 Jul 15:11
183485b
Compare
Choose a tag to compare

1.1.0 - 2024-07-11

Added

  • Add experimental API for reading and writing gain maps in AVIF files.
    If enabled at compile time, add gainMap field to avifImage,
    add qualityGainMap field to avifEncoder, add gainMapPresent,
    enableDecodingGainMap, enableParsingGainMapMetadata and
    ignoreColorAndAlpha to avifDecoder.
    Utility functions for working with gain maps are also added.
    Gain maps allow readers that support them to display HDR images that look
    good on both HDR and SDR displays.
    This feature is highly experimental. The API might change or be removed
    in the future. Files created now might not decode in a future version.
    This feature is off by default and must be enabled with the
    AVIF_ENABLE_EXPERIMENTAL_GAIN_MAP compilation flag.
  • Add experimental support for converting jpeg files with gain maps to AVIF
    files with gain maps. Requires libxml2, and the AVIF_ENABLE_EXPERIMENTAL_GAIN_MAP
    compilation flag.
    Add a --qgain-map flag to control the gain map quality in avifenc.
  • Add the headerFormat member of new type avifHeaderFormat to avifEncoder.
  • Add experimental API for reading and writing "mif3"-branded AVIF files
    behind the compilation flag AVIF_ENABLE_EXPERIMENTAL_METAV1.
  • Implement avifImageScale() fallback when libyuv is not available.
  • Partial import of libyuv to third_party/libyuv (new LICENSE).
  • Add avifenc flag suffixes ":update" and ":u". Quality-relative,
    tiling-relative and codec-specific flags can now be positional, relative to
    input files.
  • Add experimental support for layered AVIF encoding in avifenc.
    Use the --layered flag to enable layered AVIF encoding.
    Layered AVIF has multiple layers, which works like frame of animated AVIF,
    and layers can be rendered in progressive manner on supported viewers
    (e.g. Chrome 94 or newer).
    Only aom supports layered AVIF encoding at the time of writing.
    Add --scaling-mode flag to set scaling mode of each layer.
    This part of AV1 encoder is not as thoroughly tested, so there are higher
    possibility encoder may crash when given certain configuration or input.
  • Add imageSequenceTrackPresent flag to the avifDecoder struct.
  • avifImageScale() function was made part of the public ABI.
  • Add avif_cxx.h as a C++ header with basic functionality.
  • Add enum aliases AVIF_COLOR_PRIMARIES_SRGB, AVIF_COLOR_PRIMARIES_BT2100,
    AVIF_COLOR_PRIMARIES_DCI_P3, AVIF_TRANSFER_CHARACTERISTICS_PQ.
  • Add avifResult enum entry AVIF_RESULT_INTERNAL_ERROR.
  • Require libyuv by default (but it can still be disabled with
    -DAVIF_LIBYUV=OFF).
  • Add avifdec --icc flag to override the output color profile.
  • Add experimental API for reading and writing 16-bit AVIF files behind the
    compilation flag AVIF_ENABLE_EXPERIMENTAL_SAMPLE_TRANSFORM.
  • Add AVIF_CHROMA_SAMPLE_POSITION_RESERVED to avifChromaSamplePosition enum.

Changed

  • Update aom.cmd: v3.9.1
  • Update avm.cmd: research-v7.0.1
  • Update dav1d.cmd: 1.4.3
  • Update libgav1.cmd: v0.19.0
  • Update libjpeg.cmd: v3.0.3
  • Update libxml2.cmd: v2.12.7
  • Update libyuv.cmd: a6a2ec65
  • Update mp4box.sh: v2.4.0
  • Update rav1e.cmd: v0.7.1
  • Update svt.cmd/svt.sh: v2.1.1
  • Update zlibpng.cmd: zlib 1.3.1 and libpng 1.6.40
  • AVIF sequences encoded by libavif will now also have the "avio" brand when
    there is at least one track made only of AV1 keyframes.
  • Fix SVT-AV1 codec interface which was not setting video range at encoding.
  • Any item ID being 0 in an "iref" box with version 0 or 1 is now treated as an
    error instead of being ignored.
  • API calls now return AVIF_RESULT_OUT_OF_MEMORY instead of aborting on memory
    allocation failure.
  • avifdec and avifenc: Change the default value of the --jobs option from 1 to
    "all".
  • Update avifCropRectConvertCleanApertureBox() to the revised requirements in
    ISO/IEC 23000-22:2019/Amd. 2:2021 Section 7.3.6.7.
  • AVIF files with an exif_tiff_header_offset pointing at another byte than the
    first II or MM tag in the Exif metadata payload will now fail to be decoded.
    Set decoder->ignoreExif to true to skip the issue and decode the image.
  • Fix memory errors reported in crbug.com/1501766, crbug.com/1501770, and
    crbug.com/1504792 by Fudan University.
  • For codecs, AVIF_CODEC_* and AVIF_LOCAL_* are now merged into AVIF_CODEC_*
    that can only take the values: OFF, LOCAL or SYSTEM.
  • For the gtest, jpeg, libsharpyuv, libxml2, libyuv and zlibpng dependencies,
    AVIF_LOCAL_* is now replaced by flags AVIF_* that can take the values:
    OFF, LOCAL or SYSTEM.
  • src/reformat.c: Allocate the threadData array directly.
  • AVIF_ENABLE_WERROR is set to OFF by default.
  • Fix wrong alpha plane deallocation when decoded tile pixel format does not
    match reconstructed output image pixel format (b/320234262).
  • Fix identical chunk skipping optimization when writing animation data
    (b/321189607).
  • Fix ID selection for artificial grid alpha item when decoding a grid of tiles
    which each have an associated auxiliary alpha image item
    (https://crbug.com/oss-fuzz/65657).
  • ext/libjpeg.cmd now pulls libjpeg-turbo instead of libjpeg and AVIF_JPEG=LOCAL
    now expects the library dependency in ext/libjpeg-turbo/build.libavif.
  • Fix 'iloc' box parsing bugs that may have wrongly accepted, rejected or parsed
    some files with rare values of offset_size, length_size, base_offset_size and
    index_size.
  • 'infe' boxes with an item_type different from 'mime' and without a
    null-terminated item_name are now considered invalid as per ISO/IEC 14496-12.

v1.0.4

08 Feb 15:52
Compare
Choose a tag to compare

[1.0.4] - 2024-02-08

Changed

  • AVIF_ENABLE_WERROR is set to OFF by default.
  • Fix wrong alpha plane deallocation when decoded tile pixel format does not
    match reconstructed output image pixel format (b/320234262).
  • Fix identical chunk skipping optimization when writing animation data
    (b/321189607).
  • Fix ID selection for artificial grid alpha item when decoding a grid of tiles
    which each have an associated auxiliary alpha image item
    (https://crbug.com/oss-fuzz/65657).

v1.0.3

04 Dec 19:26
Compare
Choose a tag to compare

[1.0.3] - 2023-12-03

Changed

  • Rewrite the fix for memory errors reported in crbug.com/1501770.
  • Fix memory errors reported in crbug.com/1504792 by Fudan
    University
    .
  • src/reformat.c: Allocate the threadData array directly.

v1.0.2

16 Nov 23:02
Compare
Choose a tag to compare

[1.0.2] - 2023-11-16

Changed

  • Update avifCropRectConvertCleanApertureBox() to the revised requirements in
    ISO/IEC 23000-22:2019/Amd. 2:2021 Section 7.3.6.7.
  • Fix memory errors reported in crbug.com/1501766 and crbug.com/1501770 by
    Fudan University.

v1.0.1

29 Aug 22:21
Compare
Choose a tag to compare

1.0.1 - 2023-08-29

Changed

  • gdk-pixbuf: Explicitly pass link directories
  • gdk-pixbuf: Fix build failure after imir.mode -> imir.axis rename

v1.0.0

28 Aug 22:27
bc41fc5
Compare
Choose a tag to compare

1.0.0 - 2023-08-24

With the 1.0.0 release, the ABI will be more stable from now on. Please note
the allocation and initialization requirements for avifImage, avifDecoder,
avifEncoder, and avifRGBImage in the "avif/avif.h" header.

List of incompatible ABI changes in this release:

  • The clli member was added to the avifImage struct.
  • The repetitionCount member was added to the avifEncoder and avifDecoder
    structs.
  • The quality and qualityAlpha members were added to the avifEncoder struct.
  • Check that functions returning pointers do not return NULL before accessing
    those pointers.
  • Check the return value of avifEncoderSetCodecSpecificOption().
  • The maxThreads member was added to the avifRGBImage struct.
  • Check the return value of avifRGBImageAllocatePixels(), avifRWDataRealloc(),
    avifRWDataSet(), avifImageSetProfileICC(), avifImageSetMetadataExif() and
    avifImageSetMetadataXMP().
  • The meaning of the keyframeInterval member of avifEncoder struct has changed
    slightly. When set to a value of "n",
    • Before: It forces a keyframe on every nth frame.
    • After: Any set of "n" consecutive frame will have at least one keyframe
      (every nth frame may or may not be a keyframe).

Added

  • Add STATIC library target avif_internal to allow tests to access functions
    from internal.h when BUILD_SHARED_LIBS is ON.
  • Add clli metadata read and write support
  • Add repetitionCount member to avifEncoder and avifDecoder structs to specify
    the number of repetitions for animated image sequences.
  • Add quality and qualityAlpha to avifEncoder. Note: minQuantizer,
    maxQuantizer, minQuantizerAlpha, and maxQuantizerAlpha are deprecated. Code
    should be updated to set quality (and qualityAlpha if applicable) and leave
    minQuantizer, maxQuantizer, minQuantizerAlpha, and maxQuantizerAlpha
    initialized to the default values.
  • The --target-size flag in avifenc was added to adapt the quality so that the
    output file size is as close to the given number of bytes as possible.
  • Add the public API function avifImageIsOpaque() in avif.h.
  • Add the public API functions avifImagePlane(), avifImagePlaneRowBytes(),
    avifImagePlaneWidth(), and avifImagePlaneHeight() in avif.h.
  • Add experimental API for progressive AVIF encoding.
  • Add API for multi-threaded YUV to RGB color conversion.
  • Add experimental support for AV2 behind the compilation flag AVIF_CODEC_AVM.
    AVIF_CODEC_CHOICE_AVM is now part of avifCodecChoice.
  • Add experimental YCgCo-R support behind the compilation flag
    AVIF_ENABLE_EXPERIMENTAL_YCGCO_R.
  • Allow lossless 4:0:0 on grayscale input.
  • Add avifenc --no-overwrite flag to avoid overwriting output file.
  • Add avifenc --clli flag to set clli.
  • Add support for all transfer functions when using libsharpyuv.

Changed

  • Enable the libaom AV1E_SET_SKIP_POSTPROC_FILTERING codec control by default.
  • Use the constant rate factor (CRF) instead of the constant quantization
    parameter (CQP) rate control mode with the SVT-AV1 encoder.
  • Exif and XMP metadata is exported to PNG and JPEG files by default,
    except XMP payloads larger than 65502 bytes in JPEG.
  • The --grid flag in avifenc can be used for images that are not evenly divided
    into cells.
  • Apps must be built with libpng version 1.6.32 or above.
  • Change the encoder to write the boxes within the "stbl" box in the order of
    stsd, stts, stsc, stsz, stco, stss.
  • avifImageCopy() no longer accepts source U and V channels to be NULL for
    non-4:0:0 input if Y is not NULL and if AVIF_PLANES_YUV is specified.
  • The default values of the maxQuantizer and maxQuantizerAlpha members of
    avifEncoder changed from AVIF_QUANTIZER_LOSSLESS (0) to
    AVIF_QUANTIZER_WORST_QUALITY (63). The behavior changed if minQuantizer and
    maxQuantizer are left initialized to the default values. Code should be
    updated to set the quality member. Similarly for the alpha quantizers and
    qualityAlpha.
  • avifImageRGBToYUV() and avifImageYUVToRGB() handle avifImage bit depths 8, 10,
    12 and now also 16. Files read by apps/shared/ can output 16-bit avifImage
    instances.
  • Update aom.cmd: v3.6.1
  • Update dav1d.cmd: 1.2.1
  • Update libsharpyuv: 0.4.0
  • Update rav1e.cmd: v0.6.6
  • Update svt.cmd/svt.sh: v1.6.0
  • Update zlibpng.cmd: zlib 1.2.13 and libpng 1.6.39
  • avifImageCreate(), avifImageCreateEmpty(), avifEncoderCreate() and other
    internal functions now return NULL if a memory allocation failed.
  • avifEncoderSetCodecSpecificOption() now returns avifResult instead of void to
    report memory allocation failures.
  • At decoding, avifIOStats now returns the same values as at encoding.
  • avifRGBImageAllocatePixels(), avifRWDataRealloc(), avifRWDataSet(),
    avifImageSetProfileICC(), avifImageSetMetadataExif() and
    avifImageSetMetadataXMP() now return avifResult instead of void to report
    memory allocation failures.
  • avifReadImage(), avifJPEGRead() and avifPNGRead() now remove the trailing zero
    byte from read XMP chunks, if any. See avifImageFixXMP().
  • Force keyframe for alpha if color is a keyframe.
  • Write primaries and transfer characteritics info in decoded PNG.
  • Add support for reading PNG gAMA, cHRM and sRGB chunks.
  • The 'mode' member of the avifImageMirror struct was renamed 'axis'.
  • Change the type of the 'depth' parameter from int to uint32_t in
    avifFullToLimitedY(), avifFullToLimitedUV(), avifLimitedToFullY(), and
    avifLimitedToFullUV().

v0.11.1

20 Oct 23:13
6ab5318
Compare
Choose a tag to compare

[0.11.1] - 2022-10-19

Changed

  • avifincrtest_helpers: Cast 64-bit offset to size_t
  • avifmetadatatest: don't include avif/internal.h
  • avifrgbtoyuvtest: skip if no libsharpyuv
  • Disable tests that may fail if the codec is not aom (#1176)

v0.11.1-rc1

19 Oct 21:38
6ab5318
Compare
Choose a tag to compare
v0.11.1-rc1 Pre-release
Pre-release
v0.11.1-rc1

v0.11.0

14 Oct 20:56
3c48152
Compare
Choose a tag to compare

[0.11.0] - 2022-10-12

There are incompatible ABI changes in this release. The alphaRange member was
removed from the avifImage struct. The chromaDownsampling and avoidLibYUV
members were added to the avifRGBImage struct. The imageDimensionLimit member
was added to the avifDecoder struct. avifImageCopy() and
avifImageAllocatePlanes() signatures changed. It is necessary to recompile your
code. Also check the return values of avifImageCopy() and
avifImageAllocatePlanes().

Added

  • Add man pages for avifenc and avifdec
  • Add the avifChannelIndex type alias for enum avifChannelIndex
  • Add avifChromaDownsampling enum
  • Add chromaDownsampling field to avifRGBImage struct
  • Add support for AVIF_RGB_FORMAT_RGB_565
  • Add imageDimensionLimit field to avifDecoder struct
  • Add autoTiling field to avifEncoder struct
  • Add new avifResult codes AVIF_RESULT_CANNOT_CHANGE_SETTING and
    AVIF_RESULT_INCOMPATIBLE_IMAGE
  • Add new enum constants AVIF_PIXEL_FORMAT_COUNT and AVIF_RGB_FORMAT_COUNT
  • avifdec: Add --dimension-limit, which specifies the image dimension limit
    (width or height) that should be tolerated
  • avifenc: Add --sharpyuv, which enables "sharp" RGB to YUV420 conversion, which
    reduces artifacts caused by 420 chroma downsampling. Needs libsharpyuv (part
    of the libwebp repository) at compile time.
  • avifenc: Add --ignore-exif and --ignore-xmp flags.
  • avifenc: Add --autotiling, which sets --tilerowslog2 and --tilecolslog2
    automatically.
  • avifenc: Input Exif orientation is converted to irot/imir by default.

Changed

  • Fix memory leaks of metadata on avifenc exit
  • Update the handling of 'lsel' and progressive decoding to AVIF spec v1.1.0
  • Treat an absent lsel and layer_id == 0xFFFF equivalently for backward
    compatibility with earlier drafts of AVIF spec v1.1.0
  • Set libavif's own default value of cfg.rc_end_usage for libaom
  • Fix #953
  • Set the libaom-specific option -a tune=ssim by default
  • Bump cmake_minimum_required from 3.5 to 3.13
  • Fix https://crbug.com/oss-fuzz/48135
  • Use several new libyuv functions in reformat_libyuv.c
  • Fix SVT-AV1's issue 1957 related to uninitialized variables crashing the
    encoder
  • Fix #787
  • Update aom.cmd: v3.5.0
  • Update rav1e.cmd: v0.5.1
  • Update svt.cmd/svt.sh: v1.2.1
  • Update libgav1.cmd: v0.18.0
  • Update libyuv.cmd: f9fda6e7 (version 1844)
  • avifImageCopy() and avifImageAllocatePlanes() now return avifResult instead of
    void to report invalid parameters or memory allocation failures.
  • avifImageRGBToYUV() now uses libyuv fast paths by default. It may slightly
    change conversion results. The old behavior can be restored by setting
    avifRGBImage::chromaDownsampling to AVIF_CHROMA_DOWNSAMPLING_BEST_QUALITY
    and avifRGBImage::avoidLibYUV to AVIF_TRUE.
  • avifRGBImage::chromaUpsampling now only applies to conversions that need
    upsampling chroma from 4:2:0 or 4:2:2 and has no impact on the use of libyuv.
    Set avifRGBImage::avoidLibYUV accordingly to control the use of libyuv.
  • avifenc: Set the YUV format to 4:0:0 for grayscale PNGs
  • Support updating encoder settings and codec-specific options during encoding
  • Disable AVIF_STRICT_CLAP_VALID and AVIF_STRICT_PIXI_REQUIRED in the JNI
    wrapper
  • avifdec: Return proper exit code in "info" mode
  • In avifenc and avifdec, treat all arguments that start with '-' as options
  • Fix #1086
  • Exif and XMP metadata is imported from PNG and JPEG files.
  • avifImageSetMetadataExif() parses the Exif metadata and converts any Exif
    orientation found into transformFlags, irot and imir values.
  • Write 'auxi' box for animated images with alpha channel
  • Write 'auxv' as handler_type for alpha channel track
  • Use PNG_COLOR_TYPE_GRAY for 8-bit grayscale output
  • Replace repeated subtraction by modulo in calcGCD (fix b/246649620)
  • Change avifImageCreate to take uint32_t instead of int parameters
  • When writing an image sequence, check if it's safe to cast width and height to
    uint16_t
  • Allow clamped grid cells in avifEncoderAddImageGrid()

Removed

  • alphaRange field was removed from the avifImage struct. It it presumed that
    alpha plane is always full range.
  • The avifCodecConfigurationBox struct becomes a private type for libavif
    internal use