Commit df6ecbd8 authored by Simon Morlat's avatar Simon Morlat
Browse files

fix for inband dtmfs not sent

parent ed7f62c6
......@@ -32,6 +32,9 @@ Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
#include <ortp/event.h>
#define PAYLOAD_TYPE_FLAG_CAN_RECV PAYLOAD_TYPE_USER_FLAG_1
#define PAYLOAD_TYPE_FLAG_CAN_SEND PAYLOAD_TYPE_USER_FLAG_2
typedef enum EchoLimiterType{
ELInactive,
ELControlMic,
......
......@@ -260,7 +260,7 @@ int audio_stream_start_full(AudioStream *stream, RtpProfile *profile, const char
MSSndCard *playcard, MSSndCard *captcard, bool_t use_ec)
{
RtpSession *rtps=stream->session;
PayloadType *pt;
PayloadType *pt,*tel_ev;
int tmp;
MSConnectionHelper h;
int sample_rate;
......@@ -298,7 +298,9 @@ int audio_stream_start_full(AudioStream *stream, RtpProfile *profile, const char
ms_error("audiostream.c: undefined payload type.");
return -1;
}
if (rtp_profile_get_payload_from_mime (profile,"telephone-event")==NULL
tel_ev=rtp_profile_get_payload_from_mime (profile,"telephone-event");
if ( (tel_ev==NULL || ( (tel_ev->flags & PAYLOAD_TYPE_FLAG_CAN_RECV) && !(tel_ev->flags & PAYLOAD_TYPE_FLAG_CAN_SEND)))
&& ( strcasecmp(pt->mime_type,"pcmu")==0 || strcasecmp(pt->mime_type,"pcma")==0)){
/*if no telephone-event payload is usable and pcma or pcmu is used, we will generate
inband dtmf*/
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment