summaryrefslogtreecommitdiffstats
path: root/ext
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 /ext
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 'ext')
-rw-r--r--ext/amrwb/gstamrwbdec.c8
-rw-r--r--ext/amrwb/gstamrwbenc.c8
-rw-r--r--ext/amrwb/gstamrwbparse.c7
-rw-r--r--ext/audioresample/gstaudioresample.c7
-rw-r--r--ext/bz2/gstbz2dec.c8
-rw-r--r--ext/bz2/gstbz2enc.c8
-rw-r--r--ext/divx/gstdivxdec.c8
-rw-r--r--ext/divx/gstdivxenc.c8
-rw-r--r--ext/faac/gstfaac.c8
-rw-r--r--ext/gsm/gstgsmdec.c6
-rw-r--r--ext/gsm/gstgsmenc.c6
-rw-r--r--ext/hermes/gsthermescolorspace.c8
-rw-r--r--ext/lcs/gstcolorspace.c6
-rw-r--r--ext/libfame/gstlibfame.c8
-rw-r--r--ext/snapshot/gstsnapshot.c6
-rw-r--r--ext/spc/gstspc.c8
-rw-r--r--ext/swfdec/gstswfdec.c9
-rw-r--r--ext/xvid/gstxvidenc.c8
18 files changed, 40 insertions, 95 deletions
diff --git a/ext/amrwb/gstamrwbdec.c b/ext/amrwb/gstamrwbdec.c
index 792addd7..57de2c7a 100644
--- a/ext/amrwb/gstamrwbdec.c
+++ b/ext/amrwb/gstamrwbdec.c
@@ -97,18 +97,14 @@ static void
gst_amrwbdec_init (GstAmrwbDec * amrwbdec, GstAmrwbDecClass * klass)
{
/* create the sink pad */
- amrwbdec->sinkpad =
- gst_pad_new_from_template (gst_static_pad_template_get (&sink_template),
- "sink");
+ amrwbdec->sinkpad = gst_pad_new_from_static_template (&sink_template, "sink");
gst_pad_set_setcaps_function (amrwbdec->sinkpad, gst_amrwbdec_setcaps);
gst_pad_set_event_function (amrwbdec->sinkpad, gst_amrwbdec_event);
gst_pad_set_chain_function (amrwbdec->sinkpad, gst_amrwbdec_chain);
gst_element_add_pad (GST_ELEMENT (amrwbdec), amrwbdec->sinkpad);
/* create the src pad */
- amrwbdec->srcpad =
- gst_pad_new_from_template (gst_static_pad_template_get (&src_template),
- "src");
+ amrwbdec->srcpad = gst_pad_new_from_static_template (&src_template, "src");
gst_pad_use_fixed_caps (amrwbdec->srcpad);
gst_element_add_pad (GST_ELEMENT (amrwbdec), amrwbdec->srcpad);
diff --git a/ext/amrwb/gstamrwbenc.c b/ext/amrwb/gstamrwbenc.c
index 0d8e91e0..52f303cd 100644
--- a/ext/amrwb/gstamrwbenc.c
+++ b/ext/amrwb/gstamrwbenc.c
@@ -89,17 +89,13 @@ static void
gst_amrwbenc_init (GstAmrwbEnc * amrwbenc, GstAmrwbEncClass * klass)
{
/* create the sink pad */
- amrwbenc->sinkpad =
- gst_pad_new_from_template (gst_static_pad_template_get (&sink_template),
- "sink");
+ amrwbenc->sinkpad = gst_pad_new_from_static_template (&sink_template, "sink");
gst_pad_set_setcaps_function (amrwbenc->sinkpad, gst_amrwbenc_setcaps);
gst_pad_set_chain_function (amrwbenc->sinkpad, gst_amrwbenc_chain);
gst_element_add_pad (GST_ELEMENT (amrwbenc), amrwbenc->sinkpad);
/* create the src pad */
- amrwbenc->srcpad =
- gst_pad_new_from_template (gst_static_pad_template_get (&src_template),
- "src");
+ amrwbenc->srcpad = gst_pad_new_from_static_template (&src_template, "src");
gst_pad_use_fixed_caps (amrwbenc->srcpad);
gst_element_add_pad (GST_ELEMENT (amrwbenc), amrwbenc->srcpad);
diff --git a/ext/amrwb/gstamrwbparse.c b/ext/amrwb/gstamrwbparse.c
index b233878c..d5afc6df 100644
--- a/ext/amrwb/gstamrwbparse.c
+++ b/ext/amrwb/gstamrwbparse.c
@@ -95,8 +95,7 @@ gst_amrwbparse_init (GstAmrwbParse * amrwbparse, GstAmrwbParseClass * klass)
{
/* create the sink pad */
amrwbparse->sinkpad =
- gst_pad_new_from_template (gst_static_pad_template_get (&sink_template),
- "sink");
+ gst_pad_new_from_static_template (&sink_template, "sink");
gst_pad_set_chain_function (amrwbparse->sinkpad,
GST_DEBUG_FUNCPTR (gst_amrwbparse_chain));
@@ -108,9 +107,7 @@ gst_amrwbparse_init (GstAmrwbParse * amrwbparse, GstAmrwbParseClass * klass)
gst_element_add_pad (GST_ELEMENT (amrwbparse), amrwbparse->sinkpad);
/* create the src pad */
- amrwbparse->srcpad =
- gst_pad_new_from_template (gst_static_pad_template_get (&src_template),
- "src");
+ amrwbparse->srcpad = gst_pad_new_from_static_template (&src_template, "src");
gst_pad_set_query_function (amrwbparse->srcpad,
GST_DEBUG_FUNCPTR (gst_amrwbparse_query));
gst_pad_set_query_type_function (amrwbparse->srcpad,
diff --git a/ext/audioresample/gstaudioresample.c b/ext/audioresample/gstaudioresample.c
index acba8b3e..6b63db33 100644
--- a/ext/audioresample/gstaudioresample.c
+++ b/ext/audioresample/gstaudioresample.c
@@ -282,8 +282,8 @@ static void gst_audioresample_init (Audioresample * audioresample)
ResampleState *r;
audioresample->sinkpad =
- gst_pad_new_from_template (gst_static_pad_template_get
- (&gst_audioresample_sink_template), "sink");
+ gst_pad_new_from_static_template (&gst_audioresample_sink_template,
+ "sink");
gst_element_add_pad (GST_ELEMENT (audioresample), audioresample->sinkpad);
gst_pad_set_chain_function (audioresample->sinkpad, gst_audioresample_chain);
gst_pad_set_link_function (audioresample->sinkpad, gst_audioresample_link);
@@ -293,8 +293,7 @@ static void gst_audioresample_init (Audioresample * audioresample)
gst_audioresample_fixate);
audioresample->srcpad =
- gst_pad_new_from_template (gst_static_pad_template_get
- (&gst_audioresample_src_template), "src");
+ gst_pad_new_from_static_template (&gst_audioresample_src_template, "src");
gst_element_add_pad (GST_ELEMENT (audioresample), audioresample->srcpad);
gst_pad_set_link_function (audioresample->srcpad, gst_audioresample_link);
diff --git a/ext/bz2/gstbz2dec.c b/ext/bz2/gstbz2dec.c
index f4b3a8d9..1017261a 100644
--- a/ext/bz2/gstbz2dec.c
+++ b/ext/bz2/gstbz2dec.c
@@ -179,14 +179,10 @@ gst_bz2dec_init (GstBz2dec * b, GstBz2decClass * klass)
b->first_buffer_size = DEFAULT_FIRST_BUFFER_SIZE;
b->buffer_size = DEFAULT_BUFFER_SIZE;
- pad =
- gst_pad_new_from_template (gst_static_pad_template_get (&sink_template),
- "sink");
+ pad = gst_pad_new_from_static_template (&sink_template, "sink");
gst_pad_set_chain_function (pad, gst_bz2dec_chain);
gst_element_add_pad (GST_ELEMENT (b), pad);
- pad =
- gst_pad_new_from_template (gst_static_pad_template_get (&src_template),
- "src");
+ pad = gst_pad_new_from_static_template (&src_template, "src");
gst_element_add_pad (GST_ELEMENT (b), pad);
gst_pad_use_fixed_caps (pad);
diff --git a/ext/bz2/gstbz2enc.c b/ext/bz2/gstbz2enc.c
index e8bb2341..ed5a354b 100644
--- a/ext/bz2/gstbz2enc.c
+++ b/ext/bz2/gstbz2enc.c
@@ -210,15 +210,11 @@ gst_bz2enc_init (GstBz2enc * b, GstBz2encClass * klass)
{
GstPad *pad;
- pad =
- gst_pad_new_from_template (gst_static_pad_template_get (&sink_template),
- "sink");
+ pad = gst_pad_new_from_static_template (&sink_template, "sink");
gst_pad_set_chain_function (pad, gst_bz2enc_chain);
gst_pad_set_event_function (pad, gst_bz2enc_event);
gst_element_add_pad (GST_ELEMENT (b), pad);
- pad =
- gst_pad_new_from_template (gst_static_pad_template_get (&src_template),
- "src");
+ pad = gst_pad_new_from_static_template (&src_template, "src");
gst_element_add_pad (GST_ELEMENT (b), pad);
b->block_size = DEFAULT_BLOCK_SIZE;
diff --git a/ext/divx/gstdivxdec.c b/ext/divx/gstdivxdec.c
index dfc8ffd8..1e4460ed 100644
--- a/ext/divx/gstdivxdec.c
+++ b/ext/divx/gstdivxdec.c
@@ -163,17 +163,13 @@ static void
gst_divxdec_init (GstDivxDec * divxdec)
{
/* create the sink pad */
- divxdec->sinkpad =
- gst_pad_new_from_template (gst_static_pad_template_get (&sink_template),
- "sink");
+ divxdec->sinkpad = gst_pad_new_from_static_template (&sink_template, "sink");
gst_element_add_pad (GST_ELEMENT (divxdec), divxdec->sinkpad);
gst_pad_set_chain_function (divxdec->sinkpad, gst_divxdec_chain);
gst_pad_set_setcaps_function (divxdec->sinkpad, gst_divxdec_connect);
/* create the src pad */
- divxdec->srcpad =
- gst_pad_new_from_template (gst_static_pad_template_get (&src_template),
- "src");
+ divxdec->srcpad = gst_pad_new_from_static_template (&src_template, "src");
gst_element_add_pad (GST_ELEMENT (divxdec), divxdec->srcpad);
gst_pad_use_fixed_caps (divxdec->srcpad);
diff --git a/ext/divx/gstdivxenc.c b/ext/divx/gstdivxenc.c
index 6fb449c9..ab970ba7 100644
--- a/ext/divx/gstdivxenc.c
+++ b/ext/divx/gstdivxenc.c
@@ -198,18 +198,14 @@ static void
gst_divxenc_init (GstDivxEnc * divxenc)
{
/* create the sink pad */
- divxenc->sinkpad =
- gst_pad_new_from_template (gst_static_pad_template_get (&sink_template),
- "sink");
+ divxenc->sinkpad = gst_pad_new_from_static_template (&sink_template, "sink");
gst_element_add_pad (GST_ELEMENT (divxenc), divxenc->sinkpad);
gst_pad_set_chain_function (divxenc->sinkpad, gst_divxenc_chain);
gst_pad_set_setcaps_function (divxenc->sinkpad, gst_divxenc_setcaps);
/* create the src pad */
- divxenc->srcpad =
- gst_pad_new_from_template (gst_static_pad_template_get (&src_template),
- "src");
+ divxenc->srcpad = gst_pad_new_from_static_template (&src_template, "src");
gst_pad_use_fixed_caps (divxenc->srcpad);
gst_element_add_pad (GST_ELEMENT (divxenc), divxenc->srcpad);
diff --git a/ext/faac/gstfaac.c b/ext/faac/gstfaac.c
index 4291cc82..959e5d1a 100644
--- a/ext/faac/gstfaac.c
+++ b/ext/faac/gstfaac.c
@@ -251,9 +251,7 @@ gst_faac_init (GstFaac * faac)
faac->cache_time = GST_CLOCK_TIME_NONE;
faac->cache_duration = 0;
- faac->sinkpad =
- gst_pad_new_from_template (gst_static_pad_template_get (&sink_template),
- "sink");
+ faac->sinkpad = gst_pad_new_from_static_template (&sink_template, "sink");
gst_pad_set_chain_function (faac->sinkpad,
GST_DEBUG_FUNCPTR (gst_faac_chain));
gst_pad_set_setcaps_function (faac->sinkpad,
@@ -262,9 +260,7 @@ gst_faac_init (GstFaac * faac)
GST_DEBUG_FUNCPTR (gst_faac_sink_event));
gst_element_add_pad (GST_ELEMENT (faac), faac->sinkpad);
- faac->srcpad =
- gst_pad_new_from_template (gst_static_pad_template_get (&src_template),
- "src");
+ faac->srcpad = gst_pad_new_from_static_template (&src_template, "src");
gst_pad_use_fixed_caps (faac->srcpad);
gst_element_add_pad (GST_ELEMENT (faac), faac->srcpad);
diff --git a/ext/gsm/gstgsmdec.c b/ext/gsm/gstgsmdec.c
index 412aaf68..c20c72a8 100644
--- a/ext/gsm/gstgsmdec.c
+++ b/ext/gsm/gstgsmdec.c
@@ -139,16 +139,14 @@ gst_gsmdec_init (GstGSMDec * gsmdec)
{
/* create the sink and src pads */
gsmdec->sinkpad =
- gst_pad_new_from_template (gst_static_pad_template_get
- (&gsmdec_sink_template), "sink");
+ gst_pad_new_from_static_template (&gsmdec_sink_template, "sink");
gst_pad_set_setcaps_function (gsmdec->sinkpad, gst_gsmdec_sink_setcaps);
gst_pad_set_event_function (gsmdec->sinkpad, gst_gsmdec_sink_event);
gst_pad_set_chain_function (gsmdec->sinkpad, gst_gsmdec_chain);
gst_element_add_pad (GST_ELEMENT (gsmdec), gsmdec->sinkpad);
gsmdec->srcpad =
- gst_pad_new_from_template (gst_static_pad_template_get
- (&gsmdec_src_template), "src");
+ gst_pad_new_from_static_template (&gsmdec_src_template, "src");
gst_element_add_pad (GST_ELEMENT (gsmdec), gsmdec->srcpad);
gsmdec->state = gsm_create ();
diff --git a/ext/gsm/gstgsmenc.c b/ext/gsm/gstgsmenc.c
index 47636f99..ffd629a1 100644
--- a/ext/gsm/gstgsmenc.c
+++ b/ext/gsm/gstgsmenc.c
@@ -137,15 +137,13 @@ gst_gsmenc_init (GstGSMEnc * gsmenc)
/* create the sink and src pads */
gsmenc->sinkpad =
- gst_pad_new_from_template (gst_static_pad_template_get
- (&gsmenc_sink_template), "sink");
+ gst_pad_new_from_static_template (&gsmenc_sink_template, "sink");
gst_pad_set_chain_function (gsmenc->sinkpad, gst_gsmenc_chain);
gst_pad_set_setcaps_function (gsmenc->sinkpad, gst_gsmenc_setcaps);
gst_element_add_pad (GST_ELEMENT (gsmenc), gsmenc->sinkpad);
gsmenc->srcpad =
- gst_pad_new_from_template (gst_static_pad_template_get
- (&gsmenc_src_template), "src");
+ gst_pad_new_from_static_template (&gsmenc_src_template, "src");
gst_element_add_pad (GST_ELEMENT (gsmenc), gsmenc->srcpad);
gsmenc->state = gsm_create ();
diff --git a/ext/hermes/gsthermescolorspace.c b/ext/hermes/gsthermescolorspace.c
index cf13504e..fdf4f154 100644
--- a/ext/hermes/gsthermescolorspace.c
+++ b/ext/hermes/gsthermescolorspace.c
@@ -537,16 +537,16 @@ static void
gst_hermes_colorspace_init (GstHermesColorspace * space)
{
space->sinkpad =
- gst_pad_new_from_template (gst_static_pad_template_get
- (&gst_hermes_colorspace_sink_pad_template), "sink");
+ gst_pad_new_from_static_template
+ (&gst_hermes_colorspace_sink_pad_template, "sink");
gst_pad_set_link_function (space->sinkpad, gst_hermes_colorspace_link);
gst_pad_set_getcaps_function (space->sinkpad, gst_hermes_colorspace_getcaps);
gst_pad_set_chain_function (space->sinkpad, gst_hermes_colorspace_chain);
gst_element_add_pad (GST_ELEMENT (space), space->sinkpad);
space->srcpad =
- gst_pad_new_from_template (gst_static_pad_template_get
- (&gst_hermes_colorspace_src_pad_template), "src");
+ gst_pad_new_from_static_template (&gst_hermes_colorspace_src_pad_template,
+ "src");
gst_element_add_pad (GST_ELEMENT (space), space->srcpad);
gst_pad_set_link_function (space->srcpad, gst_hermes_colorspace_link);
diff --git a/ext/lcs/gstcolorspace.c b/ext/lcs/gstcolorspace.c
index 2299aaf4..cdf8cb83 100644
--- a/ext/lcs/gstcolorspace.c
+++ b/ext/lcs/gstcolorspace.c
@@ -370,16 +370,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/ext/libfame/gstlibfame.c b/ext/libfame/gstlibfame.c
index c921eb1c..b1727371 100644
--- a/ext/libfame/gstlibfame.c
+++ b/ext/libfame/gstlibfame.c
@@ -363,16 +363,12 @@ gst_fameenc_init (GstFameEnc * fameenc)
g_assert (fameenc->fc != NULL);
/* create the sink and src pads */
- fameenc->sinkpad =
- gst_pad_new_from_template (gst_static_pad_template_get (&sink_template),
- "sink");
+ fameenc->sinkpad = gst_pad_new_from_static_template (&sink_template, "sink");
gst_element_add_pad (GST_ELEMENT (fameenc), fameenc->sinkpad);
gst_pad_set_chain_function (fameenc->sinkpad, gst_fameenc_chain);
gst_pad_set_link_function (fameenc->sinkpad, gst_fameenc_sink_link);
- fameenc->srcpad =
- gst_pad_new_from_template (gst_static_pad_template_get (&src_template),
- "src");
+ fameenc->srcpad = gst_pad_new_from_static_template (&src_template, "src");
gst_element_add_pad (GST_ELEMENT (fameenc), fameenc->srcpad);
/* FIXME: set some more handler functions here */
diff --git a/ext/snapshot/gstsnapshot.c b/ext/snapshot/gstsnapshot.c
index 1e336ec8..185c0630 100644
--- a/ext/snapshot/gstsnapshot.c
+++ b/ext/snapshot/gstsnapshot.c
@@ -194,15 +194,13 @@ static void
gst_snapshot_init (GstSnapshot * snapshot)
{
snapshot->sinkpad =
- gst_pad_new_from_template (gst_static_pad_template_get
- (&snapshot_sink_factory), "sink");
+ gst_pad_new_from_static_template (&snapshot_sink_factory, "sink");
gst_pad_set_link_function (snapshot->sinkpad, gst_snapshot_sinkconnect);
gst_pad_set_chain_function (snapshot->sinkpad, gst_snapshot_chain);
gst_element_add_pad (GST_ELEMENT (snapshot), snapshot->sinkpad);
snapshot->srcpad =
- gst_pad_new_from_template (gst_static_pad_template_get
- (&snapshot_src_factory), "src");
+ gst_pad_new_from_static_template (&snapshot_src_factory, "src");
gst_element_add_pad (GST_ELEMENT (snapshot), snapshot->srcpad);
snapshot->cur_frame = 0;
diff --git a/ext/spc/gstspc.c b/ext/spc/gstspc.c
index aed588bd..8c24c650 100644
--- a/ext/spc/gstspc.c
+++ b/ext/spc/gstspc.c
@@ -124,17 +124,13 @@ gst_spc_dec_class_init (GstSpcDecClass * klass)
static void
gst_spc_dec_init (GstSpcDec * spc, GstSpcDecClass * klass)
{
- spc->sinkpad =
- gst_pad_new_from_template (gst_static_pad_template_get (&sink_factory),
- "sink");
+ spc->sinkpad = gst_pad_new_from_static_template (&sink_factory, "sink");
gst_pad_set_query_function (spc->sinkpad, NULL);
gst_pad_set_event_function (spc->sinkpad, gst_spc_dec_sink_event);
gst_pad_set_chain_function (spc->sinkpad, gst_spc_dec_chain);
gst_element_add_pad (GST_ELEMENT (spc), spc->sinkpad);
- spc->srcpad =
- gst_pad_new_from_template (gst_static_pad_template_get (&src_factory),
- "src");
+ spc->srcpad = gst_pad_new_from_static_template (&src_factory, "src");
gst_pad_set_event_function (spc->srcpad, gst_spc_dec_src_event);
gst_pad_set_query_function (spc->srcpad, gst_spc_dec_src_query);
gst_pad_use_fixed_caps (spc->srcpad);
diff --git a/ext/swfdec/gstswfdec.c b/ext/swfdec/gstswfdec.c
index aba025c7..19e819e3 100644
--- a/ext/swfdec/gstswfdec.c
+++ b/ext/swfdec/gstswfdec.c
@@ -536,16 +536,14 @@ gst_swfdec_init (GstSwfdec * swfdec)
{
/* create the sink and src pads */
swfdec->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_element_add_pad (GST_ELEMENT (swfdec), swfdec->sinkpad);
gst_pad_set_chain_function (swfdec->sinkpad, gst_swfdec_chain);
gst_pad_set_event_function (swfdec->sinkpad, gst_swfdec_sink_event);
swfdec->videopad =
- gst_pad_new_from_template (gst_static_pad_template_get
- (&video_template_factory), "video_00");
+ gst_pad_new_from_static_template (&video_template_factory, "video_00");
gst_pad_set_query_function (swfdec->videopad, gst_swfdec_src_query);
gst_pad_set_getcaps_function (swfdec->videopad, gst_swfdec_video_getcaps);
gst_pad_set_setcaps_function (swfdec->videopad, gst_swfdec_video_link);
@@ -557,8 +555,7 @@ gst_swfdec_init (GstSwfdec * swfdec)
gst_element_add_pad (GST_ELEMENT (swfdec), swfdec->videopad);
swfdec->audiopad =
- gst_pad_new_from_template (gst_static_pad_template_get
- (&audio_template_factory), "audio_00");
+ gst_pad_new_from_static_template (&audio_template_factory, "audio_00");
gst_pad_set_query_function (swfdec->audiopad, gst_swfdec_src_query);
gst_pad_set_event_function (swfdec->audiopad, gst_swfdec_src_event);
diff --git a/ext/xvid/gstxvidenc.c b/ext/xvid/gstxvidenc.c
index e2cf4aa4..7b77deb0 100644
--- a/ext/xvid/gstxvidenc.c
+++ b/ext/xvid/gstxvidenc.c
@@ -475,9 +475,7 @@ gst_xvidenc_init (GstXvidEnc * xvidenc)
guint i, num_props;
/* create the sink pad */
- xvidenc->sinkpad =
- gst_pad_new_from_template (gst_static_pad_template_get (&sink_template),
- "sink");
+ xvidenc->sinkpad = gst_pad_new_from_static_template (&sink_template, "sink");
gst_element_add_pad (GST_ELEMENT (xvidenc), xvidenc->sinkpad);
gst_pad_set_chain_function (xvidenc->sinkpad,
@@ -488,9 +486,7 @@ gst_xvidenc_init (GstXvidEnc * xvidenc)
GST_DEBUG_FUNCPTR (gst_xvidenc_handle_sink_event));
/* create the src pad */
- xvidenc->srcpad =
- gst_pad_new_from_template (gst_static_pad_template_get (&src_template),
- "src");
+ xvidenc->srcpad = gst_pad_new_from_static_template (&src_template, "src");
gst_element_add_pad (GST_ELEMENT (xvidenc), xvidenc->srcpad);
gst_pad_use_fixed_caps (xvidenc->srcpad);