audiotestsrc: 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: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-base/-/merge_requests/1089>
This commit is contained in:
parent
51ed45ef89
commit
a176f1a70f
@ -154,6 +154,10 @@ GST_STATIC_PAD_TEMPLATE ("src",
|
|||||||
|
|
||||||
#define gst_audio_test_src_parent_class parent_class
|
#define gst_audio_test_src_parent_class parent_class
|
||||||
G_DEFINE_TYPE (GstAudioTestSrc, gst_audio_test_src, GST_TYPE_BASE_SRC);
|
G_DEFINE_TYPE (GstAudioTestSrc, gst_audio_test_src, GST_TYPE_BASE_SRC);
|
||||||
|
GST_ELEMENT_REGISTER_DEFINE_WITH_CODE (audiotestsrc, "audiotestsrc",
|
||||||
|
GST_RANK_NONE, GST_TYPE_AUDIO_TEST_SRC,
|
||||||
|
GST_DEBUG_CATEGORY_INIT (audio_test_src_debug, "audiotestsrc", 0,
|
||||||
|
"Audio Test Source"));
|
||||||
|
|
||||||
#define GST_TYPE_AUDIO_TEST_SRC_WAVE (gst_audiostestsrc_wave_get_type())
|
#define GST_TYPE_AUDIO_TEST_SRC_WAVE (gst_audiostestsrc_wave_get_type())
|
||||||
static GType
|
static GType
|
||||||
@ -1679,11 +1683,7 @@ gst_audio_test_src_get_property (GObject * object, guint prop_id,
|
|||||||
static gboolean
|
static gboolean
|
||||||
plugin_init (GstPlugin * plugin)
|
plugin_init (GstPlugin * plugin)
|
||||||
{
|
{
|
||||||
GST_DEBUG_CATEGORY_INIT (audio_test_src_debug, "audiotestsrc", 0,
|
return GST_ELEMENT_REGISTER (audiotestsrc, plugin);
|
||||||
"Audio Test Source");
|
|
||||||
|
|
||||||
return gst_element_register (plugin, "audiotestsrc",
|
|
||||||
GST_RANK_NONE, GST_TYPE_AUDIO_TEST_SRC);
|
|
||||||
}
|
}
|
||||||
|
|
||||||
GST_PLUGIN_DEFINE (GST_VERSION_MAJOR,
|
GST_PLUGIN_DEFINE (GST_VERSION_MAJOR,
|
||||||
|
@ -135,6 +135,8 @@ struct _GstAudioTestSrc {
|
|||||||
guint tick_counter;
|
guint tick_counter;
|
||||||
};
|
};
|
||||||
|
|
||||||
|
GST_ELEMENT_REGISTER_DECLARE (audiotestsrc);
|
||||||
|
|
||||||
G_END_DECLS
|
G_END_DECLS
|
||||||
|
|
||||||
#endif /* __GST_AUDIO_TEST_SRC_H__ */
|
#endif /* __GST_AUDIO_TEST_SRC_H__ */
|
||||||
|
Loading…
x
Reference in New Issue
Block a user