remove catch() that's preventing us from getting complete backtraces to
unexpected sound driver exceptions
This commit is contained in:
@@ -33,24 +33,17 @@ static RageMutex g_SoundManMutex("SoundMan");
|
|||||||
|
|
||||||
RageSoundManager *SOUNDMAN = NULL;
|
RageSoundManager *SOUNDMAN = NULL;
|
||||||
|
|
||||||
RageSoundManager::RageSoundManager(CString drivers)
|
RageSoundManager::RageSoundManager()
|
||||||
{
|
{
|
||||||
/* needs to be done first */
|
|
||||||
SOUNDMAN = this;
|
|
||||||
|
|
||||||
try
|
|
||||||
{
|
|
||||||
MixVolume = 1.0f;
|
|
||||||
|
|
||||||
driver = MakeRageSoundDriver(drivers);
|
|
||||||
if(!driver)
|
|
||||||
RageException::Throw("Couldn't find a sound driver that works");
|
|
||||||
} catch(...) {
|
|
||||||
SOUNDMAN = NULL;
|
|
||||||
throw;
|
|
||||||
}
|
|
||||||
|
|
||||||
pos_map_queue.reserve( 1024 );
|
pos_map_queue.reserve( 1024 );
|
||||||
|
MixVolume = 1.0f;
|
||||||
|
}
|
||||||
|
|
||||||
|
void RageSoundManager::Init( CString drivers )
|
||||||
|
{
|
||||||
|
driver = MakeRageSoundDriver(drivers);
|
||||||
|
if( driver == NULL )
|
||||||
|
RageException::Throw( "Couldn't find a sound driver that works" );
|
||||||
}
|
}
|
||||||
|
|
||||||
RageSoundManager::~RageSoundManager()
|
RageSoundManager::~RageSoundManager()
|
||||||
|
|||||||
@@ -33,8 +33,9 @@ class RageSoundManager
|
|||||||
CircBuf<queued_pos_map_t> pos_map_queue;
|
CircBuf<queued_pos_map_t> pos_map_queue;
|
||||||
|
|
||||||
public:
|
public:
|
||||||
RageSoundManager(CString drivers);
|
RageSoundManager();
|
||||||
~RageSoundManager();
|
~RageSoundManager();
|
||||||
|
void Init( CString drivers );
|
||||||
|
|
||||||
float GetMixVolume() const { return MixVolume; }
|
float GetMixVolume() const { return MixVolume; }
|
||||||
void SetPrefs(float MixVol);
|
void SetPrefs(float MixVol);
|
||||||
|
|||||||
@@ -1041,8 +1041,9 @@ int main(int argc, char* argv[])
|
|||||||
NOTESKIN = new NoteSkinManager;
|
NOTESKIN = new NoteSkinManager;
|
||||||
if( PREFSMAN->m_iSoundWriteAhead )
|
if( PREFSMAN->m_iSoundWriteAhead )
|
||||||
LOG->Info( "Sound writeahead has been overridden to %i", PREFSMAN->m_iSoundWriteAhead );
|
LOG->Info( "Sound writeahead has been overridden to %i", PREFSMAN->m_iSoundWriteAhead );
|
||||||
SOUNDMAN = new RageSoundManager(PREFSMAN->m_sSoundDrivers);
|
SOUNDMAN = new RageSoundManager;
|
||||||
SOUNDMAN->SetPrefs(PREFSMAN->m_fSoundVolume);
|
SOUNDMAN->Init( PREFSMAN->m_sSoundDrivers );
|
||||||
|
SOUNDMAN->SetPrefs( PREFSMAN->m_fSoundVolume );
|
||||||
SOUND = new RageSounds;
|
SOUND = new RageSounds;
|
||||||
BOOKKEEPER = new Bookkeeper;
|
BOOKKEEPER = new Bookkeeper;
|
||||||
LIGHTSMAN = new LightsManager(PREFSMAN->m_sLightsDriver);
|
LIGHTSMAN = new LightsManager(PREFSMAN->m_sLightsDriver);
|
||||||
|
|||||||
Reference in New Issue
Block a user