From e05ec5adb7e62392de692b3eff4360e579b2aa97 Mon Sep 17 00:00:00 2001 From: John Stebbins Date: Thu, 22 Dec 2016 11:25:16 -0800 Subject: [PATCH] libhb: pass through BT.2020 transfer flags --- libhb/common.h | 2 ++ libhb/decavcodec.c | 4 ++++ 2 files changed, 6 insertions(+) diff --git a/libhb/common.h b/libhb/common.h index 51ae4ac72..0ae3fc42d 100644 --- a/libhb/common.h +++ b/libhb/common.h @@ -557,6 +557,8 @@ struct hb_job_s #define HB_COLR_TRA_BT709 1 // also use for bt470m, bt470bg, smpte170m, bt2020_10 and bt2020_12 #define HB_COLR_TRA_UNDEF 2 #define HB_COLR_TRA_SMPTE240M 7 +#define HB_COLR_TRA_BT2020_10 14 +#define HB_COLR_TRA_BT2020_12 15 #define HB_COLR_TRA_SMPTEST2084 16 // 0, 3-6, 8-15, 17-65535: reserved/not implemented #define HB_COLR_MAT_BT709 1 diff --git a/libhb/decavcodec.c b/libhb/decavcodec.c index 8a12b620d..141980e92 100644 --- a/libhb/decavcodec.c +++ b/libhb/decavcodec.c @@ -1809,6 +1809,10 @@ static int get_color_transfer(int color_trc) return HB_COLR_TRA_SMPTE240M; case AVCOL_TRC_SMPTEST2084: return HB_COLR_TRA_SMPTEST2084; + case AVCOL_TRC_BT2020_10: + return HB_COLR_TRA_BT2020_10; + case AVCOL_TRC_BT2020_12: + return HB_COLR_TRA_BT2020_12; default: // ITU BT.601, BT.709, anything else return HB_COLR_TRA_BT709; -- 2.40.0