diff --git a/stepmania/src/RageSound.cpp b/stepmania/src/RageSound.cpp index 1df818a6f8..1aa0517629 100644 --- a/stepmania/src/RageSound.cpp +++ b/stepmania/src/RageSound.cpp @@ -70,8 +70,6 @@ RageSound::RageSound(): m_iMaxDriverFrame = 0; m_bPlaying = false; - m_iID = SOUNDMAN->GetUniqueID(); - /* Register ourself last, once everything is initialized. */ SOUNDMAN->RegisterSound( this ); } @@ -93,12 +91,6 @@ RageSound::RageSound( const RageSound &cpy ): m_pSource = NULL; *this = cpy; - - /* We have a different ID than our parent. */ - m_iID = SOUNDMAN->GetUniqueID(); - - /* Register ourself. */ - SOUNDMAN->RegisterSound( this ); } RageSound &RageSound::operator=( const RageSound &cpy ) @@ -365,13 +357,6 @@ void RageSound::StopPlaying() m_HardwareToStreamMap.Clear(); m_StreamToSourceMap.Clear(); - /* We may still have positions queued up in RageSoundManager. We need to make sure - * that we don't accept those; otherwise, if we start playing again quickly, they'll - * confuse GetPositionSeconds(). Do this by changing our ID. */ - SOUNDMAN->UnregisterSound( this ); - m_iID = SOUNDMAN->GetUniqueID(); - SOUNDMAN->RegisterSound( this ); - // LOG->Trace("StopPlaying %p finished (%s)", this, this->GetLoadedFilePath().c_str()); m_Mutex.Unlock(); diff --git a/stepmania/src/RageSound.h b/stepmania/src/RageSound.h index c020f17829..c1010ad5a1 100644 --- a/stepmania/src/RageSound.h +++ b/stepmania/src/RageSound.h @@ -135,7 +135,6 @@ public: float GetPlaybackRate() const; RageTimer GetStartTime() const; float GetAbsoluteVolume() const; // factors in SOUNDMAN->GetMixVolume() - int GetID() const { return m_iID; } void SetParams( const RageSoundParams &p ); const RageSoundParams &GetParams() const { return m_Param; } bool SetProperty( const RString &sProperty, float fValue ); @@ -175,9 +174,6 @@ private: /* Keep track of the max SOUNDMAN->GetPosition result (see GetPositionSecondsInternal). */ mutable int64_t m_iMaxDriverFrame; - /* Unique ID number for this instance of RageSound. */ - int m_iID; - RString m_sError; int64_t GetPositionSecondsInternal( bool *bApproximate = NULL, RageTimer *pTimer = NULL ) const;