mirror of
https://gitlab.freedesktop.org/gstreamer/gstreamer.git
synced 2024-11-26 11:41:09 +00:00
nle: composition: Avoid running query before being constructed
`gst_pad_create_stream_id` runs a URI query on the element which triggers traces for not constructed objects which fails in rust tracers as object should have names in all traces. Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/4975>
This commit is contained in:
parent
96f86da61a
commit
7911a580c2
1 changed files with 13 additions and 2 deletions
|
@ -1079,6 +1079,17 @@ nle_composition_set_property (GObject * object, guint property_id,
|
|||
}
|
||||
}
|
||||
|
||||
static void
|
||||
nle_composition_constructed (GObject * obj)
|
||||
{
|
||||
NleCompositionPrivate *priv = NLE_COMPOSITION (obj)->priv;
|
||||
|
||||
priv->id = gst_pad_create_stream_id (NLE_OBJECT_SRC (obj),
|
||||
GST_ELEMENT (obj), NULL);
|
||||
|
||||
((GObjectClass *) parent_class)->constructed (obj);
|
||||
}
|
||||
|
||||
static void
|
||||
nle_composition_class_init (NleCompositionClass * klass)
|
||||
{
|
||||
|
@ -1098,6 +1109,8 @@ nle_composition_class_init (NleCompositionClass * klass)
|
|||
" Mathieu Duponchelle <mathieu.duponchelle@opencreed.com>,"
|
||||
" Thibault Saunier <tsaunier@gnome.org>");
|
||||
|
||||
|
||||
gobject_class->constructed = GST_DEBUG_FUNCPTR (nle_composition_constructed);
|
||||
gobject_class->dispose = GST_DEBUG_FUNCPTR (nle_composition_dispose);
|
||||
gobject_class->finalize = GST_DEBUG_FUNCPTR (nle_composition_finalize);
|
||||
gobject_class->get_property =
|
||||
|
@ -1195,8 +1208,6 @@ nle_composition_init (NleComposition * comp)
|
|||
|
||||
nle_composition_reset (comp);
|
||||
|
||||
priv->id = gst_pad_create_stream_id (NLE_OBJECT_SRC (comp),
|
||||
GST_ELEMENT (comp), NULL);
|
||||
priv->drop_tags = DEFAULT_DROP_TAGS;
|
||||
priv->nle_event_pad_func = GST_PAD_EVENTFUNC (NLE_OBJECT_SRC (comp));
|
||||
gst_pad_set_event_function (NLE_OBJECT_SRC (comp),
|
||||
|
|
Loading…
Reference in a new issue