mirror of
https://gitlab.freedesktop.org/gstreamer/gstreamer.git
synced 2024-11-28 04:31:06 +00:00
unify caps template for VAAPI encoders and decoders
There is no difference in VAAPI surface caps between encoders and decoders. Thus, the patch makes a simplification by removing encoders specific caps and shares the same definition of VAAPI surfaces caps for all the elements.
This commit is contained in:
parent
fe08f7ecdc
commit
d4f00383ed
7 changed files with 7 additions and 11 deletions
|
@ -56,7 +56,7 @@ GST_DEBUG_CATEGORY_STATIC (gst_vaapi_h264_encode_debug);
|
|||
|
||||
/* *INDENT-OFF* */
|
||||
static const char gst_vaapiencode_h264_sink_caps_str[] =
|
||||
GST_VAAPI_MAKE_ENC_SURFACE_CAPS ", "
|
||||
GST_VAAPI_MAKE_SURFACE_CAPS ", "
|
||||
GST_CAPS_INTERLACED_FALSE "; "
|
||||
GST_VIDEO_CAPS_MAKE (GST_VIDEO_FORMATS_ALL) ", "
|
||||
GST_CAPS_INTERLACED_FALSE;
|
||||
|
|
|
@ -55,7 +55,7 @@ GST_DEBUG_CATEGORY_STATIC (gst_vaapi_h265_encode_debug);
|
|||
|
||||
/* *INDENT-OFF* */
|
||||
static const char gst_vaapiencode_h265_sink_caps_str[] =
|
||||
GST_VAAPI_MAKE_ENC_SURFACE_CAPS ", "
|
||||
GST_VAAPI_MAKE_SURFACE_CAPS ", "
|
||||
GST_CAPS_INTERLACED_FALSE "; "
|
||||
GST_VIDEO_CAPS_MAKE (GST_VIDEO_FORMATS_ALL) ", "
|
||||
GST_CAPS_INTERLACED_FALSE;
|
||||
|
|
|
@ -52,7 +52,7 @@ GST_DEBUG_CATEGORY_STATIC (gst_vaapi_jpeg_encode_debug);
|
|||
|
||||
/* *INDENT-OFF* */
|
||||
static const char gst_vaapiencode_jpeg_sink_caps_str[] =
|
||||
GST_VAAPI_MAKE_ENC_SURFACE_CAPS ", "
|
||||
GST_VAAPI_MAKE_SURFACE_CAPS ", "
|
||||
GST_CAPS_INTERLACED_FALSE "; "
|
||||
GST_VIDEO_CAPS_MAKE (GST_VIDEO_FORMATS_ALL) ", "
|
||||
GST_CAPS_INTERLACED_FALSE;
|
||||
|
|
|
@ -54,7 +54,7 @@ GST_DEBUG_CATEGORY_STATIC (gst_vaapi_mpeg2_encode_debug);
|
|||
|
||||
/* *INDENT-OFF* */
|
||||
static const char gst_vaapiencode_mpeg2_sink_caps_str[] =
|
||||
GST_VAAPI_MAKE_ENC_SURFACE_CAPS ", "
|
||||
GST_VAAPI_MAKE_SURFACE_CAPS ", "
|
||||
GST_CAPS_INTERLACED_FALSE "; "
|
||||
GST_VIDEO_CAPS_MAKE (GST_VIDEO_FORMATS_ALL) ", "
|
||||
GST_CAPS_INTERLACED_FALSE;
|
||||
|
|
|
@ -52,7 +52,7 @@ GST_DEBUG_CATEGORY_STATIC (gst_vaapi_vp8_encode_debug);
|
|||
|
||||
/* *INDENT-OFF* */
|
||||
static const char gst_vaapiencode_vp8_sink_caps_str[] =
|
||||
GST_VAAPI_MAKE_ENC_SURFACE_CAPS ", "
|
||||
GST_VAAPI_MAKE_SURFACE_CAPS ", "
|
||||
GST_CAPS_INTERLACED_FALSE "; "
|
||||
GST_VIDEO_CAPS_MAKE (GST_VIDEO_FORMATS_ALL) ", "
|
||||
GST_CAPS_INTERLACED_FALSE;
|
||||
|
|
|
@ -106,10 +106,6 @@ gst_vaapi_caps_feature_contains (const GstCaps * caps,
|
|||
GST_VIDEO_CAPS_MAKE_WITH_FEATURES( \
|
||||
GST_CAPS_FEATURE_MEMORY_VAAPI_SURFACE, "{ ENCODED, NV12, I420, YV12, P010_10LE }")
|
||||
|
||||
#define GST_VAAPI_MAKE_ENC_SURFACE_CAPS \
|
||||
GST_VIDEO_CAPS_MAKE_WITH_FEATURES( \
|
||||
GST_CAPS_FEATURE_MEMORY_VAAPI_SURFACE, "{ ENCODED, NV12, I420, YV12, P010_10LE }")
|
||||
|
||||
#define GST_VAAPI_MAKE_GLTEXUPLOAD_CAPS \
|
||||
GST_VIDEO_CAPS_MAKE_WITH_FEATURES( \
|
||||
GST_CAPS_FEATURE_META_GST_VIDEO_GL_TEXTURE_UPLOAD_META, "{ RGBA, BGRA }")
|
||||
|
|
|
@ -64,7 +64,7 @@ GST_DEBUG_CATEGORY_STATIC (gst_debug_vaapisink);
|
|||
/* Default template */
|
||||
/* *INDENT-OFF* */
|
||||
static const char gst_vaapisink_sink_caps_str[] =
|
||||
GST_VAAPI_MAKE_ENC_SURFACE_CAPS ";"
|
||||
GST_VAAPI_MAKE_SURFACE_CAPS ";"
|
||||
GST_VIDEO_CAPS_MAKE_WITH_FEATURES (
|
||||
GST_CAPS_FEATURE_MEMORY_VAAPI_SURFACE ","
|
||||
GST_CAPS_FEATURE_META_GST_VIDEO_OVERLAY_COMPOSITION,
|
||||
|
@ -1215,7 +1215,7 @@ gst_vaapisink_get_caps_impl (GstBaseSink * base_sink)
|
|||
GstVaapiSink *const sink = GST_VAAPISINK_CAST (base_sink);
|
||||
GstCaps *out_caps, *raw_caps;
|
||||
static const char surface_caps_str[] =
|
||||
GST_VAAPI_MAKE_ENC_SURFACE_CAPS ";"
|
||||
GST_VAAPI_MAKE_SURFACE_CAPS ";"
|
||||
GST_VIDEO_CAPS_MAKE_WITH_FEATURES (GST_CAPS_FEATURE_MEMORY_VAAPI_SURFACE
|
||||
"," GST_CAPS_FEATURE_META_GST_VIDEO_OVERLAY_COMPOSITION,
|
||||
"{ ENCODED, NV12, I420, YV12 }");
|
||||
|
|
Loading…
Reference in a new issue