Created
October 9, 2017 13:57
-
-
Save tatsuyaueda/c74af3fd6eb75fc9059e012e3012ed01 to your computer and use it in GitHub Desktop.
OrkAudio Patch
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
diff -cr oreka-svn.orig/orkaudio/audiocaptureplugins/voip/VoIpSession.cpp oreka-svn/orkaudio/audiocaptureplugins/voip/VoIpSession.cpp | |
*** oreka-svn.orig/orkaudio/audiocaptureplugins/voip/VoIpSession.cpp 2017-10-09 13:49:42.243212033 +0000 | |
--- oreka-svn/orkaudio/audiocaptureplugins/voip/VoIpSession.cpp 2017-10-09 13:51:21.793068023 +0000 | |
*************** | |
*** 24,29 **** | |
--- 24,30 ---- | |
#include "ace/OS_NS_arpa_inet.h" | |
#include "MemUtils.h" | |
#include <boost/algorithm/string/predicate.hpp> | |
+ #include <cmath> | |
extern AudioChunkCallBackFunction g_audioChunkCallBack; | |
extern CaptureEventCallBackFunction g_captureEventCallBack; | |
*************** | |
*** 1290,1297 **** | |
if(DLLCONFIG.m_rtpDiscontinuityDetect) | |
{ | |
double timestampDelta = (double)rtpPacket->m_timestamp - (double)m_lastRtpPacketSide1->m_timestamp; | |
! if( abs(seqNumDelta) > m_minRtpSeqDelta && | |
! abs(timestampDelta) > m_minRtpTimestampDelta) | |
{ | |
logMsg.Format("[%s] RTP discontinuity s1: before: seq:%u ts:%u after: seq:%u ts:%u", | |
m_trackingId, m_lastRtpPacketSide1->m_seqNum, m_lastRtpPacketSide1->m_timestamp, | |
--- 1291,1298 ---- | |
if(DLLCONFIG.m_rtpDiscontinuityDetect) | |
{ | |
double timestampDelta = (double)rtpPacket->m_timestamp - (double)m_lastRtpPacketSide1->m_timestamp; | |
! if( std::abs(seqNumDelta) > m_minRtpSeqDelta && | |
! std::abs(timestampDelta) > m_minRtpTimestampDelta) | |
{ | |
logMsg.Format("[%s] RTP discontinuity s1: before: seq:%u ts:%u after: seq:%u ts:%u", | |
m_trackingId, m_lastRtpPacketSide1->m_seqNum, m_lastRtpPacketSide1->m_timestamp, | |
*************** | |
*** 1303,1309 **** | |
//In case of dialer session, rtp keeps on going even when the call is done | |
//If we detect the pausing in rtp, we break the session | |
int deltaTimestamp = rtpPacket->m_timestamp - m_lastRtpPacketSide1->m_timestamp; | |
! if(DLLCONFIG.m_rtpBreakupOnStreamPause == true && (abs(seqNumDelta) * 160) < deltaTimestamp) | |
{ | |
if((double)rtpPacket->m_seqNum < (double)m_lastRtpPacketSide1->m_seqNum) //seq reset | |
{ | |
--- 1304,1310 ---- | |
//In case of dialer session, rtp keeps on going even when the call is done | |
//If we detect the pausing in rtp, we break the session | |
int deltaTimestamp = rtpPacket->m_timestamp - m_lastRtpPacketSide1->m_timestamp; | |
! if(DLLCONFIG.m_rtpBreakupOnStreamPause == true && (std::abs(seqNumDelta) * 160) < deltaTimestamp) | |
{ | |
if((double)rtpPacket->m_seqNum < (double)m_lastRtpPacketSide1->m_seqNum) //seq reset | |
{ | |
*************** | |
*** 1372,1379 **** | |
if(DLLCONFIG.m_rtpDiscontinuityDetect) | |
{ | |
double timestampDelta = (double)rtpPacket->m_timestamp - (double)m_lastRtpPacketSide2->m_timestamp; | |
! if( abs(seqNumDelta) > m_minRtpSeqDelta && | |
! abs(timestampDelta) > m_minRtpTimestampDelta) | |
{ | |
logMsg.Format("[%s] RTP discontinuity s2: before: seq:%u ts:%u after: seq:%u ts:%u", | |
m_trackingId, m_lastRtpPacketSide2->m_seqNum, m_lastRtpPacketSide2->m_timestamp, | |
--- 1373,1380 ---- | |
if(DLLCONFIG.m_rtpDiscontinuityDetect) | |
{ | |
double timestampDelta = (double)rtpPacket->m_timestamp - (double)m_lastRtpPacketSide2->m_timestamp; | |
! if( std::abs(seqNumDelta) > m_minRtpSeqDelta && | |
! std::abs(timestampDelta) > m_minRtpTimestampDelta) | |
{ | |
logMsg.Format("[%s] RTP discontinuity s2: before: seq:%u ts:%u after: seq:%u ts:%u", | |
m_trackingId, m_lastRtpPacketSide2->m_seqNum, m_lastRtpPacketSide2->m_timestamp, | |
diff -cr oreka-svn.orig/orkaudio/configure.in oreka-svn/orkaudio/configure.in | |
*** oreka-svn.orig/orkaudio/configure.in 2017-10-09 13:49:42.203212091 +0000 | |
--- oreka-svn/orkaudio/configure.in 2017-10-09 13:50:26.133148541 +0000 | |
*************** | |
*** 3,9 **** | |
AM_CONFIG_HEADER(config.h) | |
AM_INIT_AUTOMAKE(orkaudio, 1.0) | |
! speex_lib=orkspeex | |
if [cat /etc/issue | grep Ubuntu]; then | |
speex_lib=speex | |
--- 3,9 ---- | |
AM_CONFIG_HEADER(config.h) | |
AM_INIT_AUTOMAKE(orkaudio, 1.0) | |
! speex_lib=speex | |
if [cat /etc/issue | grep Ubuntu]; then | |
speex_lib=speex | |
diff -cr oreka-svn.orig/orkaudio/filters/Makefile.am oreka-svn/orkaudio/filters/Makefile.am | |
*** oreka-svn.orig/orkaudio/filters/Makefile.am 2017-10-09 13:49:42.573211555 +0000 | |
--- oreka-svn/orkaudio/filters/Makefile.am 2017-10-09 13:52:16.752988517 +0000 | |
*************** | |
*** 1,2 **** | |
METASOURCES = AUTO | |
! SUBDIRS = rtpmixer silkcodec | |
--- 1,2 ---- | |
METASOURCES = AUTO | |
! SUBDIRS = rtpmixer | |
diff -cr oreka-svn.orig/orkaudio/filters/rtpmixer/RtpMixer.cpp oreka-svn/orkaudio/filters/rtpmixer/RtpMixer.cpp | |
*** oreka-svn.orig/orkaudio/filters/rtpmixer/RtpMixer.cpp 2017-10-09 13:49:42.263212004 +0000 | |
--- oreka-svn/orkaudio/filters/rtpmixer/RtpMixer.cpp 2017-10-09 13:52:03.733007352 +0000 | |
*************** | |
*** 21,26 **** | |
--- 21,27 ---- | |
#include <log4cxx/logger.h> | |
#include "Filter.h" | |
#include "AudioCapture.h" | |
+ #include <cmath> | |
extern "C" | |
{ | |
*************** | |
*** 225,232 **** | |
{ | |
double seqNumDelta = (double)details->m_sequenceNumber - (double)lastDetails->m_sequenceNumber; | |
double timestampDelta = (double)details->m_timestamp - (double)lastDetails->m_timestamp; | |
! if( abs(seqNumDelta) > 1000.0 && | |
! abs(timestampDelta) > 160000.0) | |
{ | |
seqNumDiscontinuities++; | |
CStdString logMsg; | |
--- 226,233 ---- | |
{ | |
double seqNumDelta = (double)details->m_sequenceNumber - (double)lastDetails->m_sequenceNumber; | |
double timestampDelta = (double)details->m_timestamp - (double)lastDetails->m_timestamp; | |
! if( std::abs(seqNumDelta) > 1000.0 && | |
! std::abs(timestampDelta) > 160000.0) | |
{ | |
seqNumDiscontinuities++; | |
CStdString logMsg; |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment