From f2d5cae8daade402e9d74a829d2b87283167aaa7 Mon Sep 17 00:00:00 2001 From: Andy Wingo Date: Wed, 8 Oct 2003 16:08:18 +0000 Subject: /GstBuffer/GstData/ in the API where you can pass events. Fix the plugins to deal with that. Fixes #113488. Original commit message from CVS: /GstBuffer/GstData/ in the API where you can pass events. Fix the plugins to deal with that. Fixes #113488. --- ext/ladspa/gstladspa.c | 19 ++++++++++--------- 1 file changed, 10 insertions(+), 9 deletions(-) (limited to 'ext/ladspa') diff --git a/ext/ladspa/gstladspa.c b/ext/ladspa/gstladspa.c index 5f16dbf5..f22b4aac 100644 --- a/ext/ladspa/gstladspa.c +++ b/ext/ladspa/gstladspa.c @@ -76,8 +76,8 @@ static void gst_ladspa_deactivate (GstLADSPA *ladspa); static GstElementStateReturn gst_ladspa_change_state (GstElement *element); static void gst_ladspa_loop (GstElement *element); -static void gst_ladspa_chain (GstPad *pad,GstBuffer *buf); -static GstBuffer * gst_ladspa_get (GstPad *pad); +static void gst_ladspa_chain (GstPad *pad,GstData *_data); +static GstData * gst_ladspa_get (GstPad *pad); static GstElementClass *parent_class = NULL; @@ -676,13 +676,13 @@ gst_ladspa_loop (GstElement *element) /* first get all the necessary data from the input ports */ for (i=0 ; isinkpads[i]); + buffers_in[i] = GST_BUFFER (gst_pad_pull (ladspa->sinkpads[i])); if (GST_IS_EVENT (buffers_in[i])) { /* push it out on all pads */ gst_data_ref_by_count ((GstData*)buffers_in[i], numsrcpads); for (j=0; jsrcpads[j], buffers_in[i]); + gst_pad_push (ladspa->srcpads[j], GST_DATA (buffers_in[i])); if (GST_EVENT_TYPE (buffers_in[i]) == GST_EVENT_EOS) { /* shut down */ gst_element_set_eos (element); @@ -753,7 +753,7 @@ gst_ladspa_loop (GstElement *element) } for (i=0 ; isrcpads[i], buffers_out[i]); + gst_pad_push (ladspa->srcpads[i], GST_DATA (buffers_out[i])); data_out[i] = NULL; buffers_out[i] = NULL; @@ -770,8 +770,9 @@ gst_ladspa_loop (GstElement *element) } static void -gst_ladspa_chain (GstPad *pad, GstBuffer *buffer_in) +gst_ladspa_chain (GstPad *pad, GstData *_data) { + GstBuffer *buffer_in = GST_BUFFER (_data); LADSPA_Descriptor *desc; LADSPA_Data *data_in, **data_out = NULL; GstBuffer **buffers_out = NULL; @@ -850,7 +851,7 @@ gst_ladspa_chain (GstPad *pad, GstBuffer *buffer_in) for (i=0; isrcpads[i], buffers_out[i]); + gst_pad_push (ladspa->srcpads[i], GST_DATA (buffers_out[i])); } g_free(buffers_out); @@ -858,7 +859,7 @@ gst_ladspa_chain (GstPad *pad, GstBuffer *buffer_in) } } -static GstBuffer * +static GstData * gst_ladspa_get(GstPad *pad) { GstLADSPA *ladspa; @@ -902,7 +903,7 @@ gst_ladspa_get(GstPad *pad) num_processed = num_to_process; } - return buf; + return GST_DATA (buf); } static void -- cgit