raw1394: 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-good/-/merge_requests/876>
This commit is contained in:
Stéphane Cerveau 2021-02-12 15:53:19 +01:00
parent 98fa1618f8
commit d661515829
5 changed files with 14 additions and 7 deletions

View file

@ -32,16 +32,15 @@
static gboolean
plugin_init (GstPlugin * plugin)
{
if (!gst_element_register (plugin, "dv1394src", GST_RANK_NONE,
GST_TYPE_DV1394SRC))
return FALSE;
gboolean ret = FALSE;
ret |= GST_ELEMENT_REGISTER (dv1394src, plugin);
#ifdef HAVE_LIBIEC61883
if (!gst_element_register (plugin, "hdv1394src", GST_RANK_NONE,
GST_TYPE_HDV1394SRC))
return FALSE;
ret |= GST_ELEMENT_REGISTER (hdv1394src, plugin);
#endif
return TRUE;
return ret;
}
GST_PLUGIN_DEFINE (GST_VERSION_MAJOR,

View file

@ -146,6 +146,8 @@ static void gst_dv1394src_update_device_name (GstDV1394Src * src);
G_DEFINE_TYPE_WITH_CODE (GstDV1394Src, gst_dv1394src, GST_TYPE_PUSH_SRC,
G_IMPLEMENT_INTERFACE (GST_TYPE_URI_HANDLER,
gst_dv1394src_uri_handler_init));
GST_ELEMENT_REGISTER_DEFINE (dv1394src, "dv1394src", GST_RANK_NONE,
GST_TYPE_DV1394SRC);
static guint gst_dv1394src_signals[LAST_SIGNAL] = { 0 };

View file

@ -76,6 +76,8 @@ struct _GstDV1394Src {
Gst1394Clock *provided_clock;
};
GST_ELEMENT_REGISTER_DECLARE (dv1394src);
G_END_DECLS
#endif /* __GST_GST1394_H__ */

View file

@ -119,6 +119,8 @@ static void gst_hdv1394src_update_device_name (GstHDV1394Src * src);
G_DEFINE_TYPE_WITH_CODE (GstHDV1394Src, gst_hdv1394src, GST_TYPE_PUSH_SRC,
G_IMPLEMENT_INTERFACE (GST_TYPE_URI_HANDLER,
gst_hdv1394src_uri_handler_init));
GST_ELEMENT_REGISTER_DEFINE (hdv1394src, "hdv1394src", GST_RANK_NONE,
GST_TYPE_HDV1394SRC);
static void
gst_hdv1394src_class_init (GstHDV1394SrcClass * klass)

View file

@ -64,6 +64,8 @@ struct _GstHDV1394Src {
iec61883_mpeg2_t iec61883mpeg2;
};
GST_ELEMENT_REGISTER_DECLARE (hdv1394src);
G_END_DECLS
#endif /* __GST_GST1394_H__ */