diff options
author | Ben Morss <morss@google.com> | 2021-03-03 21:35:56 -0500 |
---|---|---|
committer | GitHub <noreply@github.com> | 2021-03-03 21:35:56 -0500 |
commit | f2aa2836ed910ca3510585a47a8a064b5140e148 (patch) | |
tree | 0830fdcac9308d28bc8d911b43f4e1ccb7ed1f8d /configure.ac | |
parent | e697147788720da40eb3e9c3e17ef385c08191b7 (diff) | |
download | libgd-f2aa2836ed910ca3510585a47a8a064b5140e148.tar.gz |
AVIF support (#671)
Demand for AVIF support on the web is growing, as the word gets out
about this new file format which allows higher-quality encoding at
smaller sizes. Core contributors to major open-source CMSs are
interested in auto-generating AVIF images! They've been simply
waiting for support to appear in libgd.
This PR aims to meet the growing demand, and to help bring smaller,
more beautiful images to more of the web - to sites created by
experienced developers and CMS users alike.
This PR adds support by incorporating libavif in addition to the
existing libheif support. It's generally felt that libavif has
more complete support for the AVIF format. libavif is also used
by the Chromium project and squoosh.app.
In this PR, I've endeavored to incorporate the latest research into
best practices for AVIF encoding - not just for default quantizer
values, but also an algorithm for determining the number of
horizontal tiles, vertical tiles, and threads.
Fixes #557.
Diffstat (limited to 'configure.ac')
-rw-r--r-- | configure.ac | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/configure.ac b/configure.ac index 5a4c357..535db68 100644 --- a/configure.ac +++ b/configure.ac @@ -289,6 +289,13 @@ dnl Check for heif support. GD_LIB_PKG_CHECK([LIBHEIF], [HEIF], [heif], [libheif >= 1.7.0], [ AC_CHECK_LIB([heif], [heif_get_version], [dnl AS_VAR_APPEND([LIBHEIF_LIBS], [" -lheif"]) + ]) +]) + +dnl Check for avif support. +GD_LIB_PKG_CHECK([LIBAVIF], [AVIF], [avif], [libavif >= 0.8.2], [ + AC_CHECK_LIB([avif], [avifVersion], [dnl + AS_VAR_APPEND([LIBAVIF_LIBS], [" -lavif"]) gd_found_lib=yes ]) ]) @@ -323,6 +330,7 @@ AC_MSG_RESULT([ Support for JPEG library: $gd_with_LIBJPEG Support for WebP library: $gd_with_LIBWEBP Support for HEIF library: $gd_with_LIBHEIF + Support for AVIF library: $gd_with_LIBAVIF Support for TIFF library: $gd_with_LIBTIFF Support for Freetype 2.x library: $gd_with_LIBFREETYPE Support for Fontconfig library: $gd_with_LIBFONTCONFIG |