mirror of
https://github.com/isledecomp/isle.git
synced 2025-10-23 16:34:06 +00:00
LegoCacheSound and related STL (#560)
* LegoCacheSound and related STL * Changes/annotations --------- Co-authored-by: Christian Semmler <mail@csemmler.com>
This commit is contained in:
82
LEGO1/lego/legoomni/src/audio/legounknown100d5778.cpp
Normal file
82
LEGO1/lego/legoomni/src/audio/legounknown100d5778.cpp
Normal file
@@ -0,0 +1,82 @@
|
||||
#include "legounknown100d5778.h"
|
||||
|
||||
#include "legoomni.h"
|
||||
#include "legounksavedatawriter.h"
|
||||
|
||||
DECOMP_SIZE_ASSERT(LegoUnknown100d5778, 0x30)
|
||||
|
||||
// FUNCTION: LEGO1 0x10011630
|
||||
LegoUnknown100d5778::LegoUnknown100d5778()
|
||||
{
|
||||
Init();
|
||||
}
|
||||
|
||||
// FUNCTION: LEGO1 0x10011670
|
||||
LegoUnknown100d5778::~LegoUnknown100d5778()
|
||||
{
|
||||
Destroy();
|
||||
}
|
||||
|
||||
// FUNCTION: LEGO1 0x10011680
|
||||
void LegoUnknown100d5778::Init()
|
||||
{
|
||||
m_dsBuffer = NULL;
|
||||
m_unk0xc = NULL;
|
||||
m_unk0x10 = 0;
|
||||
m_unk0x18 = 0;
|
||||
m_unk0x14 = FALSE;
|
||||
m_unk0x15 = FALSE;
|
||||
m_unk0x2c = 79;
|
||||
}
|
||||
|
||||
// STUB: LEGO1 0x100116a0
|
||||
MxResult LegoUnknown100d5778::FUN_100116a0(LPDIRECTSOUND p_dsound, undefined4, undefined4 p_unk0x2c)
|
||||
{
|
||||
m_unk0x2c = p_unk0x2c;
|
||||
|
||||
if (MxOmni::IsSound3D()) {
|
||||
p_dsound->QueryInterface(IID_IDirectSoundBuffer, (LPVOID*) &m_dsBuffer);
|
||||
if (m_dsBuffer == NULL) {
|
||||
return FAILURE;
|
||||
}
|
||||
|
||||
// TODO
|
||||
}
|
||||
|
||||
// TODO
|
||||
|
||||
return SUCCESS;
|
||||
}
|
||||
|
||||
// FUNCTION: LEGO1 0x10011880
|
||||
void LegoUnknown100d5778::Destroy()
|
||||
{
|
||||
if (m_dsBuffer) {
|
||||
m_dsBuffer->Release();
|
||||
m_dsBuffer = NULL;
|
||||
}
|
||||
|
||||
if (m_unk0x14 && m_unk0xc && UnkSaveDataWriter()) {
|
||||
if (m_unk0x15) {
|
||||
UnkSaveDataWriter()->FUN_10083db0(m_unk0xc);
|
||||
}
|
||||
else {
|
||||
UnkSaveDataWriter()->FUN_10083f10(m_unk0xc);
|
||||
}
|
||||
}
|
||||
|
||||
Init();
|
||||
}
|
||||
|
||||
// STUB: LEGO1 0x100118e0
|
||||
undefined4 LegoUnknown100d5778::FUN_100118e0(LPDIRECTSOUNDBUFFER p_dsBuffer)
|
||||
{
|
||||
// TODO
|
||||
return 0;
|
||||
}
|
||||
|
||||
// STUB: LEGO1 0x10011ca0
|
||||
void LegoUnknown100d5778::FUN_10011ca0()
|
||||
{
|
||||
// TODO
|
||||
}
|
||||
Reference in New Issue
Block a user