mirror of
https://github.com/jambonz/sbc-outbound.git
synced 2025-12-19 04:27:45 +00:00
use inject dtmf only for webrtc clients (https://github.com/jambonz/sbc-inbound/issues/222)
This commit is contained in:
@@ -559,7 +559,7 @@ class CallSession extends Emitter {
|
||||
...this.rtpEngineOpts.uas.mediaOpts,
|
||||
'from-tag': this.rtpEngineOpts.uas.tag,
|
||||
'to-tag': this.rtpEngineOpts.uac.tag,
|
||||
flags: ['single codec', 'inject DTMF'],
|
||||
flags: ['single codec'],
|
||||
sdp
|
||||
};
|
||||
const response = await this.answer(opts);
|
||||
|
||||
@@ -19,8 +19,8 @@ function makeRtpEngineOpts(req, srcIsUsingSrtp, dstIsUsingSrtp, padCrypto, teams
|
||||
const dstOpts = dstIsUsingSrtp ? srtpOpts : rtpCopy;
|
||||
const srcOpts = srcIsUsingSrtp ? srtpOpts : rtpCopy;
|
||||
|
||||
/** Allow feature server to send DTMF to the call excepts call from/to teams */
|
||||
if (!teams) {
|
||||
/** Allow rtpengine to inject DTMF on calls from webrtc only (this disables kernel forwarding) */
|
||||
if (!teams && (dstIsUsingSrtp || process.env.JAMBONES_RTPENGINE_INJECT_DTMF_ALWAYS)) {
|
||||
if (!dstOpts.flags.includes('inject DTMF')) {
|
||||
dstOpts.flags.push('inject DTMF');
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user