From eb74905991f8ec104e4f76f47a8b5805310a9485 Mon Sep 17 00:00:00 2001 From: Olivier Crete Date: Fri, 4 May 2007 19:52:51 +0000 Subject: [MOVED FROM GST-P-FARSIGHT] Only send dtmf if the method is unspecified or is 1 20070504195251-3e2dc-b95b4b8e8dad87962cf39ec2ee67b6f1b619e9bd.gz --- gst/rtpdtmf/gstrtpdtmfsrc.c | 17 ++++++++++++++++- 1 file changed, 16 insertions(+), 1 deletion(-) (limited to 'gst') diff --git a/gst/rtpdtmf/gstrtpdtmfsrc.c b/gst/rtpdtmf/gstrtpdtmfsrc.c index 26ac5f93..d716b219 100644 --- a/gst/rtpdtmf/gstrtpdtmfsrc.c +++ b/gst/rtpdtmf/gstrtpdtmfsrc.c @@ -84,7 +84,15 @@ * start * G_TYPE_BOOLEAN * True or False - * Wether the event is starting or ending. + * Whether the event is starting or ending. + * + * + * method + * G_TYPE_INT + * 1 + * The method used for sending event, this element will react if this field + * is absent or 1. + * * * * @@ -321,12 +329,19 @@ gst_rtp_dtmf_src_handle_dtmf_event (GstRTPDTMFSrc *dtmfsrc, { gint event_type; gboolean start; + gint method; if (!gst_structure_get_int (event_structure, "type", &event_type) || !gst_structure_get_boolean (event_structure, "start", &start) || event_type != GST_RTP_DTMF_TYPE_EVENT) goto failure; + if (gst_structure_get_int (event_structure, "method", &method)) { + if (method != 1) { + goto failure; + } + } + if (start) { gint event_number; gint event_volume; -- cgit v1.2.1