Xbox: virtual memory fixes
This commit is contained in:
@@ -12,6 +12,10 @@
|
||||
#include "arch/arch.h"
|
||||
#include "arch/Sound/RageSoundDriver.h"
|
||||
|
||||
#if defined(XBOX)
|
||||
#include "archutils/Xbox/VirtualMemory.h"
|
||||
#endif
|
||||
|
||||
/*
|
||||
* This mutex is locked before Update() deletes old sounds from owned_sounds. Lock
|
||||
* this mutex if you want to ensure that sounds remain valid. (Other threads may
|
||||
@@ -217,6 +221,10 @@ RageSound *RageSoundManager::PlaySound( RageSound &snd, const RageSoundParams *p
|
||||
else
|
||||
{
|
||||
sound_to_play = new RageSound(snd);
|
||||
#if defined(XBOX)
|
||||
// keep the sound data committed to memory
|
||||
vmem_Manager.Lock(sound_to_play);
|
||||
#endif
|
||||
|
||||
/* We're responsible for freeing it. */
|
||||
g_SoundManMutex.Lock(); /* lock for access to owned_sounds */
|
||||
|
||||
Reference in New Issue
Block a user