mirror of
https://gitlab.freedesktop.org/gstreamer/gstreamer.git
synced 2024-12-19 06:46:38 +00:00
vaapidecode_props: h264: add base-only property
https://bugzilla.gnome.org/show_bug.cgi?id=732265
This commit is contained in:
parent
a1fc1e9822
commit
bd040adb9c
2 changed files with 13 additions and 0 deletions
|
@ -29,6 +29,7 @@
|
|||
enum
|
||||
{
|
||||
GST_VAAPI_DECODER_H264_PROP_FORCE_LOW_LATENCY = 1,
|
||||
GST_VAAPI_DECODER_H264_PROP_BASE_ONLY
|
||||
};
|
||||
|
||||
static gint h264_private_offset;
|
||||
|
@ -45,6 +46,9 @@ gst_vaapi_decode_h264_get_property (GObject * object, guint prop_id,
|
|||
case GST_VAAPI_DECODER_H264_PROP_FORCE_LOW_LATENCY:
|
||||
g_value_set_boolean (value, priv->is_low_latency);
|
||||
break;
|
||||
case GST_VAAPI_DECODER_H264_PROP_BASE_ONLY:
|
||||
g_value_set_boolean (value, priv->base_only);
|
||||
break;
|
||||
default:
|
||||
G_OBJECT_WARN_INVALID_PROPERTY_ID (object, prop_id, pspec);
|
||||
break;
|
||||
|
@ -67,6 +71,9 @@ gst_vaapi_decode_h264_set_property (GObject * object, guint prop_id,
|
|||
if (decoder)
|
||||
gst_vaapi_decoder_h264_set_low_latency (decoder, priv->is_low_latency);
|
||||
break;
|
||||
case GST_VAAPI_DECODER_H264_PROP_BASE_ONLY:
|
||||
priv->base_only = g_value_get_boolean (value);
|
||||
break;
|
||||
default:
|
||||
G_OBJECT_WARN_INVALID_PROPERTY_ID (object, prop_id, pspec);
|
||||
break;
|
||||
|
@ -88,6 +95,11 @@ gst_vaapi_decode_h264_install_properties (GObjectClass * klass)
|
|||
"When enabled, frames will be pushed as soon as they are available. "
|
||||
"It might violate the H.264 spec.", FALSE,
|
||||
G_PARAM_READWRITE | G_PARAM_STATIC_STRINGS | G_PARAM_CONSTRUCT));
|
||||
|
||||
g_object_class_install_property (klass, GST_VAAPI_DECODER_H264_PROP_BASE_ONLY,
|
||||
g_param_spec_boolean ("base-only", "Decode base view only",
|
||||
"Drop any NAL unit not defined in Annex.A", FALSE,
|
||||
G_PARAM_READWRITE | G_PARAM_STATIC_STRINGS));
|
||||
}
|
||||
|
||||
GstVaapiDecodeH264Private *
|
||||
|
|
|
@ -33,6 +33,7 @@ typedef struct _GstVaapiDecodeH264Private GstVaapiDecodeH264Private;
|
|||
struct _GstVaapiDecodeH264Private
|
||||
{
|
||||
gboolean is_low_latency;
|
||||
gboolean base_only;
|
||||
};
|
||||
|
||||
void
|
||||
|
|
Loading…
Reference in a new issue