[FFmpeg-devel] [PATCH] avcodec: Add smpte2084 transfer function to videotoolboxenc
Nomis101 🐝
Nomis101 at web.de
Wed Jun 12 10:44:26 EEST 2019
This patch will add support of the smpte2084 transfer function to videotoolboxenc. kCVImageBufferTransferFunction_SMPTE_ST_2084_PQ is available on macOS 10.13 and up.
This is on the bug tracker at https://trac.ffmpeg.org/ticket/7953
diff --git a/libavcodec/videotoolboxenc.c b/libavcodec/videotoolboxenc.c
index 3665581283..e786ebe3a7 100644
--- a/libavcodec/videotoolboxenc.c
+++ b/libavcodec/videotoolboxenc.c
@@ -909,6 +909,12 @@ static int get_cv_transfer_function(AVCodecContext *avctx,
case AVCOL_TRC_SMPTE240M:
*transfer_fnc = kCVImageBufferTransferFunction_SMPTE_240M_1995;
break;
+
+#if __MAC_OS_X_VERSION_MIN_REQUIRED >= 101300
+ case AVCOL_TRC_SMPTE2084:
+ *transfer_fnc = kCVImageBufferTransferFunction_SMPTE_ST_2084_PQ;
+ break;
+#endif
case AVCOL_TRC_GAMMA22:
gamma = 2.2;
-------------- next part --------------
A non-text attachment was scrubbed...
Name: patch.bin
Type: application/macbinary
Size: 875 bytes
Desc: not available
URL: <http://ffmpeg.org/pipermail/ffmpeg-devel/attachments/20190612/8bab7982/attachment.bin>
More information about the ffmpeg-devel
mailing list