diff options
-rw-r--r-- | meson.build | 1 | ||||
-rw-r--r-- | video/zimg.c | 4 | ||||
-rw-r--r-- | wscript | 4 |
3 files changed, 9 insertions, 0 deletions
diff --git a/meson.build b/meson.build index 8f90aa9137..0db557f50d 100644 --- a/meson.build +++ b/meson.build @@ -756,6 +756,7 @@ if features['zimg'] sources += files('test/repack.c', 'test/scale_zimg.c') endif + features += {'zimg-st428': zimg.version().version_compare('>= 3.0.5')} endif zlib = dependency('zlib', required: get_option('zlib')) diff --git a/video/zimg.c b/video/zimg.c index ff379ed4d9..01b44c96f3 100644 --- a/video/zimg.c +++ b/video/zimg.c @@ -30,6 +30,7 @@ #include "video/fmt-conversion.h" #include "video/img_format.h" #include "zimg.h" +#include "config.h" static_assert(MP_IMAGE_BYTE_ALIGN >= ZIMG_ALIGN, ""); @@ -155,6 +156,9 @@ static zimg_transfer_characteristics_e mp_to_z_trc(enum mp_csp_trc trc) case MP_CSP_TRC_GAMMA28: return ZIMG_TRANSFER_BT470_BG; case MP_CSP_TRC_PQ: return ZIMG_TRANSFER_ST2084; case MP_CSP_TRC_HLG: return ZIMG_TRANSFER_ARIB_B67; +#if HAVE_ZIMG_ST428 + case MP_CSP_TRC_ST428: return ZIMG_TRANSFER_ST428; +#endif case MP_CSP_TRC_GAMMA18: // ? case MP_CSP_TRC_GAMMA20: case MP_CSP_TRC_GAMMA24: @@ -408,6 +408,10 @@ iconv support use --disable-iconv.", 'name': 'rubberband-3', 'desc': 'new engine support for librubberband', 'func': check_pkg_config('rubberband >= 3.0.0'), + }, { + 'name': 'zimg-st428', + 'desc': 'ZIMG suport for ZIMG_TRANSFER_ST428', + 'func': check_pkg_config('zimg', '>= 3.0.5'), } ] |