From de13a71735dad99ffc91e1d60ba74e88dae25363 Mon Sep 17 00:00:00 2001 From: Volker Fischer Date: Sat, 1 Nov 2008 08:47:31 +0000 Subject: [PATCH] bug fix --- src/clientsettingsdlg.cpp | 12 +----------- src/clientsettingsdlgbase.ui | 2 +- windows/sound.cpp | 9 +++------ windows/sound.h | 2 +- 4 files changed, 6 insertions(+), 19 deletions(-) diff --git a/src/clientsettingsdlg.cpp b/src/clientsettingsdlg.cpp index 02f28599..5852541d 100755 --- a/src/clientsettingsdlg.cpp +++ b/src/clientsettingsdlg.cpp @@ -57,9 +57,6 @@ CClientSettingsDlg::CClientSettingsDlg ( CClient* pNCliP, QWidget* parent, TextNetBufSiFactOut->setWhatsThis ( strNetwBlockSize ); GroupBoxNetwBuf->setWhatsThis ( strNetwBlockSize ); - // init timing jitter text label - //TextLabelStdDevTimer->setText ( "" ); - // init delay information controls CLEDOverallDelay->SetUpdateTime ( 2 * PING_UPDATE_TIME ); CLEDOverallDelay->Reset(); @@ -341,16 +338,9 @@ void CClientSettingsDlg::OnPingTimeResult ( int iPingTime ) void CClientSettingsDlg::UpdateDisplay() { - if ( pClient->IsRunning() ) - { - // response time - //TextLabelStdDevTimer->setText ( QString(). - // setNum ( pClient->GetTimingStdDev(), 'f', 2 ) + " ms" ); - } - else + if ( !pClient->IsRunning() ) { // clear text labels with client parameters - //TextLabelStdDevTimer->setText ( "" ); TextLabelPingTime->setText ( "" ); TextLabelBufferDelay->setText ( "" ); TextLabelOverallDelay->setText ( "" ); diff --git a/src/clientsettingsdlgbase.ui b/src/clientsettingsdlgbase.ui index f43a24d4..9fd6efb8 100755 --- a/src/clientsettingsdlgbase.ui +++ b/src/clientsettingsdlgbase.ui @@ -910,7 +910,7 @@ - 0 + 2 diff --git a/windows/sound.cpp b/windows/sound.cpp index ac5b5ec5..68ea0876 100755 --- a/windows/sound.cpp +++ b/windows/sound.cpp @@ -327,7 +327,7 @@ std::string CSound::LoadAndInitializeDriver ( int iDriverIdx ) return "The audio driver could not be initialized."; } - const std::string strStat = GetAndCheckSoundCardProperties(); + const std::string strStat = PrepareDriver(); // store ID of selected driver if initialization was successful if ( strStat.empty() ) @@ -351,7 +351,7 @@ bool CSound::LoadAndInitializeFirstValidDriver() { if ( ASIOInit ( &driverInfo ) == ASE_OK ) { - if ( GetAndCheckSoundCardProperties().empty() ) + if ( PrepareDriver().empty() ) { // initialization was successful bValidDriverDetected = true; @@ -379,7 +379,7 @@ bool CSound::LoadAndInitializeFirstValidDriver() return bValidDriverDetected; } -std::string CSound::GetAndCheckSoundCardProperties() +std::string CSound::PrepareDriver() { int i; @@ -592,9 +592,6 @@ void CSound::Close() // wait for the thread to terminate Sleep ( 500 ); - // dispose ASIO buffers - ASIODisposeBuffers(); - // set flag to open devices the next time it is initialized bChangParamIn = true; bChangParamOut = true; diff --git a/windows/sound.h b/windows/sound.h index 99d6a86b..57685429 100755 --- a/windows/sound.h +++ b/windows/sound.h @@ -97,7 +97,7 @@ public: protected: bool LoadAndInitializeFirstValidDriver(); std::string LoadAndInitializeDriver ( int iIdx ); - std::string GetAndCheckSoundCardProperties(); + std::string PrepareDriver(); void InitRecordingAndPlayback(); // audio hardware buffer info