From add47b7cb01b86b9bbfdfecb554ee549b36fd637 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?St=C3=A9phane=20Cerveau?= Date: Wed, 17 Feb 2021 15:59:36 +0100 Subject: [PATCH] faac: allow per feature registration Split plugin into features including dynamic types which can be indiviually registered during a static build. More details here: https://gitlab.freedesktop.org/gstreamer/gst-build/-/merge_requests/199 https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/661 Part-of: --- ext/faac/gstfaac.c | 4 ++-- ext/faac/gstfaac.h | 2 ++ 2 files changed, 4 insertions(+), 2 deletions(-) diff --git a/ext/faac/gstfaac.c b/ext/faac/gstfaac.c index edae8e2ecc..c24a514a64 100644 --- a/ext/faac/gstfaac.c +++ b/ext/faac/gstfaac.c @@ -135,6 +135,7 @@ GST_DEBUG_CATEGORY_STATIC (faac_debug); #define gst_faac_parent_class parent_class G_DEFINE_TYPE (GstFaac, gst_faac, GST_TYPE_AUDIO_ENCODER); +GST_ELEMENT_REGISTER_DEFINE (faac, "faac", GST_RANK_SECONDARY, GST_TYPE_FAAC); #define GST_TYPE_FAAC_RATE_CONTROL (gst_faac_brtype_get_type ()) static GType @@ -781,8 +782,7 @@ gst_faac_get_property (GObject * object, static gboolean plugin_init (GstPlugin * plugin) { - return gst_element_register (plugin, "faac", GST_RANK_SECONDARY, - GST_TYPE_FAAC); + return GST_ELEMENT_REGISTER (faac, plugin); } GST_PLUGIN_DEFINE (GST_VERSION_MAJOR, diff --git a/ext/faac/gstfaac.h b/ext/faac/gstfaac.h index 9890354e1d..83a31775ef 100644 --- a/ext/faac/gstfaac.h +++ b/ext/faac/gstfaac.h @@ -73,6 +73,8 @@ struct _GstFaacClass { GType gst_faac_get_type (void); +GST_ELEMENT_REGISTER_DECLARE (faac); + G_END_DECLS #endif /* __GST_FAAC_H__ */