1
0
mirror of https://github.com/FFmpeg/FFmpeg.git synced 2024-12-28 20:53:54 +02:00

avcodec/videotoolboxenc: Fix build failure due to PropertyKey_EncoderID

Signed-off-by: Zhao Zhili <zhilizhao@tencent.com>
This commit is contained in:
Zhao Zhili 2023-11-25 12:06:01 +08:00
parent 36980179a0
commit cb049d377f

View File

@ -119,6 +119,7 @@ static struct{
CFStringRef kVTCompressionPropertyKey_TargetQualityForAlpha;
CFStringRef kVTCompressionPropertyKey_PrioritizeEncodingSpeedOverQuality;
CFStringRef kVTCompressionPropertyKey_ConstantBitRate;
CFStringRef kVTCompressionPropertyKey_EncoderID;
CFStringRef kVTVideoEncoderSpecification_EnableHardwareAcceleratedVideoEncoder;
CFStringRef kVTVideoEncoderSpecification_RequireHardwareAcceleratedVideoEncoder;
@ -191,6 +192,7 @@ static void loadVTEncSymbols(void){
GET_SYM(kVTCompressionPropertyKey_PrioritizeEncodingSpeedOverQuality,
"PrioritizeEncodingSpeedOverQuality");
GET_SYM(kVTCompressionPropertyKey_ConstantBitRate, "ConstantBitRate");
GET_SYM(kVTCompressionPropertyKey_EncoderID, "EncoderID");
GET_SYM(kVTVideoEncoderSpecification_EnableHardwareAcceleratedVideoEncoder,
"EnableHardwareAcceleratedVideoEncoder");
@ -1178,7 +1180,7 @@ static int vtenc_create_encoder(AVCodecContext *avctx,
{
CFStringRef encoderID = NULL;
status = VTSessionCopyProperty(vtctx->session,
kVTCompressionPropertyKey_EncoderID,
compat_keys.kVTCompressionPropertyKey_EncoderID,
kCFAllocatorDefault,
&encoderID);
if (status == noErr) {