Commit c0e101e9 authored by Vincent Penquerc'h's avatar Vincent Penquerc'h

various: fix pad template leaks

https://bugzilla.gnome.org/show_bug.cgi?id=662664
parent a2337b8a
......@@ -190,8 +190,8 @@ gst_aasink_base_init (gpointer g_class)
{
GstElementClass *element_class = GST_ELEMENT_CLASS (g_class);
gst_element_class_add_pad_template (element_class,
gst_static_pad_template_get (&sink_template));
gst_element_class_add_static_pad_template (element_class,
&sink_template);
gst_element_class_set_details_simple (element_class, "ASCII art video sink",
"Sink/Video",
"An ASCII art videosink", "Wim Taymans <wim.taymans@chello.be>");
......
......@@ -121,10 +121,10 @@ gst_cmml_dec_base_init (gpointer g_class)
{
GstElementClass *element_class = GST_ELEMENT_CLASS (g_class);
gst_element_class_add_pad_template (element_class,
gst_static_pad_template_get (&gst_cmml_dec_sink_factory));
gst_element_class_add_pad_template (element_class,
gst_static_pad_template_get (&gst_cmml_dec_src_factory));
gst_element_class_add_static_pad_template (element_class,
&gst_cmml_dec_sink_factory);
gst_element_class_add_static_pad_template (element_class,
&gst_cmml_dec_src_factory);
gst_element_class_set_details_simple (element_class, "CMML stream decoder",
"Codec/Decoder",
"Decodes CMML streams", "Alessandro Decina <alessandro@nnva.org>");
......
......@@ -108,10 +108,10 @@ gst_cmml_enc_base_init (gpointer g_class)
{
GstElementClass *element_class = GST_ELEMENT_CLASS (g_class);
gst_element_class_add_pad_template (element_class,
gst_static_pad_template_get (&gst_cmml_enc_sink_factory));
gst_element_class_add_pad_template (element_class,
gst_static_pad_template_get (&gst_cmml_enc_src_factory));
gst_element_class_add_static_pad_template (element_class,
&gst_cmml_enc_sink_factory);
gst_element_class_add_static_pad_template (element_class,
&gst_cmml_enc_src_factory);
gst_element_class_set_details_simple (element_class, "CMML streams encoder",
"Codec/Encoder",
"Encodes CMML streams", "Alessandro Decina <alessandro@nnva.org>");
......
......@@ -194,10 +194,10 @@ gst_cairo_overlay_base_init (gpointer g_class)
"Render overlay on a video stream using Cairo",
"Jon Nordby <jononor@gmail.com>");
gst_element_class_add_pad_template (element_class,
gst_static_pad_template_get (&gst_cairo_overlay_sink_template));
gst_element_class_add_pad_template (element_class,
gst_static_pad_template_get (&gst_cairo_overlay_src_template));
gst_element_class_add_static_pad_template (element_class,
&gst_cairo_overlay_sink_template);
gst_element_class_add_static_pad_template (element_class,
&gst_cairo_overlay_src_template);
}
static void
......
......@@ -354,8 +354,8 @@ gst_cairo_render_base_init (gpointer g_class)
gst_element_class_set_details_simple (ec, "Cairo encoder",
"Codec/Encoder", "Encodes streams using Cairo",
"Lutz Mueller <lutz@topfrose.de>");
gst_element_class_add_pad_template (ec, gst_static_pad_template_get (&t_snk));
gst_element_class_add_pad_template (ec, gst_static_pad_template_get (&t_src));
gst_element_class_add_static_pad_template (ec, &t_snk);
gst_element_class_add_static_pad_template (ec, &t_src);
}
static void
......
......@@ -132,12 +132,12 @@ gst_text_overlay_base_init (gpointer g_class)
{
GstElementClass *element_class = GST_ELEMENT_CLASS (g_class);
gst_element_class_add_pad_template (element_class,
gst_static_pad_template_get (&cairo_text_overlay_src_template_factory));
gst_element_class_add_pad_template (element_class,
gst_static_pad_template_get (&video_sink_template_factory));
gst_element_class_add_pad_template (element_class,
gst_static_pad_template_get (&text_sink_template_factory));
gst_element_class_add_static_pad_template (element_class,
&cairo_text_overlay_src_template_factory);
gst_element_class_add_static_pad_template (element_class,
&video_sink_template_factory);
gst_element_class_add_static_pad_template (element_class,
&text_sink_template_factory);
gst_element_class_set_details_simple (element_class, "Text overlay",
"Filter/Editor/Video",
......
......@@ -265,10 +265,10 @@ gst_cairo_time_overlay_base_init (gpointer g_class)
"Filter/Editor/Video",
"Overlays the time on a video stream", "David Schleef <ds@schleef.org>");
gst_element_class_add_pad_template (element_class,
gst_static_pad_template_get (&gst_cairo_time_overlay_sink_template));
gst_element_class_add_pad_template (element_class,
gst_static_pad_template_get (&gst_cairo_time_overlay_src_template));
gst_element_class_add_static_pad_template (element_class,
&gst_cairo_time_overlay_sink_template);
gst_element_class_add_static_pad_template (element_class,
&gst_cairo_time_overlay_src_template);
}
static void
......
......@@ -166,10 +166,8 @@ gst_dvdec_base_init (gpointer g_class)
{
GstElementClass *element_class = GST_ELEMENT_CLASS (g_class);
gst_element_class_add_pad_template (element_class,
gst_static_pad_template_get (&sink_temp));
gst_element_class_add_pad_template (element_class,
gst_static_pad_template_get (&src_temp));
gst_element_class_add_static_pad_template (element_class, &sink_temp);
gst_element_class_add_static_pad_template (element_class, &src_temp);
gst_element_class_set_details_simple (element_class, "DV video decoder",
"Codec/Decoder/Video",
......
......@@ -174,12 +174,11 @@ gst_dvdemux_base_init (gpointer g_class)
{
GstElementClass *element_class = GST_ELEMENT_CLASS (g_class);
gst_element_class_add_pad_template (element_class,
gst_static_pad_template_get (&sink_temp));
gst_element_class_add_pad_template (element_class,
gst_static_pad_template_get (&video_src_temp));
gst_element_class_add_pad_template (element_class,
gst_static_pad_template_get (&audio_src_temp));
gst_element_class_add_static_pad_template (element_class, &sink_temp);
gst_element_class_add_static_pad_template (element_class,
&video_src_temp);
gst_element_class_add_static_pad_template (element_class,
&audio_src_temp);
gst_element_class_set_details_simple (element_class,
"DV system stream demuxer", "Codec/Demuxer",
......
......@@ -168,8 +168,7 @@ gst_esdmon_base_init (gpointer g_class)
{
GstElementClass *element_class = GST_ELEMENT_CLASS (g_class);
gst_element_class_add_pad_template (element_class,
gst_static_pad_template_get (&src_factory));
gst_element_class_add_static_pad_template (element_class, &src_factory);
gst_element_class_set_details_simple (element_class, "Esound audio monitor",
"Source/Audio",
"Monitors audio from an esound server",
......
......@@ -111,8 +111,7 @@ gst_esdsink_base_init (gpointer g_class)
{
GstElementClass *element_class = GST_ELEMENT_CLASS (g_class);
gst_element_class_add_pad_template (element_class,
gst_static_pad_template_get (&sink_factory));
gst_element_class_add_static_pad_template (element_class, &sink_factory);
gst_element_class_set_details_simple (element_class, "Esound audio sink",
"Sink/Audio",
"Plays audio to an esound server",
......
......@@ -178,10 +178,10 @@ gst_flac_dec_base_init (gpointer g_class)
{
GstElementClass *element_class = GST_ELEMENT_CLASS (g_class);
gst_element_class_add_pad_template (element_class,
gst_static_pad_template_get (&flac_dec_src_factory));
gst_element_class_add_pad_template (element_class,
gst_static_pad_template_get (&flac_dec_sink_factory));
gst_element_class_add_static_pad_template (element_class,
&flac_dec_src_factory);
gst_element_class_add_static_pad_template (element_class,
&flac_dec_sink_factory);
gst_element_class_set_details_simple (element_class, "FLAC audio decoder",
"Codec/Decoder/Audio",
"Decodes FLAC lossless audio streams", "Wim Taymans <wim@fluendo.com>");
......
......@@ -258,10 +258,8 @@ gst_flac_enc_base_init (gpointer g_class)
{
GstElementClass *element_class = GST_ELEMENT_CLASS (g_class);
gst_element_class_add_pad_template (element_class,
gst_static_pad_template_get (&src_factory));
gst_element_class_add_pad_template (element_class,
gst_static_pad_template_get (&sink_factory));
gst_element_class_add_static_pad_template (element_class, &src_factory);
gst_element_class_add_static_pad_template (element_class, &sink_factory);
gst_element_class_set_details_simple (element_class, "FLAC audio encoder",
"Codec/Encoder/Audio",
......
......@@ -117,10 +117,10 @@ gst_flac_tag_base_init (gpointer g_class)
"Formatter/Metadata",
"Rewrite tags in a FLAC file", "Christophe Fergeau <teuf@gnome.org>");
gst_element_class_add_pad_template (element_class,
gst_static_pad_template_get (&flac_tag_sink_template));
gst_element_class_add_pad_template (element_class,
gst_static_pad_template_get (&flac_tag_src_template));
gst_element_class_add_static_pad_template (element_class,
&flac_tag_sink_template);
gst_element_class_add_static_pad_template (element_class,
&flac_tag_src_template);
GST_DEBUG_CATEGORY_INIT (flactag_debug, "flactag", 0, "flac tag rewriter");
}
......
......@@ -64,8 +64,7 @@ gst_switch_sink_class_init (GstSwitchSinkClass * klass)
/* Provide a default pad template if the child didn't */
child_pad_templ = gst_element_class_get_pad_template (eklass, "sink");
if (child_pad_templ == NULL) {
gst_element_class_add_pad_template (eklass,
gst_static_pad_template_get (&sink_template));
gst_element_class_add_static_pad_template (eklass, &sink_template);
}
}
......
......@@ -60,8 +60,7 @@ gst_switch_src_class_init (GstSwitchSrcClass * klass)
/* Provide a default pad template if the child didn't */
child_pad_templ = gst_element_class_get_pad_template (eklass, "src");
if (child_pad_templ == NULL) {
gst_element_class_add_pad_template (eklass,
gst_static_pad_template_get (&src_template));
gst_element_class_add_static_pad_template (eklass, &src_template);
}
}
......
......@@ -157,10 +157,10 @@ gst_gdk_pixbuf_base_init (gpointer g_class)
{
GstElementClass *element_class = GST_ELEMENT_CLASS (g_class);
gst_element_class_add_pad_template (element_class,
gst_static_pad_template_get (&gst_gdk_pixbuf_src_template));
gst_element_class_add_pad_template (element_class,
gst_static_pad_template_get (&gst_gdk_pixbuf_sink_template));
gst_element_class_add_static_pad_template (element_class,
&gst_gdk_pixbuf_src_template);
gst_element_class_add_static_pad_template (element_class,
&gst_gdk_pixbuf_sink_template);
gst_element_class_set_details_simple (element_class,
"GdkPixbuf image decoder", "Codec/Decoder/Image",
"Decodes images in a video stream using GdkPixbuf",
......
......@@ -146,8 +146,8 @@ gst_gdk_pixbuf_sink_base_init (gpointer g_class)
"Sink/Video", "Output images as GdkPixbuf objects in bus messages",
"Tim-Philipp Müller <tim centricular net>");
gst_element_class_add_pad_template (element_class,
gst_static_pad_template_get (&pixbufsink_sink_factory));
gst_element_class_add_static_pad_template (element_class,
&pixbufsink_sink_factory);
}
static void
......
......@@ -122,10 +122,10 @@ gst_pixbufscale_base_init (gpointer g_class)
"Wim Taymans <wim.taymans@chello.be>, "
"Renato Filho <renato.filho@indt.org.br>");
gst_element_class_add_pad_template (element_class,
gst_static_pad_template_get (&gst_pixbufscale_src_template));
gst_element_class_add_pad_template (element_class,
gst_static_pad_template_get (&gst_pixbufscale_sink_template));
gst_element_class_add_static_pad_template (element_class,
&gst_pixbufscale_src_template);
gst_element_class_add_static_pad_template (element_class,
&gst_pixbufscale_sink_template);
}
static void
......
......@@ -74,8 +74,7 @@ gst_hal_audio_sink_base_init (gpointer klass)
GST_PAD_ALWAYS,
GST_STATIC_CAPS_ANY);
gst_element_class_add_pad_template (eklass,
gst_static_pad_template_get (&sink_template));
gst_element_class_add_static_pad_template (eklass, &sink_template);
gst_element_class_set_details_simple (eklass, "HAL audio sink",
"Sink/Audio",
"Audio sink for sound device access via HAL",
......
......@@ -76,8 +76,7 @@ gst_hal_audio_src_base_init (gpointer klass)
GST_PAD_ALWAYS,
GST_STATIC_CAPS_ANY);
gst_element_class_add_pad_template (eklass,
gst_static_pad_template_get (&src_template));
gst_element_class_add_static_pad_template (eklass, &src_template);
gst_element_class_set_details_simple (eklass, "HAL audio source",
"Source/Audio",
"Audio source for sound device access via HAL",
......
......@@ -681,8 +681,8 @@ gst_jack_audio_sink_base_init (gpointer g_class)
"Sink/Audio", "Output audio to a JACK server",
"Wim Taymans <wim.taymans@gmail.com>");
gst_element_class_add_pad_template (element_class,
gst_static_pad_template_get (&jackaudiosink_sink_factory));
gst_element_class_add_static_pad_template (element_class,
&jackaudiosink_sink_factory);
}
static void
......
......@@ -697,8 +697,7 @@ gst_jack_audio_src_base_init (gpointer gclass)
{
GstElementClass *element_class = GST_ELEMENT_CLASS (gclass);
gst_element_class_add_pad_template (element_class,
gst_static_pad_template_get (&src_factory));
gst_element_class_add_static_pad_template (element_class, &src_factory);
gst_element_class_set_details_simple (element_class, "Audio Source (Jack)",
"Source/Audio", "Captures audio from a JACK server",
"Tristan Matthews <tristan@sat.qc.ca>");
......
......@@ -167,10 +167,10 @@ gst_jpeg_dec_base_init (gpointer g_class)
{
GstElementClass *element_class = GST_ELEMENT_CLASS (g_class);
gst_element_class_add_pad_template (element_class,
gst_static_pad_template_get (&gst_jpeg_dec_src_pad_template));
gst_element_class_add_pad_template (element_class,
gst_static_pad_template_get (&gst_jpeg_dec_sink_pad_template));
gst_element_class_add_static_pad_template (element_class,
&gst_jpeg_dec_src_pad_template);
gst_element_class_add_static_pad_template (element_class,
&gst_jpeg_dec_sink_pad_template);
gst_element_class_set_details_simple (element_class, "JPEG image decoder",
"Codec/Decoder/Image",
"Decode images from JPEG format", "Wim Taymans <wim@fluendo.com>");
......
......@@ -142,10 +142,10 @@ gst_jpegenc_base_init (gpointer g_class)
{
GstElementClass *element_class = GST_ELEMENT_CLASS (g_class);
gst_element_class_add_pad_template (element_class,
gst_static_pad_template_get (&gst_jpegenc_sink_pad_template));
gst_element_class_add_pad_template (element_class,
gst_static_pad_template_get (&gst_jpegenc_src_pad_template));
gst_element_class_add_static_pad_template (element_class,
&gst_jpegenc_sink_pad_template);
gst_element_class_add_static_pad_template (element_class,
&gst_jpegenc_src_pad_template);
gst_element_class_set_details_simple (element_class, "JPEG image encoder",
"Codec/Encoder/Image",
"Encode images in JPEG format", "Wim Taymans <wim.taymans@tvd.be>");
......
......@@ -106,10 +106,10 @@ gst_smokedec_base_init (gpointer g_class)
{
GstElementClass *element_class = GST_ELEMENT_CLASS (g_class);
gst_element_class_add_pad_template (element_class,
gst_static_pad_template_get (&gst_smokedec_src_pad_template));
gst_element_class_add_pad_template (element_class,
gst_static_pad_template_get (&gst_smokedec_sink_pad_template));
gst_element_class_add_static_pad_template (element_class,
&gst_smokedec_src_pad_template);
gst_element_class_add_static_pad_template (element_class,
&gst_smokedec_sink_pad_template);
gst_element_class_set_details_simple (element_class, "Smoke video decoder",
"Codec/Decoder/Video",
"Decode video from Smoke format", "Wim Taymans <wim@fluendo.com>");
......
......@@ -123,10 +123,10 @@ gst_smokeenc_base_init (gpointer g_class)
{
GstElementClass *element_class = GST_ELEMENT_CLASS (g_class);
gst_element_class_add_pad_template (element_class,
gst_static_pad_template_get (&gst_smokeenc_sink_pad_template));
gst_element_class_add_pad_template (element_class,
gst_static_pad_template_get (&gst_smokeenc_src_pad_template));
gst_element_class_add_static_pad_template (element_class,
&gst_smokeenc_sink_pad_template);
gst_element_class_add_static_pad_template (element_class,
&gst_smokeenc_src_pad_template);
gst_element_class_set_details_simple (element_class, "Smoke video encoder",
"Codec/Encoder/Video",
"Encode images into the Smoke format", "Wim Taymans <wim@fluendo.com>");
......
......@@ -151,8 +151,8 @@ gst_cacasink_base_init (gpointer g_class)
gst_element_class_set_details_simple (element_class,
"A colored ASCII art video sink", "Sink/Video",
"A colored ASCII art videosink", "Zeeshan Ali <zak147@yahoo.com>");
gst_element_class_add_pad_template (element_class,
gst_static_pad_template_get (&sink_template));
gst_element_class_add_static_pad_template (element_class,
&sink_template);
}
static void
......
......@@ -66,10 +66,10 @@ gst_mng_dec_base_init (gpointer g_class)
{
GstElementClass *element_class = GST_ELEMENT_CLASS (g_class);
gst_element_class_add_pad_template (element_class,
gst_static_pad_template_get (&gst_mng_dec_src_pad_template));
gst_element_class_add_pad_template (element_class,
gst_static_pad_template_get (&gst_mng_dec_sink_pad_template));
gst_element_class_add_static_pad_template (element_class,
&gst_mng_dec_src_pad_template);
gst_element_class_add_static_pad_template (element_class,
&gst_mng_dec_sink_pad_template);
gst_element_class_set_details_simple (element_class, "MNG video decoder",
"Codec/Decoder/Video",
"Decode a mng video to raw images", "Wim Taymans <wim@fluendo.com>");
......
......@@ -87,6 +87,9 @@ gst_mng_enc_base_init (gpointer g_class)
gst_element_class_set_details_simple (element_class, "MNG video encoder",
"Codec/Encoder/Video",
"Encode a video frame to an .mng video", "Wim Taymans <wim@fluendo.com>");
gst_object_unref (mngenc_src_template);
gst_object_unref (mngenc_sink_template);
}
static void
......
......@@ -102,10 +102,10 @@ gst_pngdec_base_init (gpointer g_class)
{
GstElementClass *element_class = GST_ELEMENT_CLASS (g_class);
gst_element_class_add_pad_template (element_class,
gst_static_pad_template_get (&gst_pngdec_src_pad_template));
gst_element_class_add_pad_template (element_class,
gst_static_pad_template_get (&gst_pngdec_sink_pad_template));
gst_element_class_add_static_pad_template (element_class,
&gst_pngdec_src_pad_template);
gst_element_class_add_static_pad_template (element_class,
&gst_pngdec_sink_pad_template);
gst_element_class_set_details_simple (element_class, "PNG image decoder",
"Codec/Decoder/Image",
"Decode a png video frame to a raw image",
......
......@@ -97,10 +97,10 @@ gst_pngenc_base_init (gpointer g_class)
{
GstElementClass *element_class = GST_ELEMENT_CLASS (g_class);
gst_element_class_add_pad_template
(element_class, gst_static_pad_template_get (&pngenc_sink_template));
gst_element_class_add_pad_template
(element_class, gst_static_pad_template_get (&pngenc_src_template));
gst_element_class_add_static_pad_template
(element_class, &pngenc_sink_template);
gst_element_class_add_static_pad_template
(element_class, &pngenc_src_template);
gst_element_class_set_details_simple (element_class, "PNG image encoder",
"Codec/Encoder/Image",
"Encode a video frame to a .png image",
......
......@@ -128,10 +128,10 @@ gst_mikmod_base_init (gpointer g_class)
{
GstElementClass *element_class = GST_ELEMENT_CLASS (g_class);
gst_element_class_add_pad_template (element_class,
gst_static_pad_template_get (&mikmod_src_factory));
gst_element_class_add_pad_template (element_class,
gst_static_pad_template_get (&mikmod_sink_factory));
gst_element_class_add_static_pad_template (element_class,
&mikmod_src_factory);
gst_element_class_add_static_pad_template (element_class,
&mikmod_sink_factory);
gst_element_class_set_details_simple (element_class, "MikMod audio decoder",
"Codec/Decoder/Audio",
"Module decoder based on libmikmod", "Jeremy SIMON <jsimon13@yahoo.fr>");
......
......@@ -140,8 +140,8 @@ gst_pulse_audio_sink_base_init (gpointer klass)
{
GstElementClass *element_class = GST_ELEMENT_CLASS (klass);
gst_element_class_add_pad_template (element_class,
gst_static_pad_template_get (&sink_template));
gst_element_class_add_static_pad_template (element_class,
&sink_template);
gst_element_class_set_details_simple (element_class,
"Bin wrapping pulsesink", "Sink/Audio/Bin",
......
......@@ -1809,8 +1809,7 @@ gst_pulsesink_base_init (gpointer g_class)
gst_element_class_set_details_simple (element_class,
"PulseAudio Audio Sink",
"Sink/Audio", "Plays audio to a PulseAudio server", "Lennart Poettering");
gst_element_class_add_pad_template (element_class,
gst_static_pad_template_get (&pad_template));
gst_element_class_add_static_pad_template (element_class, &pad_template);
}
static GstRingBuffer *
......
......@@ -227,8 +227,7 @@ gst_pulsesrc_base_init (gpointer g_class)
"PulseAudio Audio Source",
"Source/Audio",
"Captures audio from a PulseAudio server", "Lennart Poettering");
gst_element_class_add_pad_template (element_class,
gst_static_pad_template_get (&pad_template));
gst_element_class_add_static_pad_template (element_class, &pad_template);
}
static void
......
......@@ -170,8 +170,7 @@ gst_dv1394src_base_init (gpointer g_class)
{
GstElementClass *element_class = GST_ELEMENT_CLASS (g_class);
gst_element_class_add_pad_template (element_class,
gst_static_pad_template_get (&src_factory));
gst_element_class_add_static_pad_template (element_class, &src_factory);
gst_element_class_set_details_simple (element_class,
"Firewire (1394) DV video source", "Source/Video",
......
......@@ -140,8 +140,7 @@ gst_hdv1394src_base_init (gpointer g_class)
{
GstElementClass *element_class = GST_ELEMENT_CLASS (g_class);
gst_element_class_add_pad_template (element_class,
gst_static_pad_template_get (&src_factory));
gst_element_class_add_static_pad_template (element_class, &src_factory);
gst_element_class_set_details_simple (element_class,
"Firewire (1394) HDV video source", "Source/Video",
......
......@@ -160,8 +160,8 @@ gst_shout2send_base_init (GstShout2sendClass * klass)
{
GstElementClass *element_class = GST_ELEMENT_CLASS (klass);
gst_element_class_add_pad_template (element_class,
gst_static_pad_template_get (&sink_template));
gst_element_class_add_static_pad_template (element_class,
&sink_template);
gst_element_class_set_details_simple (element_class, "Icecast network sink",
"Sink/Network", "Sends data to an icecast server",
"Wim Taymans <wim.taymans@chello.be>, "
......
......@@ -119,8 +119,8 @@ gst_soup_http_client_sink_base_init (gpointer g_class)
{
GstElementClass *element_class = GST_ELEMENT_CLASS (g_class);
gst_element_class_add_pad_template (element_class,
gst_static_pad_template_get (&gst_soup_http_client_sink_sink_template));
gst_element_class_add_static_pad_template (element_class,
&gst_soup_http_client_sink_sink_template);
gst_element_class_set_details_simple (element_class, "HTTP client sink",
"Generic", "Sends streams to HTTP server via PUT",
......
......@@ -193,8 +193,7 @@ gst_soup_http_src_base_init (gpointer g_class)
{
GstElementClass *element_class = GST_ELEMENT_CLASS (g_class);
gst_element_class_add_pad_template (element_class,
gst_static_pad_template_get (&srctemplate));
gst_element_class_add_static_pad_template (element_class, &srctemplate);
gst_element_class_set_details_simple (element_class, "HTTP client source",
"Source/Network",
......
......@@ -97,10 +97,10 @@ gst_speex_dec_base_init (gpointer g_class)
{
GstElementClass *element_class = GST_ELEMENT_CLASS (g_class);
gst_element_class_add_pad_template (element_class,
gst_static_pad_template_get (&speex_dec_src_factory));
gst_element_class_add_pad_template (element_class,
gst_static_pad_template_get (&speex_dec_sink_factory));
gst_element_class_add_static_pad_template (element_class,
&speex_dec_src_factory);
gst_element_class_add_static_pad_template (element_class,
&speex_dec_sink_factory);
gst_element_class_set_details_simple (element_class, "Speex audio decoder",
"Codec/Decoder/Audio",
"decode speex streams to audio", "Wim Taymans <wim@fluendo.com>");
......
......@@ -154,10 +154,8 @@ gst_speex_enc_base_init (gpointer g_class)
{
GstElementClass *element_class = GST_ELEMENT_CLASS (g_class);
gst_element_class_add_pad_template (element_class,
gst_static_pad_template_get (&src_factory));
gst_element_class_add_pad_template (element_class,
gst_static_pad_template_get (&sink_factory));
gst_element_class_add_static_pad_template (element_class, &src_factory);
gst_element_class_add_static_pad_template (element_class, &sink_factory);
gst_element_class_set_details_simple (element_class, "Speex audio encoder",
"Codec/Encoder/Audio",
"Encodes audio in Speex format", "Wim Taymans <wim@fluendo.com>");
......
......@@ -75,8 +75,7 @@ gst_apev2_mux_base_init (gpointer g_class)
{
GstElementClass *element_class = GST_ELEMENT_CLASS (g_class);
gst_element_class_add_pad_template (element_class,
gst_static_pad_template_get (&src_template));
gst_element_class_add_static_pad_template (element_class, &src_template);
gst_element_class_set_details_simple (element_class,
"TagLib-based APEv2 Muxer", "Formatter/Metadata",
......
......@@ -84,8 +84,7 @@ gst_id3v2_mux_base_init (gpointer g_class)
{
GstElementClass *element_class = GST_ELEMENT_CLASS (g_class);
gst_element_class_add_pad_template (element_class,
gst_static_pad_template_get (&src_template));
gst_element_class_add_static_pad_template (element_class, &src_template);
gst_element_class_set_details_simple (element_class,
"TagLib-based ID3v2 Muxer", "Formatter/Metadata",
......
......@@ -83,8 +83,8 @@ gst_tag_lib_mux_base_init (gpointer g_class)
{
GstElementClass *element_class = GST_ELEMENT_CLASS (g_class);
gst_element_class_add_pad_template (element_class,
gst_static_pad_template_get (&gst_tag_lib_mux_sink_template));
gst_element_class_add_static_pad_template (element_class,
&gst_tag_lib_mux_sink_template);
GST_DEBUG_CATEGORY_INIT (gst_tag_lib_mux_debug, "taglibmux", 0,
"taglib-based muxer");
......
......@@ -95,10 +95,8 @@ gst_wavpack_dec_base_init (gpointer klass)
{
GstElementClass *element_class = GST_ELEMENT_CLASS (klass);
gst_element_class_add_pad_template (element_class,
gst_static_pad_template_get (&src_factory));
gst_element_class_add_pad_template (element_class,
gst_static_pad_template_get (&sink_factory));
gst_element_class_add_static_pad_template (element_class, &src_factory);
gst_element_class_add_static_pad_template (element_class, &sink_factory);
gst_element_class_set_details_simple (element_class, "Wavpack audio decoder",
"Codec/Decoder/Audio",
"Decodes Wavpack audio data",