From: <man...@us...> - 2012-11-02 14:39:44
|
Revision: 1413 http://modplug.svn.sourceforge.net/modplug/?rev=1413&view=rev Author: manxorist Date: 2012-11-02 14:39:37 +0000 (Fri, 02 Nov 2012) Log Message: ----------- [Ref] Remove ISoundDevice::SilenceAudioBuffer which hab been completely unused since at least r150 6 years ago. Revision Links: -------------- http://modplug.svn.sourceforge.net/modplug/?rev=150&view=rev Modified Paths: -------------- trunk/OpenMPT/mptrack/MainFrm.cpp trunk/OpenMPT/soundlib/SNDDEV.H trunk/OpenMPT/soundlib/SNDDEVX.H trunk/OpenMPT/soundlib/Snddev.cpp Modified: trunk/OpenMPT/mptrack/MainFrm.cpp =================================================================== --- trunk/OpenMPT/mptrack/MainFrm.cpp 2012-10-30 10:56:17 UTC (rev 1412) +++ trunk/OpenMPT/mptrack/MainFrm.cpp 2012-11-02 14:39:37 UTC (rev 1413) @@ -688,10 +688,7 @@ if ((pMainFrm) && (pMainFrm->IsPlaying()) && (CMainFrame::gpSoundDevice)) { bOk = CMainFrame::gpSoundDevice->FillAudioBuffer(&gMPTSoundSource, gdwPlayLatency, dwUser); - }/* else - { - CMainFrame::gpSoundDevice->SilenceAudioBuffer(&gMPTSoundSource, gdwPlayLatency, dwUser); - }*/ + } if (!bOk) { gbStopSent = TRUE; @@ -761,7 +758,6 @@ if (nSleep > 40) nSleep = 40; } else { - //CMainFrame::gpSoundDevice->SilenceAudioBuffer(&gMPTSoundSource, gdwPlayLatency); gbStopSent = TRUE; pMainFrm->PostMessage(WM_COMMAND, ID_PLAYER_STOP); } @@ -986,7 +982,7 @@ gpSoundDevice->Reset(); gpSoundDevice->Close(); - } + } } Modified: trunk/OpenMPT/soundlib/SNDDEV.H =================================================================== --- trunk/OpenMPT/soundlib/SNDDEV.H 2012-10-30 10:56:17 UTC (rev 1412) +++ trunk/OpenMPT/soundlib/SNDDEV.H 2012-11-02 14:39:37 UTC (rev 1413) @@ -92,7 +92,6 @@ virtual UINT HasFixedBitsPerSample() { return 0; } virtual bool IsOpen() = 0; virtual UINT GetCurrentLatency() = 0; - virtual void SilenceAudioBuffer(ISoundSource *pSource, ULONG nMaxLatency, DWORD dwUser=0) = 0; virtual UINT GetCurrentSampleRate(UINT nDevice) { UNREFERENCED_PARAMETER(nDevice); return 0; } // Return which samplerates are actually supported by the device. Currently only implemented properly for ASIO. virtual bool CanSampleRate(UINT nDevice, vector<UINT> &samplerates, vector<bool> &result) { UNREFERENCED_PARAMETER(nDevice); result.assign(samplerates.size(), true); return true; } ; Modified: trunk/OpenMPT/soundlib/SNDDEVX.H =================================================================== --- trunk/OpenMPT/soundlib/SNDDEVX.H 2012-10-30 10:56:17 UTC (rev 1412) +++ trunk/OpenMPT/soundlib/SNDDEVX.H 2012-11-02 14:39:37 UTC (rev 1413) @@ -57,7 +57,6 @@ VOID Start() {} bool IsOpen() { return (m_hWaveOut != NULL); } UINT GetCurrentLatency() { return m_nBuffersPending * m_nWaveBufferSize; } - void SilenceAudioBuffer(ISoundSource *pSource, ULONG nMaxLatency, DWORD dwBuffer); public: static VOID CALLBACK WaveOutCallBack(HWAVEOUT, UINT uMsg, DWORD, DWORD dw1, DWORD dw2); @@ -96,7 +95,6 @@ VOID Start() {} bool IsOpen() { return (m_pMixBuffer != NULL); } UINT GetCurrentLatency() { return m_dwLatency; } - void SilenceAudioBuffer(ISoundSource *pSource, ULONG nMaxLatency, DWORD dwBuffer); protected: DWORD LockBuffer(DWORD dwBytes, LPVOID *lpBuf1, LPDWORD lpSize1, LPVOID *lpBuf2, LPDWORD lpSize2); @@ -150,7 +148,6 @@ BOOL Directcallback() { return TRUE; } UINT HasFixedBitsPerSample() { return m_nBitsPerSample; } UINT GetCurrentLatency() { return m_nAsioBufferLen; } - void SilenceAudioBuffer(ISoundSource *pSource, ULONG nMaxLatency, DWORD dwBuffer); bool CanSampleRate(UINT nDevice, vector<UINT> &samplerates, vector<bool> &result); UINT GetCurrentSampleRate(UINT nDevice); Modified: trunk/OpenMPT/soundlib/Snddev.cpp =================================================================== --- trunk/OpenMPT/soundlib/Snddev.cpp 2012-10-30 10:56:17 UTC (rev 1412) +++ trunk/OpenMPT/soundlib/Snddev.cpp 2012-11-02 14:39:37 UTC (rev 1413) @@ -185,14 +185,7 @@ } } -void CWaveDevice::SilenceAudioBuffer(ISoundSource *pSource, ULONG nMaxLatency, DWORD dwBuffer) -{ - UNREFERENCED_PARAMETER(pSource); - UNREFERENCED_PARAMETER(nMaxLatency); - UNREFERENCED_PARAMETER(dwBuffer); -} - BOOL CWaveDevice::FillAudioBuffer(ISoundSource *pSource, ULONG nMaxLatency, DWORD) //-------------------------------------------------------------------------------- { @@ -520,13 +513,6 @@ } -void CDSoundDevice::SilenceAudioBuffer(ISoundSource *pSource, ULONG nMaxLatency, DWORD dwBuffer) -{ - UNREFERENCED_PARAMETER(pSource); - UNREFERENCED_PARAMETER(nMaxLatency); - UNREFERENCED_PARAMETER(dwBuffer); -} - BOOL CDSoundDevice::FillAudioBuffer(ISoundSource *pSource, ULONG nMaxLatency, DWORD) //---------------------------------------------------------------------------------- { @@ -926,17 +912,6 @@ } -void CASIODevice::SilenceAudioBuffer(ISoundSource *pSource, ULONG nMaxLatency, DWORD dwBuffer) -//-------------------------------------------------------------------------------------------- -{ - UNREFERENCED_PARAMETER(pSource); - UNREFERENCED_PARAMETER(nMaxLatency); - for (UINT ich=0; ich<m_nChannels; ich++){ - memset(m_BufferInfo[ich].buffers[dwBuffer], 0, m_nAsioBufferLen); - } - -} - BOOL CASIODevice::FillAudioBuffer(ISoundSource *pSource, ULONG nMaxLatency, DWORD dwBuffer) //----------------------------------------------------------------------------------------- { This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |