summaryrefslogtreecommitdiff
path: root/gst/adpcmenc/adpcmenc.c
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/adpcmenc/adpcmenc.c
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/adpcmenc/adpcmenc.c')
-rw-r--r--gst/adpcmenc/adpcmenc.c14
1 files changed, 7 insertions, 7 deletions
diff --git a/gst/adpcmenc/adpcmenc.c b/gst/adpcmenc/adpcmenc.c
index 52962e408..027029cf5 100644
--- a/gst/adpcmenc/adpcmenc.c
+++ b/gst/adpcmenc/adpcmenc.c
@@ -132,7 +132,12 @@ typedef struct _ADPCMEnc
} ADPCMEnc;
GType adpcmenc_get_type (void);
-G_DEFINE_TYPE (ADPCMEnc, adpcmenc, GST_TYPE_AUDIO_ENCODER);
+GST_ELEMENT_REGISTER_DECLARE (adpcmenc);
+G_DEFINE_TYPE_WITH_CODE (ADPCMEnc, adpcmenc, GST_TYPE_AUDIO_ENCODER,
+ GST_DEBUG_CATEGORY_INIT (adpcmenc_debug, "adpcmenc", 0, "ADPCM Encoders");
+ );
+GST_ELEMENT_REGISTER_DEFINE (adpcmenc, "adpcmenc", GST_RANK_PRIMARY,
+ GST_TYPE_ADPCM_ENC);
static gboolean
adpcmenc_setup (ADPCMEnc * enc)
@@ -470,12 +475,7 @@ adpcmenc_class_init (ADPCMEncClass * klass)
static gboolean
plugin_init (GstPlugin * plugin)
{
- GST_DEBUG_CATEGORY_INIT (adpcmenc_debug, "adpcmenc", 0, "ADPCM Encoders");
- if (!gst_element_register (plugin, "adpcmenc", GST_RANK_PRIMARY,
- GST_TYPE_ADPCM_ENC)) {
- return FALSE;
- }
- return TRUE;
+ return GST_ELEMENT_REGISTER (adpcmenc, plugin);
}
GST_PLUGIN_DEFINE (GST_VERSION_MAJOR, GST_VERSION_MINOR, adpcmenc,