mirror of
https://gitlab.freedesktop.org/gstreamer/gstreamer.git
synced 2024-12-01 06:01:04 +00:00
rtpmux: Ville's original patch to fix the traversal of dtmf event
20070525102709-f3f1e-6c41d1ef934068a4f4e810e7e981b420075b0c98.gz
This commit is contained in:
parent
94ebe07862
commit
ed76f67e96
1 changed files with 24 additions and 0 deletions
|
@ -181,6 +181,29 @@ gst_rtp_mux_class_init (GstRTPMuxClass * klass)
|
||||||
klass->chain_func = gst_rtp_mux_chain;
|
klass->chain_func = gst_rtp_mux_chain;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
static gboolean gst_rtp_mux_src_event (GstPad * pad,
|
||||||
|
GstEvent * event)
|
||||||
|
{
|
||||||
|
gboolean result = TRUE;
|
||||||
|
GList *orig, *pads;
|
||||||
|
|
||||||
|
orig = pads = gst_pad_get_internal_links (pad);
|
||||||
|
|
||||||
|
while (pads) {
|
||||||
|
GstPad *eventpad = GST_PAD_CAST (pads->data);
|
||||||
|
pads = g_list_next (pads);
|
||||||
|
|
||||||
|
gst_event_ref (event);
|
||||||
|
result &= gst_pad_push_event (eventpad, event);
|
||||||
|
}
|
||||||
|
|
||||||
|
g_list_free (orig);
|
||||||
|
|
||||||
|
gst_event_unref (event);
|
||||||
|
|
||||||
|
return result;
|
||||||
|
}
|
||||||
|
|
||||||
static void
|
static void
|
||||||
gst_rtp_mux_init (GstRTPMux * rtp_mux)
|
gst_rtp_mux_init (GstRTPMux * rtp_mux)
|
||||||
{
|
{
|
||||||
|
@ -189,6 +212,7 @@ gst_rtp_mux_init (GstRTPMux * rtp_mux)
|
||||||
rtp_mux->srcpad =
|
rtp_mux->srcpad =
|
||||||
gst_pad_new_from_template (gst_element_class_get_pad_template (klass,
|
gst_pad_new_from_template (gst_element_class_get_pad_template (klass,
|
||||||
"src"), "src");
|
"src"), "src");
|
||||||
|
gst_pad_set_event_function (rtp_mux->srcpad, gst_rtp_mux_src_event);
|
||||||
gst_element_add_pad (GST_ELEMENT (rtp_mux), rtp_mux->srcpad);
|
gst_element_add_pad (GST_ELEMENT (rtp_mux), rtp_mux->srcpad);
|
||||||
|
|
||||||
rtp_mux->ssrc = DEFAULT_SSRC;
|
rtp_mux->ssrc = DEFAULT_SSRC;
|
||||||
|
|
Loading…
Reference in a new issue