fix for delay measurement
This commit is contained in:
parent
2f8d8fbd7e
commit
40fda55929
2 changed files with 8 additions and 9 deletions
|
@ -279,13 +279,12 @@ void CClientSettingsDlg::OnPingTimeResult ( int iPingTime )
|
||||||
const int iTotalJitterBufferDelayMS = MIN_SERVER_BLOCK_DURATION_MS *
|
const int iTotalJitterBufferDelayMS = MIN_SERVER_BLOCK_DURATION_MS *
|
||||||
( 2 /* buffer at client and server */ * pClient->GetSockBufSize() ) / 2;
|
( 2 /* buffer at client and server */ * pClient->GetSockBufSize() ) / 2;
|
||||||
|
|
||||||
|
// we assume that we have two period sizes for the input and one for the
|
||||||
// TODO consider sound card interface block size
|
// output, therefore we have "3 *" instead of "2 *" (for input and output)
|
||||||
|
// the actual sound card buffer size
|
||||||
const int iTotalSoundCardDelayMS = 0;
|
const int iTotalSoundCardDelayMS =
|
||||||
// const int iTotalSoundCardDelayMS = 2 * MIN_SERVER_BLOCK_DURATION_MS +
|
3 * pClient->GetSndCrdActualMonoBlSize() *
|
||||||
// MIN_SERVER_BLOCK_DURATION_MS * ( pClient->GetSndInterface()->GetInNumBuf() +
|
1000 / SND_CRD_SAMPLE_RATE;
|
||||||
// pClient->GetSndInterface()->GetOutNumBuf() ) / 2;
|
|
||||||
|
|
||||||
const int iDelayToFillNetworkPackets =
|
const int iDelayToFillNetworkPackets =
|
||||||
( pClient->GetNetwBufSizeOut() + pClient->GetAudioBlockSizeIn() ) *
|
( pClient->GetNetwBufSizeOut() + pClient->GetAudioBlockSizeIn() ) *
|
||||||
|
|
|
@ -50,7 +50,7 @@ public:
|
||||||
CSocket ( CChannel* pNewChannel, const quint16 iPortNumber ) :
|
CSocket ( CChannel* pNewChannel, const quint16 iPortNumber ) :
|
||||||
pChannel( pNewChannel ), bIsClient ( true ) { Init ( iPortNumber ); }
|
pChannel( pNewChannel ), bIsClient ( true ) { Init ( iPortNumber ); }
|
||||||
CSocket ( CChannelSet* pNewChannelSet, QObject* pNServP, const quint16 iPortNumber ) :
|
CSocket ( CChannelSet* pNewChannelSet, QObject* pNServP, const quint16 iPortNumber ) :
|
||||||
pChannelSet(pNewChannelSet), pServer ( pNServP ), bIsClient ( false )
|
pChannelSet ( pNewChannelSet ), pServer ( pNServP ), bIsClient ( false )
|
||||||
{ Init ( iPortNumber ); }
|
{ Init ( iPortNumber ); }
|
||||||
virtual ~CSocket() {}
|
virtual ~CSocket() {}
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue