diff options
author | Xiang, Haihao <haihao.xiang@intel.com> | 2018-11-27 15:55:51 +0800 |
---|---|---|
committer | Víctor Manuel Jáquez Leal <vjaquez@igalia.com> | 2018-12-12 09:00:13 +0000 |
commit | ba1f1624017dd85c6898f9a46850c7c33624ece8 (patch) | |
tree | 32abeb26a0101dbc84324da08ad19d6bcc847931 /sys | |
parent | f45d5dc8bc08cfc0d0b53d85d2416636d2e2815e (diff) |
msdkh265enc: re-add the sink pad template
We will add more profiles in the sink caps of msdkh265enc, so let
msdkh265enc re-add the sink pad template. Note this change doesn't
impact any capability
Diffstat (limited to 'sys')
-rw-r--r-- | sys/msdk/gstmsdkh265enc.c | 14 |
1 files changed, 14 insertions, 0 deletions
diff --git a/sys/msdk/gstmsdkh265enc.c b/sys/msdk/gstmsdkh265enc.c index 3ae9bbd25..3f9d8e397 100644 --- a/sys/msdk/gstmsdkh265enc.c +++ b/sys/msdk/gstmsdkh265enc.c @@ -39,11 +39,24 @@ # include "mfxplugin.h" #endif +#include <gst/allocators/gstdmabuf.h> + #include "gstmsdkh265enc.h" GST_DEBUG_CATEGORY_EXTERN (gst_msdkh265enc_debug); #define GST_CAT_DEFAULT gst_msdkh265enc_debug +static GstStaticPadTemplate sink_factory = GST_STATIC_PAD_TEMPLATE ("sink", + GST_PAD_SINK, + GST_PAD_ALWAYS, + GST_STATIC_CAPS ("video/x-raw, " + "format = (string) { NV12, I420, YV12, YUY2, UYVY, BGRA }, " + "framerate = (fraction) [0, MAX], " + "width = (int) [ 16, MAX ], height = (int) [ 16, MAX ]," + "interlace-mode = (string) progressive" ";" + GST_VIDEO_CAPS_MAKE_WITH_FEATURES (GST_CAPS_FEATURE_MEMORY_DMABUF, + "{ NV12 }"))); + static GstStaticPadTemplate src_factory = GST_STATIC_PAD_TEMPLATE ("src", GST_PAD_SRC, GST_PAD_ALWAYS, @@ -211,6 +224,7 @@ gst_msdkh265enc_class_init (GstMsdkH265EncClass * klass) "H265 video encoder based on Intel Media SDK", "Josep Torra <jtorra@oblong.com>"); + gst_element_class_add_static_pad_template (element_class, &sink_factory); gst_element_class_add_static_pad_template (element_class, &src_factory); } |