mirror of
https://github.com/isledecomp/isle.git
synced 2024-11-22 23:57:54 -05:00
Implement/match remaining MxSoundManager virtual functions (#250)
This commit is contained in:
parent
89b3c5f8ae
commit
6594cc78ea
3 changed files with 56 additions and 6 deletions
|
@ -1,7 +1,10 @@
|
||||||
#include "mxsoundmanager.h"
|
#include "mxsoundmanager.h"
|
||||||
|
|
||||||
|
#include "mxautolocker.h"
|
||||||
#include "mxomni.h"
|
#include "mxomni.h"
|
||||||
|
#include "mxpresenter.h"
|
||||||
#include "mxticklemanager.h"
|
#include "mxticklemanager.h"
|
||||||
|
#include "mxwavepresenter.h"
|
||||||
|
|
||||||
DECOMP_SIZE_ASSERT(MxSoundManager, 0x3c);
|
DECOMP_SIZE_ASSERT(MxSoundManager, 0x3c);
|
||||||
|
|
||||||
|
@ -124,16 +127,30 @@ MxResult MxSoundManager::Create(MxU32 p_frequencyMS, MxBool p_createThread)
|
||||||
return status;
|
return status;
|
||||||
}
|
}
|
||||||
|
|
||||||
// OFFSET: LEGO1 0x100aed10 STUB
|
// OFFSET: LEGO1 0x100aed10
|
||||||
void MxSoundManager::vtable0x34()
|
void MxSoundManager::vtable0x34()
|
||||||
{
|
{
|
||||||
// TODO
|
MxAutoLocker lock(&m_criticalSection);
|
||||||
|
|
||||||
|
MxPresenter* presenter;
|
||||||
|
MxPresenterListCursor cursor(m_presenters);
|
||||||
|
|
||||||
|
while (cursor.Next(presenter))
|
||||||
|
if (presenter->IsA("MxWavePresenter"))
|
||||||
|
((MxWavePresenter*) presenter)->VTable0x64();
|
||||||
}
|
}
|
||||||
|
|
||||||
// OFFSET: LEGO1 0x100aee10 STUB
|
// OFFSET: LEGO1 0x100aee10
|
||||||
void MxSoundManager::vtable0x38()
|
void MxSoundManager::vtable0x38()
|
||||||
{
|
{
|
||||||
// TODO
|
MxAutoLocker lock(&m_criticalSection);
|
||||||
|
|
||||||
|
MxPresenter* presenter;
|
||||||
|
MxPresenterListCursor cursor(m_presenters);
|
||||||
|
|
||||||
|
while (cursor.Next(presenter))
|
||||||
|
if (presenter->IsA("MxWavePresenter"))
|
||||||
|
((MxWavePresenter*) presenter)->VTable0x68();
|
||||||
}
|
}
|
||||||
|
|
||||||
// OFFSET: LEGO1 0x100aeab0
|
// OFFSET: LEGO1 0x100aeab0
|
||||||
|
@ -142,8 +159,18 @@ void MxSoundManager::Destroy()
|
||||||
Destroy(FALSE);
|
Destroy(FALSE);
|
||||||
}
|
}
|
||||||
|
|
||||||
// OFFSET: LEGO1 0x100aeac0 STUB
|
// OFFSET: LEGO1 0x100aeac0
|
||||||
void MxSoundManager::SetVolume(MxS32 p_volume)
|
void MxSoundManager::SetVolume(MxS32 p_volume)
|
||||||
{
|
{
|
||||||
// TODO
|
MxAudioManager::SetVolume(p_volume);
|
||||||
|
|
||||||
|
m_criticalSection.Enter();
|
||||||
|
|
||||||
|
MxPresenter* presenter;
|
||||||
|
MxPresenterListCursor cursor(m_presenters);
|
||||||
|
|
||||||
|
while (cursor.Next(presenter))
|
||||||
|
((MxAudioPresenter*) presenter)->vtable60(((MxAudioPresenter*) presenter)->vtable5c());
|
||||||
|
|
||||||
|
m_criticalSection.Leave();
|
||||||
}
|
}
|
||||||
|
|
|
@ -16,3 +16,21 @@ void MxWavePresenter::Init()
|
||||||
m_unk66 = 0;
|
m_unk66 = 0;
|
||||||
m_unk68 = 0;
|
m_unk68 = 0;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
// OFFSET: LEGO1 0x100b2440 STUB
|
||||||
|
void MxWavePresenter::VTable0x64()
|
||||||
|
{
|
||||||
|
// TODO
|
||||||
|
}
|
||||||
|
|
||||||
|
// OFFSET: LEGO1 0x100b2470 STUB
|
||||||
|
void MxWavePresenter::VTable0x68()
|
||||||
|
{
|
||||||
|
// TODO
|
||||||
|
}
|
||||||
|
|
||||||
|
// OFFSET: LEGO1 0x1000d6b0
|
||||||
|
undefined MxWavePresenter::VTable0x6c()
|
||||||
|
{
|
||||||
|
return m_unk68;
|
||||||
|
}
|
||||||
|
|
|
@ -26,6 +26,11 @@ class MxWavePresenter : public MxSoundPresenter {
|
||||||
return !strcmp(name, MxWavePresenter::ClassName()) || MxSoundPresenter::IsA(name);
|
return !strcmp(name, MxWavePresenter::ClassName()) || MxSoundPresenter::IsA(name);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
virtual void VTable0x64(); // vtable+0x64
|
||||||
|
virtual void VTable0x68(); // vtable+0x68
|
||||||
|
virtual undefined VTable0x6c(); // vtable+0x6c
|
||||||
|
|
||||||
|
private:
|
||||||
undefined4 m_unk54;
|
undefined4 m_unk54;
|
||||||
undefined4 m_unk58;
|
undefined4 m_unk58;
|
||||||
undefined4 m_unk5c;
|
undefined4 m_unk5c;
|
||||||
|
|
Loading…
Reference in a new issue