summaryrefslogtreecommitdiffstats
path: root/gst
diff options
context:
space:
mode:
authorEdward Hervey <bilboed@bilboed.com>2007-06-22 10:46:33 +0000
committerEdward Hervey <bilboed@bilboed.com>2007-06-22 10:46:33 +0000
commitb8a18741d88bd208d15918655a33f9b42bd614e6 (patch)
tree3006c560e2e604290fbcf119e3256add3d3f982a /gst
parent1b6c4e2ab29de3ed3394c99372656ee0dbc2abe5 (diff)
downloadgst-plugins-bad-b8a18741d88bd208d15918655a33f9b42bd614e6.tar.gz
gst-plugins-bad-b8a18741d88bd208d15918655a33f9b42bd614e6.tar.bz2
gst-plugins-bad-b8a18741d88bd208d15918655a33f9b42bd614e6.zip
Fix leaks.
Original commit message from CVS: * ext/amrwb/gstamrwbdec.c: (gst_amrwbdec_init): * ext/amrwb/gstamrwbenc.c: (gst_amrwbenc_init): * ext/amrwb/gstamrwbparse.c: (gst_amrwbparse_init): * ext/audioresample/gstaudioresample.c: * ext/bz2/gstbz2dec.c: (gst_bz2dec_init): * ext/bz2/gstbz2enc.c: (gst_bz2enc_init): * ext/divx/gstdivxdec.c: (gst_divxdec_init): * ext/divx/gstdivxenc.c: (gst_divxenc_init): * ext/faac/gstfaac.c: (gst_faac_init): * ext/gsm/gstgsmdec.c: (gst_gsmdec_init): * ext/gsm/gstgsmenc.c: (gst_gsmenc_init): * ext/hermes/gsthermescolorspace.c: (gst_hermes_colorspace_init): * ext/lcs/gstcolorspace.c: (gst_colorspace_init): * ext/libfame/gstlibfame.c: (gst_fameenc_init): * ext/snapshot/gstsnapshot.c: (gst_snapshot_init): * ext/spc/gstspc.c: (gst_spc_dec_init): * ext/swfdec/gstswfdec.c: (gst_swfdec_init): * ext/xvid/gstxvidenc.c: (gst_xvidenc_init): * gst/cdxaparse/gstcdxaparse.c: (gst_cdxa_parse_init): * gst/cdxaparse/gstcdxastrip.c: (gst_cdxastrip_init): * gst/chart/gstchart.c: (gst_chart_init): * gst/colorspace/gstcolorspace.c: (gst_colorspace_init): * gst/festival/gstfestival.c: (gst_festival_init): * gst/freeze/gstfreeze.c: (gst_freeze_init): * gst/mixmatrix/mixmatrix.c: (gst_mixmatrix_request_new_pad): * gst/mpeg1sys/gstmpeg1systemencode.c: (gst_system_encode_init): * gst/mpeg2sub/gstmpeg2subt.c: (gst_mpeg2subt_init): * gst/nsf/gstnsf.c: (gst_nsfdec_init): * gst/overlay/gstoverlay.c: (gst_overlay_init): * gst/passthrough/gstpassthrough.c: (passthrough_init): * gst/playondemand/gstplayondemand.c: (play_on_demand_init): * gst/smooth/gstsmooth.c: (gst_smooth_init): * gst/smoothwave/gstsmoothwave.c: (gst_smoothwave_init): * gst/speed/gstspeed.c: (speed_init): * gst/vbidec/gstvbidec.c: (gst_vbidec_init): * gst/videodrop/gstvideodrop.c: (gst_videodrop_init): * sys/dxr3/dxr3spusink.c: (dxr3spusink_init): * sys/dxr3/dxr3videosink.c: (dxr3videosink_init): * sys/qcam/gstqcamsrc.c: (gst_qcamsrc_init): Fix leaks.
Diffstat (limited to 'gst')
-rw-r--r--gst/cdxaparse/gstcdxaparse.c6
-rw-r--r--gst/cdxaparse/gstcdxastrip.c6
-rw-r--r--gst/cdxaparse/gstvcdparse.c6
-rw-r--r--gst/chart/gstchart.c8
-rw-r--r--gst/colorspace/gstcolorspace.c6
-rw-r--r--gst/festival/gstfestival.c6
-rw-r--r--gst/freeze/gstfreeze.c7
-rw-r--r--gst/mixmatrix/mixmatrix.c8
-rw-r--r--gst/mpeg1sys/gstmpeg1systemencode.c3
-rw-r--r--gst/mpeg2sub/gstmpeg2subt.c10
-rw-r--r--gst/nsf/gstnsf.c8
-rw-r--r--gst/overlay/gstoverlay.c12
-rw-r--r--gst/passthrough/gstpassthrough.c6
-rw-r--r--gst/playondemand/gstplayondemand.c6
-rw-r--r--gst/smooth/gstsmooth.c6
-rw-r--r--gst/smoothwave/gstsmoothwave.c7
-rw-r--r--gst/speed/gstspeed.c6
-rw-r--r--gst/vbidec/gstvbidec.c6
-rw-r--r--gst/videodrop/gstvideodrop.c6
19 files changed, 41 insertions, 88 deletions
diff --git a/gst/cdxaparse/gstcdxaparse.c b/gst/cdxaparse/gstcdxaparse.c
index 3a302af3..1169cef3 100644
--- a/gst/cdxaparse/gstcdxaparse.c
+++ b/gst/cdxaparse/gstcdxaparse.c
@@ -92,8 +92,7 @@ gst_cdxa_parse_init (GstCDXAParse * cdxaparse, GstCDXAParseClass * klass)
GstCaps *caps;
cdxaparse->sinkpad =
- gst_pad_new_from_template (gst_static_pad_template_get
- (&sink_template_factory), "sink");
+ gst_pad_new_from_static_template (&sink_template_factory, "sink");
gst_pad_set_activate_function (cdxaparse->sinkpad,
GST_DEBUG_FUNCPTR (gst_cdxa_parse_sink_activate));
gst_pad_set_activatepull_function (cdxaparse->sinkpad,
@@ -102,8 +101,7 @@ gst_cdxa_parse_init (GstCDXAParse * cdxaparse, GstCDXAParseClass * klass)
gst_element_add_pad (GST_ELEMENT (cdxaparse), cdxaparse->sinkpad);
cdxaparse->srcpad =
- gst_pad_new_from_template (gst_static_pad_template_get
- (&src_template_factory), "src");
+ gst_pad_new_from_static_template (&src_template_factory, "src");
gst_pad_set_event_function (cdxaparse->srcpad,
GST_DEBUG_FUNCPTR (gst_cdxa_parse_src_event));
diff --git a/gst/cdxaparse/gstcdxastrip.c b/gst/cdxaparse/gstcdxastrip.c
index 00124b30..80bf7c87 100644
--- a/gst/cdxaparse/gstcdxastrip.c
+++ b/gst/cdxaparse/gstcdxastrip.c
@@ -116,14 +116,12 @@ gst_cdxastrip_init (GstCDXAStrip * cdxastrip)
GST_OBJECT_FLAG_SET (cdxastrip, GST_ELEMENT_EVENT_AWARE);
cdxastrip->sinkpad =
- gst_pad_new_from_template (gst_static_pad_template_get
- (&sink_template_factory), "sink");
+ gst_pad_new_from_static_template (&sink_template_factory, "sink");
gst_pad_set_chain_function (cdxastrip->sinkpad, gst_cdxastrip_chain);
gst_element_add_pad (GST_ELEMENT (cdxastrip), cdxastrip->sinkpad);
cdxastrip->srcpad =
- gst_pad_new_from_template (gst_static_pad_template_get
- (&src_template_factory), "src");
+ gst_pad_new_from_static_template (&src_template_factory, "src");
gst_pad_set_formats_function (cdxastrip->srcpad,
gst_cdxastrip_get_src_formats);
gst_pad_set_event_mask_function (cdxastrip->srcpad,
diff --git a/gst/cdxaparse/gstvcdparse.c b/gst/cdxaparse/gstvcdparse.c
index 00124b30..80bf7c87 100644
--- a/gst/cdxaparse/gstvcdparse.c
+++ b/gst/cdxaparse/gstvcdparse.c
@@ -116,14 +116,12 @@ gst_cdxastrip_init (GstCDXAStrip * cdxastrip)
GST_OBJECT_FLAG_SET (cdxastrip, GST_ELEMENT_EVENT_AWARE);
cdxastrip->sinkpad =
- gst_pad_new_from_template (gst_static_pad_template_get
- (&sink_template_factory), "sink");
+ gst_pad_new_from_static_template (&sink_template_factory, "sink");
gst_pad_set_chain_function (cdxastrip->sinkpad, gst_cdxastrip_chain);
gst_element_add_pad (GST_ELEMENT (cdxastrip), cdxastrip->sinkpad);
cdxastrip->srcpad =
- gst_pad_new_from_template (gst_static_pad_template_get
- (&src_template_factory), "src");
+ gst_pad_new_from_static_template (&src_template_factory, "src");
gst_pad_set_formats_function (cdxastrip->srcpad,
gst_cdxastrip_get_src_formats);
gst_pad_set_event_mask_function (cdxastrip->srcpad,
diff --git a/gst/chart/gstchart.c b/gst/chart/gstchart.c
index d5531e7a..775e37cc 100644
--- a/gst/chart/gstchart.c
+++ b/gst/chart/gstchart.c
@@ -172,12 +172,8 @@ static void
gst_chart_init (GstChart * chart)
{
/* create the sink and src pads */
- chart->sinkpad =
- gst_pad_new_from_template (gst_static_pad_template_get (&sink_factory),
- "sink");
- chart->srcpad =
- gst_pad_new_from_template (gst_static_pad_template_get (&src_factory),
- "src");
+ chart->sinkpad = gst_pad_new_from_static_template (&sink_factory, "sink");
+ chart->srcpad = gst_pad_new_from_static_template (&src_factory, "src");
gst_element_add_pad (GST_ELEMENT (chart), chart->sinkpad);
gst_element_add_pad (GST_ELEMENT (chart), chart->srcpad);
diff --git a/gst/colorspace/gstcolorspace.c b/gst/colorspace/gstcolorspace.c
index deed9c15..59339bf6 100644
--- a/gst/colorspace/gstcolorspace.c
+++ b/gst/colorspace/gstcolorspace.c
@@ -516,16 +516,14 @@ static void
gst_colorspace_init (GstColorspace * space)
{
space->sinkpad =
- gst_pad_new_from_template (gst_static_pad_template_get
- (&gst_colorspace_sink_template), "sink");
+ gst_pad_new_from_static_template (&gst_colorspace_sink_template, "sink");
gst_pad_set_link_function (space->sinkpad, gst_colorspace_link);
gst_pad_set_getcaps_function (space->sinkpad, gst_colorspace_getcaps);
gst_pad_set_chain_function (space->sinkpad, gst_colorspace_chain);
gst_element_add_pad (GST_ELEMENT (space), space->sinkpad);
space->srcpad =
- gst_pad_new_from_template (gst_static_pad_template_get
- (&gst_colorspace_src_template), "src");
+ gst_pad_new_from_static_template (&gst_colorspace_src_template, "src");
gst_element_add_pad (GST_ELEMENT (space), space->srcpad);
gst_pad_set_link_function (space->srcpad, gst_colorspace_link);
}
diff --git a/gst/festival/gstfestival.c b/gst/festival/gstfestival.c
index 0559af86..f63e0b73 100644
--- a/gst/festival/gstfestival.c
+++ b/gst/festival/gstfestival.c
@@ -186,14 +186,12 @@ static void
gst_festival_init (GstFestival * festival)
{
festival->sinkpad =
- gst_pad_new_from_template (gst_static_pad_template_get
- (&sink_template_factory), "sink");
+ gst_pad_new_from_static_template (&sink_template_factory, "sink");
gst_pad_set_chain_function (festival->sinkpad, gst_festival_chain);
gst_element_add_pad (GST_ELEMENT (festival), festival->sinkpad);
festival->srcpad =
- gst_pad_new_from_template (gst_static_pad_template_get
- (&src_template_factory), "src");
+ gst_pad_new_from_static_template (&src_template_factory, "src");
gst_element_add_pad (GST_ELEMENT (festival), festival->srcpad);
festival->info = festival_default_info ();
diff --git a/gst/freeze/gstfreeze.c b/gst/freeze/gstfreeze.c
index 40617245..5b6a688d 100644
--- a/gst/freeze/gstfreeze.c
+++ b/gst/freeze/gstfreeze.c
@@ -111,8 +111,7 @@ static void
gst_freeze_init (GstFreeze * freeze, GstFreezeClass * klass)
{
freeze->sinkpad =
- gst_pad_new_from_template (gst_static_pad_template_get
- (&gst_freeze_sink_template), "sink");
+ gst_pad_new_from_static_template (&gst_freeze_sink_template, "sink");
gst_element_add_pad (GST_ELEMENT (freeze), freeze->sinkpad);
gst_pad_set_activate_function (freeze->sinkpad, gst_freeze_sink_activate);
gst_pad_set_activatepull_function (freeze->sinkpad,
@@ -121,8 +120,8 @@ gst_freeze_init (GstFreeze * freeze, GstFreezeClass * klass)
gst_pad_set_getcaps_function (freeze->sinkpad, gst_pad_proxy_getcaps);
gst_pad_set_event_function (freeze->sinkpad, gst_freeze_sink_event);
- freeze->srcpad = gst_pad_new_from_template (gst_static_pad_template_get
- (&gst_freeze_src_template), "src");
+ freeze->srcpad =
+ gst_pad_new_from_static_template (&gst_freeze_src_template, "src");
gst_element_add_pad (GST_ELEMENT (freeze), freeze->srcpad);
gst_pad_set_getcaps_function (freeze->srcpad, gst_pad_proxy_getcaps);
diff --git a/gst/mixmatrix/mixmatrix.c b/gst/mixmatrix/mixmatrix.c
index 392cb139..93ca2ab8 100644
--- a/gst/mixmatrix/mixmatrix.c
+++ b/gst/mixmatrix/mixmatrix.c
@@ -381,9 +381,7 @@ gst_mixmatrix_request_new_pad (GstElement * element, GstPadTemplate * templ,
mixmatrix_resize (mix, ROUND_UP (padnum, mix->grpsize),
mix->sinkpadalloc);
- pad =
- gst_pad_new_from_template (gst_static_pad_template_get
- (&mixmatrix_sink_template), name);
+ pad = gst_pad_new_from_static_template (&mixmatrix_sink_template, name);
GST_PAD_ELEMENT_PRIVATE (pad) = GINT_TO_POINTER (padnum);
gst_element_add_pad (GST_ELEMENT (mix), pad);
/* g_signal_connect(G_OBJECT(pad), "unlink", G_CALLBACK(sink_unlinked), mix); */
@@ -405,9 +403,7 @@ gst_mixmatrix_request_new_pad (GstElement * element, GstPadTemplate * templ,
if (padnum >= mix->srcpadalloc)
mixmatrix_resize (mix, ROUND_UP (padnum, mix->grpsize), mix->srcpadalloc);
- pad =
- gst_pad_new_from_template (gst_static_pad_template_get
- (&mixmatrix_src_template), name);
+ pad = gst_pad_new_from_static_template (&mixmatrix_src_template, name);
GST_PAD_ELEMENT_PRIVATE (pad) = GINT_TO_POINTER (padnum);
gst_element_add_pad (GST_ELEMENT (mix), pad);
/* g_signal_connect(G_OBJECT(pad), "unlink", G_CALLBACK(sink_unlinked), mix); */
diff --git a/gst/mpeg1sys/gstmpeg1systemencode.c b/gst/mpeg1sys/gstmpeg1systemencode.c
index 4cf8a781..64089567 100644
--- a/gst/mpeg1sys/gstmpeg1systemencode.c
+++ b/gst/mpeg1sys/gstmpeg1systemencode.c
@@ -149,8 +149,7 @@ static void
gst_system_encode_init (GstMPEG1SystemEncode * system_encode)
{
system_encode->srcpad =
- gst_pad_new_from_template (gst_static_pad_template_get (&src_factory),
- "src");
+ gst_pad_new_from_static_template (&src_factory, "src");
gst_element_add_pad (GST_ELEMENT (system_encode), system_encode->srcpad);
system_encode->video_buffer = mpeg1mux_buffer_new (BUFFER_TYPE_VIDEO, 0xE0);
diff --git a/gst/mpeg2sub/gstmpeg2subt.c b/gst/mpeg2sub/gstmpeg2subt.c
index e3baea20..c338853b 100644
--- a/gst/mpeg2sub/gstmpeg2subt.c
+++ b/gst/mpeg2sub/gstmpeg2subt.c
@@ -205,8 +205,7 @@ static void
gst_mpeg2subt_init (GstMpeg2Subt * mpeg2subt)
{
mpeg2subt->videopad =
- gst_pad_new_from_template (gst_static_pad_template_get
- (&video_template), "video");
+ gst_pad_new_from_static_template (&video_template, "video");
gst_element_add_pad (GST_ELEMENT (mpeg2subt), mpeg2subt->videopad);
gst_pad_set_link_function (mpeg2subt->videopad,
GST_DEBUG_FUNCPTR (gst_mpeg2subt_link_video));
@@ -214,13 +213,10 @@ gst_mpeg2subt_init (GstMpeg2Subt * mpeg2subt)
GST_DEBUG_FUNCPTR (gst_mpeg2subt_getcaps_video));
mpeg2subt->subtitlepad =
- gst_pad_new_from_template (gst_static_pad_template_get
- (&subtitle_template), "subtitle");
+ gst_pad_new_from_static_template (&subtitle_template, "subtitle");
gst_element_add_pad (GST_ELEMENT (mpeg2subt), mpeg2subt->subtitlepad);
- mpeg2subt->srcpad =
- gst_pad_new_from_template (gst_static_pad_template_get
- (&src_template), "src");
+ mpeg2subt->srcpad = gst_pad_new_from_static_template (&src_template, "src");
gst_element_add_pad (GST_ELEMENT (mpeg2subt), mpeg2subt->srcpad);
gst_pad_set_getcaps_function (mpeg2subt->srcpad,
GST_DEBUG_FUNCPTR (gst_mpeg2subt_getcaps_video));
diff --git a/gst/nsf/gstnsf.c b/gst/nsf/gstnsf.c
index 5a9194d8..e5b4f332 100644
--- a/gst/nsf/gstnsf.c
+++ b/gst/nsf/gstnsf.c
@@ -180,17 +180,13 @@ gst_nsfdec_class_init (GstNsfDec * klass)
static void
gst_nsfdec_init (GstNsfDec * nsfdec)
{
- nsfdec->sinkpad =
- gst_pad_new_from_template (gst_static_pad_template_get (&sink_templ),
- "sink");
+ nsfdec->sinkpad = gst_pad_new_from_static_template (&sink_templ, "sink");
gst_pad_set_query_function (nsfdec->sinkpad, NULL);
gst_pad_set_event_function (nsfdec->sinkpad, gst_nsfdec_sink_event);
gst_pad_set_chain_function (nsfdec->sinkpad, gst_nsfdec_chain);
gst_element_add_pad (GST_ELEMENT (nsfdec), nsfdec->sinkpad);
- nsfdec->srcpad =
- gst_pad_new_from_template (gst_static_pad_template_get (&src_templ),
- "src");
+ nsfdec->srcpad = gst_pad_new_from_static_template (&src_templ, "src");
gst_pad_set_event_function (nsfdec->srcpad, gst_nsfdec_src_event);
gst_pad_set_query_function (nsfdec->srcpad, gst_nsfdec_src_query);
gst_pad_use_fixed_caps (nsfdec->srcpad);
diff --git a/gst/overlay/gstoverlay.c b/gst/overlay/gstoverlay.c
index 373b29c1..2c6345a9 100644
--- a/gst/overlay/gstoverlay.c
+++ b/gst/overlay/gstoverlay.c
@@ -195,26 +195,22 @@ static void
gst_overlay_init (GstOverlay * overlay)
{
overlay->sinkpad1 =
- gst_pad_new_from_template (gst_static_pad_template_get
- (&overlay_sink1_factory), "sink1");
+ gst_pad_new_from_static_template (&overlay_sink1_factory, "sink1");
gst_pad_set_link_function (overlay->sinkpad1, gst_overlay_sinkconnect);
gst_element_add_pad (GST_ELEMENT (overlay), overlay->sinkpad1);
overlay->sinkpad2 =
- gst_pad_new_from_template (gst_static_pad_template_get
- (&overlay_sink2_factory), "sink2");
+ gst_pad_new_from_static_template (&overlay_sink2_factory, "sink2");
gst_pad_set_link_function (overlay->sinkpad2, gst_overlay_sinkconnect);
gst_element_add_pad (GST_ELEMENT (overlay), overlay->sinkpad2);
overlay->sinkpad3 =
- gst_pad_new_from_template (gst_static_pad_template_get
- (&overlay_sink3_factory), "sink3");
+ gst_pad_new_from_static_template (&overlay_sink3_factory, "sink3");
gst_pad_set_link_function (overlay->sinkpad3, gst_overlay_sinkconnect);
gst_element_add_pad (GST_ELEMENT (overlay), overlay->sinkpad3);
overlay->srcpad =
- gst_pad_new_from_template (gst_static_pad_template_get
- (&overlay_src_factory), "src");
+ gst_pad_new_from_static_template (&overlay_src_factory, "src");
gst_element_add_pad (GST_ELEMENT (overlay), overlay->srcpad);
gst_element_set_loop_function (GST_ELEMENT (overlay), gst_overlay_loop);
diff --git a/gst/passthrough/gstpassthrough.c b/gst/passthrough/gstpassthrough.c
index 4524f69f..5ccfe1aa 100644
--- a/gst/passthrough/gstpassthrough.c
+++ b/gst/passthrough/gstpassthrough.c
@@ -193,12 +193,10 @@ static void
passthrough_init (GstPassthrough * filter)
{
filter->srcpad =
- gst_pad_new_from_template (gst_static_pad_template_get
- (&passthrough_src_template), "src");
+ gst_pad_new_from_static_template (&passthrough_src_template, "src");
gst_element_add_pad (GST_ELEMENT (filter), filter->srcpad);
filter->sinkpad =
- gst_pad_new_from_template (gst_static_pad_template_get
- (&passthrough_sink_template), "sink");
+ gst_pad_new_from_static_template (&passthrough_sink_template, "sink");
gst_element_add_pad (GST_ELEMENT (filter), filter->sinkpad);
gst_pad_set_link_function (filter->sinkpad, passthrough_connect_sink);
diff --git a/gst/playondemand/gstplayondemand.c b/gst/playondemand/gstplayondemand.c
index 2309cacb..91eae05c 100644
--- a/gst/playondemand/gstplayondemand.c
+++ b/gst/playondemand/gstplayondemand.c
@@ -236,11 +236,9 @@ static void
play_on_demand_init (GstPlayOnDemand * filter)
{
filter->srcpad =
- gst_pad_new_from_template (gst_static_pad_template_get
- (&play_on_demand_src_template), "src");
+ gst_pad_new_from_static_template (&play_on_demand_src_template, "src");
filter->sinkpad =
- gst_pad_new_from_template (gst_static_pad_template_get
- (&play_on_demand_sink_template), "sink");
+ gst_pad_new_from_static_template (&play_on_demand_sink_template, "sink");
gst_pad_set_link_function (filter->sinkpad, play_on_demand_pad_link);
diff --git a/gst/smooth/gstsmooth.c b/gst/smooth/gstsmooth.c
index 97ecd9dd..b1af76a6 100644
--- a/gst/smooth/gstsmooth.c
+++ b/gst/smooth/gstsmooth.c
@@ -160,15 +160,13 @@ static void
gst_smooth_init (GstSmooth * smooth)
{
smooth->sinkpad =
- gst_pad_new_from_template (gst_static_pad_template_get
- (&gst_smooth_sink_template), "sink");
+ gst_pad_new_from_static_template (&gst_smooth_sink_template, "sink");
gst_pad_set_link_function (smooth->sinkpad, gst_smooth_link);
gst_pad_set_chain_function (smooth->sinkpad, gst_smooth_chain);
gst_element_add_pad (GST_ELEMENT (smooth), smooth->sinkpad);
smooth->srcpad =
- gst_pad_new_from_template (gst_static_pad_template_get
- (&gst_smooth_sink_template), "src");
+ gst_pad_new_from_static_template (&gst_smooth_sink_template, "src");
gst_pad_set_link_function (smooth->srcpad, gst_smooth_link);
gst_element_add_pad (GST_ELEMENT (smooth), smooth->srcpad);
diff --git a/gst/smoothwave/gstsmoothwave.c b/gst/smoothwave/gstsmoothwave.c
index a0ee5e7c..3a2a23b0 100644
--- a/gst/smoothwave/gstsmoothwave.c
+++ b/gst/smoothwave/gstsmoothwave.c
@@ -156,11 +156,8 @@ gst_smoothwave_init (GstSmoothWave * smoothwave)
int i;
smoothwave->sinkpad =
- gst_pad_new_from_template (gst_static_pad_template_get (&sink_template),
- "sink");
- smoothwave->srcpad =
- gst_pad_new_from_template (gst_static_pad_template_get (&src_template),
- "src");
+ gst_pad_new_from_static_template (&sink_template, "sink");
+ smoothwave->srcpad = gst_pad_new_from_static_template (&src_template, "src");
gst_element_add_pad (GST_ELEMENT (smoothwave), smoothwave->sinkpad);
gst_pad_set_chain_function (smoothwave->sinkpad, gst_smoothwave_chain);
gst_pad_set_link_function (smoothwave->sinkpad, gst_sw_sinklink);
diff --git a/gst/speed/gstspeed.c b/gst/speed/gstspeed.c
index 1d65f4f1..be80418e 100644
--- a/gst/speed/gstspeed.c
+++ b/gst/speed/gstspeed.c
@@ -490,16 +490,14 @@ static void
speed_init (GstSpeed * filter)
{
filter->sinkpad =
- gst_pad_new_from_template (gst_static_pad_template_get
- (&gst_speed_sink_template), "sink");
+ gst_pad_new_from_static_template (&gst_speed_sink_template, "sink");
gst_pad_set_setcaps_function (filter->sinkpad, speed_setcaps);
gst_pad_set_chain_function (filter->sinkpad, speed_chain);
gst_element_add_pad (GST_ELEMENT (filter), filter->sinkpad);
gst_pad_set_event_function (filter->sinkpad, speed_sink_event);
filter->srcpad =
- gst_pad_new_from_template (gst_static_pad_template_get
- (&gst_speed_src_template), "src");
+ gst_pad_new_from_static_template (&gst_speed_src_template, "src");
gst_pad_set_setcaps_function (filter->srcpad, speed_setcaps);
gst_pad_set_query_type_function (filter->srcpad, speed_get_query_types);
gst_pad_set_query_function (filter->srcpad, speed_src_query);
diff --git a/gst/vbidec/gstvbidec.c b/gst/vbidec/gstvbidec.c
index 4f16e99d..412d1ce2 100644
--- a/gst/vbidec/gstvbidec.c
+++ b/gst/vbidec/gstvbidec.c
@@ -206,15 +206,13 @@ gst_vbidec_init (GstVBIDec * vbidec)
{
/* create the sink and src pads */
vbidec->sinkpad =
- gst_pad_new_from_template (gst_static_pad_template_get
- (&gst_vbidec_sink_template), "sink");
+ gst_pad_new_from_static_template (&gst_vbidec_sink_template, "sink");
gst_element_add_pad (GST_ELEMENT (vbidec), vbidec->sinkpad);
gst_pad_set_chain_function (vbidec->sinkpad,
GST_DEBUG_FUNCPTR (gst_vbidec_chain));
vbidec->srcpad =
- gst_pad_new_from_template (gst_static_pad_template_get
- (&gst_vbidec_src_template), "src");
+ gst_pad_new_from_static_template (&gst_vbidec_src_template, "src");
gst_element_add_pad (GST_ELEMENT (vbidec), vbidec->srcpad);
vbidec->vbiscreen = vbiscreen_new (0, 0, 1.0, 0, (void *) vbidec);
diff --git a/gst/videodrop/gstvideodrop.c b/gst/videodrop/gstvideodrop.c
index 11d7f6f5..9d6c3355 100644
--- a/gst/videodrop/gstvideodrop.c
+++ b/gst/videodrop/gstvideodrop.c
@@ -232,16 +232,14 @@ gst_videodrop_init (GstVideodrop * videodrop)
GST_DEBUG ("gst_videodrop_init");
videodrop->sinkpad =
- gst_pad_new_from_template (gst_static_pad_template_get
- (&gst_videodrop_sink_template), "sink");
+ gst_pad_new_from_static_template (&gst_videodrop_sink_template, "sink");
gst_element_add_pad (GST_ELEMENT (videodrop), videodrop->sinkpad);
gst_pad_set_chain_function (videodrop->sinkpad, gst_videodrop_chain);
gst_pad_set_getcaps_function (videodrop->sinkpad, gst_videodrop_getcaps);
gst_pad_set_link_function (videodrop->sinkpad, gst_videodrop_link);
videodrop->srcpad =
- gst_pad_new_from_template (gst_static_pad_template_get
- (&gst_videodrop_src_template), "src");
+ gst_pad_new_from_static_template (&gst_videodrop_src_template, "src");
gst_element_add_pad (GST_ELEMENT (videodrop), videodrop->srcpad);
gst_pad_set_getcaps_function (videodrop->srcpad, gst_videodrop_getcaps);
gst_pad_set_link_function (videodrop->srcpad, gst_videodrop_link);