summaryrefslogtreecommitdiff
path: root/gst/sdp
diff options
context:
space:
mode:
authorStéphane Cerveau <scerveau@collabora.com>2021-02-25 15:22:15 +0100
committerGStreamer Marge Bot <gitlab-merge-bot@gstreamer-foundation.org>2021-04-11 16:16:55 +0000
commit891be511057dbcdf1f38740e55cbd376c4b25894 (patch)
treeb077e8cd0b584ebe2a10950ef2398ab3f60b48b4 /gst/sdp
parent7f60138ef68e2a1fef8ccd4ff3710dfccd243314 (diff)
downloadgstreamer-plugins-bad-891be511057dbcdf1f38740e55cbd376c4b25894.tar.gz
gst-plugins: 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-bad/-/merge_requests/2110>
Diffstat (limited to 'gst/sdp')
-rw-r--r--gst/sdp/gstsdpdemux.c2
-rw-r--r--gst/sdp/gstsdpdemux.h1
-rw-r--r--gst/sdp/gstsdpelem.c11
-rw-r--r--gst/sdp/gstsdpsrc.c1
-rw-r--r--gst/sdp/gstsdpsrc.h1
5 files changed, 10 insertions, 6 deletions
diff --git a/gst/sdp/gstsdpdemux.c b/gst/sdp/gstsdpdemux.c
index 1374bbb92..1737ed8d4 100644
--- a/gst/sdp/gstsdpdemux.c
+++ b/gst/sdp/gstsdpdemux.c
@@ -110,6 +110,8 @@ static GstFlowReturn gst_sdp_demux_sink_chain (GstPad * pad, GstObject * parent,
#define gst_sdp_demux_parent_class parent_class
G_DEFINE_TYPE (GstSDPDemux, gst_sdp_demux, GST_TYPE_BIN);
+GST_ELEMENT_REGISTER_DEFINE (sdpdemux, "sdpdemux", GST_RANK_NONE,
+ GST_TYPE_SDP_DEMUX);
static void
gst_sdp_demux_class_init (GstSDPDemuxClass * klass)
diff --git a/gst/sdp/gstsdpdemux.h b/gst/sdp/gstsdpdemux.h
index 908ac5baf..fb8ea4402 100644
--- a/gst/sdp/gstsdpdemux.h
+++ b/gst/sdp/gstsdpdemux.h
@@ -113,6 +113,7 @@ struct _GstSDPDemuxClass {
};
GType gst_sdp_demux_get_type(void);
+GST_ELEMENT_REGISTER_DECLARE (sdpdemux);
G_END_DECLS
diff --git a/gst/sdp/gstsdpelem.c b/gst/sdp/gstsdpelem.c
index 8a945cdbf..a9d22fc78 100644
--- a/gst/sdp/gstsdpelem.c
+++ b/gst/sdp/gstsdpelem.c
@@ -27,13 +27,12 @@
static gboolean
plugin_init (GstPlugin * plugin)
{
- if (!gst_element_register (plugin, "sdpdemux", GST_RANK_NONE,
- GST_TYPE_SDP_DEMUX))
- return FALSE;
- if (!gst_element_register (plugin, "sdpsrc", GST_RANK_NONE, GST_TYPE_SDP_SRC))
- return FALSE;
+ gboolean ret = FALSE;
- return TRUE;
+ ret |= GST_ELEMENT_REGISTER (sdpdemux, plugin);
+ ret |= GST_ELEMENT_REGISTER (sdpsrc, plugin);
+
+ return ret;
}
GST_PLUGIN_DEFINE (GST_VERSION_MAJOR,
diff --git a/gst/sdp/gstsdpsrc.c b/gst/sdp/gstsdpsrc.c
index 96b483d23..184c9bfda 100644
--- a/gst/sdp/gstsdpsrc.c
+++ b/gst/sdp/gstsdpsrc.c
@@ -45,6 +45,7 @@ static void gst_sdp_src_handler_init (gpointer g_iface, gpointer iface_data);
#define gst_sdp_src_parent_class parent_class
G_DEFINE_TYPE_WITH_CODE (GstSdpSrc, gst_sdp_src, GST_TYPE_BIN,
G_IMPLEMENT_INTERFACE (GST_TYPE_URI_HANDLER, gst_sdp_src_handler_init));
+GST_ELEMENT_REGISTER_DEFINE (sdpsrc, "sdpsrc", GST_RANK_NONE, GST_TYPE_SDP_SRC);
static void
gst_sdp_src_finalize (GObject * object)
diff --git a/gst/sdp/gstsdpsrc.h b/gst/sdp/gstsdpsrc.h
index 05f2074f9..955fc5c3a 100644
--- a/gst/sdp/gstsdpsrc.h
+++ b/gst/sdp/gstsdpsrc.h
@@ -57,6 +57,7 @@ struct _GstSdpSrcClass
};
GType gst_sdp_src_get_type (void);
+GST_ELEMENT_REGISTER_DECLARE (sdpsrc);
G_END_DECLS
#endif /* __GST_SDP_SRC_H__ */