diff --git a/subprojects/gst-plugins-bad/sys/applemedia/vtdec.c b/subprojects/gst-plugins-bad/sys/applemedia/vtdec.c index 4e28b0bbb5..76a268aeed 100644 --- a/subprojects/gst-plugins-bad/sys/applemedia/vtdec.c +++ b/subprojects/gst-plugins-bad/sys/applemedia/vtdec.c @@ -117,7 +117,7 @@ const CFStringRef CFSTR ("RequireHardwareAcceleratedVideoDecoder"); #endif -#define VIDEO_SRC_CAPS_FORMATS "{ NV12, AYUV64 }" +#define VIDEO_SRC_CAPS_FORMATS "{ NV12, AYUV64, RGBA64_LE, ARGB64_BE }" #define VIDEO_SRC_CAPS_NATIVE \ GST_VIDEO_CAPS_MAKE(VIDEO_SRC_CAPS_FORMATS) ";" \ @@ -269,6 +269,8 @@ get_preferred_video_format (GstStructure * s, gboolean prores) return vfmt; break; case GST_VIDEO_FORMAT_AYUV64: + case GST_VIDEO_FORMAT_ARGB64_BE: + case GST_VIDEO_FORMAT_RGBA64_LE: if (prores) return vfmt; break; @@ -655,6 +657,12 @@ gst_vtdec_create_session (GstVtdec * vtdec, GstVideoFormat format, #endif cv_format = kCVPixelFormatType_4444AYpCbCr16; break; + case GST_VIDEO_FORMAT_ARGB64_BE: + cv_format = kCVPixelFormatType_64ARGB; + break; + case GST_VIDEO_FORMAT_RGBA64_LE: + cv_format = kCVPixelFormatType_64RGBALE; + break; default: g_warn_if_reached (); break; diff --git a/subprojects/gst-plugins-bad/sys/applemedia/vtenc.c b/subprojects/gst-plugins-bad/sys/applemedia/vtenc.c index c3b90af67b..ecdc5597f3 100644 --- a/subprojects/gst-plugins-bad/sys/applemedia/vtenc.c +++ b/subprojects/gst-plugins-bad/sys/applemedia/vtenc.c @@ -159,7 +159,8 @@ static GstStaticCaps sink_caps = GST_STATIC_CAPS (GST_VIDEO_CAPS_MAKE ("{ NV12, I420 }")); #else static GstStaticCaps sink_caps = -GST_STATIC_CAPS (GST_VIDEO_CAPS_MAKE ("{ AYUV64, UYVY, NV12, I420 }")); +GST_STATIC_CAPS (GST_VIDEO_CAPS_MAKE + ("{ AYUV64, UYVY, NV12, I420, RGBA64_LE, ARGB64_BE }")); #endif static void @@ -1549,6 +1550,9 @@ gst_vtenc_encode_frame (GstVTEnc * self, GstVideoCodecFrame * frame) } switch (GST_VIDEO_INFO_FORMAT (&self->video_info)) { + case GST_VIDEO_FORMAT_ARGB64_BE: + pixel_format_type = kCVPixelFormatType_64ARGB; + break; case GST_VIDEO_FORMAT_AYUV64: /* This is fine for now because Apple only ships LE devices */ #if G_BYTE_ORDER != G_LITTLE_ENDIAN @@ -1556,6 +1560,9 @@ gst_vtenc_encode_frame (GstVTEnc * self, GstVideoCodecFrame * frame) #endif pixel_format_type = kCVPixelFormatType_4444AYpCbCr16; break; + case GST_VIDEO_FORMAT_RGBA64_LE: + pixel_format_type = kCVPixelFormatType_64RGBALE; + break; case GST_VIDEO_FORMAT_I420: pixel_format_type = kCVPixelFormatType_420YpCbCr8Planar; break;