Skip to content
Snippets Groups Projects
Commit 009905f4 authored by Alexandre Savard's avatar Alexandre Savard
Browse files

[#4367] use symetric audio rtp session, not dual

parent 39c656f2
Branches
Tags
No related merge requests found
...@@ -49,7 +49,7 @@ timeval2microtimeout(const timeval& t) ...@@ -49,7 +49,7 @@ timeval2microtimeout(const timeval& t)
AudioRtpSession::AudioRtpSession (ManagerImpl * manager, SIPCall * sipcall) : AudioRtpSession::AudioRtpSession (ManagerImpl * manager, SIPCall * sipcall) :
// ost::SymmetricRTPSession (ost::InetHostAddress (sipcall->getLocalIp().c_str()), sipcall->getLocalAudioPort()), // ost::SymmetricRTPSession (ost::InetHostAddress (sipcall->getLocalIp().c_str()), sipcall->getLocalAudioPort()),
AudioRtpRecordHandler(manager, sipcall), AudioRtpRecordHandler(manager, sipcall),
ost::TRTPSessionBase<ost::DualRTPUDPIPv4Channel,ost::DualRTPUDPIPv4Channel,ost::AVPQueue>(ost::InetHostAddress (sipcall->getLocalIp().c_str()), ost::TRTPSessionBase<ost::SymmetricRTPChannel,ost::SymmetricRTPChannel,ost::AVPQueue>(ost::InetHostAddress (sipcall->getLocalIp().c_str()),
sipcall->getLocalAudioPort(), sipcall->getLocalAudioPort(),
0, 0,
ost::MembershipBookkeeping::defaultMembersHashSize, ost::MembershipBookkeeping::defaultMembersHashSize,
...@@ -252,12 +252,8 @@ void AudioRtpSession::sendMicData() ...@@ -252,12 +252,8 @@ void AudioRtpSession::sendMicData()
_timestampCount = 0; _timestampCount = 0;
} }
// getCurrentTimestamp();
// RTPDataQueue::getTimestampIncrement();
// Increment timestamp for outgoing packet // Increment timestamp for outgoing packet
_timestamp += _timestampIncrement; _timestamp += _timestampIncrement;
_debug("sendMicData: %d, timestamp increment %d", _timestamp, _timestampIncrement);
// putData put the data on RTP queue, sendImmediate bypass this queue // putData put the data on RTP queue, sendImmediate bypass this queue
putData (_timestamp, getMicDataEncoded(), compSize); putData (_timestamp, getMicDataEncoded(), compSize);
...@@ -275,7 +271,6 @@ void AudioRtpSession::receiveSpeakerData () ...@@ -275,7 +271,6 @@ void AudioRtpSession::receiveSpeakerData ()
adu = getData (packetTimestamp); adu = getData (packetTimestamp);
if (!adu) { if (!adu) {
_debug("receiveSpeakerData: no data!");
return; return;
} }
...@@ -378,9 +373,7 @@ void AudioRtpSession::run () ...@@ -378,9 +373,7 @@ void AudioRtpSession::run ()
// make sure the scheduling timeout is // make sure the scheduling timeout is
// <= the check interval for RTCP // <= the check interval for RTCP
// packets // packets
_debug("timeout before: %d, maxwait %d", timeout, maxWait);
timeout = (timeout > maxWait)? maxWait : timeout; timeout = (timeout > maxWait)? maxWait : timeout;
_debug("timeout after: %d", timeout);
if ( timeout < 1000 ) { // !(timeout/1000) if ( timeout < 1000 ) { // !(timeout/1000)
setCancel(cancelDeferred); setCancel(cancelDeferred);
......
...@@ -64,7 +64,8 @@ static const int g722PayloadType = 9; ...@@ -64,7 +64,8 @@ static const int g722PayloadType = 9;
static const int g722RtpClockRate = 8000; static const int g722RtpClockRate = 8000;
static const int g722RtpTimeincrement = 160; static const int g722RtpTimeincrement = 160;
class AudioRtpSession : protected ost::Thread, public ost::TimerPort, public AudioRtpRecordHandler, public ost::TRTPSessionBase<ost::DualRTPUDPIPv4Channel,ost::DualRTPUDPIPv4Channel,ost::AVPQueue> // class AudioRtpSession : protected ost::Thread, public ost::TimerPort, public AudioRtpRecordHandler, public ost::TRTPSessionBase<ost::DualRTPUDPIPv4Channel,ost::DualRTPUDPIPv4Channel,ost::AVPQueue>
class AudioRtpSession : protected ost::Thread, public ost::TimerPort, public AudioRtpRecordHandler, public ost::TRTPSessionBase<ost::SymmetricRTPChannel, ost::SymmetricRTPChannel, ost::AVPQueue>
{ {
public: public:
/** /**
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment