mirror of
https://gitlab.freedesktop.org/gstreamer/gstreamer.git
synced 2024-12-17 22:06:41 +00:00
vtenc: fix build on iOS
This commit is contained in:
parent
ad00f4a0e2
commit
5977ef5552
1 changed files with 5 additions and 2 deletions
|
@ -527,14 +527,16 @@ static VTCompressionSessionRef
|
|||
gst_vtenc_create_session (GstVTEnc * self)
|
||||
{
|
||||
VTCompressionSessionRef session = NULL;
|
||||
CFMutableDictionaryRef encoder_spec, pb_attrs;
|
||||
CFMutableDictionaryRef encoder_spec = NULL, pb_attrs;
|
||||
OSStatus status;
|
||||
|
||||
#if !HAVE_IOS
|
||||
encoder_spec =
|
||||
CFDictionaryCreateMutable (NULL, 0, &kCFTypeDictionaryKeyCallBacks,
|
||||
&kCFTypeDictionaryValueCallBacks);
|
||||
gst_vtutil_dict_set_boolean (encoder_spec,
|
||||
kVTVideoEncoderSpecification_EnableHardwareAcceleratedVideoEncoder, true);
|
||||
#endif
|
||||
|
||||
pb_attrs = CFDictionaryCreateMutable (NULL, 0, &kCFTypeDictionaryKeyCallBacks,
|
||||
&kCFTypeDictionaryValueCallBacks);
|
||||
|
@ -600,7 +602,8 @@ gst_vtenc_create_session (GstVTEnc * self)
|
|||
#endif
|
||||
|
||||
beach:
|
||||
CFRelease (encoder_spec);
|
||||
if (encoder_spec)
|
||||
CFRelease (encoder_spec);
|
||||
CFRelease (pb_attrs);
|
||||
|
||||
return session;
|
||||
|
|
Loading…
Reference in a new issue