mirror of
https://gitlab.freedesktop.org/gstreamer/gstreamer.git
synced 2025-01-03 14:08:56 +00:00
ges: track-element: Fix FIXME about handling NULL factories to add properties
Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/5981>
This commit is contained in:
parent
4c8396da8e
commit
ff9fec521b
2 changed files with 4 additions and 6 deletions
|
@ -398,10 +398,9 @@ ges_effect_asset_id_get_type_and_bindesc (const char *id,
|
||||||
}
|
}
|
||||||
|
|
||||||
for (tmp = GST_BIN_CHILDREN (effect); tmp; tmp = tmp->next) {
|
for (tmp = GST_BIN_CHILDREN (effect); tmp; tmp = tmp->next) {
|
||||||
GstElementFactory *factory =
|
|
||||||
gst_element_get_factory (GST_ELEMENT (tmp->data));
|
|
||||||
const gchar *klass =
|
const gchar *klass =
|
||||||
gst_element_factory_get_metadata (factory, GST_ELEMENT_METADATA_KLASS);
|
gst_element_class_get_metadata (GST_ELEMENT_GET_CLASS (tmp->data),
|
||||||
|
GST_ELEMENT_METADATA_KLASS);
|
||||||
|
|
||||||
if (g_strrstr (klass, "Effect") || g_strrstr (klass, "Filter")) {
|
if (g_strrstr (klass, "Effect") || g_strrstr (klass, "Filter")) {
|
||||||
if (g_strrstr (klass, "Audio")) {
|
if (g_strrstr (klass, "Audio")) {
|
||||||
|
|
|
@ -1084,11 +1084,10 @@ ges_track_element_add_child_props (GESTrackElement * self,
|
||||||
guint i;
|
guint i;
|
||||||
|
|
||||||
factory = gst_element_get_factory (child);
|
factory = gst_element_get_factory (child);
|
||||||
/* FIXME: handle NULL factory */
|
klass = gst_element_class_get_metadata (GST_ELEMENT_GET_CLASS (child),
|
||||||
klass = gst_element_factory_get_metadata (factory,
|
|
||||||
GST_ELEMENT_METADATA_KLASS);
|
GST_ELEMENT_METADATA_KLASS);
|
||||||
|
|
||||||
if (strv_find_str (blacklist, GST_OBJECT_NAME (factory))) {
|
if (factory && strv_find_str (blacklist, GST_OBJECT_NAME (factory))) {
|
||||||
GST_DEBUG_OBJECT (self, "%s blacklisted", GST_OBJECT_NAME (factory));
|
GST_DEBUG_OBJECT (self, "%s blacklisted", GST_OBJECT_NAME (factory));
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in a new issue