mirror of https://github.com/stella-emu/stella.git
Oops, the last commit contained experimental sound changes.
git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@2268 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
This commit is contained in:
parent
737e6743de
commit
738e0aa73d
|
@ -50,11 +50,7 @@ SoundSDL::SoundSDL(OSystem* osystem)
|
|||
SoundSDL::~SoundSDL()
|
||||
{
|
||||
// Close the SDL audio system if it's initialized
|
||||
if(myIsInitializedFlag)
|
||||
{
|
||||
SDL_CloseAudio();
|
||||
myIsInitializedFlag = false;
|
||||
}
|
||||
close();
|
||||
}
|
||||
|
||||
// - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
|
||||
|
@ -79,9 +75,8 @@ void SoundSDL::open()
|
|||
myRegWriteQueue.clear();
|
||||
myTIASound.reset();
|
||||
|
||||
if(!myIsInitializedFlag && SDL_WasInit(SDL_INIT_AUDIO) == 0)
|
||||
if(SDL_WasInit(SDL_INIT_AUDIO) == 0)
|
||||
{
|
||||
cerr << "SoundSDL::open()\n";
|
||||
myIsInitializedFlag = false;
|
||||
myIsMuted = false;
|
||||
myLastRegisterSetCycle = 0;
|
||||
|
@ -163,8 +158,8 @@ void SoundSDL::close()
|
|||
{
|
||||
if(myIsInitializedFlag)
|
||||
{
|
||||
cerr << "SoundSDL::close()\n";
|
||||
SDL_PauseAudio(1);
|
||||
SDL_CloseAudio();
|
||||
myIsInitializedFlag = false;
|
||||
}
|
||||
}
|
||||
|
||||
|
|
|
@ -464,7 +464,7 @@ fallback:
|
|||
// - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
|
||||
void OSystem::createSound()
|
||||
{
|
||||
if(!mySound)
|
||||
delete mySound; mySound = NULL;
|
||||
mySound = MediaFactory::createAudio(this);
|
||||
#ifndef SOUND_SUPPORT
|
||||
mySettings->setBool("sound", false);
|
||||
|
|
Loading…
Reference in New Issue