mirror of
https://github.com/isledecomp/isle.git
synced 2025-10-23 00:14:22 +00:00
Reorganize sources and files (#414)
* Reorganize sources * Refactor * Remove relative paths * Renames * Fix gitignore * Remove stuff * Try fixing format script * Fix format * Fix format * Fix naming script * Test format * Fix format
This commit is contained in:

committed by
GitHub

parent
6a85e62406
commit
c47206617d
114
LEGO1/omni/include/mxactionnotificationparam.h
Normal file
114
LEGO1/omni/include/mxactionnotificationparam.h
Normal file
@@ -0,0 +1,114 @@
|
||||
#ifndef MXACTIONNOTIFICATIONPARAM_H
|
||||
#define MXACTIONNOTIFICATIONPARAM_H
|
||||
|
||||
#include "mxdsaction.h"
|
||||
#include "mxnotificationparam.h"
|
||||
|
||||
class MxPresenter;
|
||||
|
||||
// VTABLE: LEGO1 0x100d8350
|
||||
// SIZE 0x14
|
||||
class MxActionNotificationParam : public MxNotificationParam {
|
||||
public:
|
||||
inline MxActionNotificationParam(
|
||||
NotificationId p_type,
|
||||
MxCore* p_sender,
|
||||
MxDSAction* p_action,
|
||||
MxBool p_reallocAction
|
||||
)
|
||||
: MxNotificationParam(p_type, p_sender)
|
||||
{
|
||||
MxDSAction* oldAction = p_action;
|
||||
this->m_realloc = p_reallocAction;
|
||||
|
||||
if (p_reallocAction)
|
||||
this->m_action = new MxDSAction();
|
||||
else {
|
||||
this->m_action = oldAction;
|
||||
return;
|
||||
}
|
||||
|
||||
this->m_action->SetAtomId(oldAction->GetAtomId());
|
||||
this->m_action->SetObjectId(oldAction->GetObjectId());
|
||||
this->m_action->SetUnknown24(oldAction->GetUnknown24());
|
||||
}
|
||||
|
||||
// FUNCTION: LEGO1 0x10051050
|
||||
inline virtual ~MxActionNotificationParam() override
|
||||
{
|
||||
if (!this->m_realloc)
|
||||
return;
|
||||
|
||||
if (this->m_action)
|
||||
delete this->m_action;
|
||||
}
|
||||
|
||||
virtual MxNotificationParam* Clone() override; // vtable+0x4
|
||||
|
||||
inline MxDSAction* GetAction() { return m_action; }
|
||||
|
||||
protected:
|
||||
MxDSAction* m_action; // 0xc
|
||||
MxBool m_realloc; // 0x10
|
||||
};
|
||||
|
||||
// VTABLE: LEGO1 0x100dc210
|
||||
// SIZE 0x14
|
||||
class MxStartActionNotificationParam : public MxActionNotificationParam {
|
||||
public:
|
||||
inline MxStartActionNotificationParam(
|
||||
NotificationId p_type,
|
||||
MxCore* p_sender,
|
||||
MxDSAction* p_action,
|
||||
MxBool p_reallocAction
|
||||
)
|
||||
: MxActionNotificationParam(p_type, p_sender, p_action, p_reallocAction)
|
||||
{
|
||||
}
|
||||
|
||||
virtual MxNotificationParam* Clone() override; // vtable+0x4
|
||||
};
|
||||
|
||||
// VTABLE: LEGO1 0x100d8358
|
||||
// SIZE 0x14
|
||||
class MxEndActionNotificationParam : public MxActionNotificationParam {
|
||||
public:
|
||||
inline MxEndActionNotificationParam(
|
||||
NotificationId p_type,
|
||||
MxCore* p_sender,
|
||||
MxDSAction* p_action,
|
||||
MxBool p_reallocAction
|
||||
)
|
||||
: MxActionNotificationParam(p_type, p_sender, p_action, p_reallocAction)
|
||||
{
|
||||
}
|
||||
|
||||
virtual MxNotificationParam* Clone() override; // vtable+0x4
|
||||
};
|
||||
|
||||
// VTABLE: LEGO1 0x100dc208
|
||||
// SIZE 0x18
|
||||
class MxType4NotificationParam : public MxActionNotificationParam {
|
||||
public:
|
||||
inline MxType4NotificationParam(MxCore* p_sender, MxDSAction* p_action, MxPresenter* p_unk0x14)
|
||||
: MxActionNotificationParam(TYPE4, p_sender, p_action, FALSE)
|
||||
{
|
||||
m_unk0x14 = p_unk0x14;
|
||||
}
|
||||
|
||||
virtual MxNotificationParam* Clone() override; // vtable+0x4
|
||||
|
||||
private:
|
||||
MxPresenter* m_unk0x14; // 0x14
|
||||
};
|
||||
|
||||
// SYNTHETIC: LEGO1 0x100513a0
|
||||
// MxEndActionNotificationParam::`scalar deleting destructor'
|
||||
|
||||
// SYNTHETIC: LEGO1 0x100b0430
|
||||
// MxStartActionNotificationParam::`scalar deleting destructor'
|
||||
|
||||
// SYNTHETIC: LEGO1 0x100b05c0
|
||||
// MxType4NotificationParam::`scalar deleting destructor'
|
||||
|
||||
#endif
|
36
LEGO1/omni/include/mxatomid.h
Normal file
36
LEGO1/omni/include/mxatomid.h
Normal file
@@ -0,0 +1,36 @@
|
||||
#ifndef MXATOMID_H
|
||||
#define MXATOMID_H
|
||||
|
||||
#include "mxatomidcounter.h"
|
||||
#include "mxtypes.h"
|
||||
|
||||
enum LookupMode {
|
||||
LookupMode_Exact = 0,
|
||||
LookupMode_LowerCase = 1,
|
||||
LookupMode_UpperCase = 2,
|
||||
LookupMode_LowerCase2 = 3
|
||||
};
|
||||
|
||||
class MxAtomId {
|
||||
public:
|
||||
__declspec(dllexport) MxAtomId(const char*, LookupMode);
|
||||
__declspec(dllexport) MxAtomId& operator=(const MxAtomId& p_atomId);
|
||||
__declspec(dllexport) ~MxAtomId();
|
||||
|
||||
MxAtomId() { this->m_internal = 0; }
|
||||
|
||||
inline MxBool operator==(const MxAtomId& p_atomId) const { return this->m_internal == p_atomId.m_internal; }
|
||||
inline MxBool operator!=(const MxAtomId& p_atomId) const { return this->m_internal != p_atomId.m_internal; }
|
||||
|
||||
void Clear();
|
||||
|
||||
const char* GetInternal() const { return m_internal; }
|
||||
|
||||
private:
|
||||
MxAtomIdCounter* GetCounter(const char*, LookupMode);
|
||||
void Destroy();
|
||||
|
||||
const char* m_internal;
|
||||
};
|
||||
|
||||
#endif // MXATOMID_H
|
46
LEGO1/omni/include/mxatomidcounter.h
Normal file
46
LEGO1/omni/include/mxatomidcounter.h
Normal file
@@ -0,0 +1,46 @@
|
||||
#ifndef MXATOMIDCOUNTER_H
|
||||
#define MXATOMIDCOUNTER_H
|
||||
|
||||
#include "mxstl/stlcompat.h"
|
||||
#include "mxstring.h"
|
||||
|
||||
// Counts the number of existing MxAtomId objects based
|
||||
// on the matching char* string. A <map> seems fit for purpose here:
|
||||
// We have an MxString as a key and MxU16 as the value.
|
||||
// And yet a <set> is the best match. The malloc in MxOmni::Create
|
||||
// for the _Nil node asks for more bytes than a regular node if a <map>
|
||||
// is used, but all nodes are 20 bytes wide with a <set>.
|
||||
// Also: the increment/decrement methods suggest a custom type was used
|
||||
// for the combined key_value_pair, which doesn't seem possible with <map>.
|
||||
|
||||
// SIZE 0x14
|
||||
class MxAtomIdCounter {
|
||||
public:
|
||||
// always inlined
|
||||
MxAtomIdCounter(const char* p_str)
|
||||
{
|
||||
m_key = p_str;
|
||||
m_value = 0;
|
||||
}
|
||||
|
||||
void Inc();
|
||||
void Dec();
|
||||
inline MxString* GetKey() { return &m_key; };
|
||||
inline MxU16 GetValue() { return m_value; };
|
||||
|
||||
private:
|
||||
MxString m_key;
|
||||
MxU16 m_value;
|
||||
};
|
||||
|
||||
struct MxAtomIdCounterCompare {
|
||||
// FUNCTION: LEGO1 0x100ad120
|
||||
int operator()(MxAtomIdCounter* const& p_val0, MxAtomIdCounter* const& p_val1) const
|
||||
{
|
||||
return strcmp(p_val0->GetKey()->GetData(), p_val1->GetKey()->GetData()) > 0;
|
||||
}
|
||||
};
|
||||
|
||||
class MxAtomIdCounterSet : public set<MxAtomIdCounter*, MxAtomIdCounterCompare> {};
|
||||
|
||||
#endif // MXATOMIDCOUNTER_H
|
29
LEGO1/omni/include/mxaudiomanager.h
Normal file
29
LEGO1/omni/include/mxaudiomanager.h
Normal file
@@ -0,0 +1,29 @@
|
||||
#ifndef MXAUDIOMANAGER_H
|
||||
#define MXAUDIOMANAGER_H
|
||||
|
||||
#include "decomp.h"
|
||||
#include "mxmediamanager.h"
|
||||
|
||||
// VTABLE: LEGO1 0x100dc6e0
|
||||
class MxAudioManager : public MxMediaManager {
|
||||
public:
|
||||
MxAudioManager();
|
||||
virtual ~MxAudioManager() override;
|
||||
|
||||
virtual MxResult InitPresenters() override; // vtable+14
|
||||
virtual void Destroy() override; // vtable+18
|
||||
virtual MxS32 GetVolume(); // vtable+28
|
||||
virtual void SetVolume(MxS32 p_volume); // vtable+2c
|
||||
|
||||
private:
|
||||
void Destroy(MxBool p_fromDestructor);
|
||||
|
||||
static MxS32 g_count;
|
||||
|
||||
protected:
|
||||
void Init();
|
||||
|
||||
MxS32 m_volume; // 0x2c
|
||||
};
|
||||
|
||||
#endif // MXAUDIOMANAGER_H
|
33
LEGO1/omni/include/mxaudiopresenter.h
Normal file
33
LEGO1/omni/include/mxaudiopresenter.h
Normal file
@@ -0,0 +1,33 @@
|
||||
#ifndef MXAUDIOPRESENTER_H
|
||||
#define MXAUDIOPRESENTER_H
|
||||
|
||||
#include "decomp.h"
|
||||
#include "mxmediapresenter.h"
|
||||
|
||||
// VTABLE: LEGO1 0x100d4c70
|
||||
// SIZE 0x54
|
||||
class MxAudioPresenter : public MxMediaPresenter {
|
||||
public:
|
||||
MxAudioPresenter() { m_volume = 100; }
|
||||
|
||||
// FUNCTION: LEGO1 0x1000d280
|
||||
inline virtual const char* ClassName() const override // vtable+0x0c
|
||||
{
|
||||
// STRING: LEGO1 0x100f078c
|
||||
return "MxAudioPresenter";
|
||||
}
|
||||
|
||||
// FUNCTION: LEGO1 0x1000d290
|
||||
inline virtual MxBool IsA(const char* p_name) const override // vtable+0x10
|
||||
{
|
||||
return !strcmp(p_name, MxAudioPresenter::ClassName()) || MxMediaPresenter::IsA(p_name);
|
||||
}
|
||||
|
||||
virtual MxS32 GetVolume(); // vtable+0x5c
|
||||
virtual void SetVolume(MxS32 p_volume); // vtable+0x60
|
||||
|
||||
protected:
|
||||
MxS32 m_volume;
|
||||
};
|
||||
|
||||
#endif // MXAUDIOPRESENTER_H
|
15
LEGO1/omni/include/mxautolocker.h
Normal file
15
LEGO1/omni/include/mxautolocker.h
Normal file
@@ -0,0 +1,15 @@
|
||||
#ifndef MXAUTOLOCKER_H
|
||||
#define MXAUTOLOCKER_H
|
||||
|
||||
#include "mxcriticalsection.h"
|
||||
|
||||
class MxAutoLocker {
|
||||
public:
|
||||
MxAutoLocker(MxCriticalSection* p_criticalSection);
|
||||
~MxAutoLocker();
|
||||
|
||||
private:
|
||||
MxCriticalSection* m_criticalSection;
|
||||
};
|
||||
|
||||
#endif // MXAUTOLOCKER_H
|
66
LEGO1/omni/include/mxbackgroundaudiomanager.h
Normal file
66
LEGO1/omni/include/mxbackgroundaudiomanager.h
Normal file
@@ -0,0 +1,66 @@
|
||||
#ifndef MXBACKGROUNDAUDIOMANAGER_H
|
||||
#define MXBACKGROUNDAUDIOMANAGER_H
|
||||
|
||||
#include "mxaudiopresenter.h"
|
||||
#include "mxcore.h"
|
||||
#include "mxdsaction.h"
|
||||
#include "mxnotificationmanager.h"
|
||||
#include "mxpresenter.h"
|
||||
#include "mxtypes.h"
|
||||
|
||||
// VTABLE: LEGO1 0x100d9fe8
|
||||
// SIZE 0x150
|
||||
class MxBackgroundAudioManager : public MxCore {
|
||||
public:
|
||||
MxBackgroundAudioManager();
|
||||
virtual ~MxBackgroundAudioManager() override;
|
||||
|
||||
virtual MxLong Notify(MxParam& p_param) override; // vtable+0x04
|
||||
virtual MxResult Tickle() override; // vtable+0x08
|
||||
|
||||
// FUNCTION: LEGO1 0x1007eb70
|
||||
inline virtual const char* ClassName() const override // vtable+0x0c
|
||||
{
|
||||
// STRING: LEGO1 0x100f7ac4
|
||||
return "MxBackgroundAudioManager";
|
||||
}
|
||||
|
||||
// FUNCTION: LEGO1 0x1007eb80
|
||||
inline virtual MxBool IsA(const char* p_name) const override // vtable+0x10
|
||||
{
|
||||
return !strcmp(p_name, MxBackgroundAudioManager::ClassName()) || MxCore::IsA(p_name);
|
||||
}
|
||||
|
||||
void StartAction(MxParam& p_param);
|
||||
void StopAction(MxParam& p_param);
|
||||
MxResult PlayMusic(MxDSAction& p_action, undefined4 p_unk0x140, undefined4 p_unk0x13c);
|
||||
|
||||
void FUN_1007ee70();
|
||||
void FUN_1007ef40();
|
||||
void FadeInOrFadeOut();
|
||||
|
||||
__declspec(dllexport) void Enable(MxBool p_enable);
|
||||
virtual MxResult Create(MxAtomId& p_script, MxU32 p_frequencyMS);
|
||||
|
||||
void Stop();
|
||||
void LowerVolume();
|
||||
void RaiseVolume();
|
||||
|
||||
private:
|
||||
void Init();
|
||||
MxResult OpenMusic(MxAtomId& p_script);
|
||||
void DestroyMusic();
|
||||
|
||||
MxBool m_musicEnabled; // 0x8
|
||||
MxDSAction m_action1; // 0xc
|
||||
MxAudioPresenter* m_unk0xa0;
|
||||
MxDSAction m_action2; // 0xa4
|
||||
MxAudioPresenter* m_unk0x138;
|
||||
MxS32 m_unk0x13c;
|
||||
MxS32 m_unk0x140;
|
||||
MxS32 m_targetVolume;
|
||||
MxS16 m_unk0x148;
|
||||
MxAtomId m_script;
|
||||
};
|
||||
|
||||
#endif // MXBACKGROUNDAUDIOMANAGER_H
|
103
LEGO1/omni/include/mxbitmap.h
Normal file
103
LEGO1/omni/include/mxbitmap.h
Normal file
@@ -0,0 +1,103 @@
|
||||
#ifndef MXBITMAP_H
|
||||
#define MXBITMAP_H
|
||||
|
||||
#include "mxcore.h"
|
||||
#include "mxpalette.h"
|
||||
#include "mxtypes.h"
|
||||
|
||||
#include <stdlib.h>
|
||||
|
||||
// The stock BITMAPINFO struct from wingdi.h only makes room for one color
|
||||
// in the palette. It seems like the expectation (if you use the struct)
|
||||
// is to malloc as much as you actually need, and then index into the array
|
||||
// anyway even though its stated size is [1].
|
||||
// https://learn.microsoft.com/en-us/windows/win32/api/wingdi/ns-wingdi-bitmapinfo
|
||||
// In our case, the size 0x428 is used frequently, which matches
|
||||
// a 40-byte header plus 256 colors, so just use that as our template.
|
||||
|
||||
// SIZE 0x428
|
||||
struct MxBITMAPINFO {
|
||||
BITMAPINFOHEADER m_bmiHeader;
|
||||
RGBQUAD m_bmiColors[256];
|
||||
|
||||
static MxU32 Size() { return sizeof(MxBITMAPINFO); }
|
||||
};
|
||||
|
||||
// Non-standard value for biCompression in the BITMAPINFOHEADER struct.
|
||||
// By default, uncompressed bitmaps (BI_RGB) are stored in bottom-up order.
|
||||
// You can specify that the bitmap has top-down order instead by providing
|
||||
// a negative number for biHeight. It could be that Mindscape decided on a
|
||||
// belt & suspenders approach here.
|
||||
#define BI_RGB_TOPDOWN 0x10
|
||||
|
||||
// SIZE 0x20
|
||||
// VTABLE: LEGO1 0x100dc7b0
|
||||
class MxBitmap : public MxCore {
|
||||
public:
|
||||
__declspec(dllexport) MxBitmap();
|
||||
__declspec(dllexport) virtual ~MxBitmap(); // vtable+00
|
||||
|
||||
virtual MxResult ImportBitmap(MxBitmap* p_bitmap); // vtable+14
|
||||
virtual MxResult ImportBitmapInfo(MxBITMAPINFO* p_info); // vtable+18
|
||||
virtual MxResult SetSize(MxS32 p_width, MxS32 p_height, MxPalette* p_palette, MxBool); // vtable+1c
|
||||
virtual MxResult LoadFile(HANDLE p_handle); // vtable+20
|
||||
__declspec(dllexport) virtual MxLong Read(const char* p_filename); // vtable+24
|
||||
virtual int VTable0x28(int);
|
||||
virtual void VTable0x2c(int, int, int, int, int, int, int);
|
||||
virtual void VTable0x30(int, int, int, int, int, int, int);
|
||||
__declspec(dllexport) virtual MxPalette* CreatePalette(); // vtable+34
|
||||
virtual void ImportPalette(MxPalette* p_palette); // vtable+38
|
||||
virtual MxResult SetBitDepth(MxBool); // vtable+3c
|
||||
virtual MxResult StretchBits(
|
||||
HDC p_hdc,
|
||||
MxS32 p_xSrc,
|
||||
MxS32 p_ySrc,
|
||||
MxS32 p_xDest,
|
||||
MxS32 p_yDest,
|
||||
MxS32 p_destWidth,
|
||||
MxS32 p_destHeight
|
||||
); // vtable+40
|
||||
|
||||
// Bit mask trick to round up to the nearest multiple of four.
|
||||
// Pixel data may be stored with padding.
|
||||
// https://learn.microsoft.com/en-us/windows/win32/medfound/image-stride
|
||||
inline MxLong AlignToFourByte(MxLong p_value) const { return (p_value + 3) & -4; }
|
||||
|
||||
// Same as the one from legoutil.h, but flipped the other way
|
||||
// TODO: While it's not outside the realm of possibility that they
|
||||
// reimplemented Abs for only this file, that seems odd, right?
|
||||
inline MxLong AbsFlipped(MxLong p_value) const { return p_value > 0 ? p_value : -p_value; }
|
||||
|
||||
inline BITMAPINFOHEADER* GetBmiHeader() const { return m_bmiHeader; }
|
||||
inline MxLong GetBmiWidth() const { return m_bmiHeader->biWidth; }
|
||||
inline MxLong GetBmiStride() const { return ((m_bmiHeader->biWidth + 3) & -4); }
|
||||
inline MxLong GetBmiHeight() const { return m_bmiHeader->biHeight; }
|
||||
inline MxLong GetBmiHeightAbs() const { return AbsFlipped(m_bmiHeader->biHeight); }
|
||||
inline MxU8* GetBitmapData() const { return m_data; }
|
||||
inline MxBITMAPINFO* GetBitmapInfo() const { return m_info; }
|
||||
inline MxLong GetDataSize() const
|
||||
{
|
||||
MxLong absHeight = GetBmiHeightAbs();
|
||||
MxLong alignedWidth = AlignToFourByte(m_bmiHeader->biWidth);
|
||||
return alignedWidth * absHeight;
|
||||
}
|
||||
inline MxLong GetAdjustedStride()
|
||||
{
|
||||
if (m_bmiHeader->biCompression == BI_RGB_TOPDOWN || m_bmiHeader->biHeight < 0)
|
||||
return GetBmiStride();
|
||||
else
|
||||
return -GetBmiStride();
|
||||
}
|
||||
|
||||
private:
|
||||
MxResult ImportColorsToPalette(RGBQUAD*, MxPalette*);
|
||||
|
||||
MxBITMAPINFO* m_info; // 0x8
|
||||
BITMAPINFOHEADER* m_bmiHeader; // 0xc
|
||||
RGBQUAD* m_paletteData; // 0x10
|
||||
MxU8* m_data; // 0x14
|
||||
MxBool m_isHighColor; // 0x18
|
||||
MxPalette* m_palette; // 0x1c
|
||||
};
|
||||
|
||||
#endif // MXBITMAP_H
|
27
LEGO1/omni/include/mxcollection.h
Normal file
27
LEGO1/omni/include/mxcollection.h
Normal file
@@ -0,0 +1,27 @@
|
||||
#ifndef MXCOLLECTION_H
|
||||
#define MXCOLLECTION_H
|
||||
|
||||
#include "mxcore.h"
|
||||
|
||||
template <class T>
|
||||
class MxCollection : public MxCore {
|
||||
public:
|
||||
MxCollection()
|
||||
{
|
||||
m_count = 0;
|
||||
SetDestroy(Destroy);
|
||||
}
|
||||
|
||||
static void Destroy(T){};
|
||||
|
||||
void SetDestroy(void (*p_customDestructor)(T)) { this->m_customDestructor = p_customDestructor; }
|
||||
|
||||
virtual ~MxCollection() {}
|
||||
virtual MxS8 Compare(T, T) { return 0; }
|
||||
|
||||
protected:
|
||||
MxU32 m_count; // 0x8
|
||||
void (*m_customDestructor)(T); // 0xc
|
||||
};
|
||||
|
||||
#endif // MXCOLLECTION_H
|
40
LEGO1/omni/include/mxcompositemediapresenter.h
Normal file
40
LEGO1/omni/include/mxcompositemediapresenter.h
Normal file
@@ -0,0 +1,40 @@
|
||||
#ifndef MXCOMPOSITEMEDIAPRESENTER_H
|
||||
#define MXCOMPOSITEMEDIAPRESENTER_H
|
||||
|
||||
#include "mxcompositepresenter.h"
|
||||
|
||||
// VTABLE: LEGO1 0x100d96b0
|
||||
// SIZE 0x50
|
||||
class MxCompositeMediaPresenter : public MxCompositePresenter {
|
||||
public:
|
||||
MxCompositeMediaPresenter();
|
||||
virtual ~MxCompositeMediaPresenter() override;
|
||||
|
||||
virtual MxResult Tickle() override; // vtable+0x08
|
||||
|
||||
// FUNCTION: LEGO1 0x10073f10
|
||||
inline virtual const char* ClassName() const override // vtable+0x0c
|
||||
{
|
||||
// STRING: LEGO1 0x100f02d4
|
||||
return "MxCompositeMediaPresenter";
|
||||
}
|
||||
|
||||
// FUNCTION: LEGO1 0x10073f20
|
||||
inline virtual MxBool IsA(const char* p_name) const override // vtable+0x10
|
||||
{
|
||||
return !strcmp(p_name, MxCompositeMediaPresenter::ClassName()) || MxCompositePresenter::IsA(p_name);
|
||||
}
|
||||
|
||||
virtual void StartingTickle() override; // vtable+0x1c
|
||||
virtual MxResult StartAction(MxStreamController*, MxDSAction* p_action) override; // vtable+0x3c
|
||||
virtual MxResult PutData() override; // vtable+0x4c
|
||||
|
||||
private:
|
||||
MxS16 m_unk0x4c; // 0x4c
|
||||
MxBool m_unk0x4e; // 0x4e
|
||||
};
|
||||
|
||||
// SYNTHETIC: LEGO1 0x10074000
|
||||
// MxCompositeMediaPresenter::`scalar deleting destructor'
|
||||
|
||||
#endif // MXCOMPOSITEMEDIAPRESENTER_H
|
64
LEGO1/omni/include/mxcompositepresenter.h
Normal file
64
LEGO1/omni/include/mxcompositepresenter.h
Normal file
@@ -0,0 +1,64 @@
|
||||
#ifndef MXCOMPOSITEPRESENTER_H
|
||||
#define MXCOMPOSITEPRESENTER_H
|
||||
|
||||
#include "mxactionnotificationparam.h"
|
||||
#include "mxpresenter.h"
|
||||
#include "mxstl/stlcompat.h"
|
||||
|
||||
class MxCompositePresenterList : public list<MxPresenter*> {};
|
||||
|
||||
// VTABLE: LEGO1 0x100dc618
|
||||
// SIZE 0x4c
|
||||
class MxCompositePresenter : public MxPresenter {
|
||||
public:
|
||||
MxCompositePresenter();
|
||||
virtual ~MxCompositePresenter() override; // vtable+0x0
|
||||
|
||||
virtual MxLong Notify(MxParam& p_param) override; // vtable+0x04
|
||||
|
||||
// FUNCTION: LEGO1 0x100b6210
|
||||
inline virtual const char* ClassName() const override // vtable+0x0c
|
||||
{
|
||||
// STRING: LEGO1 0x100f0774
|
||||
return "MxCompositePresenter";
|
||||
}
|
||||
|
||||
// FUNCTION: LEGO1 0x100b6220
|
||||
inline virtual MxBool IsA(const char* p_name) const override // vtable+0x10
|
||||
{
|
||||
return !strcmp(p_name, MxCompositePresenter::ClassName()) || MxPresenter::IsA(p_name);
|
||||
}
|
||||
|
||||
virtual MxResult StartAction(MxStreamController* p_controller, MxDSAction* p_action) override; // vtable+0x3c
|
||||
virtual void EndAction() override; // vtable+0x40
|
||||
virtual void SetTickleState(TickleState p_tickleState) override; // vtable+0x44
|
||||
virtual MxBool HasTickleStatePassed(TickleState p_tickleState) override; // vtable+0x48
|
||||
virtual void Enable(MxBool p_enable) override; // vtable+0x54
|
||||
virtual void VTable0x58(MxEndActionNotificationParam& p_param); // vtable+0x58
|
||||
virtual void VTable0x5c(MxNotificationParam& p_param); // vtable+0x5c
|
||||
virtual void VTable0x60(MxPresenter* p_presenter); // vtable+0x60
|
||||
virtual MxBool VTable0x64(undefined4 p_undefined); // vtable+0x64
|
||||
|
||||
protected:
|
||||
MxCompositePresenterList m_list; // 0x40
|
||||
};
|
||||
|
||||
// TEMPLATE: LEGO1 0x1004ae90
|
||||
// list<MxPresenter *,allocator<MxPresenter *> >::_Buynode
|
||||
|
||||
// TEMPLATE: LEGO1 0x100b61a0
|
||||
// list<MxPresenter *,allocator<MxPresenter *> >::~list<MxPresenter *,allocator<MxPresenter *> >
|
||||
|
||||
// SYNTHETIC: LEGO1 0x100b62d0
|
||||
// MxCompositePresenter::`scalar deleting destructor'
|
||||
|
||||
// FUNCTION: LEGO1 0x100b62f0
|
||||
// MxCompositePresenterList::~MxCompositePresenterList
|
||||
|
||||
// TEMPLATE: LEGO1 0x100b6340
|
||||
// List<MxPresenter *>::~List<MxPresenter *>
|
||||
|
||||
// TEMPLATE: LEGO1 0x100b6cd0
|
||||
// MxList<MxDSAction *>::DeleteEntry
|
||||
|
||||
#endif // MXCOMPOSITEPRESENTER_H
|
54
LEGO1/omni/include/mxcontrolpresenter.h
Normal file
54
LEGO1/omni/include/mxcontrolpresenter.h
Normal file
@@ -0,0 +1,54 @@
|
||||
#ifndef MXCONTROLPRESENTER_H
|
||||
#define MXCONTROLPRESENTER_H
|
||||
|
||||
#include "decomp.h"
|
||||
#include "mxcompositepresenter.h"
|
||||
|
||||
// VTABLE: LEGO1 0x100d7b88
|
||||
// SIZE 0x5c
|
||||
class MxControlPresenter : public MxCompositePresenter {
|
||||
public:
|
||||
MxControlPresenter();
|
||||
virtual ~MxControlPresenter() override;
|
||||
|
||||
// FUNCTION: LEGO1 0x10044000
|
||||
inline virtual const char* ClassName() const override // vtable+0x0c
|
||||
{
|
||||
// STRING: LEGO1 0x100f0514
|
||||
return "MxControlPresenter";
|
||||
}
|
||||
|
||||
// FUNCTION: LEGO1 0x10044010
|
||||
inline virtual MxBool IsA(const char* p_name) const override // vtable+0x10
|
||||
{
|
||||
return !strcmp(p_name, MxControlPresenter::ClassName()) || MxCompositePresenter::IsA(p_name);
|
||||
}
|
||||
|
||||
virtual void ReadyTickle() override; // vtable+0x18
|
||||
virtual void RepeatingTickle() override; // vtable+0x24
|
||||
virtual void ParseExtra() override; // vtable+0x30
|
||||
virtual MxResult AddToManager() override; // vtable+0x34
|
||||
virtual MxResult StartAction(MxStreamController*, MxDSAction*) override; // vtable+0x3c
|
||||
virtual void EndAction() override; // vtable+0x40
|
||||
virtual MxBool HasTickleStatePassed(TickleState p_tickleState) override; // vtable+0x48
|
||||
virtual void Enable(MxBool p_enable) override; // vtable+0x54
|
||||
virtual MxBool VTable0x64(undefined4 p_undefined) override; // vtable+0x64
|
||||
virtual void VTable0x68(MxBool p_undefined); // vtable+0x68
|
||||
|
||||
private:
|
||||
MxBool FUN_10044270(undefined4, undefined4, undefined4*);
|
||||
MxBool FUN_10044480(undefined4, undefined4*);
|
||||
void FUN_10044540(undefined2);
|
||||
|
||||
undefined2 m_unk0x4c; // 0x4c
|
||||
MxS16 m_unk0x4e; // 0x4e
|
||||
MxBool m_unk0x50; // 0x50
|
||||
undefined2 m_unk0x52; // 0x52
|
||||
undefined2 m_unk0x54; // 0x54
|
||||
undefined4* m_unk0x58; // 0x58
|
||||
};
|
||||
|
||||
// SYNTHETIC: LEGO1 0x100440f0
|
||||
// MxControlPresenter::`scalar deleting destructor'
|
||||
|
||||
#endif // MXCONTROLPRESENTER_H
|
39
LEGO1/omni/include/mxcore.h
Normal file
39
LEGO1/omni/include/mxcore.h
Normal file
@@ -0,0 +1,39 @@
|
||||
#ifndef MXCORE_H
|
||||
#define MXCORE_H
|
||||
|
||||
#include "compat.h"
|
||||
#include "mxtypes.h"
|
||||
|
||||
#include <string.h>
|
||||
|
||||
class MxParam;
|
||||
|
||||
// VTABLE: LEGO1 0x100dc0f8
|
||||
// SIZE 0x8
|
||||
class MxCore {
|
||||
public:
|
||||
__declspec(dllexport) MxCore();
|
||||
__declspec(dllexport) virtual ~MxCore(); // vtable+00
|
||||
__declspec(dllexport) virtual MxLong Notify(MxParam& p_param); // vtable+04
|
||||
virtual MxResult Tickle(); // vtable+08
|
||||
|
||||
// FUNCTION: LEGO1 0x100144c0
|
||||
inline virtual const char* ClassName() const // vtable+0c
|
||||
{
|
||||
// STRING: LEGO1 0x100f007c
|
||||
return "MxCore";
|
||||
}
|
||||
|
||||
// FUNCTION: LEGO1 0x100140d0
|
||||
inline virtual MxBool IsA(const char* p_name) const // vtable+10
|
||||
{
|
||||
return !strcmp(p_name, MxCore::ClassName());
|
||||
}
|
||||
|
||||
inline MxU32 GetId() { return m_id; }
|
||||
|
||||
private:
|
||||
MxU32 m_id; // 0x04
|
||||
};
|
||||
|
||||
#endif // MXCORE_H
|
20
LEGO1/omni/include/mxcriticalsection.h
Normal file
20
LEGO1/omni/include/mxcriticalsection.h
Normal file
@@ -0,0 +1,20 @@
|
||||
#ifndef MXCRITICALSECTION_H
|
||||
#define MXCRITICALSECTION_H
|
||||
|
||||
#include <windows.h>
|
||||
|
||||
// SIZE 0x1c
|
||||
class MxCriticalSection {
|
||||
public:
|
||||
__declspec(dllexport) MxCriticalSection();
|
||||
__declspec(dllexport) ~MxCriticalSection();
|
||||
__declspec(dllexport) static void SetDoMutex();
|
||||
void Enter();
|
||||
void Leave();
|
||||
|
||||
private:
|
||||
CRITICAL_SECTION m_criticalSection; // 0x00
|
||||
HANDLE m_mutex; // 0x18
|
||||
};
|
||||
|
||||
#endif // MXCRITICALSECTION_H
|
87
LEGO1/omni/include/mxdiskstreamcontroller.h
Normal file
87
LEGO1/omni/include/mxdiskstreamcontroller.h
Normal file
@@ -0,0 +1,87 @@
|
||||
#ifndef MXDISKSTREAMCONTROLLER_H
|
||||
#define MXDISKSTREAMCONTROLLER_H
|
||||
|
||||
#include "decomp.h"
|
||||
#include "mxdsbuffer.h"
|
||||
#include "mxdsstreamingaction.h"
|
||||
#include "mxstl/stlcompat.h"
|
||||
#include "mxstreamcontroller.h"
|
||||
#include "mxtypes.h"
|
||||
|
||||
#include <string.h>
|
||||
|
||||
// VTABLE: LEGO1 0x100dccb8
|
||||
// SIZE 0xc8
|
||||
class MxDiskStreamController : public MxStreamController {
|
||||
public:
|
||||
MxDiskStreamController();
|
||||
virtual ~MxDiskStreamController() override;
|
||||
|
||||
virtual MxResult Tickle() override; // vtable+0x8
|
||||
|
||||
// FUNCTION: LEGO1 0x100c7360
|
||||
inline virtual const char* ClassName() const override // vtable+0x0c
|
||||
{
|
||||
// STRING: LEGO1 0x10102144
|
||||
return "MxDiskStreamController";
|
||||
}
|
||||
|
||||
// FUNCTION: LEGO1 0x100c7370
|
||||
inline virtual MxBool IsA(const char* p_name) const override // vtable+0x10
|
||||
{
|
||||
return !strcmp(p_name, MxDiskStreamController::ClassName()) || MxStreamController::IsA(p_name);
|
||||
}
|
||||
|
||||
virtual MxResult Open(const char* p_filename) override; // vtable+0x14
|
||||
virtual MxResult VTable0x18(undefined4, undefined4) override; // vtable+0x18
|
||||
virtual MxResult VTable0x20(MxDSAction* p_action) override; // vtable+0x20
|
||||
virtual MxResult VTable0x24(MxDSAction* p_action) override; // vtable+0x24
|
||||
virtual MxDSStreamingAction* VTable0x28() override; // vtable+0x28
|
||||
virtual MxResult VTable0x30(MxDSAction* p_action) override; // vtable+0x30
|
||||
virtual MxResult VTable0x34(undefined4); // vtable+0x34
|
||||
|
||||
inline MxBool GetUnk0xc4() const { return m_unk0xc4; }
|
||||
|
||||
void FUN_100c7f40(MxDSStreamingAction* p_streamingaction);
|
||||
void FUN_100c8670(MxDSStreamingAction* p_streamingAction);
|
||||
void InsertToList74(MxDSBuffer* p_buffer);
|
||||
void FUN_100c7cb0(MxDSStreamingAction* p_action);
|
||||
|
||||
private:
|
||||
MxStreamListMxDSAction m_list0x64; // 0x64
|
||||
MxBool m_unk0x70; // 0x70
|
||||
list<MxDSBuffer*> m_list0x74; // 0x74
|
||||
MxStreamListMxDSAction m_list0x80; // 0x80
|
||||
undefined2 m_unk0x8c; // 0x8c
|
||||
MxStreamListMxDSAction m_list0x90; // 0x90
|
||||
MxCriticalSection m_critical9c; // 0x9c
|
||||
MxStreamListMxDSAction m_list0xb8; // 0xb8
|
||||
MxBool m_unk0xc4; // 0xc4
|
||||
|
||||
MxResult FUN_100c7890(MxDSStreamingAction* p_action);
|
||||
void FUN_100c7970();
|
||||
void FUN_100c7ce0(MxDSBuffer* p_buffer);
|
||||
MxResult FUN_100c7d10();
|
||||
void FUN_100c7980();
|
||||
MxDSStreamingAction* FUN_100c7db0();
|
||||
MxResult FUN_100c8360(MxDSStreamingAction* p_action);
|
||||
void FUN_100c8540();
|
||||
void FUN_100c8720();
|
||||
};
|
||||
|
||||
// TEMPLATE: LEGO1 0x100c7330
|
||||
// list<MxDSAction *,allocator<MxDSAction *> >::_Buynode
|
||||
|
||||
// TEMPLATE: LEGO1 0x100c7420
|
||||
// list<MxDSBuffer *,allocator<MxDSBuffer *> >::~list<MxDSBuffer *,allocator<MxDSBuffer *> >
|
||||
|
||||
// TEMPLATE: LEGO1 0x100c7490
|
||||
// list<MxDSBuffer *,allocator<MxDSBuffer *> >::_Buynode
|
||||
|
||||
// SYNTHETIC: LEGO1 0x100c74c0
|
||||
// MxDiskStreamController::`scalar deleting destructor'
|
||||
|
||||
// TEMPLATE: LEGO1 0x100c74e0
|
||||
// List<MxDSBuffer *>::~List<MxDSBuffer *>
|
||||
|
||||
#endif // MXDISKSTREAMCONTROLLER_H
|
70
LEGO1/omni/include/mxdiskstreamprovider.h
Normal file
70
LEGO1/omni/include/mxdiskstreamprovider.h
Normal file
@@ -0,0 +1,70 @@
|
||||
#ifndef MXDISKSTREAMPROVIDER_H
|
||||
#define MXDISKSTREAMPROVIDER_H
|
||||
|
||||
#include "compat.h"
|
||||
#include "decomp.h"
|
||||
#include "mxcriticalsection.h"
|
||||
#include "mxdsaction.h"
|
||||
#include "mxstreamlist.h"
|
||||
#include "mxstreamprovider.h"
|
||||
#include "mxthread.h"
|
||||
|
||||
class MxDiskStreamProvider;
|
||||
class MxDSStreamingAction;
|
||||
|
||||
// VTABLE: LEGO1 0x100dd130
|
||||
// SIZE 0x1c
|
||||
class MxDiskStreamProviderThread : public MxThread {
|
||||
public:
|
||||
inline MxDiskStreamProviderThread() : MxThread() { m_target = NULL; }
|
||||
|
||||
MxResult Run() override;
|
||||
MxResult StartWithTarget(MxDiskStreamProvider* p_target);
|
||||
};
|
||||
|
||||
// VTABLE: LEGO1 0x100dd138
|
||||
// SIZE 0x60
|
||||
class MxDiskStreamProvider : public MxStreamProvider {
|
||||
public:
|
||||
MxDiskStreamProvider();
|
||||
virtual ~MxDiskStreamProvider() override;
|
||||
|
||||
// FUNCTION: LEGO1 0x100d1160
|
||||
inline virtual const char* ClassName() const override // vtable+0x0c
|
||||
{
|
||||
// STRING: LEGO1 0x1010287c
|
||||
return "MxDiskStreamProvider";
|
||||
}
|
||||
|
||||
// FUNCTION: LEGO1 0x100d1170
|
||||
inline virtual MxBool IsA(const char* p_name) const override // vtable+0x10
|
||||
{
|
||||
return !strcmp(p_name, MxDiskStreamProvider::ClassName()) || MxStreamProvider::IsA(p_name);
|
||||
}
|
||||
|
||||
MxResult WaitForWorkToComplete();
|
||||
MxResult FUN_100d1780(MxDSStreamingAction* p_action);
|
||||
void PerformWork();
|
||||
static MxBool FUN_100d1af0(MxDSStreamingAction* p_action);
|
||||
MxResult FUN_100d1b20(MxDSStreamingAction* p_action);
|
||||
|
||||
virtual MxResult SetResourceToGet(MxStreamController* p_resource) override; // vtable+0x14
|
||||
virtual MxU32 GetFileSize() override; // vtable+0x18
|
||||
virtual MxS32 GetStreamBuffersNum() override; // vtable+0x1c
|
||||
virtual void VTable0x20(MxDSAction* p_action) override; // vtable+0x20
|
||||
virtual MxU32 GetLengthInDWords() override; // vtable+0x24
|
||||
virtual MxU32* GetBufferForDWords() override; // vtable+0x28
|
||||
|
||||
private:
|
||||
MxDiskStreamProviderThread m_thread; // 0x10
|
||||
MxSemaphore m_busySemaphore; // 0x2c
|
||||
MxBool m_remainingWork; // 0x34
|
||||
MxBool m_unk0x35; // 0x35
|
||||
MxCriticalSection m_criticalSection; // 0x38
|
||||
MxStreamListMxDSAction m_list; // 0x54
|
||||
};
|
||||
|
||||
// SYNTHETIC: LEGO1 0x100d1220
|
||||
// MxDiskStreamProvider::`scalar deleting destructor'
|
||||
|
||||
#endif // MXDISKSTREAMPROVIDER_H
|
113
LEGO1/omni/include/mxdisplaysurface.h
Normal file
113
LEGO1/omni/include/mxdisplaysurface.h
Normal file
@@ -0,0 +1,113 @@
|
||||
#ifndef MXDISPLAYSURFACE_H
|
||||
#define MXDISPLAYSURFACE_H
|
||||
|
||||
#include "decomp.h"
|
||||
#include "mxbitmap.h"
|
||||
#include "mxcore.h"
|
||||
#include "mxpalette.h"
|
||||
#include "mxvideoparam.h"
|
||||
|
||||
#include <ddraw.h>
|
||||
|
||||
// VTABLE: LEGO1 0x100dc768
|
||||
// SIZE 0xac
|
||||
class MxDisplaySurface : public MxCore {
|
||||
public:
|
||||
MxDisplaySurface();
|
||||
virtual ~MxDisplaySurface() override;
|
||||
|
||||
virtual MxResult Init(
|
||||
MxVideoParam& p_videoParam,
|
||||
LPDIRECTDRAWSURFACE p_ddSurface1,
|
||||
LPDIRECTDRAWSURFACE p_ddSurface2,
|
||||
LPDIRECTDRAWCLIPPER p_ddClipper
|
||||
); // vtable+0x14
|
||||
virtual MxResult Create(MxVideoParam& p_videoParam); // vtable+0x18
|
||||
virtual void Destroy(); // vtable+0x1c
|
||||
virtual void SetPalette(MxPalette* p_palette); // vtable+0x20
|
||||
virtual void VTable0x24(
|
||||
LPDDSURFACEDESC,
|
||||
MxBitmap*,
|
||||
undefined4,
|
||||
undefined4,
|
||||
undefined4,
|
||||
undefined4,
|
||||
undefined4,
|
||||
undefined4
|
||||
); // vtable+0x24
|
||||
virtual void VTable0x28(
|
||||
MxBitmap* p_bitmap,
|
||||
MxS32 p_left,
|
||||
MxS32 p_top,
|
||||
MxS32 p_right,
|
||||
MxS32 p_bottom,
|
||||
MxS32 p_width,
|
||||
MxS32 p_height
|
||||
); // vtable+0x28
|
||||
virtual MxBool VTable0x2c(
|
||||
LPDDSURFACEDESC,
|
||||
MxBitmap*,
|
||||
undefined4,
|
||||
undefined4,
|
||||
undefined4,
|
||||
undefined4,
|
||||
undefined4,
|
||||
undefined4,
|
||||
MxBool
|
||||
); // vtable+0x2c
|
||||
virtual MxBool VTable0x30(
|
||||
MxBitmap* p_bitmap,
|
||||
MxS32 p_left,
|
||||
MxS32 p_top,
|
||||
MxS32 p_right,
|
||||
MxS32 p_bottom,
|
||||
MxS32 p_width,
|
||||
MxS32 p_height,
|
||||
MxBool
|
||||
); // vtable+0x30
|
||||
virtual undefined4 VTable0x34(
|
||||
undefined4,
|
||||
undefined4,
|
||||
undefined4,
|
||||
undefined4,
|
||||
undefined4,
|
||||
undefined4
|
||||
); // vtable+0x34
|
||||
virtual void Display(
|
||||
MxS32 p_left,
|
||||
MxS32 p_top,
|
||||
MxS32 p_left2,
|
||||
MxS32 p_top2,
|
||||
MxS32 p_width,
|
||||
MxS32 p_height
|
||||
); // vtable+0x38
|
||||
virtual void GetDC(HDC* p_hdc); // vtable+0x3c
|
||||
virtual void ReleaseDC(HDC p_hdc); // vtable+0x40
|
||||
virtual LPDIRECTDRAWSURFACE VTable0x44(MxBitmap*, undefined4*, undefined4, undefined4); // vtable+0x44
|
||||
|
||||
void FUN_100ba640();
|
||||
static LPDIRECTDRAWSURFACE FUN_100bc070();
|
||||
|
||||
inline LPDIRECTDRAWSURFACE GetDirectDrawSurface1() { return this->m_ddSurface1; }
|
||||
inline LPDIRECTDRAWSURFACE GetDirectDrawSurface2() { return this->m_ddSurface2; }
|
||||
inline MxVideoParam& GetVideoParam() { return this->m_videoParam; }
|
||||
|
||||
private:
|
||||
MxU8 CountTotalBitsSetTo1(MxU32 p_param);
|
||||
MxU8 CountContiguousBitsSetTo1(MxU32 p_param);
|
||||
|
||||
void Init();
|
||||
|
||||
MxVideoParam m_videoParam; // 0x08
|
||||
LPDIRECTDRAWSURFACE m_ddSurface1; // 0x2c
|
||||
LPDIRECTDRAWSURFACE m_ddSurface2; // 0x30
|
||||
LPDIRECTDRAWCLIPPER m_ddClipper; // 0x34
|
||||
MxBool m_initialized; // 0x38
|
||||
DDSURFACEDESC m_surfaceDesc; // 0x3c
|
||||
MxU16* m_16bitPal; // 0xa8
|
||||
};
|
||||
|
||||
// SYNTHETIC: LEGO1 0x100ba580
|
||||
// MxDisplaySurface::`scalar deleting destructor'
|
||||
|
||||
#endif // MXDISPLAYSURFACE_H
|
102
LEGO1/omni/include/mxdsaction.h
Normal file
102
LEGO1/omni/include/mxdsaction.h
Normal file
@@ -0,0 +1,102 @@
|
||||
#ifndef MXDSACTION_H
|
||||
#define MXDSACTION_H
|
||||
|
||||
#include "mxdsobject.h"
|
||||
#include "mxtypes.h"
|
||||
#include "realtime/vector.h"
|
||||
|
||||
class MxOmni;
|
||||
|
||||
// VTABLE: LEGO1 0x100dc098
|
||||
// SIZE 0x94
|
||||
class MxDSAction : public MxDSObject {
|
||||
public:
|
||||
enum {
|
||||
Flag_Looping = 0x01,
|
||||
Flag_Bit3 = 0x04,
|
||||
Flag_Bit4 = 0x08,
|
||||
Flag_Bit5 = 0x10,
|
||||
Flag_Enabled = 0x20,
|
||||
Flag_Bit7 = 0x40,
|
||||
Flag_World = 0x80,
|
||||
Flag_Bit9 = 0x100,
|
||||
Flag_Bit10 = 0x200,
|
||||
Flag_Bit11 = 0x400,
|
||||
};
|
||||
|
||||
__declspec(dllexport) MxDSAction();
|
||||
__declspec(dllexport) virtual ~MxDSAction();
|
||||
|
||||
void CopyFrom(MxDSAction& p_dsAction);
|
||||
MxDSAction& operator=(MxDSAction& p_dsAction);
|
||||
|
||||
// FUNCTION: LEGO1 0x100ad980
|
||||
inline virtual const char* ClassName() const override // vtable+0x0c
|
||||
{
|
||||
// STRING: LEGO1 0x101013f4
|
||||
return "MxDSAction";
|
||||
}
|
||||
|
||||
// FUNCTION: LEGO1 0x100ad990
|
||||
inline virtual MxBool IsA(const char* p_name) const override // vtable+0x10
|
||||
{
|
||||
return !strcmp(p_name, MxDSAction::ClassName()) || MxDSObject::IsA(p_name);
|
||||
}
|
||||
|
||||
virtual MxU32 GetSizeOnDisk() override; // vtable+18;
|
||||
virtual void Deserialize(MxU8** p_source, MxS16 p_unk0x24) override; // vtable+1c;
|
||||
virtual MxLong GetDuration(); // vtable+24;
|
||||
virtual void SetDuration(MxLong p_duration); // vtable+28;
|
||||
virtual MxDSAction* Clone(); // vtable+2c;
|
||||
virtual void MergeFrom(MxDSAction& p_dsAction); // vtable+30;
|
||||
virtual MxBool HasId(MxU32 p_objectId); // vtable+34;
|
||||
virtual void SetUnknown90(MxLong p_unk0x90); // vtable+38;
|
||||
virtual MxLong GetUnknown90(); // vtable+3c;
|
||||
virtual MxLong GetElapsedTime(); // vtable+40;
|
||||
|
||||
void AppendData(MxU16 p_extraLength, const char* p_extraData);
|
||||
|
||||
inline MxU32 GetFlags() { return m_flags; }
|
||||
inline void SetFlags(MxU32 p_flags) { m_flags = p_flags; }
|
||||
inline char* GetExtraData() { return m_extraData; }
|
||||
inline MxU16 GetExtraLength() const { return m_extraLength; }
|
||||
inline MxLong GetStartTime() const { return m_startTime; }
|
||||
inline MxS32 GetLoopCount() { return m_loopCount; }
|
||||
inline void SetLoopCount(MxS32 p_loopCount) { m_loopCount = p_loopCount; }
|
||||
inline Vector3Data& GetLocation() { return m_location; }
|
||||
inline Vector3Data& GetDirection() { return m_direction; }
|
||||
inline Vector3Data& GetUp() { return m_up; }
|
||||
inline MxCore* GetUnknown84() { return m_unk0x84; }
|
||||
inline void SetUnknown84(MxCore* p_unk0x84) { m_unk0x84 = p_unk0x84; }
|
||||
inline MxCore* GetOrigin() { return m_origin; }
|
||||
inline void SetOrigin(MxCore* p_origin) { m_origin = p_origin; }
|
||||
|
||||
inline MxBool IsLooping() const { return m_flags & Flag_Looping; }
|
||||
inline MxBool IsBit3() const { return m_flags & Flag_Bit3; }
|
||||
|
||||
inline void CopyFlags(MxU32 p_flags)
|
||||
{
|
||||
if (p_flags & MxDSAction::Flag_Looping)
|
||||
SetFlags(GetFlags() | MxDSAction::Flag_Looping);
|
||||
else if (p_flags & MxDSAction::Flag_Bit3)
|
||||
SetFlags(GetFlags() | MxDSAction::Flag_Bit3);
|
||||
}
|
||||
|
||||
protected:
|
||||
MxU32 m_sizeOnDisk; // 0x2c
|
||||
MxU32 m_flags; // 0x30
|
||||
MxLong m_startTime; // 0x34
|
||||
MxLong m_duration; // 0x38
|
||||
MxS32 m_loopCount; // 0x3c
|
||||
Vector3Data m_location; // 0x40
|
||||
Vector3Data m_direction; // 0x54
|
||||
Vector3Data m_up; // 0x68
|
||||
char* m_extraData; // 0x7c
|
||||
MxU16 m_extraLength; // 0x80
|
||||
MxCore* m_unk0x84; // 0x84
|
||||
undefined4 m_unk0x88; // 0x88
|
||||
MxCore* m_origin; // 0x8c
|
||||
MxLong m_unk0x90; // 0x90
|
||||
};
|
||||
|
||||
#endif // MXDSACTION_H
|
58
LEGO1/omni/include/mxdsactionlist.h
Normal file
58
LEGO1/omni/include/mxdsactionlist.h
Normal file
@@ -0,0 +1,58 @@
|
||||
#ifndef MXDSACTIONLIST_H
|
||||
#define MXDSACTIONLIST_H
|
||||
|
||||
#include "decomp.h"
|
||||
#include "mxlist.h"
|
||||
|
||||
class MxDSAction;
|
||||
|
||||
// VTABLE: LEGO1 0x100dcea8
|
||||
// class MxCollection<MxDSAction *>
|
||||
|
||||
// VTABLE: LEGO1 0x100dcec0
|
||||
// class MxList<MxDSAction *>
|
||||
|
||||
// VTABLE: LEGO1 0x100dced8
|
||||
// SIZE 0x1c
|
||||
class MxDSActionList : public MxList<MxDSAction*> {
|
||||
public:
|
||||
MxDSActionList() { this->m_unk0x18 = 0; }
|
||||
|
||||
// FUNCTION: LEGO1 0x100c9c90
|
||||
virtual MxS8 Compare(MxDSAction* p_a, MxDSAction* p_b) override
|
||||
{
|
||||
return p_a == p_b ? 0 : p_a < p_b ? -1 : 1;
|
||||
} // vtable+0x14
|
||||
|
||||
// FUNCTION: LEGO1 0x100c9cb0
|
||||
static void Destroy(MxDSAction* p_action) { delete p_action; }
|
||||
|
||||
private:
|
||||
undefined m_unk0x18;
|
||||
};
|
||||
|
||||
// VTABLE: LEGO1 0x100d7e68
|
||||
// class MxListCursor<MxDSAction *>
|
||||
|
||||
// VTABLE: LEGO1 0x100d7e50
|
||||
class MxDSActionListCursor : public MxListCursor<MxDSAction*> {
|
||||
public:
|
||||
MxDSActionListCursor(MxDSActionList* p_list) : MxListCursor<MxDSAction*>(p_list){};
|
||||
};
|
||||
|
||||
// TEMPLATE: LEGO1 0x100c9cc0
|
||||
// MxCollection<MxDSAction *>::Compare
|
||||
|
||||
// TEMPLATE: LEGO1 0x100c9d20
|
||||
// MxCollection<MxDSAction *>::Destroy
|
||||
|
||||
// TEMPLATE: LEGO1 0x100c9d30
|
||||
// MxList<MxDSAction *>::~MxList<MxDSAction *>
|
||||
|
||||
// SYNTHETIC: LEGO1 0x100c9e30
|
||||
// MxCollection<MxDSAction *>::`scalar deleting destructor'
|
||||
|
||||
// SYNTHETIC: LEGO1 0x100c9ea0
|
||||
// MxList<MxDSAction *>::`scalar deleting destructor'
|
||||
|
||||
#endif // MXDSACTIONLIST_H
|
32
LEGO1/omni/include/mxdsanim.h
Normal file
32
LEGO1/omni/include/mxdsanim.h
Normal file
@@ -0,0 +1,32 @@
|
||||
#ifndef MXDSANIM_H
|
||||
#define MXDSANIM_H
|
||||
|
||||
#include "mxdsmediaaction.h"
|
||||
|
||||
// VTABLE: LEGO1 0x100dcd88
|
||||
// SIZE 0xb8
|
||||
class MxDSAnim : public MxDSMediaAction {
|
||||
public:
|
||||
MxDSAnim();
|
||||
virtual ~MxDSAnim() override;
|
||||
|
||||
void CopyFrom(MxDSAnim& p_dsAnim);
|
||||
MxDSAnim& operator=(MxDSAnim& p_dsAnim);
|
||||
|
||||
// FUNCTION: LEGO1 0x100c9060
|
||||
inline virtual const char* ClassName() const override // vtable+0x0c
|
||||
{
|
||||
// STRING: LEGO1 0x101025d8
|
||||
return "MxDSAnim";
|
||||
}
|
||||
|
||||
// FUNCTION: LEGO1 0x100c9070
|
||||
inline virtual MxBool IsA(const char* p_name) const override // vtable+0x10
|
||||
{
|
||||
return !strcmp(p_name, MxDSAnim::ClassName()) || MxDSMediaAction::IsA(p_name);
|
||||
}
|
||||
|
||||
virtual MxDSAction* Clone() override; // vtable+2c;
|
||||
};
|
||||
|
||||
#endif // MXDSANIM_H
|
85
LEGO1/omni/include/mxdsbuffer.h
Normal file
85
LEGO1/omni/include/mxdsbuffer.h
Normal file
@@ -0,0 +1,85 @@
|
||||
#ifndef MXDSBUFFER_H
|
||||
#define MXDSBUFFER_H
|
||||
|
||||
#include "decomp.h"
|
||||
#include "mxcore.h"
|
||||
|
||||
class MxStreamController;
|
||||
class MxDSAction;
|
||||
class MxDSStreamingAction;
|
||||
class MxStreamChunk;
|
||||
class MxDSChunk;
|
||||
|
||||
enum MxDSBufferType {
|
||||
MxDSBufferType_Chunk = 0,
|
||||
MxDSBufferType_Allocate = 1,
|
||||
MxDSBufferType_Preallocated = 2,
|
||||
MxDSBufferType_Unknown = 3,
|
||||
};
|
||||
|
||||
// VTABLE: LEGO1 0x100dcca0
|
||||
// SIZE 0x34
|
||||
class MxDSBuffer : public MxCore {
|
||||
public:
|
||||
MxDSBuffer();
|
||||
virtual ~MxDSBuffer() override;
|
||||
|
||||
// FUNCTION: LEGO1 0x100c6500
|
||||
inline virtual const char* ClassName() const override // vtable+0x0c
|
||||
{
|
||||
// STRING: LEGO1 0x101025b8
|
||||
return "MxDSBuffer";
|
||||
}
|
||||
|
||||
MxResult AllocateBuffer(MxU32 p_bufferSize, MxDSBufferType p_mode);
|
||||
MxResult SetBufferPointer(MxU32* p_buffer, MxU32 p_size);
|
||||
MxResult FUN_100c67b0(
|
||||
MxStreamController* p_controller,
|
||||
MxDSAction* p_action,
|
||||
MxDSStreamingAction** p_streamingAction
|
||||
);
|
||||
MxResult CreateObject(
|
||||
MxStreamController* p_controller,
|
||||
MxU32* p_data,
|
||||
MxDSAction* p_action,
|
||||
MxDSStreamingAction** p_streamingAction
|
||||
);
|
||||
MxResult StartPresenterFromAction(MxStreamController* p_controller, MxDSAction* p_action1, MxDSAction* p_action2);
|
||||
MxResult ParseChunk(
|
||||
MxStreamController* p_controller,
|
||||
MxU32* p_data,
|
||||
MxDSAction* p_action,
|
||||
MxDSStreamingAction** p_streamingAction,
|
||||
MxStreamChunk* p_header
|
||||
);
|
||||
static MxCore* ReadChunk(MxDSBuffer* p_buffer, MxU32* p_chunkData, MxU16 p_flags);
|
||||
MxU8* SkipToData();
|
||||
MxU8 ReleaseRef(MxDSChunk*);
|
||||
void AddRef(MxDSChunk* p_chunk);
|
||||
MxResult CalcBytesRemaining(MxU8* p_data);
|
||||
void FUN_100c6f80(MxU32 p_writeOffset);
|
||||
|
||||
inline MxU8* GetBuffer() { return m_pBuffer; }
|
||||
inline MxU32 GetWriteOffset() { return m_writeOffset; }
|
||||
inline MxU32 GetBytesRemaining() { return m_bytesRemaining; }
|
||||
inline MxU16 GetRefCount() { return m_refcount; }
|
||||
inline MxDSBufferType GetMode() { return m_mode; }
|
||||
inline void SetUnknown14(undefined4 p_unk0x14) { m_unk0x14 = p_unk0x14; }
|
||||
inline void SetUnknown1c(undefined4 p_unk0x1c) { m_unk0x1c = p_unk0x1c; }
|
||||
inline void SetUnk30(MxDSStreamingAction* p_unk0x30) { m_unk0x30 = p_unk0x30; }
|
||||
|
||||
private:
|
||||
MxU8* m_pBuffer; // 0x08
|
||||
MxU8* m_pIntoBuffer; // 0x0c
|
||||
MxU8* m_pIntoBuffer2; // 0x10
|
||||
undefined4 m_unk0x14; // 0x14
|
||||
undefined4 m_unk0x18; // 0x18
|
||||
undefined4 m_unk0x1c; // 0x1c
|
||||
MxU16 m_refcount; // 0x20
|
||||
MxDSBufferType m_mode; // 0x24
|
||||
MxU32 m_writeOffset; // 0x28
|
||||
MxU32 m_bytesRemaining; // 0x2c
|
||||
MxDSStreamingAction* m_unk0x30; // 0x30
|
||||
};
|
||||
|
||||
#endif // MXDSBUFFER_H
|
64
LEGO1/omni/include/mxdschunk.h
Normal file
64
LEGO1/omni/include/mxdschunk.h
Normal file
@@ -0,0 +1,64 @@
|
||||
#ifndef MXDSCHUNK_H
|
||||
#define MXDSCHUNK_H
|
||||
|
||||
#include "decomp.h"
|
||||
#include "mxcore.h"
|
||||
#include "mxtypes.h"
|
||||
|
||||
// VTABLE: LEGO1 0x100dc7f8
|
||||
// SIZE 0x1c
|
||||
class MxDSChunk : public MxCore {
|
||||
public:
|
||||
enum {
|
||||
Flag_Bit1 = 0x01,
|
||||
Flag_End = 0x02,
|
||||
Flag_Bit3 = 0x04,
|
||||
Flag_Split = 0x10,
|
||||
Flag_Bit16 = 0x8000
|
||||
};
|
||||
|
||||
MxDSChunk();
|
||||
virtual ~MxDSChunk() override;
|
||||
|
||||
// FUNCTION: LEGO1 0x100be0c0
|
||||
inline virtual const char* ClassName() const override // vtable+0x0c
|
||||
{
|
||||
// STRING: LEGO1 0x10101e6c
|
||||
return "MxDSChunk";
|
||||
}
|
||||
|
||||
// FUNCTION: LEGO1 0x100be0d0
|
||||
inline virtual MxBool IsA(const char* p_name) const override // vtable+0x10
|
||||
{
|
||||
return !strcmp(p_name, MxDSChunk::ClassName()) || MxCore::IsA(p_name);
|
||||
}
|
||||
|
||||
static MxU32 ReturnE();
|
||||
|
||||
inline void SetFlags(MxU16 p_flags) { m_flags = p_flags; }
|
||||
inline void SetObjectId(undefined4 p_objectid) { m_objectId = p_objectid; }
|
||||
inline void SetTime(MxLong p_time) { m_time = p_time; }
|
||||
inline void SetLength(MxU32 p_length) { m_length = p_length; }
|
||||
inline void SetData(MxU8* p_data) { m_data = p_data; }
|
||||
|
||||
inline MxU16 GetFlags() { return m_flags; }
|
||||
inline undefined4 GetObjectId() { return m_objectId; }
|
||||
inline MxLong GetTime() { return m_time; }
|
||||
inline MxU32 GetLength() { return m_length; }
|
||||
inline MxU8* GetData() { return m_data; }
|
||||
|
||||
inline void Release()
|
||||
{
|
||||
if (m_data)
|
||||
delete[] m_data;
|
||||
}
|
||||
|
||||
protected:
|
||||
MxU16 m_flags; // 0x8
|
||||
MxU32 m_objectId; // 0xc
|
||||
MxLong m_time; // 0x10
|
||||
MxU32 m_length; // 0x14
|
||||
MxU8* m_data; // 0x18
|
||||
};
|
||||
|
||||
#endif // MXDSCHUNK_H
|
30
LEGO1/omni/include/mxdsevent.h
Normal file
30
LEGO1/omni/include/mxdsevent.h
Normal file
@@ -0,0 +1,30 @@
|
||||
#ifndef MXDSEVENT_H
|
||||
#define MXDSEVENT_H
|
||||
|
||||
#include "mxdsmediaaction.h"
|
||||
|
||||
class MxDSEvent : public MxDSMediaAction {
|
||||
public:
|
||||
MxDSEvent();
|
||||
virtual ~MxDSEvent() override;
|
||||
|
||||
void CopyFrom(MxDSEvent& p_dsEvent);
|
||||
MxDSEvent& operator=(MxDSEvent& p_dsEvent);
|
||||
|
||||
// FUNCTION: LEGO1 0x100c9660
|
||||
inline virtual const char* ClassName() const override // vtable+0x0c
|
||||
{
|
||||
// STRING: LEGO1 0x101025f0
|
||||
return "MxDSEvent";
|
||||
}
|
||||
|
||||
// FUNCTION: LEGO1 0x100c9670
|
||||
inline virtual MxBool IsA(const char* p_name) const override // vtable+0x10
|
||||
{
|
||||
return !strcmp(p_name, MxDSEvent::ClassName()) || MxDSMediaAction::IsA(p_name);
|
||||
}
|
||||
|
||||
virtual MxDSAction* Clone() override; // vtable+2c;
|
||||
};
|
||||
|
||||
#endif // MXDSEVENT_H
|
62
LEGO1/omni/include/mxdsfile.h
Normal file
62
LEGO1/omni/include/mxdsfile.h
Normal file
@@ -0,0 +1,62 @@
|
||||
#ifndef MXDSFILE_H
|
||||
#define MXDSFILE_H
|
||||
|
||||
#include "mxdssource.h"
|
||||
#include "mxioinfo.h"
|
||||
#include "mxstring.h"
|
||||
#include "mxtypes.h"
|
||||
|
||||
#include <windows.h>
|
||||
|
||||
// VTABLE: LEGO1 0x100dc890
|
||||
class MxDSFile : public MxDSSource {
|
||||
public:
|
||||
__declspec(dllexport) MxDSFile(const char* p_filename, MxULong p_skipReadingChunks);
|
||||
__declspec(dllexport) virtual ~MxDSFile(); // vtable+0x0
|
||||
|
||||
// FUNCTION: LEGO1 0x100c0120
|
||||
inline virtual const char* ClassName() const override // vtable+0x0c
|
||||
{
|
||||
// STRING: LEGO1 0x10102594
|
||||
return "MxDSFile";
|
||||
}
|
||||
|
||||
// FUNCTION: LEGO1 0x100c0130
|
||||
inline virtual MxBool IsA(const char* p_name) const override // vtable+0x10
|
||||
{
|
||||
return !strcmp(p_name, MxDSFile::ClassName()) || MxDSSource::IsA(p_name);
|
||||
}
|
||||
|
||||
__declspec(dllexport) virtual MxLong Open(MxULong); // vtable+0x14
|
||||
__declspec(dllexport) virtual MxLong Close(); // vtable+0x18
|
||||
__declspec(dllexport) virtual MxResult Read(unsigned char*, MxULong); // vtable+0x20
|
||||
__declspec(dllexport) virtual MxLong Seek(MxLong, int); // vtable+0x24
|
||||
__declspec(dllexport) virtual MxULong GetBufferSize(); // vtable+0x28
|
||||
__declspec(dllexport) virtual MxULong GetStreamBuffersNum(); // vtable+0x2c
|
||||
|
||||
inline void SetFileName(const char* p_filename) { m_filename = p_filename; }
|
||||
|
||||
inline MxS32 CalcFileSize() { return GetFileSize(m_io.m_info.hmmio, NULL); }
|
||||
|
||||
private:
|
||||
MxLong ReadChunks();
|
||||
struct ChunkHeader {
|
||||
ChunkHeader() : m_majorVersion(0), m_minorVersion(0), m_bufferSize(0), m_streamBuffersNum(0) {}
|
||||
|
||||
MxU16 m_majorVersion;
|
||||
MxU16 m_minorVersion;
|
||||
MxULong m_bufferSize;
|
||||
MxS16 m_streamBuffersNum;
|
||||
MxS16 m_reserved;
|
||||
};
|
||||
|
||||
MxString m_filename;
|
||||
MXIOINFO m_io;
|
||||
ChunkHeader m_header;
|
||||
|
||||
// If false, read chunks immediately on open, otherwise
|
||||
// skip reading chunks until ReadChunks is explicitly called.
|
||||
MxULong m_skipReadingChunks;
|
||||
};
|
||||
|
||||
#endif // MXDSFILE_H
|
55
LEGO1/omni/include/mxdsmediaaction.h
Normal file
55
LEGO1/omni/include/mxdsmediaaction.h
Normal file
@@ -0,0 +1,55 @@
|
||||
#ifndef MXDSMEDIAACTION_H
|
||||
#define MXDSMEDIAACTION_H
|
||||
|
||||
#include "decomp.h"
|
||||
#include "mxdsaction.h"
|
||||
#include "mxpoint32.h"
|
||||
|
||||
// VTABLE: LEGO1 0x100dcd40
|
||||
// SIZE 0xb8
|
||||
class MxDSMediaAction : public MxDSAction {
|
||||
public:
|
||||
MxDSMediaAction();
|
||||
virtual ~MxDSMediaAction() override;
|
||||
|
||||
void CopyFrom(MxDSMediaAction& p_dsMediaAction);
|
||||
MxDSMediaAction& operator=(MxDSMediaAction& p_dsMediaAction);
|
||||
|
||||
// FUNCTION: LEGO1 0x100c8be0
|
||||
inline virtual const char* ClassName() const override // vtable+0x0c
|
||||
{
|
||||
// STRING: LEGO1 0x100f7624
|
||||
return "MxDSMediaAction";
|
||||
}
|
||||
|
||||
// FUNCTION: LEGO1 0x100c8bf0
|
||||
inline virtual MxBool IsA(const char* p_name) const override // vtable+0x10
|
||||
{
|
||||
return !strcmp(p_name, MxDSMediaAction::ClassName()) || MxDSAction::IsA(p_name);
|
||||
}
|
||||
|
||||
virtual MxU32 GetSizeOnDisk() override; // vtable+18;
|
||||
virtual void Deserialize(MxU8** p_source, MxS16 p_unk0x24) override; // vtable+1c;
|
||||
|
||||
void CopyMediaSrcPath(const char* p_mediaSrcPath);
|
||||
|
||||
inline MxS32 GetFramesPerSecond() const { return this->m_framesPerSecond; }
|
||||
inline MxS32 GetMediaFormat() const { return this->m_mediaFormat; }
|
||||
inline MxS32 GetPaletteManagement() const { return this->m_paletteManagement; }
|
||||
inline MxLong GetSustainTime() const { return this->m_sustainTime; }
|
||||
|
||||
private:
|
||||
MxU32 m_sizeOnDisk; // 0x94
|
||||
char* m_mediaSrcPath; // 0x98
|
||||
struct {
|
||||
undefined4 m_unk0x00;
|
||||
undefined4 m_unk0x04;
|
||||
} m_unk0x9c; // 0x9c
|
||||
MxS32 m_framesPerSecond; // 0xa4
|
||||
MxS32 m_mediaFormat; // 0xa8
|
||||
MxS32 m_paletteManagement; // 0xac
|
||||
MxLong m_sustainTime; // 0xb0
|
||||
undefined4 m_unk0xb4; // 0xb4
|
||||
};
|
||||
|
||||
#endif // MXDSMEDIAACTION_H
|
58
LEGO1/omni/include/mxdsmultiaction.h
Normal file
58
LEGO1/omni/include/mxdsmultiaction.h
Normal file
@@ -0,0 +1,58 @@
|
||||
#ifndef MXDSMULTIACTION_H
|
||||
#define MXDSMULTIACTION_H
|
||||
|
||||
#include "mxdsaction.h"
|
||||
#include "mxdsactionlist.h"
|
||||
|
||||
// VTABLE: LEGO1 0x100dcef0
|
||||
// SIZE 0x9c
|
||||
class MxDSMultiAction : public MxDSAction {
|
||||
public:
|
||||
MxDSMultiAction();
|
||||
virtual ~MxDSMultiAction() override;
|
||||
|
||||
void CopyFrom(MxDSMultiAction& p_dsMultiAction);
|
||||
MxDSMultiAction& operator=(MxDSMultiAction& p_dsMultiAction);
|
||||
|
||||
// FUNCTION: LEGO1 0x100c9f50
|
||||
inline virtual const char* ClassName() const override // vtable+0x0c
|
||||
{
|
||||
// STRING: LEGO1 0x10101dbc
|
||||
return "MxDSMultiAction";
|
||||
}
|
||||
|
||||
// FUNCTION: LEGO1 0x100c9f60
|
||||
inline virtual MxBool IsA(const char* p_name) const override // vtable+0x10
|
||||
{
|
||||
return !strcmp(p_name, MxDSMultiAction::ClassName()) || MxDSAction::IsA(p_name);
|
||||
}
|
||||
|
||||
virtual undefined4 VTable0x14() override; // vtable+14;
|
||||
virtual MxU32 GetSizeOnDisk() override; // vtable+18;
|
||||
virtual void Deserialize(MxU8** p_source, MxS16 p_unk0x24) override; // vtable+1c;
|
||||
virtual void SetAtomId(MxAtomId p_atomId) override; // vtable+20;
|
||||
virtual MxDSAction* Clone() override; // vtable+2c;
|
||||
virtual void MergeFrom(MxDSAction& p_dsAction) override; // vtable+30;
|
||||
virtual MxBool HasId(MxU32 p_objectId) override; // vtable+34;
|
||||
virtual void SetUnknown90(MxLong p_unk0x90) override; // vtable+38;
|
||||
|
||||
inline MxDSActionList* GetActionList() const { return m_actions; };
|
||||
|
||||
protected:
|
||||
MxU32 m_sizeOnDisk; // 0x94
|
||||
MxDSActionList* m_actions; // 0x98
|
||||
};
|
||||
|
||||
// SYNTHETIC: LEGO1 0x1004ad10
|
||||
// MxDSActionListCursor::`scalar deleting destructor'
|
||||
|
||||
// TEMPLATE: LEGO1 0x1004ad80
|
||||
// MxListCursor<MxDSAction *>::~MxListCursor<MxDSAction *>
|
||||
|
||||
// SYNTHETIC: LEGO1 0x1004add0
|
||||
// MxListCursor<MxDSAction *>::`scalar deleting destructor'
|
||||
|
||||
// FUNCTION: LEGO1 0x1004ae40
|
||||
// MxDSActionListCursor::~MxDSActionListCursor
|
||||
|
||||
#endif // MXDSMULTIACTION_H
|
72
LEGO1/omni/include/mxdsobject.h
Normal file
72
LEGO1/omni/include/mxdsobject.h
Normal file
@@ -0,0 +1,72 @@
|
||||
#ifndef MXDSOBJECT_H
|
||||
#define MXDSOBJECT_H
|
||||
|
||||
#include "decomp.h"
|
||||
#include "mxatomid.h"
|
||||
#include "mxcore.h"
|
||||
#include "mxdstypes.h"
|
||||
|
||||
class MxPresenter;
|
||||
|
||||
// VTABLE: LEGO1 0x100dc868
|
||||
// SIZE 0x2c
|
||||
class MxDSObject : public MxCore {
|
||||
public:
|
||||
MxDSObject();
|
||||
virtual ~MxDSObject() override;
|
||||
|
||||
void CopyFrom(MxDSObject& p_dsObject);
|
||||
MxDSObject& operator=(MxDSObject& p_dsObject);
|
||||
|
||||
__declspec(dllexport) void SetObjectName(const char* p_objectName);
|
||||
void SetSourceName(const char* p_sourceName);
|
||||
|
||||
// FUNCTION: LEGO1 0x100bf730
|
||||
inline virtual const char* ClassName() const override { return "MxDSObject"; }; // vtable+0c
|
||||
|
||||
// FUNCTION: LEGO1 0x100bf740
|
||||
inline virtual MxBool IsA(const char* p_name) const override
|
||||
{
|
||||
return !strcmp(p_name, MxDSObject::ClassName()) || MxCore::IsA(p_name);
|
||||
}; // vtable+10;
|
||||
|
||||
virtual undefined4 VTable0x14(); // vtable+14;
|
||||
virtual MxU32 GetSizeOnDisk(); // vtable+18;
|
||||
virtual void Deserialize(MxU8** p_source, MxS16 p_unk0x24); // vtable+1c;
|
||||
inline virtual void SetAtomId(MxAtomId p_atomId) { this->m_atomId = p_atomId; } // vtable+20;
|
||||
|
||||
inline MxDSType GetType() const { return (MxDSType) this->m_type; }
|
||||
inline const char* GetSourceName() const { return this->m_sourceName; }
|
||||
inline MxU32 GetObjectId() { return this->m_objectId; }
|
||||
inline const MxAtomId& GetAtomId() { return this->m_atomId; }
|
||||
inline MxS16 GetUnknown24() { return this->m_unk0x24; }
|
||||
inline MxPresenter* GetUnknown28() { return this->m_unk0x28; }
|
||||
|
||||
inline void SetType(MxDSType p_type) { this->m_type = p_type; }
|
||||
inline void SetObjectId(MxU32 p_objectId) { this->m_objectId = p_objectId; }
|
||||
inline void SetUnknown24(MxS16 p_unk0x24) { this->m_unk0x24 = p_unk0x24; }
|
||||
inline void SetUnknown28(MxPresenter* p_unk0x28) { this->m_unk0x28 = p_unk0x28; }
|
||||
|
||||
inline void ClearAtom() { m_atomId.Clear(); }
|
||||
|
||||
private:
|
||||
MxU32 m_sizeOnDisk; // 0x8
|
||||
MxU16 m_type; // 0xc
|
||||
char* m_sourceName; // 0x10
|
||||
undefined4 m_unk0x14; // 0x14
|
||||
char* m_objectName; // 0x18
|
||||
MxU32 m_objectId; // 0x1c
|
||||
MxAtomId m_atomId; // 0x20
|
||||
MxS16 m_unk0x24; // 0x24
|
||||
MxPresenter* m_unk0x28; // 0x28
|
||||
};
|
||||
|
||||
MxDSObject* DeserializeDSObjectDispatch(MxU8**, MxS16);
|
||||
|
||||
// FUNCTION: ISLE 0x401c40
|
||||
// MxDSObject::SetAtomId
|
||||
|
||||
// FUNCTION: LEGO1 0x10005530
|
||||
// MxDSObject::SetAtomId
|
||||
|
||||
#endif // MXDSOBJECT_H
|
32
LEGO1/omni/include/mxdsobjectaction.h
Normal file
32
LEGO1/omni/include/mxdsobjectaction.h
Normal file
@@ -0,0 +1,32 @@
|
||||
#ifndef MXDSOBJECTACTION_H
|
||||
#define MXDSOBJECTACTION_H
|
||||
|
||||
#include "mxdsmediaaction.h"
|
||||
|
||||
// VTABLE: LEGO1 0x100dccf8
|
||||
// SIZE 0xb8
|
||||
class MxDSObjectAction : public MxDSMediaAction {
|
||||
public:
|
||||
MxDSObjectAction();
|
||||
virtual ~MxDSObjectAction() override;
|
||||
|
||||
MxDSObjectAction& operator=(MxDSObjectAction& p_dsObjectAction);
|
||||
|
||||
// FUNCTION: LEGO1 0x100c88e0
|
||||
inline virtual const char* ClassName() const override // vtable+0x0c
|
||||
{
|
||||
// STRING: LEGO1 0x101025c4
|
||||
return "MxDSObjectAction";
|
||||
}
|
||||
|
||||
// FUNCTION: LEGO1 0x100c88f0
|
||||
inline virtual MxBool IsA(const char* p_name) const override // vtable+0x10
|
||||
{
|
||||
return !strcmp(p_name, MxDSObjectAction::ClassName()) || MxDSMediaAction::IsA(p_name);
|
||||
}
|
||||
|
||||
virtual MxDSAction* Clone() override; // vtable+2c;
|
||||
virtual void CopyFrom(MxDSObjectAction& p_dsObjectAction); // vtable+44;
|
||||
};
|
||||
|
||||
#endif // MXDSOBJECTACTION_H
|
33
LEGO1/omni/include/mxdsparallelaction.h
Normal file
33
LEGO1/omni/include/mxdsparallelaction.h
Normal file
@@ -0,0 +1,33 @@
|
||||
#ifndef MXDSPARALLELACTION_H
|
||||
#define MXDSPARALLELACTION_H
|
||||
|
||||
#include "mxdsmultiaction.h"
|
||||
|
||||
// VTABLE: LEGO1 0x100dcf80
|
||||
// SIZE 0x9c
|
||||
class MxDSParallelAction : public MxDSMultiAction {
|
||||
public:
|
||||
MxDSParallelAction();
|
||||
virtual ~MxDSParallelAction() override;
|
||||
|
||||
void CopyFrom(MxDSParallelAction& p_dsParallelAction);
|
||||
MxDSParallelAction& operator=(MxDSParallelAction& p_dsParallelAction);
|
||||
|
||||
// FUNCTION: LEGO1 0x100caf00
|
||||
inline virtual const char* ClassName() const override // vtable+0x0c
|
||||
{
|
||||
// STRING: LEGO1 0x10102608
|
||||
return "MxDSParallelAction";
|
||||
}
|
||||
|
||||
// FUNCTION: LEGO1 0x100caf10
|
||||
inline virtual MxBool IsA(const char* p_name) const override // vtable+0x10
|
||||
{
|
||||
return !strcmp(p_name, MxDSParallelAction::ClassName()) || MxDSMultiAction::IsA(p_name);
|
||||
}
|
||||
|
||||
virtual MxLong GetDuration() override; // vtable+24;
|
||||
virtual MxDSAction* Clone() override; // vtable+2c;
|
||||
};
|
||||
|
||||
#endif // MXDSPARALLELACTION_H
|
52
LEGO1/omni/include/mxdsselectaction.h
Normal file
52
LEGO1/omni/include/mxdsselectaction.h
Normal file
@@ -0,0 +1,52 @@
|
||||
#ifndef MXDSSELECTACTION_H
|
||||
#define MXDSSELECTACTION_H
|
||||
|
||||
#include "decomp.h"
|
||||
#include "mxdsparallelaction.h"
|
||||
#include "mxstringlist.h"
|
||||
|
||||
// VTABLE: LEGO1 0x100dcfc8
|
||||
// SIZE 0xb0
|
||||
class MxDSSelectAction : public MxDSParallelAction {
|
||||
public:
|
||||
MxDSSelectAction();
|
||||
virtual ~MxDSSelectAction() override;
|
||||
|
||||
void CopyFrom(MxDSSelectAction& p_dsSelectAction);
|
||||
MxDSSelectAction& operator=(MxDSSelectAction& p_dsSelectAction);
|
||||
|
||||
// FUNCTION: LEGO1 0x100cb6f0
|
||||
inline virtual const char* ClassName() const override // vtable+0x0c
|
||||
{
|
||||
// STRING: LEGO1 0x1010261c
|
||||
return "MxDSSelectAction";
|
||||
}
|
||||
|
||||
// FUNCTION: LEGO1 0x100cb700
|
||||
inline virtual MxBool IsA(const char* p_name) const override // vtable+0x10
|
||||
{
|
||||
return !strcmp(p_name, MxDSSelectAction::ClassName()) || MxDSParallelAction::IsA(p_name);
|
||||
}
|
||||
|
||||
virtual MxU32 GetSizeOnDisk() override; // vtable+18;
|
||||
virtual void Deserialize(MxU8** p_source, MxS16 p_unk0x24) override; // vtable+1c;
|
||||
virtual MxDSAction* Clone() override; // vtable+2c;
|
||||
|
||||
private:
|
||||
MxString m_unk0x9c;
|
||||
MxStringList* m_unk0xac;
|
||||
};
|
||||
|
||||
// SYNTHETIC: LEGO1 0x100cbbd0
|
||||
// MxStringListCursor::`scalar deleting destructor'
|
||||
|
||||
// TEMPLATE: LEGO1 0x100cbc40
|
||||
// MxListCursor<MxString>::~MxListCursor<MxString>
|
||||
|
||||
// SYNTHETIC: LEGO1 0x100cbc90
|
||||
// MxListCursor<MxString>::`scalar deleting destructor'
|
||||
|
||||
// FUNCTION: LEGO1 0x100cbd00
|
||||
// MxStringListCursor::~MxStringListCursor
|
||||
|
||||
#endif // MXDSSELECTACTION_H
|
40
LEGO1/omni/include/mxdsserialaction.h
Normal file
40
LEGO1/omni/include/mxdsserialaction.h
Normal file
@@ -0,0 +1,40 @@
|
||||
#ifndef MXDSSERIALACTION_H
|
||||
#define MXDSSERIALACTION_H
|
||||
|
||||
#include "decomp.h"
|
||||
#include "mxdsmultiaction.h"
|
||||
|
||||
// VTABLE: LEGO1 0x100dcf38
|
||||
// SIZE 0xa8
|
||||
class MxDSSerialAction : public MxDSMultiAction {
|
||||
public:
|
||||
MxDSSerialAction();
|
||||
virtual ~MxDSSerialAction() override;
|
||||
|
||||
void CopyFrom(MxDSSerialAction& p_dsSerialAction);
|
||||
MxDSSerialAction& operator=(MxDSSerialAction& p_dsSerialAction);
|
||||
|
||||
// FUNCTION: LEGO1 0x100caad0
|
||||
inline virtual const char* ClassName() const override // vtable+0x0c
|
||||
{
|
||||
// STRING: LEGO1 0x100f75dc
|
||||
return "MxDSSerialAction";
|
||||
}
|
||||
|
||||
// FUNCTION: LEGO1 0x100caae0
|
||||
inline virtual MxBool IsA(const char* p_name) const override // vtable+0x10
|
||||
{
|
||||
return !strcmp(p_name, MxDSSerialAction::ClassName()) || MxDSMultiAction::IsA(p_name);
|
||||
}
|
||||
|
||||
virtual MxLong GetDuration() override; // vtable+24;
|
||||
virtual void SetDuration(MxLong p_duration) override; // vtable+28;
|
||||
virtual MxDSAction* Clone() override; // vtable+2c;
|
||||
|
||||
private:
|
||||
MxDSActionListCursor* m_cursor;
|
||||
undefined4 m_unk0xa0;
|
||||
undefined4 m_unk0xa4;
|
||||
};
|
||||
|
||||
#endif // MXDSSERIALACTION_H
|
40
LEGO1/omni/include/mxdssound.h
Normal file
40
LEGO1/omni/include/mxdssound.h
Normal file
@@ -0,0 +1,40 @@
|
||||
#ifndef MXDSSOUND_H
|
||||
#define MXDSSOUND_H
|
||||
|
||||
#include "mxdsmediaaction.h"
|
||||
|
||||
// VTABLE: LEGO1 0x100dcdd0
|
||||
// SIZE 0xc0
|
||||
class MxDSSound : public MxDSMediaAction {
|
||||
public:
|
||||
MxDSSound();
|
||||
virtual ~MxDSSound() override;
|
||||
|
||||
void CopyFrom(MxDSSound& p_dsSound);
|
||||
MxDSSound& operator=(MxDSSound& p_dsSound);
|
||||
|
||||
// FUNCTION: LEGO1 0x100c9330
|
||||
inline virtual const char* ClassName() const override // vtable+0x0c
|
||||
{
|
||||
// STRING: LEGO1 0x101025e4
|
||||
return "MxDSSound";
|
||||
}
|
||||
|
||||
// FUNCTION: LEGO1 0x100c9340
|
||||
inline virtual MxBool IsA(const char* p_name) const override // vtable+0x10
|
||||
{
|
||||
return !strcmp(p_name, MxDSSound::ClassName()) || MxDSMediaAction::IsA(p_name);
|
||||
}
|
||||
|
||||
virtual MxU32 GetSizeOnDisk() override; // vtable+18;
|
||||
virtual void Deserialize(MxU8** p_source, MxS16 p_unk0x24) override; // vtable+1c;
|
||||
virtual MxDSAction* Clone() override; // vtable+2c;
|
||||
|
||||
inline MxS32 GetVolume() const { return m_volume; }
|
||||
|
||||
private:
|
||||
MxU32 m_sizeOnDisk;
|
||||
MxS32 m_volume; // 0xbc
|
||||
};
|
||||
|
||||
#endif // MXDSSOUND_H
|
44
LEGO1/omni/include/mxdssource.h
Normal file
44
LEGO1/omni/include/mxdssource.h
Normal file
@@ -0,0 +1,44 @@
|
||||
#ifndef MXDSSOURCE_H
|
||||
#define MXDSSOURCE_H
|
||||
|
||||
#include "mxcore.h"
|
||||
|
||||
class MxDSBuffer;
|
||||
|
||||
// VTABLE: LEGO1 0x100dc8c8
|
||||
// SIZE 0x14
|
||||
class MxDSSource : public MxCore {
|
||||
public:
|
||||
MxDSSource() : m_lengthInDWords(0), m_pBuffer(NULL), m_position(-1) {}
|
||||
|
||||
// FUNCTION: LEGO1 0x100c0010
|
||||
inline virtual const char* ClassName() const override // vtable+0x0c
|
||||
{
|
||||
// STRING: LEGO1 0x10102588
|
||||
return "MxDSSource";
|
||||
}
|
||||
|
||||
// FUNCTION: LEGO1 0x100c0020
|
||||
inline virtual MxBool IsA(const char* p_name) const override // vtable+0x10
|
||||
{
|
||||
return !strcmp(p_name, MxDSSource::ClassName()) || MxCore::IsA(p_name);
|
||||
}
|
||||
|
||||
virtual MxLong Open(MxULong) = 0; // vtable+0x14
|
||||
virtual MxLong Close() = 0; // vtable+0x18
|
||||
virtual MxResult ReadToBuffer(MxDSBuffer* p_buffer); // vtable+0x1c
|
||||
virtual MxResult Read(unsigned char*, MxULong) = 0; // vtable+0x20
|
||||
virtual MxLong Seek(MxLong, int) = 0; // vtable+0x24
|
||||
virtual MxULong GetBufferSize() = 0; // vtable+0x28
|
||||
virtual MxULong GetStreamBuffersNum() = 0; // vtable+0x2c
|
||||
virtual MxLong GetLengthInDWords(); // vtable+0x30
|
||||
virtual MxU32* GetBuffer(); // vtable+0x34
|
||||
inline MxLong GetPosition() const { return m_position; }
|
||||
|
||||
protected:
|
||||
MxULong m_lengthInDWords; // 0x08
|
||||
MxU32* m_pBuffer; // 0x0c
|
||||
MxLong m_position; // 0x10
|
||||
};
|
||||
|
||||
#endif // MXDSSOURCE_H
|
32
LEGO1/omni/include/mxdsstill.h
Normal file
32
LEGO1/omni/include/mxdsstill.h
Normal file
@@ -0,0 +1,32 @@
|
||||
#ifndef MXDSSTILL_H
|
||||
#define MXDSSTILL_H
|
||||
|
||||
#include "mxdsmediaaction.h"
|
||||
|
||||
// VTABLE: LEGO1 0x100dce60
|
||||
// SIZE 0xb8
|
||||
class MxDSStill : public MxDSMediaAction {
|
||||
public:
|
||||
MxDSStill();
|
||||
virtual ~MxDSStill() override;
|
||||
|
||||
void CopyFrom(MxDSStill& p_dsStill);
|
||||
MxDSStill& operator=(MxDSStill& p_dsStill);
|
||||
|
||||
// FUNCTION: LEGO1 0x100c9930
|
||||
inline virtual const char* ClassName() const override // vtable+0x0c
|
||||
{
|
||||
// STRING: LEGO1 0x101025fc
|
||||
return "MxDSStill";
|
||||
}
|
||||
|
||||
// FUNCTION: LEGO1 0x100c9940
|
||||
inline virtual MxBool IsA(const char* p_name) const override // vtable+0x10
|
||||
{
|
||||
return !strcmp(p_name, MxDSStill::ClassName()) || MxDSMediaAction::IsA(p_name);
|
||||
}
|
||||
|
||||
virtual MxDSAction* Clone() override; // vtable+2c;
|
||||
};
|
||||
|
||||
#endif // MXDSSTILL_H
|
57
LEGO1/omni/include/mxdsstreamingaction.h
Normal file
57
LEGO1/omni/include/mxdsstreamingaction.h
Normal file
@@ -0,0 +1,57 @@
|
||||
#ifndef MXDSSTREAMINGACTION_H
|
||||
#define MXDSSTREAMINGACTION_H
|
||||
|
||||
#include "mxdsaction.h"
|
||||
|
||||
class MxDSBuffer;
|
||||
|
||||
// VTABLE: LEGO1 0x100dd088
|
||||
// SIZE 0xb4
|
||||
class MxDSStreamingAction : public MxDSAction {
|
||||
public:
|
||||
MxDSStreamingAction(MxDSAction& p_dsAction, MxU32 p_offset);
|
||||
MxDSStreamingAction(MxDSStreamingAction& p_dsStreamingAction);
|
||||
virtual ~MxDSStreamingAction();
|
||||
|
||||
MxDSStreamingAction* CopyFrom(MxDSStreamingAction& p_dsStreamingAction);
|
||||
MxDSStreamingAction& operator=(MxDSAction& p_dsAction)
|
||||
{
|
||||
MxDSAction::operator=(p_dsAction);
|
||||
return *this;
|
||||
}
|
||||
MxDSStreamingAction& operator=(MxDSStreamingAction& p_dsStreamingAction)
|
||||
{
|
||||
MxDSAction::operator=(p_dsStreamingAction);
|
||||
return *this;
|
||||
}
|
||||
|
||||
virtual MxBool HasId(MxU32 p_objectId) override; // vtable+34;
|
||||
|
||||
MxResult Init();
|
||||
void SetInternalAction(MxDSAction* p_dsAction);
|
||||
void FUN_100cd2d0();
|
||||
|
||||
inline MxU32 GetUnknown94() { return m_unk0x94; }
|
||||
inline MxS32 GetUnknown9c() { return m_unk0x9c; }
|
||||
inline MxDSBuffer* GetUnknowna0() { return m_unk0xa0; }
|
||||
inline MxDSBuffer* GetUnknowna4() { return m_unk0xa4; }
|
||||
inline MxLong GetUnknowna8() { return m_unk0xa8; }
|
||||
inline MxDSAction* GetInternalAction() { return m_internalAction; }
|
||||
inline MxU32 GetBufferOffset() { return m_bufferOffset; }
|
||||
inline void SetUnknown94(MxU32 p_unk0x94) { m_unk0x94 = p_unk0x94; }
|
||||
inline void SetUnknown9c(MxS32 p_unk0x9c) { m_unk0x9c = p_unk0x9c; }
|
||||
inline void SetUnknowna0(MxDSBuffer* p_unk0xa0) { m_unk0xa0 = p_unk0xa0; }
|
||||
inline void SetBufferOffset(MxU32 p_bufferOffset) { m_bufferOffset = p_bufferOffset; }
|
||||
|
||||
private:
|
||||
MxU32 m_unk0x94; // 0x94
|
||||
MxU32 m_bufferOffset; // 0x98
|
||||
MxS32 m_unk0x9c; // 0x9c
|
||||
MxDSBuffer* m_unk0xa0; // 0xa0
|
||||
MxDSBuffer* m_unk0xa4; // 0xa4
|
||||
MxLong m_unk0xa8; // 0xa8
|
||||
undefined2 m_unk0xac; // 0xac
|
||||
MxDSAction* m_internalAction; // 0xb0
|
||||
};
|
||||
|
||||
#endif // MXDSSTREAMINGACTION_H
|
58
LEGO1/omni/include/mxdssubscriber.h
Normal file
58
LEGO1/omni/include/mxdssubscriber.h
Normal file
@@ -0,0 +1,58 @@
|
||||
#ifndef MXDSSUBSCRIBER_H
|
||||
#define MXDSSUBSCRIBER_H
|
||||
|
||||
#include "decomp.h"
|
||||
#include "mxcore.h"
|
||||
#include "mxdschunk.h"
|
||||
#include "mxstreamchunk.h"
|
||||
#include "mxstreamchunklist.h"
|
||||
|
||||
class MxStreamController;
|
||||
|
||||
// VTABLE: LEGO1 0x100dc698
|
||||
// SIZE 0x4c
|
||||
class MxDSSubscriber : public MxCore {
|
||||
public:
|
||||
MxDSSubscriber();
|
||||
virtual ~MxDSSubscriber() override;
|
||||
|
||||
// FUNCTION: LEGO1 0x100b7d50
|
||||
inline virtual const char* ClassName() const override // vtable+0x0c
|
||||
{
|
||||
// STRING: LEGO1 0x101020f8
|
||||
return "MxDSSubscriber";
|
||||
}
|
||||
|
||||
// FUNCTION: LEGO1 0x100b7d60
|
||||
inline virtual MxBool IsA(const char* p_name) const override // vtable+0x10
|
||||
{
|
||||
return !strcmp(p_name, MxDSSubscriber::ClassName()) || MxCore::IsA(p_name);
|
||||
}
|
||||
|
||||
MxResult Create(MxStreamController* p_controller, MxU32 p_objectId, MxS16 p_unk0x48);
|
||||
void DeleteChunks();
|
||||
MxResult AddChunk(MxStreamChunk* p_chunk, MxBool p_append);
|
||||
MxStreamChunk* FUN_100b8250();
|
||||
MxStreamChunk* FUN_100b8360();
|
||||
void FUN_100b8390(MxStreamChunk* p_chunk);
|
||||
|
||||
inline MxU32 GetObjectId() { return m_objectId; }
|
||||
inline MxS16 GetUnknown48() { return m_unk0x48; }
|
||||
|
||||
private:
|
||||
MxStreamChunkList m_unk0x08; // 0x08
|
||||
MxStreamChunkListCursor* m_unk0x20; // 0x20
|
||||
MxStreamChunkList m_unk0x24; // 0x24
|
||||
MxStreamChunkListCursor* m_unk0x3c; // 0x3c
|
||||
MxStreamController* m_controller; // 0x40
|
||||
MxU32 m_objectId; // 0x44
|
||||
MxS16 m_unk0x48; // 0x48
|
||||
};
|
||||
|
||||
// SYNTHETIC: LEGO1 0x100b7de0
|
||||
// MxDSSubscriber::`scalar deleting destructor'
|
||||
|
||||
// TEMPLATE: LEGO1 0x100b7d00
|
||||
// MxStreamChunkList::~MxStreamChunkList
|
||||
|
||||
#endif // MXDSSUBSCRIBER_H
|
19
LEGO1/omni/include/mxdstypes.h
Normal file
19
LEGO1/omni/include/mxdstypes.h
Normal file
@@ -0,0 +1,19 @@
|
||||
#ifndef MXDSTYPES_H
|
||||
#define MXDSTYPES_H
|
||||
|
||||
enum MxDSType {
|
||||
MxDSType_Object = 0,
|
||||
MxDSType_Action = 1,
|
||||
MxDSType_MediaAction = 2,
|
||||
MxDSType_Anim = 3,
|
||||
MxDSType_Sound = 4,
|
||||
MxDSType_MultiAction = 5,
|
||||
MxDSType_SerialAction = 6,
|
||||
MxDSType_ParallelAction = 7,
|
||||
MxDSType_Event = 8,
|
||||
MxDSType_SelectAction = 9,
|
||||
MxDSType_Still = 10,
|
||||
MxDSType_ObjectAction = 11,
|
||||
};
|
||||
|
||||
#endif // MXDSTYPES_H
|
43
LEGO1/omni/include/mxentity.h
Normal file
43
LEGO1/omni/include/mxentity.h
Normal file
@@ -0,0 +1,43 @@
|
||||
#ifndef MXENTITY_H
|
||||
#define MXENTITY_H
|
||||
|
||||
#include "decomp.h"
|
||||
#include "mxatomid.h"
|
||||
#include "mxcore.h"
|
||||
#include "mxdsobject.h"
|
||||
#include "mxtypes.h"
|
||||
|
||||
// VTABLE: LEGO1 0x100d5390
|
||||
// SIZE 0x10
|
||||
class MxEntity : public MxCore {
|
||||
public:
|
||||
MxEntity();
|
||||
virtual ~MxEntity() override;
|
||||
|
||||
// FUNCTION: LEGO1 0x1000c180
|
||||
inline virtual const char* ClassName() const override // vtable+0xc
|
||||
{
|
||||
// STRING: LEGO1 0x100f0070
|
||||
return "MxEntity";
|
||||
}
|
||||
|
||||
// FUNCTION: LEGO1 0x1000c190
|
||||
inline virtual MxBool IsA(const char* p_name) const override // vtable+0x10
|
||||
{
|
||||
return !strcmp(p_name, MxEntity::ClassName()) || MxCore::IsA(p_name);
|
||||
}
|
||||
|
||||
virtual MxResult Create(MxS32 p_id, const MxAtomId& p_atom); // vtable+0x14
|
||||
inline MxResult Create(MxDSObject& p_dsObject)
|
||||
{
|
||||
m_mxEntityId = p_dsObject.GetObjectId();
|
||||
m_atom = p_dsObject.GetAtomId();
|
||||
return SUCCESS;
|
||||
}
|
||||
|
||||
protected:
|
||||
MxS32 m_mxEntityId; // 0x8
|
||||
MxAtomId m_atom; // 0xc
|
||||
};
|
||||
|
||||
#endif // MXENTITY_H
|
22
LEGO1/omni/include/mxeventmanager.h
Normal file
22
LEGO1/omni/include/mxeventmanager.h
Normal file
@@ -0,0 +1,22 @@
|
||||
#ifndef MXEVENTMANAGER_H
|
||||
#define MXEVENTMANAGER_H
|
||||
|
||||
#include "decomp.h"
|
||||
#include "mxmediamanager.h"
|
||||
|
||||
// VTABLE: LEGO1 0x100dc900
|
||||
// SIZE 0x2c
|
||||
class MxEventManager : public MxMediaManager {
|
||||
public:
|
||||
MxEventManager();
|
||||
virtual ~MxEventManager() override;
|
||||
|
||||
virtual void Destroy() override; // vtable+18
|
||||
virtual MxResult Create(MxU32 p_frequencyMS, MxBool p_createThread); // vtable+28
|
||||
|
||||
private:
|
||||
void Init();
|
||||
void Destroy(MxBool p_fromDestructor);
|
||||
};
|
||||
|
||||
#endif // MXEVENTMANAGER_H
|
40
LEGO1/omni/include/mxeventpresenter.h
Normal file
40
LEGO1/omni/include/mxeventpresenter.h
Normal file
@@ -0,0 +1,40 @@
|
||||
#ifndef MXEVENTPRESENTER_H
|
||||
#define MXEVENTPRESENTER_H
|
||||
|
||||
#include "decomp.h"
|
||||
#include "mxmediapresenter.h"
|
||||
|
||||
// VTABLE: LEGO1 0x100dca88
|
||||
// SIZE 0x54
|
||||
class MxEventPresenter : public MxMediaPresenter {
|
||||
public:
|
||||
MxEventPresenter();
|
||||
virtual ~MxEventPresenter() override;
|
||||
|
||||
// FUNCTION: LEGO1 0x100c2c30
|
||||
inline virtual const char* ClassName() const override // vtable+0xc
|
||||
{
|
||||
// STRING: LEGO1 0x10101dcc
|
||||
return "MxEventPresenter";
|
||||
}
|
||||
|
||||
// FUNCTION: LEGO1 0x100c2c40
|
||||
inline virtual MxBool IsA(const char* p_name) const override // vtable+0x10
|
||||
{
|
||||
return !strcmp(p_name, MxEventPresenter::ClassName()) || MxMediaPresenter::IsA(p_name);
|
||||
}
|
||||
|
||||
virtual void ReadyTickle() override; // vtable+0x18
|
||||
virtual void StartingTickle() override; // vtable+0x1c
|
||||
virtual MxResult AddToManager() override; // vtable+0x34
|
||||
virtual void Destroy() override; // vtable+0x38
|
||||
virtual MxResult PutData() override; // vtable+0x4c
|
||||
virtual void CopyData(MxStreamChunk* p_chunk); // vtable+0x5c
|
||||
|
||||
private:
|
||||
void Init();
|
||||
|
||||
MxU8* m_data; // 0x50
|
||||
};
|
||||
|
||||
#endif // MXEVENTPRESENTER_H
|
37
LEGO1/omni/include/mxflcpresenter.h
Normal file
37
LEGO1/omni/include/mxflcpresenter.h
Normal file
@@ -0,0 +1,37 @@
|
||||
#ifndef MXFLCPRESENTER_H
|
||||
#define MXFLCPRESENTER_H
|
||||
|
||||
#include "decomp.h"
|
||||
#include "mxvideopresenter.h"
|
||||
|
||||
#include <flic.h>
|
||||
|
||||
// VTABLE: LEGO1 0x100dc2c0
|
||||
// SIZE 0x68
|
||||
class MxFlcPresenter : public MxVideoPresenter {
|
||||
public:
|
||||
MxFlcPresenter();
|
||||
virtual ~MxFlcPresenter() override;
|
||||
|
||||
// FUNCTION: LEGO1 0x1004e200
|
||||
inline virtual MxBool IsA(const char* p_name) const override // vtable+0x10
|
||||
{
|
||||
return !strcmp(p_name, MxFlcPresenter::ClassName()) || MxVideoPresenter::IsA(p_name);
|
||||
}
|
||||
|
||||
// FUNCTION: LEGO1 0x100b33f0
|
||||
inline virtual const char* ClassName() const override // vtable+0xc
|
||||
{
|
||||
// STRING: LEGO1 0x100f43c8
|
||||
return "MxFlcPresenter";
|
||||
}
|
||||
|
||||
virtual void LoadHeader(MxStreamChunk* p_chunk) override; // vtable+0x5c
|
||||
virtual void CreateBitmap() override; // vtable+0x60
|
||||
virtual void RealizePalette() override; // vtable+0x70
|
||||
|
||||
protected:
|
||||
FLIC_HEADER* m_flicHeader;
|
||||
};
|
||||
|
||||
#endif // MXFLCPRESENTER_H
|
234
LEGO1/omni/include/mxhashtable.h
Normal file
234
LEGO1/omni/include/mxhashtable.h
Normal file
@@ -0,0 +1,234 @@
|
||||
#ifndef MXHASHTABLE_H
|
||||
#define MXHASHTABLE_H
|
||||
|
||||
#include "mxcollection.h"
|
||||
#include "mxcore.h"
|
||||
#include "mxtypes.h"
|
||||
|
||||
#define HASH_TABLE_INIT_SIZE 128
|
||||
|
||||
template <class T>
|
||||
class MxHashTableCursor;
|
||||
|
||||
template <class T>
|
||||
class MxHashTableNode {
|
||||
public:
|
||||
MxHashTableNode<T>(T p_obj, MxU32 p_hash)
|
||||
{
|
||||
m_obj = p_obj;
|
||||
m_hash = p_hash;
|
||||
m_prev = NULL;
|
||||
m_next = NULL;
|
||||
}
|
||||
|
||||
// DECOMP: Should use getter and setter methods here per the style guide.
|
||||
// However, LEGO1D (with no functions inlined) does not use them.
|
||||
T m_obj;
|
||||
MxU32 m_hash;
|
||||
MxHashTableNode* m_prev;
|
||||
MxHashTableNode* m_next;
|
||||
};
|
||||
|
||||
template <class T>
|
||||
class MxHashTable : protected MxCollection<T> {
|
||||
public:
|
||||
enum HashTableOpt {
|
||||
HashTableOpt_NoExpand = 0,
|
||||
HashTableOpt_ExpandAdd = 1,
|
||||
HashTableOpt_ExpandMultiply = 2,
|
||||
};
|
||||
|
||||
MxHashTable()
|
||||
{
|
||||
m_numSlots = HASH_TABLE_INIT_SIZE;
|
||||
m_slots = new MxHashTableNode<T>*[HASH_TABLE_INIT_SIZE];
|
||||
memset(m_slots, 0, sizeof(MxHashTableNode<T>*) * m_numSlots);
|
||||
m_resizeOption = HashTableOpt_NoExpand;
|
||||
}
|
||||
|
||||
virtual ~MxHashTable() override;
|
||||
|
||||
void Resize();
|
||||
void Add(T);
|
||||
void DeleteAll();
|
||||
|
||||
virtual MxU32 Hash(T) { return 0; }
|
||||
|
||||
friend class MxHashTableCursor<T>;
|
||||
|
||||
protected:
|
||||
void NodeInsert(MxHashTableNode<T>*);
|
||||
|
||||
MxHashTableNode<T>** m_slots; // 0x10
|
||||
MxU32 m_numSlots; // 0x14
|
||||
MxU32 m_autoResizeRatio; // 0x18
|
||||
HashTableOpt m_resizeOption; // 0x1c
|
||||
// FIXME: or FIXME? This qword is used as an integer or double depending
|
||||
// on the value of m_resizeOption. Hard to say whether this is how the devs
|
||||
// did it, but a simple cast in either direction doesn't match.
|
||||
union {
|
||||
MxU32 m_increaseAmount; // 0x20
|
||||
double m_increaseFactor; // 0x20
|
||||
};
|
||||
};
|
||||
|
||||
template <class T>
|
||||
class MxHashTableCursor : public MxCore {
|
||||
public:
|
||||
MxHashTableCursor(MxHashTable<T>* p_table)
|
||||
{
|
||||
m_table = p_table;
|
||||
m_match = NULL;
|
||||
}
|
||||
|
||||
MxBool Find(T p_obj);
|
||||
MxBool Current(T& p_obj);
|
||||
void DeleteMatch();
|
||||
|
||||
private:
|
||||
MxHashTable<T>* m_table;
|
||||
MxHashTableNode<T>* m_match;
|
||||
};
|
||||
|
||||
template <class T>
|
||||
MxBool MxHashTableCursor<T>::Find(T p_obj)
|
||||
{
|
||||
MxU32 hash = m_table->Hash(p_obj);
|
||||
MxS32 bucket = hash % m_table->m_numSlots;
|
||||
|
||||
MxHashTableNode<T>* t = m_table->m_slots[bucket];
|
||||
|
||||
while (t) {
|
||||
if (t->m_hash == hash && !m_table->Compare(t->m_obj, p_obj))
|
||||
m_match = t;
|
||||
t = t->m_next;
|
||||
}
|
||||
|
||||
return m_match != NULL;
|
||||
}
|
||||
|
||||
template <class T>
|
||||
MxBool MxHashTableCursor<T>::Current(T& p_obj)
|
||||
{
|
||||
if (m_match) {
|
||||
p_obj = m_match->m_obj;
|
||||
}
|
||||
|
||||
return m_match != NULL;
|
||||
}
|
||||
|
||||
template <class T>
|
||||
void MxHashTableCursor<T>::DeleteMatch()
|
||||
{
|
||||
// Cut the matching node out of the linked list
|
||||
// by updating pointer references.
|
||||
if (m_match == NULL)
|
||||
return;
|
||||
|
||||
if (m_match->m_prev) {
|
||||
m_match->m_prev->m_next = m_match->m_next;
|
||||
}
|
||||
else {
|
||||
// No "prev" node, so move "next" to the head of the list.
|
||||
MxS32 bucket = m_match->m_hash % m_table->m_numSlots;
|
||||
m_table->m_slots[bucket] = m_match->m_next;
|
||||
}
|
||||
|
||||
if (m_match->m_next)
|
||||
m_match->m_next->m_prev = m_match->m_prev;
|
||||
|
||||
m_table->m_customDestructor(m_match->m_obj);
|
||||
delete m_match;
|
||||
m_table->m_count--;
|
||||
}
|
||||
|
||||
template <class T>
|
||||
MxHashTable<T>::~MxHashTable()
|
||||
{
|
||||
DeleteAll();
|
||||
}
|
||||
|
||||
template <class T>
|
||||
void MxHashTable<T>::DeleteAll()
|
||||
{
|
||||
for (MxS32 i = 0; i < m_numSlots; i++) {
|
||||
MxHashTableNode<T>* t = m_slots[i];
|
||||
|
||||
while (t) {
|
||||
MxHashTableNode<T>* next = t->m_next;
|
||||
this->m_customDestructor(t->m_obj);
|
||||
delete t;
|
||||
t = next;
|
||||
}
|
||||
}
|
||||
|
||||
this->m_count = 0;
|
||||
memset(m_slots, 0, sizeof(MxHashTableNode<T>*) * m_numSlots);
|
||||
|
||||
delete[] m_slots;
|
||||
}
|
||||
|
||||
template <class T>
|
||||
inline void MxHashTable<T>::Resize()
|
||||
{
|
||||
// Save a reference to the current table
|
||||
// so we can walk nodes and re-insert
|
||||
MxU32 oldSize = m_numSlots;
|
||||
MxHashTableNode<T>** oldTable = m_slots;
|
||||
|
||||
switch (m_resizeOption) {
|
||||
case HashTableOpt_ExpandAdd:
|
||||
m_numSlots += m_increaseAmount;
|
||||
break;
|
||||
case HashTableOpt_ExpandMultiply:
|
||||
m_numSlots *= m_increaseFactor;
|
||||
break;
|
||||
}
|
||||
|
||||
MxHashTableNode<T>** newTable = new MxHashTableNode<T>*[m_numSlots];
|
||||
m_slots = newTable;
|
||||
memset(m_slots, 0, sizeof(MxHashTableNode<T>*) * m_numSlots);
|
||||
this->m_count = 0;
|
||||
|
||||
for (MxS32 i = 0; i != oldSize; i++) {
|
||||
MxHashTableNode<T>* t = oldTable[i];
|
||||
|
||||
while (t) {
|
||||
MxHashTableNode<T>* next = t->m_next;
|
||||
NodeInsert(t);
|
||||
t = next;
|
||||
}
|
||||
}
|
||||
|
||||
delete[] oldTable;
|
||||
}
|
||||
|
||||
template <class T>
|
||||
inline void MxHashTable<T>::NodeInsert(MxHashTableNode<T>* p_node)
|
||||
{
|
||||
MxS32 bucket = p_node->m_hash % m_numSlots;
|
||||
|
||||
p_node->m_next = m_slots[bucket];
|
||||
|
||||
if (m_slots[bucket])
|
||||
m_slots[bucket]->m_prev = p_node;
|
||||
|
||||
m_slots[bucket] = p_node;
|
||||
this->m_count++;
|
||||
}
|
||||
|
||||
template <class T>
|
||||
inline void MxHashTable<T>::Add(T p_newobj)
|
||||
{
|
||||
if (m_resizeOption && ((this->m_count + 1) / m_numSlots) > m_autoResizeRatio)
|
||||
MxHashTable<T>::Resize();
|
||||
|
||||
MxU32 hash = Hash(p_newobj);
|
||||
MxHashTableNode<T>* node = new MxHashTableNode<T>(p_newobj, hash);
|
||||
|
||||
MxHashTable<T>::NodeInsert(node);
|
||||
}
|
||||
|
||||
#undef HASH_TABLE_INIT_SIZE
|
||||
|
||||
#endif // MXHASHTABLE_H
|
31
LEGO1/omni/include/mxioinfo.h
Normal file
31
LEGO1/omni/include/mxioinfo.h
Normal file
@@ -0,0 +1,31 @@
|
||||
#ifndef MXIOINFO_H
|
||||
#define MXIOINFO_H
|
||||
|
||||
#include "mxtypes.h"
|
||||
|
||||
// mmsystem.h requires inclusion of windows.h before
|
||||
// clang-format off
|
||||
#include <windows.h>
|
||||
#include <mmsystem.h>
|
||||
// clang-format on
|
||||
|
||||
class MXIOINFO {
|
||||
public:
|
||||
MXIOINFO();
|
||||
__declspec(dllexport) ~MXIOINFO();
|
||||
|
||||
MxU16 Open(const char*, MxULong);
|
||||
MxU16 Close(MxLong);
|
||||
MxLong Read(void*, MxLong);
|
||||
MxLong Seek(MxLong, MxLong);
|
||||
MxU16 SetBuffer(char*, MxLong, MxLong);
|
||||
MxU16 Flush(MxU16);
|
||||
MxU16 Advance(MxU16);
|
||||
MxU16 Descend(MMCKINFO*, const MMCKINFO*, MxU16);
|
||||
|
||||
// NOTE: In MXIOINFO, the `hmmio` member of MMIOINFO is used like
|
||||
// an HFILE (int) instead of an HMMIO (WORD).
|
||||
MMIOINFO m_info;
|
||||
};
|
||||
|
||||
#endif // MXIOINFO_H
|
322
LEGO1/omni/include/mxlist.h
Normal file
322
LEGO1/omni/include/mxlist.h
Normal file
@@ -0,0 +1,322 @@
|
||||
#ifndef MXLIST_H
|
||||
#define MXLIST_H
|
||||
|
||||
#include "mxcollection.h"
|
||||
#include "mxcore.h"
|
||||
#include "mxtypes.h"
|
||||
|
||||
template <class T>
|
||||
class MxList;
|
||||
template <class T>
|
||||
class MxListCursor;
|
||||
|
||||
template <class T>
|
||||
class MxListEntry {
|
||||
public:
|
||||
MxListEntry() {}
|
||||
MxListEntry(T p_obj, MxListEntry* p_prev)
|
||||
{
|
||||
m_obj = p_obj;
|
||||
m_prev = p_prev;
|
||||
m_next = NULL;
|
||||
}
|
||||
MxListEntry(T p_obj, MxListEntry* p_prev, MxListEntry* p_next)
|
||||
{
|
||||
m_obj = p_obj;
|
||||
m_prev = p_prev;
|
||||
m_next = p_next;
|
||||
}
|
||||
|
||||
T GetValue() { return this->m_obj; }
|
||||
MxListEntry* GetNext() { return m_next; }
|
||||
MxListEntry* GetPrev() { return m_prev; }
|
||||
|
||||
void SetValue(T p_obj) { m_obj = p_obj; }
|
||||
void SetNext(MxListEntry* p_next) { m_next = p_next; }
|
||||
void SetPrev(MxListEntry* p_prev) { m_prev = p_prev; }
|
||||
|
||||
private:
|
||||
T m_obj;
|
||||
MxListEntry* m_prev;
|
||||
MxListEntry* m_next;
|
||||
};
|
||||
|
||||
// SIZE 0x18
|
||||
template <class T>
|
||||
class MxList : protected MxCollection<T> {
|
||||
public:
|
||||
MxList()
|
||||
{
|
||||
m_last = NULL;
|
||||
m_first = NULL;
|
||||
}
|
||||
|
||||
virtual ~MxList() override;
|
||||
|
||||
void Append(T p_obj) { InsertEntry(p_obj, this->m_last, NULL); };
|
||||
void Prepend(T p_obj) { InsertEntry(p_obj, NULL, this->m_first); };
|
||||
void DeleteAll(MxBool p_destroy = TRUE);
|
||||
MxU32 GetCount() { return this->m_count; }
|
||||
|
||||
friend class MxListCursor<T>;
|
||||
using MxCollection<T>::SetDestroy;
|
||||
|
||||
protected:
|
||||
MxListEntry<T>* m_first; // 0x10
|
||||
MxListEntry<T>* m_last; // 0x14
|
||||
|
||||
void DeleteEntry(MxListEntry<T>*);
|
||||
MxListEntry<T>* InsertEntry(T, MxListEntry<T>*, MxListEntry<T>*);
|
||||
};
|
||||
|
||||
template <class T>
|
||||
class MxPtrList : public MxList<T*> {
|
||||
public:
|
||||
MxPtrList(MxBool p_ownership) { SetOwnership(p_ownership); }
|
||||
|
||||
static void Destroy(T* p_obj) { delete p_obj; };
|
||||
|
||||
void SetOwnership(MxBool p_ownership)
|
||||
{
|
||||
MxCollection<T*>::SetDestroy(p_ownership ? MxPtrList<T>::Destroy : MxCollection<T*>::Destroy);
|
||||
}
|
||||
};
|
||||
|
||||
template <class T>
|
||||
class MxListCursor : public MxCore {
|
||||
public:
|
||||
MxListCursor(MxList<T>* p_list)
|
||||
{
|
||||
m_list = p_list;
|
||||
m_match = NULL;
|
||||
}
|
||||
|
||||
MxBool Find(T p_obj);
|
||||
void Detach();
|
||||
void Destroy();
|
||||
MxBool Next();
|
||||
MxBool Next(T& p_obj);
|
||||
MxBool Prev();
|
||||
MxBool Prev(T& p_obj);
|
||||
MxBool Current(T& p_obj);
|
||||
MxBool First(T& p_obj);
|
||||
MxBool Last(T& p_obj);
|
||||
MxBool HasMatch() { return m_match != NULL; }
|
||||
void SetValue(T p_obj);
|
||||
MxBool Head()
|
||||
{
|
||||
m_match = m_list->m_first;
|
||||
return m_match != NULL;
|
||||
}
|
||||
MxBool Tail()
|
||||
{
|
||||
m_match = m_list->m_last;
|
||||
return m_match != NULL;
|
||||
}
|
||||
void Reset() { m_match = NULL; }
|
||||
void Prepend(T p_newobj);
|
||||
|
||||
// TODO: Probably shouldn't exist
|
||||
void NextFragment()
|
||||
{
|
||||
if (m_match)
|
||||
m_match = m_match->GetNext();
|
||||
}
|
||||
|
||||
private:
|
||||
MxList<T>* m_list; // 0x08
|
||||
MxListEntry<T>* m_match; // 0x0c
|
||||
};
|
||||
|
||||
template <class T>
|
||||
class MxPtrListCursor : public MxListCursor<T*> {
|
||||
public:
|
||||
MxPtrListCursor(MxPtrList<T>* p_list) : MxListCursor<T*>(p_list){};
|
||||
};
|
||||
|
||||
template <class T>
|
||||
MxList<T>::~MxList()
|
||||
{
|
||||
DeleteAll();
|
||||
}
|
||||
|
||||
template <class T>
|
||||
inline void MxList<T>::DeleteAll(MxBool p_destroy)
|
||||
{
|
||||
for (MxListEntry<T>* t = m_first;;) {
|
||||
if (!t)
|
||||
break;
|
||||
|
||||
MxListEntry<T>* next = t->GetNext();
|
||||
|
||||
if (p_destroy)
|
||||
this->m_customDestructor(t->GetValue());
|
||||
|
||||
delete t;
|
||||
t = next;
|
||||
}
|
||||
|
||||
this->m_count = 0;
|
||||
m_last = NULL;
|
||||
m_first = NULL;
|
||||
}
|
||||
|
||||
template <class T>
|
||||
inline MxListEntry<T>* MxList<T>::InsertEntry(T p_newobj, MxListEntry<T>* p_prev, MxListEntry<T>* p_next)
|
||||
{
|
||||
MxListEntry<T>* newEntry = new MxListEntry<T>(p_newobj, p_prev, p_next);
|
||||
|
||||
if (p_prev)
|
||||
p_prev->SetNext(newEntry);
|
||||
else
|
||||
this->m_first = newEntry;
|
||||
|
||||
if (p_next)
|
||||
p_next->SetPrev(newEntry);
|
||||
else
|
||||
this->m_last = newEntry;
|
||||
|
||||
this->m_count++;
|
||||
return newEntry;
|
||||
}
|
||||
|
||||
template <class T>
|
||||
inline void MxList<T>::DeleteEntry(MxListEntry<T>* p_match)
|
||||
{
|
||||
if (p_match->GetPrev())
|
||||
p_match->GetPrev()->SetNext(p_match->GetNext());
|
||||
else
|
||||
m_first = p_match->GetNext();
|
||||
|
||||
if (p_match->GetNext())
|
||||
p_match->GetNext()->SetPrev(p_match->GetPrev());
|
||||
else
|
||||
m_last = p_match->GetPrev();
|
||||
|
||||
delete p_match;
|
||||
this->m_count--;
|
||||
}
|
||||
|
||||
template <class T>
|
||||
inline MxBool MxListCursor<T>::Find(T p_obj)
|
||||
{
|
||||
for (m_match = m_list->m_first; m_match && m_list->Compare(m_match->GetValue(), p_obj);
|
||||
m_match = m_match->GetNext())
|
||||
;
|
||||
|
||||
return m_match != NULL;
|
||||
}
|
||||
|
||||
template <class T>
|
||||
inline void MxListCursor<T>::Detach()
|
||||
{
|
||||
if (m_match) {
|
||||
m_list->DeleteEntry(m_match);
|
||||
m_match = NULL;
|
||||
}
|
||||
}
|
||||
|
||||
template <class T>
|
||||
inline void MxListCursor<T>::Destroy()
|
||||
{
|
||||
if (m_match) {
|
||||
m_list->m_customDestructor(m_match->GetValue());
|
||||
m_list->DeleteEntry(m_match);
|
||||
m_match = NULL;
|
||||
}
|
||||
}
|
||||
|
||||
template <class T>
|
||||
inline MxBool MxListCursor<T>::Next()
|
||||
{
|
||||
if (!m_match)
|
||||
m_match = m_list->m_first;
|
||||
else
|
||||
m_match = m_match->GetNext();
|
||||
|
||||
return m_match != NULL;
|
||||
}
|
||||
|
||||
template <class T>
|
||||
inline MxBool MxListCursor<T>::Next(T& p_obj)
|
||||
{
|
||||
if (!m_match)
|
||||
m_match = m_list->m_first;
|
||||
else
|
||||
m_match = m_match->GetNext();
|
||||
|
||||
if (m_match)
|
||||
p_obj = m_match->GetValue();
|
||||
|
||||
return m_match != NULL;
|
||||
}
|
||||
|
||||
template <class T>
|
||||
inline MxBool MxListCursor<T>::Prev()
|
||||
{
|
||||
if (!m_match)
|
||||
m_match = m_list->m_last;
|
||||
else
|
||||
m_match = m_match->GetPrev();
|
||||
|
||||
return m_match != NULL;
|
||||
}
|
||||
|
||||
template <class T>
|
||||
inline MxBool MxListCursor<T>::Prev(T& p_obj)
|
||||
{
|
||||
if (!m_match)
|
||||
m_match = m_list->m_last;
|
||||
else
|
||||
m_match = m_match->GetPrev();
|
||||
|
||||
if (m_match)
|
||||
p_obj = m_match->GetValue();
|
||||
|
||||
return m_match != NULL;
|
||||
}
|
||||
|
||||
template <class T>
|
||||
inline MxBool MxListCursor<T>::Current(T& p_obj)
|
||||
{
|
||||
if (m_match)
|
||||
p_obj = m_match->GetValue();
|
||||
|
||||
return m_match != NULL;
|
||||
}
|
||||
|
||||
template <class T>
|
||||
inline MxBool MxListCursor<T>::First(T& p_obj)
|
||||
{
|
||||
m_match = m_list->m_first;
|
||||
if (m_match)
|
||||
p_obj = m_match->GetValue();
|
||||
|
||||
return m_match != NULL;
|
||||
}
|
||||
|
||||
template <class T>
|
||||
inline MxBool MxListCursor<T>::Last(T& p_obj)
|
||||
{
|
||||
m_match = m_list->m_last;
|
||||
if (m_match)
|
||||
p_obj = m_match->GetValue();
|
||||
|
||||
return m_match != NULL;
|
||||
}
|
||||
|
||||
template <class T>
|
||||
inline void MxListCursor<T>::SetValue(T p_obj)
|
||||
{
|
||||
if (m_match)
|
||||
m_match->SetValue(p_obj);
|
||||
}
|
||||
|
||||
template <class T>
|
||||
inline void MxListCursor<T>::Prepend(T p_newobj)
|
||||
{
|
||||
if (m_match)
|
||||
m_list->InsertEntry(p_newobj, m_match->GetPrev(), m_match);
|
||||
}
|
||||
|
||||
#endif // MXLIST_H
|
30
LEGO1/omni/include/mxloopingflcpresenter.h
Normal file
30
LEGO1/omni/include/mxloopingflcpresenter.h
Normal file
@@ -0,0 +1,30 @@
|
||||
#ifndef MXLOOPINGFLCPRESENTER_H
|
||||
#define MXLOOPINGFLCPRESENTER_H
|
||||
|
||||
#include "decomp.h"
|
||||
#include "mxflcpresenter.h"
|
||||
|
||||
// VTABLE: LEGO1 0x100dc480
|
||||
// SIZE 0x6c
|
||||
class MxLoopingFlcPresenter : public MxFlcPresenter {
|
||||
public:
|
||||
MxLoopingFlcPresenter();
|
||||
virtual ~MxLoopingFlcPresenter() override;
|
||||
|
||||
// FUNCTION: LEGO1 0x100b4380
|
||||
inline virtual const char* ClassName() const override // vtable+0xc
|
||||
{
|
||||
// STRING: LEGO1 0x10101e20
|
||||
return "MxLoopingFlcPresenter";
|
||||
}
|
||||
|
||||
virtual void NextFrame() override; // vtable+0x64
|
||||
|
||||
private:
|
||||
void Init();
|
||||
void Destroy(MxBool p_fromDestructor);
|
||||
|
||||
undefined4 m_unk0x68;
|
||||
};
|
||||
|
||||
#endif // MXLOOPINGFLCPRESENTER_H
|
31
LEGO1/omni/include/mxloopingmidipresenter.h
Normal file
31
LEGO1/omni/include/mxloopingmidipresenter.h
Normal file
@@ -0,0 +1,31 @@
|
||||
#ifndef MXLOOPINGMIDIPRESENTER_H
|
||||
#define MXLOOPINGMIDIPRESENTER_H
|
||||
|
||||
#include "mxmidipresenter.h"
|
||||
|
||||
// VTABLE: LEGO1 0x100dc240
|
||||
// SIZE 0x58
|
||||
class MxLoopingMIDIPresenter : public MxMIDIPresenter {
|
||||
public:
|
||||
// FUNCTION: LEGO1 0x100b1830
|
||||
inline virtual const char* ClassName() const override // vtable+0xc
|
||||
{
|
||||
// STRING: LEGO1 0x10101de0
|
||||
return "MxLoopingMIDIPresenter";
|
||||
}
|
||||
|
||||
// FUNCTION: LEGO1 0x100b1840
|
||||
inline virtual MxBool IsA(const char* p_name) const override // vtable+0x10
|
||||
{
|
||||
return !strcmp(p_name, MxLoopingMIDIPresenter::ClassName()) || MxMIDIPresenter::IsA(p_name);
|
||||
}
|
||||
|
||||
virtual void StreamingTickle() override; // vtable+0x20
|
||||
virtual void DoneTickle() override; // vtable+0x2c
|
||||
virtual MxResult PutData() override; // vtable+0x4c
|
||||
};
|
||||
|
||||
// SYNTHETIC: LEGO1 0x100b19c0
|
||||
// MxLoopingMIDIPresenter::`scalar deleting destructor'
|
||||
|
||||
#endif // MXLOOPINGMIDIPRESENTER_H
|
38
LEGO1/omni/include/mxloopingsmkpresenter.h
Normal file
38
LEGO1/omni/include/mxloopingsmkpresenter.h
Normal file
@@ -0,0 +1,38 @@
|
||||
#ifndef MXLOOPINGSMKPRESENTER_H
|
||||
#define MXLOOPINGSMKPRESENTER_H
|
||||
|
||||
#include "decomp.h"
|
||||
#include "mxsmkpresenter.h"
|
||||
|
||||
// VTABLE: LEGO1 0x100dc540
|
||||
// SIZE 0x724
|
||||
class MxLoopingSmkPresenter : public MxSmkPresenter {
|
||||
public:
|
||||
MxLoopingSmkPresenter();
|
||||
virtual ~MxLoopingSmkPresenter() override; // vtable+0x0
|
||||
|
||||
// FUNCTION: LEGO1 0x100b4920
|
||||
inline virtual const char* ClassName() const override // vtable+0xc
|
||||
{
|
||||
// STRING: LEGO1 0x10101e08
|
||||
return "MxLoopingSmkPresenter";
|
||||
}
|
||||
|
||||
virtual void RepeatingTickle() override; // vtable+0x24
|
||||
virtual MxResult AddToManager() override; // vtable+0x34
|
||||
virtual void Destroy() override; // vtable+0x38
|
||||
virtual void NextFrame() override; // vtable+0x64
|
||||
virtual void VTable0x88() override; // vtable+0x88
|
||||
virtual void VTable0x8c(); // vtable+0x8c
|
||||
|
||||
private:
|
||||
void Init();
|
||||
void Destroy(MxBool p_fromDestructor);
|
||||
|
||||
MxLong m_elapsedDuration; // 0x720
|
||||
};
|
||||
|
||||
// SYNTHETIC: LEGO1 0x100b4930
|
||||
// MxLoopingSmkPresenter::`scalar deleting destructor'
|
||||
|
||||
#endif // MXLOOPINGSMKPRESENTER_H
|
32
LEGO1/omni/include/mxmediamanager.h
Normal file
32
LEGO1/omni/include/mxmediamanager.h
Normal file
@@ -0,0 +1,32 @@
|
||||
#ifndef MXMEDIAMANGER_H
|
||||
#define MXMEDIAMANGER_H
|
||||
|
||||
#include "mxcore.h"
|
||||
#include "mxcriticalsection.h"
|
||||
#include "mxpresenterlist.h"
|
||||
#include "mxthread.h"
|
||||
#include "mxtypes.h"
|
||||
|
||||
// VTABLE: LEGO1 0x100dc6b0
|
||||
// SIZE 0x2c
|
||||
class MxMediaManager : public MxCore {
|
||||
public:
|
||||
MxMediaManager();
|
||||
virtual ~MxMediaManager() override;
|
||||
|
||||
virtual MxResult Tickle() override; // vtable+08
|
||||
virtual MxResult InitPresenters(); // vtable+14
|
||||
virtual void Destroy(); // vtable+18
|
||||
virtual void AddPresenter(MxPresenter& p_presenter); // vtable+1c
|
||||
virtual void RemovePresenter(MxPresenter& p_presenter); // vtable+20
|
||||
virtual void StopPresenters(); // vtable+24
|
||||
|
||||
MxResult Init();
|
||||
|
||||
protected:
|
||||
MxPresenterList* m_presenters;
|
||||
MxThread* m_thread; // 0xc
|
||||
MxCriticalSection m_criticalSection; // 0x10
|
||||
};
|
||||
|
||||
#endif // MXMEDIAMANGER_H
|
66
LEGO1/omni/include/mxmediapresenter.h
Normal file
66
LEGO1/omni/include/mxmediapresenter.h
Normal file
@@ -0,0 +1,66 @@
|
||||
#ifndef MXMEDIAPRESENTER_H
|
||||
#define MXMEDIAPRESENTER_H
|
||||
|
||||
#include "decomp.h"
|
||||
#include "mxdssubscriber.h"
|
||||
#include "mxpresenter.h"
|
||||
#include "mxstreamchunklist.h"
|
||||
|
||||
// VTABLE: LEGO1 0x100d4cd8
|
||||
// SIZE 0x50
|
||||
class MxMediaPresenter : public MxPresenter {
|
||||
public:
|
||||
inline MxMediaPresenter() { Init(); }
|
||||
virtual ~MxMediaPresenter() override;
|
||||
|
||||
virtual MxResult Tickle() override; // vtable+0x8
|
||||
|
||||
// FUNCTION: LEGO1 0x1000c5c0
|
||||
inline virtual const char* ClassName() const override // vtable+0xc
|
||||
{
|
||||
// STRING: LEGO1 0x100f074c
|
||||
return "MxMediaPresenter";
|
||||
}
|
||||
|
||||
// FUNCTION: LEGO1 0x1000c5d0
|
||||
inline virtual MxBool IsA(const char* p_name) const override // vtable+0x10
|
||||
{
|
||||
return !strcmp(p_name, MxMediaPresenter::ClassName()) || MxPresenter::IsA(p_name);
|
||||
}
|
||||
|
||||
virtual void StreamingTickle() override; // vtable+0x20
|
||||
virtual void RepeatingTickle() override; // vtable+0x24
|
||||
virtual void DoneTickle() override; // vtable+0x2c
|
||||
virtual void Destroy() override; // vtable+0x38
|
||||
virtual MxResult StartAction(MxStreamController*, MxDSAction*) override; // vtable+0x3c
|
||||
virtual void EndAction() override; // vtable+0x40
|
||||
virtual void Enable(MxBool p_enable) override; // vtable+0x54
|
||||
virtual void AppendChunk(MxStreamChunk* p_chunk); // vtable+0x58
|
||||
|
||||
protected:
|
||||
MxDSSubscriber* m_subscriber; // 0x40
|
||||
MxStreamChunkList* m_chunks; // 0x44
|
||||
MxStreamChunkListCursor* m_cursor; // 0x48
|
||||
MxStreamChunk* m_currentChunk; // 0x4c
|
||||
|
||||
void Init();
|
||||
void Destroy(MxBool p_fromDestructor);
|
||||
|
||||
public:
|
||||
MxStreamChunk* FUN_100b5650();
|
||||
MxStreamChunk* NextChunk();
|
||||
};
|
||||
|
||||
// SYNTHETIC: LEGO1 0x100b46e0
|
||||
// MxStreamChunkListCursor::`scalar deleting destructor'
|
||||
|
||||
// TEMPLATE: LEGO1 0x100b4750
|
||||
// MxListCursor<MxStreamChunk *>::~MxListCursor<MxStreamChunk *>
|
||||
|
||||
// SYNTHETIC: LEGO1 0x100b47a0
|
||||
// MxListCursor<MxStreamChunk *>::`scalar deleting destructor'
|
||||
|
||||
// FUNCTION: LEGO1 0x100b4810
|
||||
// MxStreamChunkListCursor::~MxStreamChunkListCursor
|
||||
|
||||
#endif // MXMEDIAPRESENTER_H
|
44
LEGO1/omni/include/mxmidipresenter.h
Normal file
44
LEGO1/omni/include/mxmidipresenter.h
Normal file
@@ -0,0 +1,44 @@
|
||||
#ifndef MXMIDIPRESENTER_H
|
||||
#define MXMIDIPRESENTER_H
|
||||
|
||||
#include "mxmusicpresenter.h"
|
||||
#include "mxstreamchunk.h"
|
||||
|
||||
// VTABLE: LEGO1 0x100dca20
|
||||
// SIZE 0x58
|
||||
class MxMIDIPresenter : public MxMusicPresenter {
|
||||
public:
|
||||
MxMIDIPresenter();
|
||||
virtual ~MxMIDIPresenter() override;
|
||||
|
||||
// FUNCTION: LEGO1 0x100c2650
|
||||
inline virtual const char* ClassName() const override // vtable+0xc
|
||||
{
|
||||
// STRING: LEGO1 0x10101df8
|
||||
return "MxMIDIPresenter";
|
||||
}
|
||||
|
||||
// FUNCTION: LEGO1 0x100c2660
|
||||
inline virtual MxBool IsA(const char* p_name) const override // vtable+0x10
|
||||
{
|
||||
return !strcmp(p_name, MxMIDIPresenter::ClassName()) || MxMusicPresenter::IsA(p_name);
|
||||
}
|
||||
|
||||
virtual void ReadyTickle() override; // vtable+0x18
|
||||
virtual void StartingTickle() override; // vtable+0x1c
|
||||
virtual void StreamingTickle() override; // vtable+0x20
|
||||
virtual void DoneTickle() override; // vtable+0x2c
|
||||
virtual void Destroy() override; // vtable+0x38
|
||||
virtual void EndAction() override; // vtable+0x40
|
||||
virtual MxResult PutData() override; // vtable+0x4c
|
||||
virtual void SetVolume(MxS32 p_volume) override; // vtable+0x60
|
||||
|
||||
private:
|
||||
void Init();
|
||||
void Destroy(MxBool p_fromDestructor);
|
||||
|
||||
protected:
|
||||
MxStreamChunk* m_chunk;
|
||||
};
|
||||
|
||||
#endif // MXMIDIPRESENTER_H
|
46
LEGO1/omni/include/mxmusicmanager.h
Normal file
46
LEGO1/omni/include/mxmusicmanager.h
Normal file
@@ -0,0 +1,46 @@
|
||||
#ifndef MXMUSICMANAGER_H
|
||||
#define MXMUSICMANAGER_H
|
||||
|
||||
#include "decomp.h"
|
||||
#include "mxaudiomanager.h"
|
||||
|
||||
// VTABLE: LEGO1 0x100dc930
|
||||
// SIZE 0x58
|
||||
class MxMusicManager : public MxAudioManager {
|
||||
public:
|
||||
MxMusicManager();
|
||||
virtual ~MxMusicManager() override;
|
||||
|
||||
virtual void Destroy() override; // vtable+18
|
||||
virtual void SetVolume(MxS32 p_volume) override; // vtable+2c
|
||||
virtual MxResult Create(MxU32 p_frequencyMS, MxBool p_createThread); // vtable+30
|
||||
|
||||
inline MxBool GetMIDIInitialized() { return m_midiInitialized; }
|
||||
|
||||
void DeinitializeMIDI();
|
||||
undefined4 FUN_100c09c0(MxU8* p_data, MxS32 p_loopCount);
|
||||
void SetMultiplier(MxS32 p_multiplier);
|
||||
|
||||
private:
|
||||
void Destroy(MxBool p_fromDestructor);
|
||||
|
||||
MxS32 CalculateVolume(MxS32 p_volume);
|
||||
void SetMIDIVolume();
|
||||
|
||||
HMIDISTRM m_midiStreamH; // 0x30
|
||||
MxBool m_midiInitialized; // 0x34
|
||||
undefined4 m_unk0x38; // 0x38
|
||||
undefined4 m_unk0x3c; // 0x3c
|
||||
undefined4 m_unk0x40; // 0x40
|
||||
undefined4 m_unk0x44; // 0x44
|
||||
undefined4 m_unk0x48; // 0x48
|
||||
MIDIHDR* m_midiHdrP; // 0x4c
|
||||
MxS32 m_multiplier; // 0x50
|
||||
DWORD m_midiVolume; // 0x54
|
||||
|
||||
protected:
|
||||
void Init();
|
||||
void InitData();
|
||||
};
|
||||
|
||||
#endif // MXMUSICMANAGER_H
|
34
LEGO1/omni/include/mxmusicpresenter.h
Normal file
34
LEGO1/omni/include/mxmusicpresenter.h
Normal file
@@ -0,0 +1,34 @@
|
||||
#ifndef MXMUSICPRESENTER_H
|
||||
#define MXMUSICPRESENTER_H
|
||||
|
||||
#include "mxaudiopresenter.h"
|
||||
|
||||
// VTABLE: LEGO1 0x100dc9b8
|
||||
// SIZE 0x54
|
||||
class MxMusicPresenter : public MxAudioPresenter {
|
||||
public:
|
||||
MxMusicPresenter();
|
||||
virtual ~MxMusicPresenter() override;
|
||||
|
||||
// FUNCTION: LEGO1 0x100c23a0
|
||||
inline virtual const char* ClassName() const override // vtable+0xc
|
||||
{
|
||||
// STRING: LEGO1 0x10101e48
|
||||
return "MxMusicPresenter";
|
||||
}
|
||||
|
||||
// FUNCTION: LEGO1 0x100c23b0
|
||||
inline virtual MxBool IsA(const char* p_name) const override // vtable+0x10
|
||||
{
|
||||
return !strcmp(p_name, MxMusicPresenter::ClassName()) || MxAudioPresenter::IsA(p_name);
|
||||
}
|
||||
|
||||
virtual MxResult AddToManager() override; // vtable+0x34
|
||||
virtual void Destroy() override; // vtable+0x38
|
||||
|
||||
private:
|
||||
void Init();
|
||||
void Destroy(MxBool p_fromDestructor);
|
||||
};
|
||||
|
||||
#endif // MXMUSICPRESENTER_H
|
42
LEGO1/omni/include/mxnextactiondatastart.h
Normal file
42
LEGO1/omni/include/mxnextactiondatastart.h
Normal file
@@ -0,0 +1,42 @@
|
||||
#ifndef MXNEXTACTIONDATASTART_H
|
||||
#define MXNEXTACTIONDATASTART_H
|
||||
|
||||
#include "mxcore.h"
|
||||
|
||||
// VTABLE: LEGO1 0x100dc9a0
|
||||
// SIZE 0x14
|
||||
class MxNextActionDataStart : public MxCore {
|
||||
public:
|
||||
// inlined constructor at 0x100c1847
|
||||
inline MxNextActionDataStart(MxU32 p_objectId, MxS16 p_unk0x24, MxU32 p_data)
|
||||
{
|
||||
m_objectId = p_objectId;
|
||||
m_unk0x24 = p_unk0x24;
|
||||
m_data = p_data;
|
||||
}
|
||||
|
||||
// FUNCTION: LEGO1 0x100c1900
|
||||
inline virtual const char* ClassName() const override // vtable+0xc
|
||||
{
|
||||
// STRING: LEGO1 0x101025a0
|
||||
return "MxNextActionDataStart";
|
||||
}
|
||||
|
||||
// FUNCTION: LEGO1 0x100c1910
|
||||
inline virtual MxBool IsA(const char* p_name) const override // vtable+0x10
|
||||
{
|
||||
return !strcmp(p_name, MxNextActionDataStart::ClassName()) || MxCore::IsA(p_name);
|
||||
}
|
||||
|
||||
inline MxU32 GetObjectId() const { return m_objectId; }
|
||||
inline MxS16 GetUnknown24() const { return m_unk0x24; }
|
||||
inline MxU32 GetData() const { return m_data; }
|
||||
inline void SetData(MxU32 p_data) { m_data = p_data; }
|
||||
|
||||
private:
|
||||
MxU32 m_objectId; // 0x08
|
||||
MxS16 m_unk0x24; // 0x0c
|
||||
MxU32 m_data; // 0x10
|
||||
};
|
||||
|
||||
#endif // MXNEXTACTIONDATASTART_H
|
55
LEGO1/omni/include/mxnotificationmanager.h
Normal file
55
LEGO1/omni/include/mxnotificationmanager.h
Normal file
@@ -0,0 +1,55 @@
|
||||
#ifndef MXNOTIFICATIONMANAGER_H
|
||||
#define MXNOTIFICATIONMANAGER_H
|
||||
|
||||
#include "mxcore.h"
|
||||
#include "mxcriticalsection.h"
|
||||
#include "mxnotificationparam.h"
|
||||
#include "mxstl/stlcompat.h"
|
||||
#include "mxtypes.h"
|
||||
|
||||
class MxNotification {
|
||||
public:
|
||||
MxNotification(MxCore* p_target, MxNotificationParam* p_param);
|
||||
~MxNotification();
|
||||
|
||||
inline MxCore* GetTarget() { return m_target; }
|
||||
inline MxNotificationParam* GetParam() { return m_param; }
|
||||
|
||||
private:
|
||||
MxCore* m_target; // 0x0
|
||||
MxNotificationParam* m_param; // 0x4
|
||||
};
|
||||
|
||||
class MxIdList : public list<MxU32> {};
|
||||
|
||||
class MxNotificationPtrList : public list<MxNotification*> {};
|
||||
|
||||
// VTABLE: LEGO1 0x100dc078
|
||||
class MxNotificationManager : public MxCore {
|
||||
private:
|
||||
MxNotificationPtrList* m_queue; // 0x8
|
||||
MxNotificationPtrList* m_sendList; // 0xc
|
||||
MxCriticalSection m_lock; // 0x10
|
||||
MxS32 m_unk0x2c; // 0x2c
|
||||
MxIdList m_listenerIds; // 0x30
|
||||
MxBool m_active; // 0x3c
|
||||
|
||||
public:
|
||||
MxNotificationManager();
|
||||
virtual ~MxNotificationManager(); // vtable+0x0 (scalar deleting destructor)
|
||||
|
||||
virtual MxResult Tickle(); // vtable+0x8
|
||||
// TODO: Where does this method come from?
|
||||
virtual MxResult Create(MxU32 p_frequencyMS, MxBool p_createThread); // vtable+0x14
|
||||
void Register(MxCore* p_listener);
|
||||
void Unregister(MxCore* p_listener);
|
||||
MxResult Send(MxCore* p_listener, MxNotificationParam* p_param);
|
||||
|
||||
inline MxNotificationPtrList* GetQueue() { return m_queue; }
|
||||
inline void SetActive(MxBool p_active) { m_active = p_active; }
|
||||
|
||||
private:
|
||||
void FlushPending(MxCore* p_listener);
|
||||
};
|
||||
|
||||
#endif // MXNOTIFICATIONMANAGER_H
|
55
LEGO1/omni/include/mxnotificationparam.h
Normal file
55
LEGO1/omni/include/mxnotificationparam.h
Normal file
@@ -0,0 +1,55 @@
|
||||
#ifndef MXNOTIFICATIONPARAM_H
|
||||
#define MXNOTIFICATIONPARAM_H
|
||||
|
||||
#include "compat.h"
|
||||
#include "mxparam.h"
|
||||
#include "mxtypes.h"
|
||||
|
||||
class MxCore;
|
||||
|
||||
enum NotificationId {
|
||||
PARAM_NONE = 0,
|
||||
c_notificationStartAction = 1, // 100dc210:100d8350
|
||||
c_notificationEndAction = 2, // 100d8358:100d8350
|
||||
TYPE4 = 4, // 100dc208:100d8350
|
||||
MXPRESENTER_NOTIFICATION = 5,
|
||||
MXSTREAMER_DELETE_NOTIFY = 6, // 100dc760
|
||||
c_notificationKeyPress = 7, // 100d6aa0
|
||||
c_notificationButtonUp = 8, // 100d6aa0
|
||||
c_notificationButtonDown = 9, // 100d6aa0
|
||||
c_notificationMouseMove = 10, // 100d6aa0
|
||||
TYPE11 = 11, // 100d6aa0
|
||||
c_notificationDragEnd = 12,
|
||||
c_notificationDragStart = 13,
|
||||
c_notificationDrag = 14,
|
||||
c_notificationTimer = 15, // 100d6aa0
|
||||
TYPE17 = 17,
|
||||
TYPE18 = 18, // 100d7e80
|
||||
TYPE19 = 19, // 100d6230
|
||||
TYPE20 = 20,
|
||||
c_notificationNewPresenter = 21,
|
||||
TYPE22 = 22,
|
||||
TYPE23 = 23,
|
||||
MXTRANSITIONMANAGER_TRANSITIONENDED = 24
|
||||
};
|
||||
|
||||
// VTABLE: LEGO1 0x100d56e0
|
||||
class MxNotificationParam : public MxParam {
|
||||
public:
|
||||
inline MxNotificationParam(NotificationId p_type, MxCore* p_sender) : MxParam(), m_type(p_type), m_sender(p_sender)
|
||||
{
|
||||
}
|
||||
|
||||
virtual ~MxNotificationParam() override {} // vtable+0x0 (scalar deleting destructor)
|
||||
virtual MxNotificationParam* Clone(); // vtable+0x4
|
||||
|
||||
inline NotificationId GetNotification() const { return m_type; }
|
||||
inline MxCore* GetSender() const { return m_sender; }
|
||||
inline NotificationId GetType() const { return m_type; }
|
||||
|
||||
protected:
|
||||
NotificationId m_type; // 0x4
|
||||
MxCore* m_sender; // 0x8
|
||||
};
|
||||
|
||||
#endif // MXNOTIFICATIONPARAM_H
|
48
LEGO1/omni/include/mxobjectfactory.h
Normal file
48
LEGO1/omni/include/mxobjectfactory.h
Normal file
@@ -0,0 +1,48 @@
|
||||
#ifndef MXOBJECTFACTORY_H
|
||||
#define MXOBJECTFACTORY_H
|
||||
|
||||
#include "mxatomid.h"
|
||||
#include "mxcore.h"
|
||||
|
||||
#define FOR_MXOBJECTFACTORY_OBJECTS(X) \
|
||||
X(MxPresenter) \
|
||||
X(MxCompositePresenter) \
|
||||
X(MxVideoPresenter) \
|
||||
X(MxFlcPresenter) \
|
||||
X(MxSmkPresenter) \
|
||||
X(MxStillPresenter) \
|
||||
X(MxWavePresenter) \
|
||||
X(MxMIDIPresenter) \
|
||||
X(MxEventPresenter) \
|
||||
X(MxLoopingFlcPresenter) \
|
||||
X(MxLoopingSmkPresenter) \
|
||||
X(MxLoopingMIDIPresenter)
|
||||
|
||||
// VTABLE: LEGO1 0x100dc220
|
||||
class MxObjectFactory : public MxCore {
|
||||
public:
|
||||
MxObjectFactory();
|
||||
|
||||
// FUNCTION: LEGO1 0x10008f70
|
||||
inline virtual const char* ClassName() const override // vtable+0xc
|
||||
{
|
||||
// STRING: LEGO1 0x100f0730
|
||||
return "MxObjectFactory";
|
||||
}
|
||||
|
||||
// FUNCTION: LEGO1 0x10008f80
|
||||
inline virtual MxBool IsA(const char* p_name) const override // vtable+0x10
|
||||
{
|
||||
return !strcmp(p_name, MxObjectFactory::ClassName()) || MxCore::IsA(p_name);
|
||||
}
|
||||
|
||||
virtual MxCore* Create(const char* p_name); // vtable 0x14
|
||||
virtual void Destroy(MxCore* p_object); // vtable 0x18
|
||||
|
||||
private:
|
||||
#define X(V) MxAtomId m_id##V;
|
||||
FOR_MXOBJECTFACTORY_OBJECTS(X)
|
||||
#undef X
|
||||
};
|
||||
|
||||
#endif // MXOBJECTFACTORY_H
|
109
LEGO1/omni/include/mxomni.h
Normal file
109
LEGO1/omni/include/mxomni.h
Normal file
@@ -0,0 +1,109 @@
|
||||
#ifndef MXOMNI_H
|
||||
#define MXOMNI_H
|
||||
|
||||
#include "mxcore.h"
|
||||
#include "mxcriticalsection.h"
|
||||
#include "mxstring.h"
|
||||
|
||||
class MxAtomId;
|
||||
class MxAtomIdCounterSet;
|
||||
class MxDSAction;
|
||||
class MxEventManager;
|
||||
class MxMusicManager;
|
||||
class MxNotificationManager;
|
||||
class MxNotificationParam;
|
||||
class MxObjectFactory;
|
||||
class MxOmniCreateParam;
|
||||
class MxPresenter;
|
||||
class MxSoundManager;
|
||||
class MxStreamer;
|
||||
class MxTickleManager;
|
||||
class MxTimer;
|
||||
class MxVariableTable;
|
||||
class MxVideoManager;
|
||||
class MxEntity;
|
||||
class MxStreamController;
|
||||
|
||||
// VTABLE: LEGO1 0x100dc168
|
||||
// SIZE 0x68
|
||||
class MxOmni : public MxCore {
|
||||
public:
|
||||
__declspec(dllexport) static void DestroyInstance();
|
||||
__declspec(dllexport) static const char* GetCD();
|
||||
__declspec(dllexport) static const char* GetHD();
|
||||
__declspec(dllexport) static MxOmni* GetInstance();
|
||||
__declspec(dllexport) static MxBool IsSound3D();
|
||||
__declspec(dllexport) static void SetCD(const char* p_cd);
|
||||
__declspec(dllexport) static void SetHD(const char* p_hd);
|
||||
__declspec(dllexport) static void SetSound3D(MxBool p_use3dSound);
|
||||
|
||||
MxOmni();
|
||||
virtual ~MxOmni() override;
|
||||
|
||||
virtual MxLong Notify(MxParam& p_param) override; // vtable+04
|
||||
virtual void Init(); // vtable+14
|
||||
virtual MxResult Create(MxOmniCreateParam& p_param); // vtable+18
|
||||
virtual void Destroy(); // vtable+1c
|
||||
virtual MxResult Start(MxDSAction* p_dsAction); // vtable+20
|
||||
virtual void DeleteObject(MxDSAction& p_dsAction); // vtable+24
|
||||
virtual MxBool DoesEntityExist(MxDSAction& p_dsAction); // vtable+28
|
||||
virtual MxResult CreatePresenter(MxStreamController* p_controller, MxDSAction& p_action); // vtable+2c
|
||||
virtual MxEntity* FindWorld(const char*, MxS32, MxPresenter*); // vtable+30
|
||||
virtual void NotifyCurrentEntity(MxNotificationParam* p_param); // vtable+34
|
||||
virtual void StartTimer(); // vtable+38
|
||||
virtual void StopTimer(); // vtable+3c
|
||||
virtual MxBool IsTimerRunning(); // vtable+40
|
||||
|
||||
static void SetInstance(MxOmni* p_instance);
|
||||
static MxBool FUN_100b06b0(MxDSAction* p_action, const char* p_name);
|
||||
|
||||
HWND GetWindowHandle() const { return this->m_windowHandle; }
|
||||
MxObjectFactory* GetObjectFactory() const { return this->m_objectFactory; }
|
||||
MxNotificationManager* GetNotificationManager() const { return this->m_notificationManager; }
|
||||
MxTickleManager* GetTickleManager() const { return this->m_tickleManager; }
|
||||
MxTimer* GetTimer() const { return this->m_timer; }
|
||||
MxStreamer* GetStreamer() const { return this->m_streamer; }
|
||||
MxSoundManager* GetSoundManager() const { return this->m_soundManager; }
|
||||
MxVideoManager* GetVideoManager() const { return this->m_videoManager; }
|
||||
MxVariableTable* GetVariableTable() const { return this->m_variableTable; }
|
||||
MxMusicManager* GetMusicManager() const { return this->m_musicManager; }
|
||||
MxEventManager* GetEventManager() const { return this->m_eventManager; }
|
||||
MxAtomIdCounterSet* GetAtomIdCounterSet() const { return this->m_atomIdCounterSet; }
|
||||
MxLong HandleActionEnd(MxParam& p_param);
|
||||
|
||||
protected:
|
||||
static MxOmni* g_instance;
|
||||
|
||||
MxString m_mediaPath; // 0x8
|
||||
HWND m_windowHandle; // 0x18
|
||||
MxObjectFactory* m_objectFactory; // 0x1C
|
||||
MxVariableTable* m_variableTable; // 0x20
|
||||
MxTickleManager* m_tickleManager; // 0x24
|
||||
MxNotificationManager* m_notificationManager; // 0x28
|
||||
MxVideoManager* m_videoManager; // 0x2C
|
||||
MxSoundManager* m_soundManager; // 0x30
|
||||
MxMusicManager* m_musicManager; // 0x34
|
||||
MxEventManager* m_eventManager; // 0x38
|
||||
MxTimer* m_timer; // 0x3C
|
||||
MxStreamer* m_streamer; // 0x40
|
||||
MxAtomIdCounterSet* m_atomIdCounterSet; // 0x44
|
||||
MxCriticalSection m_criticalsection; // 0x48
|
||||
MxBool m_timerRunning; // 0x64
|
||||
};
|
||||
|
||||
__declspec(dllexport) MxTickleManager* TickleManager();
|
||||
__declspec(dllexport) MxTimer* Timer();
|
||||
__declspec(dllexport) MxStreamer* Streamer();
|
||||
__declspec(dllexport) MxSoundManager* MSoundManager();
|
||||
__declspec(dllexport) MxVariableTable* VariableTable();
|
||||
__declspec(dllexport) MxMusicManager* MusicManager();
|
||||
__declspec(dllexport) MxEventManager* EventManager();
|
||||
__declspec(dllexport) MxNotificationManager* NotificationManager();
|
||||
|
||||
MxVideoManager* MVideoManager();
|
||||
MxAtomIdCounterSet* AtomIdCounterSet();
|
||||
MxObjectFactory* ObjectFactory();
|
||||
void DeleteObject(MxDSAction& p_dsAction);
|
||||
void DeleteObjects(MxAtomId* p_id, MxS32 p_first, MxS32 p_last);
|
||||
|
||||
#endif // MXOMNI_H
|
94
LEGO1/omni/include/mxomnicreateflags.h
Normal file
94
LEGO1/omni/include/mxomnicreateflags.h
Normal file
@@ -0,0 +1,94 @@
|
||||
#ifndef MXOMNICREATEFLAGS_H
|
||||
#define MXOMNICREATEFLAGS_H
|
||||
|
||||
#include "mxtypes.h"
|
||||
|
||||
class MxOmniCreateFlags {
|
||||
public:
|
||||
enum LowFlags {
|
||||
Flag_CreateObjectFactory = 0x01,
|
||||
Flag_CreateVariableTable = 0x02,
|
||||
Flag_CreateTickleManager = 0x04,
|
||||
Flag_CreateNotificationManager = 0x08,
|
||||
Flag_CreateVideoManager = 0x10,
|
||||
Flag_CreateSoundManager = 0x20,
|
||||
Flag_CreateMusicManager = 0x40,
|
||||
Flag_CreateEventManager = 0x80
|
||||
};
|
||||
|
||||
enum HighFlags {
|
||||
Flag_CreateTimer = 0x02,
|
||||
Flag_CreateStreamer = 0x04
|
||||
};
|
||||
|
||||
__declspec(dllexport) MxOmniCreateFlags();
|
||||
|
||||
inline const MxBool CreateObjectFactory() const { return this->m_flags1 & Flag_CreateObjectFactory; }
|
||||
inline const MxBool CreateVariableTable() const { return this->m_flags1 & Flag_CreateVariableTable; }
|
||||
inline const MxBool CreateTickleManager() const { return this->m_flags1 & Flag_CreateTickleManager; }
|
||||
inline const MxBool CreateNotificationManager() const { return this->m_flags1 & Flag_CreateNotificationManager; }
|
||||
inline const MxBool CreateVideoManager() const { return this->m_flags1 & Flag_CreateVideoManager; }
|
||||
inline const MxBool CreateSoundManager() const { return this->m_flags1 & Flag_CreateSoundManager; }
|
||||
inline const MxBool CreateMusicManager() const { return this->m_flags1 & Flag_CreateMusicManager; }
|
||||
inline const MxBool CreateEventManager() const { return this->m_flags1 & Flag_CreateEventManager; }
|
||||
|
||||
inline const MxBool CreateTimer() const { return this->m_flags2 & Flag_CreateTimer; }
|
||||
inline const MxBool CreateStreamer() const { return this->m_flags2 & Flag_CreateStreamer; }
|
||||
|
||||
inline void CreateObjectFactory(MxBool p_enable)
|
||||
{
|
||||
this->m_flags1 =
|
||||
(p_enable ? this->m_flags1 | Flag_CreateObjectFactory : this->m_flags1 & ~Flag_CreateObjectFactory);
|
||||
}
|
||||
inline void CreateVariableTable(MxBool p_enable)
|
||||
{
|
||||
this->m_flags1 =
|
||||
(p_enable ? this->m_flags1 | Flag_CreateVariableTable : this->m_flags1 & ~Flag_CreateVariableTable);
|
||||
}
|
||||
inline void CreateTickleManager(MxBool p_enable)
|
||||
{
|
||||
this->m_flags1 =
|
||||
(p_enable ? this->m_flags1 | Flag_CreateTickleManager : this->m_flags1 & ~Flag_CreateTickleManager);
|
||||
}
|
||||
inline void CreateNotificationManager(MxBool p_enable)
|
||||
{
|
||||
this->m_flags1 =
|
||||
(p_enable ? this->m_flags1 | Flag_CreateNotificationManager
|
||||
: this->m_flags1 & ~Flag_CreateNotificationManager);
|
||||
}
|
||||
inline void CreateVideoManager(MxBool p_enable)
|
||||
{
|
||||
this->m_flags1 =
|
||||
(p_enable ? this->m_flags1 | Flag_CreateVideoManager : this->m_flags1 & ~Flag_CreateVideoManager);
|
||||
}
|
||||
inline void CreateSoundManager(MxBool p_enable)
|
||||
{
|
||||
this->m_flags1 =
|
||||
(p_enable ? this->m_flags1 | Flag_CreateSoundManager : this->m_flags1 & ~Flag_CreateSoundManager);
|
||||
}
|
||||
inline void CreateMusicManager(MxBool p_enable)
|
||||
{
|
||||
this->m_flags1 =
|
||||
(p_enable ? this->m_flags1 | Flag_CreateMusicManager : this->m_flags1 & ~Flag_CreateMusicManager);
|
||||
}
|
||||
inline void CreateEventManager(MxBool p_enable)
|
||||
{
|
||||
this->m_flags1 =
|
||||
(p_enable ? this->m_flags1 | Flag_CreateEventManager : this->m_flags1 & ~Flag_CreateEventManager);
|
||||
}
|
||||
|
||||
inline void CreateTimer(MxBool p_enable)
|
||||
{
|
||||
this->m_flags2 = (p_enable ? this->m_flags2 | Flag_CreateTimer : this->m_flags2 & ~Flag_CreateTimer);
|
||||
}
|
||||
inline void CreateStreamer(MxBool p_enable)
|
||||
{
|
||||
this->m_flags2 = (p_enable ? this->m_flags2 | Flag_CreateStreamer : this->m_flags2 & ~Flag_CreateStreamer);
|
||||
}
|
||||
|
||||
private:
|
||||
MxU8 m_flags1;
|
||||
MxU8 m_flags2;
|
||||
};
|
||||
|
||||
#endif // MXOMNICREATEFLAGS_H
|
33
LEGO1/omni/include/mxomnicreateparam.h
Normal file
33
LEGO1/omni/include/mxomnicreateparam.h
Normal file
@@ -0,0 +1,33 @@
|
||||
#ifndef MXOMNICREATEPARAM_H
|
||||
#define MXOMNICREATEPARAM_H
|
||||
|
||||
#include "mxomnicreateflags.h"
|
||||
#include "mxparam.h"
|
||||
#include "mxstring.h"
|
||||
#include "mxvideoparam.h"
|
||||
|
||||
#include <windows.h>
|
||||
|
||||
class MxOmniCreateParam : public MxParam {
|
||||
public:
|
||||
__declspec(dllexport) MxOmniCreateParam(
|
||||
const char* p_mediaPath,
|
||||
struct HWND__* p_windowHandle,
|
||||
MxVideoParam& p_vparam,
|
||||
MxOmniCreateFlags p_flags
|
||||
);
|
||||
|
||||
MxOmniCreateFlags& CreateFlags() { return this->m_createFlags; }
|
||||
const MxString& GetMediaPath() const { return m_mediaPath; }
|
||||
const HWND GetWindowHandle() const { return m_windowHandle; }
|
||||
MxVideoParam& GetVideoParam() { return m_videoParam; }
|
||||
const MxVideoParam& GetVideoParam() const { return m_videoParam; }
|
||||
|
||||
private:
|
||||
MxString m_mediaPath;
|
||||
HWND m_windowHandle;
|
||||
MxVideoParam m_videoParam;
|
||||
MxOmniCreateFlags m_createFlags;
|
||||
};
|
||||
|
||||
#endif // MXOMNICREATEPARAM_H
|
38
LEGO1/omni/include/mxpalette.h
Normal file
38
LEGO1/omni/include/mxpalette.h
Normal file
@@ -0,0 +1,38 @@
|
||||
#ifndef MXPALETTE_H
|
||||
#define MXPALETTE_H
|
||||
|
||||
#include "mxcore.h"
|
||||
#include "mxtypes.h"
|
||||
|
||||
#include <ddraw.h>
|
||||
|
||||
// VTABLE: LEGO1 0x100dc848
|
||||
// SIZE 0x414
|
||||
class MxPalette : public MxCore {
|
||||
public:
|
||||
__declspec(dllexport) MxBool operator==(MxPalette& p_other);
|
||||
__declspec(dllexport) void Detach();
|
||||
|
||||
MxPalette();
|
||||
MxPalette(const RGBQUAD*);
|
||||
virtual ~MxPalette();
|
||||
|
||||
void ApplySystemEntriesToPalette(LPPALETTEENTRY p_entries);
|
||||
MxPalette* Clone();
|
||||
void GetDefaultPalette(LPPALETTEENTRY p_entries);
|
||||
MxResult GetEntries(LPPALETTEENTRY p_entries);
|
||||
MxResult SetEntries(LPPALETTEENTRY p_palette);
|
||||
MxResult SetSkyColor(LPPALETTEENTRY p_skyColor);
|
||||
void Reset(MxBool p_ignoreSkyColor);
|
||||
LPDIRECTDRAWPALETTE CreateNativePalette();
|
||||
|
||||
inline void SetOverrideSkyColor(MxBool p_value) { this->m_overrideSkyColor = p_value; }
|
||||
|
||||
private:
|
||||
LPDIRECTDRAWPALETTE m_palette;
|
||||
PALETTEENTRY m_entries[256]; // 0xc
|
||||
MxBool m_overrideSkyColor; // 0x40c
|
||||
PALETTEENTRY m_skyColor; // 0x40d
|
||||
};
|
||||
|
||||
#endif // MXPALETTE_H
|
9
LEGO1/omni/include/mxparam.h
Normal file
9
LEGO1/omni/include/mxparam.h
Normal file
@@ -0,0 +1,9 @@
|
||||
#ifndef MXPARAM_H
|
||||
#define MXPARAM_H
|
||||
|
||||
class MxParam {
|
||||
public:
|
||||
virtual ~MxParam() {}
|
||||
};
|
||||
|
||||
#endif // MXPARAM_H
|
33
LEGO1/omni/include/mxpoint32.h
Normal file
33
LEGO1/omni/include/mxpoint32.h
Normal file
@@ -0,0 +1,33 @@
|
||||
#ifndef MXPOINT32_H
|
||||
#define MXPOINT32_H
|
||||
|
||||
#include "mxtypes.h"
|
||||
|
||||
class MxPoint32 {
|
||||
public:
|
||||
MxPoint32() {}
|
||||
MxPoint32(MxS32 p_x, MxS32 p_y) { CopyFrom(p_x, p_y); }
|
||||
MxPoint32(const MxPoint32& p_point)
|
||||
{
|
||||
this->m_x = p_point.m_x;
|
||||
this->m_y = p_point.m_y;
|
||||
}
|
||||
|
||||
inline MxS32 GetX() const { return m_x; }
|
||||
inline MxS32 GetY() const { return m_y; }
|
||||
|
||||
inline void SetX(MxS32 p_x) { m_x = p_x; }
|
||||
inline void SetY(MxS32 p_y) { m_y = p_y; }
|
||||
|
||||
private:
|
||||
inline void CopyFrom(MxS32 p_x, MxS32 p_y)
|
||||
{
|
||||
this->m_x = p_x;
|
||||
this->m_y = p_y;
|
||||
}
|
||||
|
||||
MxS32 m_x; // 0x00
|
||||
MxS32 m_y; // 0x04
|
||||
};
|
||||
|
||||
#endif // MXPOINT32_H
|
97
LEGO1/omni/include/mxpresenter.h
Normal file
97
LEGO1/omni/include/mxpresenter.h
Normal file
@@ -0,0 +1,97 @@
|
||||
#ifndef MXPRESENTER_H
|
||||
#define MXPRESENTER_H
|
||||
|
||||
#include "decomp.h"
|
||||
#include "mxcore.h"
|
||||
#include "mxcriticalsection.h"
|
||||
#include "mxdsaction.h"
|
||||
#include "mxomni.h"
|
||||
#include "mxpoint32.h"
|
||||
|
||||
class MxCompositePresenter;
|
||||
class MxStreamController;
|
||||
class MxEntity;
|
||||
|
||||
// VTABLE: LEGO1 0x100d4d38
|
||||
// SIZE 0x40
|
||||
class MxPresenter : public MxCore {
|
||||
public:
|
||||
enum TickleState {
|
||||
TickleState_Idle = 0,
|
||||
TickleState_Ready,
|
||||
TickleState_Starting,
|
||||
TickleState_Streaming,
|
||||
TickleState_Repeating,
|
||||
TickleState_unk5,
|
||||
TickleState_Done,
|
||||
};
|
||||
|
||||
MxPresenter() { Init(); }
|
||||
|
||||
__declspec(dllexport) virtual ~MxPresenter(); // vtable+0x0
|
||||
__declspec(dllexport) virtual MxResult Tickle() override; // vtable+0x8
|
||||
|
||||
// FUNCTION: LEGO1 0x1000bfe0
|
||||
inline virtual const char* ClassName() const override // vtable+0xc
|
||||
{
|
||||
// STRING: LEGO1 0x100f0740
|
||||
return "MxPresenter";
|
||||
}
|
||||
|
||||
// FUNCTION: LEGO1 0x1000bff0
|
||||
inline virtual MxBool IsA(const char* p_name) const override // vtable+0x10
|
||||
{
|
||||
return !strcmp(p_name, MxPresenter::ClassName()) || MxCore::IsA(p_name);
|
||||
}
|
||||
|
||||
virtual void VTable0x14(); // vtable+0x14
|
||||
virtual void ReadyTickle(); // vtable+0x18
|
||||
virtual void StartingTickle(); // vtable+0x1c
|
||||
virtual void StreamingTickle(); // vtable+0x20
|
||||
virtual void RepeatingTickle(); // vtable+0x24
|
||||
virtual void Unk5Tickle(); // vtable+0x28
|
||||
|
||||
protected:
|
||||
__declspec(dllexport) virtual void DoneTickle(); // vtable+0x2c
|
||||
__declspec(dllexport) virtual void ParseExtra(); // vtable+0x30
|
||||
|
||||
public:
|
||||
virtual MxResult AddToManager(); // vtable+0x34
|
||||
virtual void Destroy(); // vtable+0x38
|
||||
__declspec(dllexport) virtual MxResult StartAction(MxStreamController*, MxDSAction*); // vtable+0x3c
|
||||
__declspec(dllexport) virtual void EndAction(); // vtable+0x40
|
||||
virtual void SetTickleState(TickleState p_tickleState); // vtable+0x44
|
||||
virtual MxBool HasTickleStatePassed(TickleState p_tickleState); // vtable+0x48
|
||||
virtual MxResult PutData(); // vtable+0x4c
|
||||
virtual MxBool IsHit(MxS32 p_x, MxS32 p_y); // vtable+0x50
|
||||
__declspec(dllexport) virtual void Enable(MxBool p_enable); // vtable+0x54
|
||||
|
||||
MxEntity* CreateEntityBackend(const char* p_name);
|
||||
MxBool IsEnabled();
|
||||
|
||||
inline MxS32 GetCurrentTickleState() const { return this->m_currentTickleState; }
|
||||
inline MxPoint32 GetLocation() const { return this->m_location; }
|
||||
inline MxS32 GetDisplayZ() const { return this->m_displayZ; }
|
||||
inline MxDSAction* GetAction() const { return this->m_action; }
|
||||
|
||||
inline void SetCompositePresenter(MxCompositePresenter* p_compositePresenter)
|
||||
{
|
||||
m_compositePresenter = p_compositePresenter;
|
||||
}
|
||||
|
||||
protected:
|
||||
__declspec(dllexport) void Init();
|
||||
void SendToCompositePresenter(MxOmni*);
|
||||
|
||||
TickleState m_currentTickleState; // 0x8
|
||||
MxU32 m_previousTickleStates; // 0x0c
|
||||
MxPoint32 m_location; // 0x10
|
||||
MxS32 m_displayZ; // 0x18
|
||||
MxDSAction* m_action; // 0x1c
|
||||
MxCriticalSection m_criticalSection; // 0x20
|
||||
MxCompositePresenter* m_compositePresenter; // 0x3c
|
||||
};
|
||||
|
||||
const char* PresenterNameDispatch(const MxDSAction&);
|
||||
|
||||
#endif // MXPRESENTER_H
|
65
LEGO1/omni/include/mxpresenterlist.h
Normal file
65
LEGO1/omni/include/mxpresenterlist.h
Normal file
@@ -0,0 +1,65 @@
|
||||
#ifndef MXPRESENTERLIST_H
|
||||
#define MXPRESENTERLIST_H
|
||||
|
||||
#include "mxlist.h"
|
||||
#include "mxpresenter.h"
|
||||
|
||||
// VTABLE: LEGO1 0x100d62f0
|
||||
// class MxPtrList<MxPresenter>
|
||||
|
||||
// VTABLE: LEGO1 0x100d6308
|
||||
// SIZE 0x18
|
||||
class MxPresenterList : public MxPtrList<MxPresenter> {
|
||||
public:
|
||||
MxPresenterList(MxBool p_ownership = FALSE) : MxPtrList<MxPresenter>(p_ownership) {}
|
||||
|
||||
// FUNCTION: LEGO1 0x1001cd00
|
||||
virtual MxS8 Compare(MxPresenter* p_a, MxPresenter* p_b) override
|
||||
{
|
||||
return p_a == p_b ? 0 : p_a < p_b ? -1 : 1;
|
||||
}; // vtable+0x14
|
||||
};
|
||||
|
||||
// VTABLE: LEGO1 0x100d6488
|
||||
// class MxListCursor<MxPresenter *>
|
||||
|
||||
// VTABLE: LEGO1 0x100d6530
|
||||
// class MxPtrListCursor<MxPresenter>
|
||||
|
||||
// VTABLE: LEGO1 0x100d6470
|
||||
class MxPresenterListCursor : public MxPtrListCursor<MxPresenter> {
|
||||
public:
|
||||
MxPresenterListCursor(MxPresenterList* p_list) : MxPtrListCursor<MxPresenter>(p_list){};
|
||||
};
|
||||
|
||||
// VTABLE: LEGO1 0x100d6350
|
||||
// class MxCollection<MxPresenter *>
|
||||
|
||||
// VTABLE: LEGO1 0x100d6368
|
||||
// class MxList<MxPresenter *>
|
||||
|
||||
// TEMPLATE: LEGO1 0x1001cd20
|
||||
// MxCollection<MxPresenter *>::Compare
|
||||
|
||||
// TEMPLATE: LEGO1 0x1001cd30
|
||||
// MxCollection<MxPresenter *>::Destroy
|
||||
|
||||
// TEMPLATE: LEGO1 0x1001cd40
|
||||
// MxList<MxPresenter *>::MxList<MxPresenter *>
|
||||
|
||||
// TEMPLATE: LEGO1 0x1001cdd0
|
||||
// MxCollection<MxPresenter *>::~MxCollection<MxPresenter *>
|
||||
|
||||
// TEMPLATE: LEGO1 0x1001ce20
|
||||
// MxList<MxPresenter *>::~MxList<MxPresenter *>
|
||||
|
||||
// SYNTHETIC: LEGO1 0x1001cf70
|
||||
// MxCollection<MxPresenter *>::`scalar deleting destructor'
|
||||
|
||||
// SYNTHETIC: LEGO1 0x1001cfe0
|
||||
// MxList<MxPresenter *>::`scalar deleting destructor'
|
||||
|
||||
// SYNTHETIC: LEGO1 0x1001d090
|
||||
// MxPtrList<MxPresenter>::`scalar deleting destructor'
|
||||
|
||||
#endif // MXPRESENTERLIST_H
|
26
LEGO1/omni/include/mxqueue.h
Normal file
26
LEGO1/omni/include/mxqueue.h
Normal file
@@ -0,0 +1,26 @@
|
||||
#ifndef MXQUEUE_H
|
||||
#define MXQUEUE_H
|
||||
|
||||
#include "mxlist.h"
|
||||
|
||||
template <class T>
|
||||
class MxQueue : public MxList<T> {
|
||||
public:
|
||||
void Enqueue(T& p_obj)
|
||||
{
|
||||
// TODO
|
||||
}
|
||||
|
||||
MxBool Dequeue(T& p_obj)
|
||||
{
|
||||
MxBool hasNext = (this->m_first != NULL);
|
||||
if (this->m_first) {
|
||||
p_obj = this->m_first->GetValue();
|
||||
this->DeleteEntry(this->m_first);
|
||||
}
|
||||
|
||||
return hasNext;
|
||||
}
|
||||
};
|
||||
|
||||
#endif // MXQUEUE_H
|
41
LEGO1/omni/include/mxramstreamcontroller.h
Normal file
41
LEGO1/omni/include/mxramstreamcontroller.h
Normal file
@@ -0,0 +1,41 @@
|
||||
#ifndef MXRAMSTREAMCONTROLLER_H
|
||||
#define MXRAMSTREAMCONTROLLER_H
|
||||
|
||||
#include "mxdsbuffer.h"
|
||||
#include "mxdsstreamingaction.h"
|
||||
#include "mxstreamcontroller.h"
|
||||
|
||||
// VTABLE: LEGO1 0x100dc728
|
||||
// SIZE 0x98
|
||||
class MxRAMStreamController : public MxStreamController {
|
||||
public:
|
||||
inline MxRAMStreamController() {}
|
||||
|
||||
// FUNCTION: LEGO1 0x100b9430
|
||||
inline virtual const char* ClassName() const override // vtable+0xc
|
||||
{
|
||||
// STRING: LEGO1 0x10102118
|
||||
return "MxRAMStreamController";
|
||||
}
|
||||
|
||||
// FUNCTION: LEGO1 0x100b9440
|
||||
inline virtual MxBool IsA(const char* p_name) const override // vtable+0x10
|
||||
{
|
||||
return !strcmp(p_name, MxRAMStreamController::ClassName()) ||
|
||||
!strcmp(p_name, MxStreamController::ClassName()) || MxCore::IsA(p_name);
|
||||
}
|
||||
|
||||
virtual MxResult Open(const char* p_filename) override;
|
||||
virtual MxResult VTable0x20(MxDSAction* p_action) override;
|
||||
virtual MxResult VTable0x24(MxDSAction* p_action) override;
|
||||
|
||||
private:
|
||||
MxDSBuffer m_buffer; // 0x64
|
||||
|
||||
MxResult DeserializeObject(MxDSStreamingAction& p_action);
|
||||
};
|
||||
|
||||
// SYNTHETIC: LEGO1 0x100b94f0
|
||||
// MxRAMStreamController::`scalar deleting destructor'
|
||||
|
||||
#endif // MXRAMSTREAMCONTROLLER_H
|
45
LEGO1/omni/include/mxramstreamprovider.h
Normal file
45
LEGO1/omni/include/mxramstreamprovider.h
Normal file
@@ -0,0 +1,45 @@
|
||||
#ifndef MXRAMSTREAMPROVIDER_H
|
||||
#define MXRAMSTREAMPROVIDER_H
|
||||
|
||||
#include "mxstreamprovider.h"
|
||||
|
||||
// VTABLE: LEGO1 0x100dd0d0
|
||||
// SIZE 0x24
|
||||
class MxRAMStreamProvider : public MxStreamProvider {
|
||||
public:
|
||||
MxRAMStreamProvider();
|
||||
virtual ~MxRAMStreamProvider() override;
|
||||
|
||||
// FUNCTION: LEGO1 0x100d0970
|
||||
inline virtual const char* ClassName() const override // vtable+0xc
|
||||
{
|
||||
// STRING: LEGO1 0x10102864
|
||||
return "MxRAMStreamProvider";
|
||||
}
|
||||
|
||||
// FUNCTION: LEGO1 0x100d0980
|
||||
inline virtual MxBool IsA(const char* p_name) const override // vtable+0x10
|
||||
{
|
||||
return !strcmp(p_name, MxRAMStreamProvider::ClassName()) || MxStreamProvider::IsA(p_name);
|
||||
}
|
||||
|
||||
virtual MxResult SetResourceToGet(MxStreamController* p_resource) override; // vtable+0x14
|
||||
virtual MxU32 GetFileSize() override; // vtable+0x18
|
||||
virtual MxS32 GetStreamBuffersNum() override; // vtable+0x1c
|
||||
virtual MxU32 GetLengthInDWords() override; // vtable+0x24
|
||||
virtual MxU32* GetBufferForDWords() override; // vtable+0x28
|
||||
|
||||
inline MxU32* GetBufferOfFileSize() { return m_pBufferOfFileSize; }
|
||||
|
||||
protected:
|
||||
MxU32 m_bufferSize; // 0x10
|
||||
MxU32 m_fileSize; // 0x14
|
||||
MxU32* m_pBufferOfFileSize; // 0x18
|
||||
MxU32 m_lengthInDWords; // 0x1c
|
||||
MxU32* m_bufferForDWords; // 0x20
|
||||
};
|
||||
|
||||
// SYNTHETIC: LEGO1 0x100d0a30
|
||||
// MxRAMStreamProvider::`scalar deleting destructor'
|
||||
|
||||
#endif // MXRAMSTREAMPROVIDER_H
|
126
LEGO1/omni/include/mxrect32.h
Normal file
126
LEGO1/omni/include/mxrect32.h
Normal file
@@ -0,0 +1,126 @@
|
||||
#ifndef MXRECT32_H
|
||||
#define MXRECT32_H
|
||||
|
||||
#include "mxpoint32.h"
|
||||
#include "mxsize32.h"
|
||||
|
||||
// SIZE 0x10
|
||||
class MxRect32 {
|
||||
public:
|
||||
MxRect32() {}
|
||||
MxRect32(MxS32 p_left, MxS32 p_top, MxS32 p_right, MxS32 p_bottom) { CopyFrom(p_left, p_top, p_right, p_bottom); }
|
||||
MxRect32(const MxPoint32& p_point, const MxSize32& p_size) { CopyFrom(p_point, p_size); }
|
||||
MxRect32(const MxRect32& p_a, const MxRect32& p_b)
|
||||
{
|
||||
m_left = Max(p_a.m_left, p_b.m_left);
|
||||
m_top = Max(p_a.m_top, p_b.m_top);
|
||||
m_right = Min(p_a.m_right, p_b.m_right);
|
||||
m_bottom = Min(p_a.m_bottom, p_b.m_bottom);
|
||||
}
|
||||
|
||||
MxRect32(const MxRect32& p_rect) { CopyFrom(p_rect); }
|
||||
|
||||
MxRect32& operator=(const MxRect32& p_rect)
|
||||
{
|
||||
CopyFrom(p_rect);
|
||||
return *this;
|
||||
}
|
||||
|
||||
inline void Intersect(const MxRect32& p_rect)
|
||||
{
|
||||
m_left = Max(p_rect.m_left, m_left);
|
||||
m_top = Max(p_rect.m_top, m_top);
|
||||
m_right = Min(p_rect.m_right, m_right);
|
||||
m_bottom = Min(p_rect.m_bottom, m_bottom);
|
||||
}
|
||||
|
||||
inline void SetPoint(const MxPoint32& p_point)
|
||||
{
|
||||
this->m_left = p_point.GetX();
|
||||
this->m_top = p_point.GetY();
|
||||
}
|
||||
|
||||
inline void AddPoint(const MxPoint32& p_point)
|
||||
{
|
||||
this->m_left += p_point.GetX();
|
||||
this->m_top += p_point.GetY();
|
||||
this->m_right += p_point.GetX();
|
||||
this->m_bottom += p_point.GetY();
|
||||
}
|
||||
|
||||
inline void SubtractPoint(const MxPoint32& p_point)
|
||||
{
|
||||
this->m_left -= p_point.GetX();
|
||||
this->m_top -= p_point.GetY();
|
||||
this->m_right -= p_point.GetX();
|
||||
this->m_bottom -= p_point.GetY();
|
||||
}
|
||||
|
||||
inline void UpdateBounds(const MxRect32& p_rect)
|
||||
{
|
||||
m_left = Min(m_left, p_rect.m_left);
|
||||
m_top = Min(m_top, p_rect.m_top);
|
||||
m_right = Max(m_right, p_rect.m_right);
|
||||
m_bottom = Max(m_bottom, p_rect.m_bottom);
|
||||
}
|
||||
|
||||
inline MxBool IsValid() const { return m_left < m_right && m_top < m_bottom; }
|
||||
inline MxBool IntersectsWith(const MxRect32& p_rect) const
|
||||
{
|
||||
return m_left < p_rect.m_right && p_rect.m_left < m_right && m_top < p_rect.m_bottom && p_rect.m_top < m_bottom;
|
||||
}
|
||||
|
||||
inline MxS32 GetWidth() const { return (m_right - m_left) + 1; }
|
||||
inline MxS32 GetHeight() const { return (m_bottom - m_top) + 1; }
|
||||
|
||||
inline MxPoint32 GetPoint() const { return MxPoint32(this->m_left, this->m_top); }
|
||||
inline MxSize32 GetSize() const { return MxSize32(this->m_right, this->m_bottom); }
|
||||
|
||||
inline MxS32 GetLeft() const { return m_left; }
|
||||
inline MxS32 GetTop() const { return m_top; }
|
||||
inline MxS32 GetRight() const { return m_right; }
|
||||
inline MxS32 GetBottom() const { return m_bottom; }
|
||||
|
||||
inline void SetLeft(MxS32 p_left) { m_left = p_left; }
|
||||
inline void SetTop(MxS32 p_top) { m_top = p_top; }
|
||||
inline void SetRight(MxS32 p_right) { m_right = p_right; }
|
||||
inline void SetBottom(MxS32 p_bottom) { m_bottom = p_bottom; }
|
||||
|
||||
private:
|
||||
inline void CopyFrom(MxS32 p_left, MxS32 p_top, MxS32 p_right, MxS32 p_bottom)
|
||||
{
|
||||
this->m_left = p_left;
|
||||
this->m_top = p_top;
|
||||
this->m_right = p_right;
|
||||
this->m_bottom = p_bottom;
|
||||
}
|
||||
|
||||
inline void CopyFrom(const MxRect32& p_rect)
|
||||
{
|
||||
this->m_left = p_rect.m_left;
|
||||
this->m_top = p_rect.m_top;
|
||||
this->m_right = p_rect.m_right;
|
||||
this->m_bottom = p_rect.m_bottom;
|
||||
}
|
||||
|
||||
// The address might also be the constructor that calls CopyFrom
|
||||
// FUNCTION: LEGO1 0x100b6fc0
|
||||
inline MxRect32* CopyFrom(const MxPoint32& p_point, const MxSize32& p_size)
|
||||
{
|
||||
this->m_left = p_point.GetX();
|
||||
this->m_top = p_point.GetY();
|
||||
this->m_right = p_size.GetWidth() + p_point.GetX() - 1;
|
||||
this->m_bottom = p_size.GetHeight() + p_point.GetY() - 1;
|
||||
return this;
|
||||
}
|
||||
|
||||
inline static MxS32 Min(MxS32 p_a, MxS32 p_b) { return p_a <= p_b ? p_a : p_b; };
|
||||
inline static MxS32 Max(MxS32 p_a, MxS32 p_b) { return p_a <= p_b ? p_b : p_a; };
|
||||
|
||||
MxS32 m_left; // 0x00
|
||||
MxS32 m_top; // 0x04
|
||||
MxS32 m_right; // 0x08
|
||||
MxS32 m_bottom; // 0x0c
|
||||
};
|
||||
|
||||
#endif // MXRECT32_H
|
86
LEGO1/omni/include/mxrectlist.h
Normal file
86
LEGO1/omni/include/mxrectlist.h
Normal file
@@ -0,0 +1,86 @@
|
||||
#ifndef MXRECTLIST_H
|
||||
#define MXRECTLIST_H
|
||||
|
||||
#include "mxlist.h"
|
||||
#include "mxrect32.h"
|
||||
|
||||
// VTABLE: LEGO1 0x100dc3f0
|
||||
// SIZE 0x18
|
||||
class MxRectList : public MxPtrList<MxRect32> {
|
||||
public:
|
||||
MxRectList(MxBool p_ownership = FALSE) : MxPtrList<MxRect32>(p_ownership) {}
|
||||
};
|
||||
|
||||
// VTABLE: LEGO1 0x100dc438
|
||||
// class MxListCursor<MxRect32 *>
|
||||
|
||||
// VTABLE: LEGO1 0x100dc408
|
||||
// class MxPtrListCursor<MxRect32>
|
||||
|
||||
// VTABLE: LEGO1 0x100dc420
|
||||
class MxRectListCursor : public MxPtrListCursor<MxRect32> {
|
||||
public:
|
||||
MxRectListCursor(MxRectList* p_list) : MxPtrListCursor<MxRect32>(p_list){};
|
||||
};
|
||||
|
||||
// VTABLE: LEGO1 0x100dc3d8
|
||||
// class MxPtrList<MxRect32>
|
||||
|
||||
// VTABLE: LEGO1 0x100dc450
|
||||
// class MxList<MxRect32 *>
|
||||
|
||||
// VTABLE: LEGO1 0x100dc468
|
||||
// class MxCollection<MxRect32 *>
|
||||
|
||||
// TEMPLATE: LEGO1 0x100b3c00
|
||||
// MxCollection<MxRect32 *>::Compare
|
||||
|
||||
// TEMPLATE: LEGO1 0x100b3c10
|
||||
// MxCollection<MxRect32 *>::MxCollection<MxRect32 *>
|
||||
|
||||
// TEMPLATE: LEGO1 0x100b3c80
|
||||
// MxCollection<MxRect32 *>::~MxCollection<MxRect32 *>
|
||||
|
||||
// TEMPLATE: LEGO1 0x100b3cd0
|
||||
// MxCollection<MxRect32 *>::Destroy
|
||||
|
||||
// TEMPLATE: LEGO1 0x100b3ce0
|
||||
// MxList<MxRect32 *>::~MxList<MxRect32 *>
|
||||
|
||||
// TEMPLATE: LEGO1 0x100b3d70
|
||||
// MxPtrList<MxRect32>::Destroy
|
||||
|
||||
// SYNTHETIC: LEGO1 0x100b3d80
|
||||
// MxRectList::`scalar deleting destructor'
|
||||
|
||||
// SYNTHETIC: LEGO1 0x100b3e40
|
||||
// MxCollection<MxRect32 *>::`scalar deleting destructor'
|
||||
|
||||
// SYNTHETIC: LEGO1 0x100b3eb0
|
||||
// MxList<MxRect32 *>::`scalar deleting destructor'
|
||||
|
||||
// SYNTHETIC: LEGO1 0x100b3f60
|
||||
// MxPtrList<MxRect32>::`scalar deleting destructor'
|
||||
|
||||
// TEMPLATE: LEGO1 0x100b3fd0
|
||||
// MxRectList::~MxRectList
|
||||
|
||||
// SYNTHETIC: LEGO1 0x100b4020
|
||||
// MxRectListCursor::`scalar deleting destructor'
|
||||
|
||||
// TEMPLATE: LEGO1 0x100b4090
|
||||
// MxPtrListCursor<MxRect32>::~MxPtrListCursor<MxRect32>
|
||||
|
||||
// SYNTHETIC: LEGO1 0x100b40e0
|
||||
// MxListCursor<MxRect32 *>::`scalar deleting destructor'
|
||||
|
||||
// SYNTHETIC: LEGO1 0x100b4150
|
||||
// MxPtrListCursor<MxRect32>::`scalar deleting destructor'
|
||||
|
||||
// TEMPLATE: LEGO1 0x100b41c0
|
||||
// MxListCursor<MxRect32 *>::~MxListCursor<MxRect32 *>
|
||||
|
||||
// TEMPLATE: LEGO1 0x100b4210
|
||||
// MxRectListCursor::~MxRectListCursor
|
||||
|
||||
#endif // MXRECTLIST_H
|
31
LEGO1/omni/include/mxregion.h
Normal file
31
LEGO1/omni/include/mxregion.h
Normal file
@@ -0,0 +1,31 @@
|
||||
#ifndef MXREGION_H
|
||||
#define MXREGION_H
|
||||
|
||||
#include "decomp.h"
|
||||
#include "mxcore.h"
|
||||
#include "mxrect32.h"
|
||||
#include "mxregionlist.h"
|
||||
|
||||
// VTABLE: LEGO1 0x100dcae8
|
||||
// SIZE 0x1c
|
||||
class MxRegion : public MxCore {
|
||||
public:
|
||||
MxRegion();
|
||||
virtual ~MxRegion() override;
|
||||
|
||||
virtual void Reset(); // vtable+0x14
|
||||
virtual void VTable0x18(MxRect32& p_rect); // vtable+0x18
|
||||
virtual MxBool VTable0x1c(MxRect32& p_rect); // vtable+0x1c
|
||||
virtual MxBool VTable0x20(); // vtable+0x20
|
||||
|
||||
inline MxRegionTopBottomList* GetTopBottomList() const { return m_list; }
|
||||
inline const MxRect32& GetRect() const { return m_rect; }
|
||||
|
||||
friend class MxRegionCursor;
|
||||
|
||||
private:
|
||||
MxRegionTopBottomList* m_list; // 0x08
|
||||
MxRect32 m_rect; // 0x0c
|
||||
};
|
||||
|
||||
#endif // MXREGION_H
|
45
LEGO1/omni/include/mxregioncursor.h
Normal file
45
LEGO1/omni/include/mxregioncursor.h
Normal file
@@ -0,0 +1,45 @@
|
||||
#ifndef MXREGIONCURSOR_H
|
||||
#define MXREGIONCURSOR_H
|
||||
|
||||
#include "mxregion.h"
|
||||
|
||||
// VTABLE: LEGO1 0x100dcbb8
|
||||
// SIZE 0x18
|
||||
class MxRegionCursor : public MxCore {
|
||||
public:
|
||||
MxRegionCursor(MxRegion* p_region);
|
||||
virtual ~MxRegionCursor() override;
|
||||
|
||||
virtual MxRect32* VTable0x14(MxRect32& p_rect); // vtable+0x14
|
||||
virtual MxRect32* VTable0x18(); // vtable+0x18
|
||||
virtual MxRect32* VTable0x1c(MxRect32& p_rect); // vtable+0x1c
|
||||
virtual MxRect32* VTable0x20(); // vtable+0x20
|
||||
virtual MxRect32* VTable0x24(MxRect32& p_rect); // vtable+0x24
|
||||
virtual MxRect32* VTable0x28(); // vtable+0x28
|
||||
virtual MxRect32* VTable0x2c(MxRect32& p_rect); // vtable+0x2c
|
||||
virtual MxRect32* VTable0x30(); // vtable+0x30
|
||||
|
||||
// FUNCTION: LEGO1 0x100c4070
|
||||
virtual MxRect32* GetRect() { return m_rect; } // vtable+0x34
|
||||
|
||||
// FUNCTION: LEGO1 0x100c4080
|
||||
virtual MxBool HasRect() { return m_rect != NULL; } // vtable+0x38
|
||||
|
||||
virtual void Reset(); // vtable+0x3c
|
||||
|
||||
private:
|
||||
void FUN_100c46c0(MxRegionLeftRightList& p_leftRightList);
|
||||
void UpdateRect(MxS32 p_left, MxS32 p_top, MxS32 p_right, MxS32 p_bottom);
|
||||
void FUN_100c4a20(MxRect32& p_rect);
|
||||
void FUN_100c4b50(MxRect32& p_rect);
|
||||
|
||||
MxRegion* m_region; // 0x08
|
||||
MxRect32* m_rect; // 0x0c
|
||||
MxRegionTopBottomListCursor* m_topBottomCursor; // 0x10
|
||||
MxRegionLeftRightListCursor* m_leftRightCursor; // 0x14
|
||||
};
|
||||
|
||||
// SYNTHETIC: LEGO1 0x100c4090
|
||||
// MxRegionCursor::`scalar deleting destructor'
|
||||
|
||||
#endif // MXREGIONCURSOR_H
|
206
LEGO1/omni/include/mxregionlist.h
Normal file
206
LEGO1/omni/include/mxregionlist.h
Normal file
@@ -0,0 +1,206 @@
|
||||
#ifndef MXREGIONLIST_H
|
||||
#define MXREGIONLIST_H
|
||||
|
||||
#include "mxlist.h"
|
||||
|
||||
// SIZE 0x08
|
||||
struct MxRegionLeftRight {
|
||||
MxRegionLeftRight(MxS32 p_left, MxS32 p_right)
|
||||
{
|
||||
m_left = p_left;
|
||||
m_right = p_right;
|
||||
}
|
||||
|
||||
MxRegionLeftRight* Clone() { return new MxRegionLeftRight(m_left, m_right); }
|
||||
|
||||
inline MxS32 GetLeft() { return m_left; }
|
||||
inline MxS32 GetRight() { return m_right; }
|
||||
|
||||
inline void SetLeft(MxS32 p_left) { m_left = p_left; }
|
||||
inline void SetRight(MxS32 p_right) { m_right = p_right; }
|
||||
|
||||
inline MxBool IntersectsWith(MxRect32& p_rect) { return m_left < p_rect.GetRight() && p_rect.GetTop() < m_right; }
|
||||
|
||||
private:
|
||||
MxS32 m_left; // 0x00
|
||||
MxS32 m_right; // 0x04
|
||||
};
|
||||
|
||||
// VTABLE: LEGO1 0x100dcc40
|
||||
// class MxCollection<MxRegionLeftRight *>
|
||||
|
||||
// VTABLE: LEGO1 0x100dcc58
|
||||
// class MxList<MxRegionLeftRight *>
|
||||
|
||||
// VTABLE: LEGO1 0x100dcc70
|
||||
// class MxPtrList<MxRegionLeftRight>
|
||||
|
||||
// VTABLE: LEGO1 0x100dcc88
|
||||
// SIZE 0x18
|
||||
class MxRegionLeftRightList : public MxPtrList<MxRegionLeftRight> {
|
||||
public:
|
||||
MxRegionLeftRightList() : MxPtrList<MxRegionLeftRight>(TRUE) {}
|
||||
};
|
||||
|
||||
// VTABLE: LEGO1 0x100dcbf8
|
||||
// class MxPtrListCursor<MxRegionLeftRight>
|
||||
|
||||
// VTABLE: LEGO1 0x100dcc28
|
||||
// class MxListCursor<MxRegionLeftRight *>
|
||||
|
||||
// VTABLE: LEGO1 0x100dcc10
|
||||
class MxRegionLeftRightListCursor : public MxPtrListCursor<MxRegionLeftRight> {
|
||||
public:
|
||||
MxRegionLeftRightListCursor(MxRegionLeftRightList* p_list) : MxPtrListCursor<MxRegionLeftRight>(p_list){};
|
||||
};
|
||||
|
||||
// SIZE 0x0c
|
||||
struct MxRegionTopBottom {
|
||||
MxRegionTopBottom(MxRect32& p_rect);
|
||||
MxRegionTopBottom(MxS32 p_top, MxS32 p_bottom);
|
||||
~MxRegionTopBottom() { delete m_leftRightList; }
|
||||
|
||||
MxRegionTopBottom* Clone();
|
||||
void FUN_100c5280(MxS32 p_left, MxS32 p_right);
|
||||
MxBool FUN_100c57b0(MxRect32& p_rect);
|
||||
|
||||
inline MxS32 GetTop() { return m_top; }
|
||||
inline MxS32 GetBottom() { return m_bottom; }
|
||||
|
||||
inline void SetTop(MxS32 p_top) { m_top = p_top; }
|
||||
inline void SetBottom(MxS32 p_bottom) { m_bottom = p_bottom; }
|
||||
|
||||
inline MxBool IntersectsWith(MxRect32& p_rect) { return m_top < p_rect.GetBottom() && p_rect.GetTop() < m_bottom; }
|
||||
|
||||
friend class MxRegionTopBottomList;
|
||||
friend class MxRegionCursor;
|
||||
|
||||
private:
|
||||
MxS32 m_top; // 0x00
|
||||
MxS32 m_bottom; // 0x04
|
||||
MxRegionLeftRightList* m_leftRightList; // 0x08
|
||||
};
|
||||
|
||||
// VTABLE: LEGO1 0x100dcb10
|
||||
// class MxCollection<MxRegionTopBottom *>
|
||||
|
||||
// VTABLE: LEGO1 0x100dcb28
|
||||
// class MxList<MxRegionTopBottom *>
|
||||
|
||||
// VTABLE: LEGO1 0x100dcb40
|
||||
// class MxPtrList<MxRegionTopBottom>
|
||||
|
||||
// VTABLE: LEGO1 0x100dcb58
|
||||
// SIZE 0x18
|
||||
class MxRegionTopBottomList : public MxPtrList<MxRegionTopBottom> {
|
||||
public:
|
||||
MxRegionTopBottomList() : MxPtrList<MxRegionTopBottom>(TRUE) {}
|
||||
};
|
||||
|
||||
// VTABLE: LEGO1 0x100dcb70
|
||||
// class MxPtrListCursor<MxRegionTopBottom>
|
||||
|
||||
// VTABLE: LEGO1 0x100dcba0
|
||||
// class MxListCursor<MxRegionTopBottom *>
|
||||
|
||||
// TODO: The initialize list param type should be MxRegionTopBottomList, but doing that
|
||||
// drastically reduced the match percentage for MxRegion::VTable0x18.
|
||||
// It also works with MxPtrList, so we'll do that until we figure this out.
|
||||
|
||||
// VTABLE: LEGO1 0x100dcb88
|
||||
class MxRegionTopBottomListCursor : public MxPtrListCursor<MxRegionTopBottom> {
|
||||
public:
|
||||
MxRegionTopBottomListCursor(MxPtrList<MxRegionTopBottom>* p_list) : MxPtrListCursor<MxRegionTopBottom>(p_list){};
|
||||
};
|
||||
|
||||
// TEMPLATE: LEGO1 0x100c32e0
|
||||
// MxCollection<MxRegionTopBottom *>::Compare
|
||||
|
||||
// TEMPLATE: LEGO1 0x100c3340
|
||||
// MxCollection<MxRegionTopBottom *>::Destroy
|
||||
|
||||
// TEMPLATE: LEGO1 0x100c33e0
|
||||
// MxPtrList<MxRegionTopBottom>::Destroy
|
||||
|
||||
// SYNTHETIC: LEGO1 0x100c34d0
|
||||
// MxCollection<MxRegionTopBottom *>::`scalar deleting destructor'
|
||||
|
||||
// SYNTHETIC: LEGO1 0x100c3540
|
||||
// MxList<MxRegionTopBottom *>::`scalar deleting destructor'
|
||||
|
||||
// SYNTHETIC: LEGO1 0x100c35f0
|
||||
// MxPtrList<MxRegionTopBottom>::`scalar deleting destructor'
|
||||
|
||||
// SYNTHETIC: LEGO1 0x100c3be0
|
||||
// MxRegionTopBottomListCursor::`scalar deleting destructor'
|
||||
|
||||
// TEMPLATE: LEGO1 0x100c3c50
|
||||
// MxPtrListCursor<MxRegionTopBottom>::~MxPtrListCursor<MxRegionTopBottom>
|
||||
|
||||
// SYNTHETIC: LEGO1 0x100c3ca0
|
||||
// MxListCursor<MxRegionTopBottom *>::`scalar deleting destructor'
|
||||
|
||||
// SYNTHETIC: LEGO1 0x100c3d10
|
||||
// MxPtrListCursor<MxRegionTopBottom>::`scalar deleting destructor'
|
||||
|
||||
// TEMPLATE: LEGO1 0x100c3d80
|
||||
// MxListCursor<MxRegionTopBottom *>::~MxListCursor<MxRegionTopBottom *>
|
||||
|
||||
// FUNCTION: LEGO1 0x100c3dd0
|
||||
// MxRegionTopBottomListCursor::~MxRegionTopBottomListCursor
|
||||
|
||||
// SYNTHETIC: LEGO1 0x100c4790
|
||||
// MxRegionLeftRightListCursor::`scalar deleting destructor'
|
||||
|
||||
// TEMPLATE: LEGO1 0x100c4800
|
||||
// MxPtrListCursor<MxRegionLeftRight>::~MxPtrListCursor<MxRegionLeftRight>
|
||||
|
||||
// SYNTHETIC: LEGO1 0x100c4850
|
||||
// MxListCursor<MxRegionLeftRight *>::`scalar deleting destructor'
|
||||
|
||||
// SYNTHETIC: LEGO1 0x100c48c0
|
||||
// MxPtrListCursor<MxRegionLeftRight>::`scalar deleting destructor'
|
||||
|
||||
// TEMPLATE: LEGO1 0x100c4930
|
||||
// MxListCursor<MxRegionLeftRight *>::~MxListCursor<MxRegionLeftRight *>
|
||||
|
||||
// TEMPLATE: LEGO1 0x100c4d80
|
||||
// MxCollection<MxRegionLeftRight *>::Compare
|
||||
|
||||
// TEMPLATE: LEGO1 0x100c4de0
|
||||
// MxCollection<MxRegionLeftRight *>::Destroy
|
||||
|
||||
// SYNTHETIC: LEGO1 0x100c4f50
|
||||
// MxCollection<MxRegionLeftRight *>::`scalar deleting destructor'
|
||||
|
||||
// TEMPLATE: LEGO1 0x100c4e80
|
||||
// MxPtrList<MxRegionLeftRight>::Destroy
|
||||
|
||||
// SYNTHETIC: LEGO1 0x100c4fc0
|
||||
// MxList<MxRegionLeftRight *>::`scalar deleting destructor'
|
||||
|
||||
// SYNTHETIC: LEGO1 0x100c5070
|
||||
// MxPtrList<MxRegionLeftRight>::`scalar deleting destructor'
|
||||
|
||||
// TEMPLATE: LEGO1 0x100c54f0
|
||||
// MxListCursor<MxRegionLeftRight *>::MxListCursor<MxRegionLeftRight *>
|
||||
|
||||
// FUNCTION: LEGO1 0x100c5560
|
||||
// MxRegionLeftRightListCursor::~MxRegionLeftRightListCursor
|
||||
|
||||
// TEMPLATE: LEGO1 0x100c55b0
|
||||
// MxListCursor<MxRegionLeftRight *>::operator=
|
||||
|
||||
// TEMPLATE: LEGO1 0x100c58c0
|
||||
// MxList<MxRegionLeftRight *>::InsertEntry
|
||||
|
||||
// TEMPLATE: LEGO1 0x100c5970
|
||||
// MxList<MxRegionTopBottom *>::InsertEntry
|
||||
|
||||
// TEMPLATE: LEGO1 0x100c5a20
|
||||
// MxListEntry<MxRegionTopBottom *>::MxListEntry<MxRegionTopBottom *>
|
||||
|
||||
// TEMPLATE: LEGO1 0x100c5a40
|
||||
// MxList<MxRegionLeftRight *>::DeleteEntry
|
||||
|
||||
#endif // MXREGIONLIST_H
|
12
LEGO1/omni/include/mxscheduler.h
Normal file
12
LEGO1/omni/include/mxscheduler.h
Normal file
@@ -0,0 +1,12 @@
|
||||
#ifndef MXSCHEDULER_H
|
||||
#define MXSCHEDULER_H
|
||||
|
||||
#include "mxtypes.h"
|
||||
|
||||
class MxScheduler {
|
||||
public:
|
||||
__declspec(dllexport) static MxScheduler* GetInstance();
|
||||
__declspec(dllexport) void StartMultiTasking(MxULong);
|
||||
};
|
||||
|
||||
#endif // MXSCHEDULER_H
|
25
LEGO1/omni/include/mxsemaphore.h
Normal file
25
LEGO1/omni/include/mxsemaphore.h
Normal file
@@ -0,0 +1,25 @@
|
||||
#ifndef MX_SEMAPHORE_H
|
||||
#define MX_SEMAPHORE_H
|
||||
|
||||
#include "mxtypes.h"
|
||||
|
||||
#include <windows.h>
|
||||
|
||||
// SIZE 0x08
|
||||
class MxSemaphore {
|
||||
public:
|
||||
MxSemaphore();
|
||||
|
||||
// Inlined only, no offset
|
||||
~MxSemaphore() { CloseHandle(m_hSemaphore); }
|
||||
|
||||
virtual MxResult Init(MxU32 p_initialCount, MxU32 p_maxCount);
|
||||
|
||||
void Wait(MxU32 p_timeoutMS);
|
||||
void Release(MxU32 p_releaseCount);
|
||||
|
||||
private:
|
||||
HANDLE m_hSemaphore; // 0x04
|
||||
};
|
||||
|
||||
#endif // MX_SEMAPHORE_H
|
25
LEGO1/omni/include/mxsize32.h
Normal file
25
LEGO1/omni/include/mxsize32.h
Normal file
@@ -0,0 +1,25 @@
|
||||
#ifndef MXSIZE32_H
|
||||
#define MXSIZE32_H
|
||||
|
||||
#include "mxtypes.h"
|
||||
|
||||
class MxSize32 {
|
||||
public:
|
||||
MxSize32() {}
|
||||
MxSize32(MxS32 p_width, MxS32 p_height) { CopyFrom(p_width, p_height); }
|
||||
|
||||
inline MxS32 GetWidth() const { return m_width; }
|
||||
inline MxS32 GetHeight() const { return m_height; }
|
||||
|
||||
private:
|
||||
inline void CopyFrom(MxS32 p_width, MxS32 p_height)
|
||||
{
|
||||
this->m_width = p_width;
|
||||
this->m_height = p_height;
|
||||
}
|
||||
|
||||
MxS32 m_width;
|
||||
MxS32 m_height;
|
||||
};
|
||||
|
||||
#endif // MXSIZE32_H
|
62
LEGO1/omni/include/mxsmack.h
Normal file
62
LEGO1/omni/include/mxsmack.h
Normal file
@@ -0,0 +1,62 @@
|
||||
#ifndef MXSMACK_H
|
||||
#define MXSMACK_H
|
||||
|
||||
#include "decomp.h"
|
||||
#include "mxbitmap.h"
|
||||
#include "mxrectlist.h"
|
||||
#include "mxtypes.h"
|
||||
|
||||
#include <smack.h>
|
||||
|
||||
// These functions are not part of the public interface,
|
||||
// but present in SMACK.LIB and used directly by Mindscape.
|
||||
extern "C"
|
||||
{
|
||||
// (SMACK.LIB) FUNCTION: LEGO1 0x100cd782
|
||||
u32 SmackGetSizeTables();
|
||||
|
||||
// (SMACK.LIB) FUNCTION: LEGO1 0x100cd7e8
|
||||
void SmackDoTables(
|
||||
u8* p_huffmanTrees,
|
||||
u8* p_huffmanTables,
|
||||
u32 p_codeSize,
|
||||
u32 p_abSize,
|
||||
u32 p_detailSize,
|
||||
u32 p_typeSize
|
||||
);
|
||||
|
||||
// (SMACK.LIB) FUNCTION: LEGO1 0x100cda83
|
||||
void SmackDoFrameToBuffer(u8* p_source, u8* p_huffmanTables, u8* p_unk0x6b4);
|
||||
|
||||
// (SMACK.LIB) FUNCTION: LEGO1 0x100d052c
|
||||
u32 SmackGetSizeDeltas(u32 p_width, u32 p_height);
|
||||
|
||||
// (SMACK.LIB) FUNCTION: LEGO1 0x100d0543
|
||||
u8 SmackGetRect(u8* p_unk0x6b4, u32* p_rect);
|
||||
}
|
||||
|
||||
// SIZE 0x6b8
|
||||
struct MxSmack {
|
||||
SmackTag m_smackTag; // 0x00
|
||||
undefined m_unk0x390[784]; // 0x390
|
||||
MxU32* m_frameSizes; // 0x6a0
|
||||
MxU8* m_frameTypes; // 0x6a4
|
||||
MxU8* m_huffmanTrees; // 0x6a8
|
||||
MxU8* m_huffmanTables; // 0x6ac
|
||||
MxU32 m_maxFrameSize; // 0x6b0
|
||||
MxU8* m_unk0x6b4; // 0x6b4
|
||||
|
||||
static MxResult LoadHeader(MxU8* p_data, MxSmack* p_mxSmack);
|
||||
static void Destroy(MxSmack* p_mxSmack);
|
||||
static MxResult LoadFrame(
|
||||
MxBITMAPINFO* p_bitmapInfo,
|
||||
MxU8* p_bitmapData,
|
||||
MxSmack* p_mxSmack,
|
||||
MxU8* p_chunkData,
|
||||
MxBool p_paletteChanged,
|
||||
MxRectList* p_list
|
||||
);
|
||||
static MxBool GetRect(MxU8* p_unk0x6b4, MxU16* p_und, u32* p_smackRect, MxRect32* p_rect);
|
||||
};
|
||||
|
||||
#endif // MXSMACK_H
|
45
LEGO1/omni/include/mxsmkpresenter.h
Normal file
45
LEGO1/omni/include/mxsmkpresenter.h
Normal file
@@ -0,0 +1,45 @@
|
||||
#ifndef MXSMKPRESENTER_H
|
||||
#define MXSMKPRESENTER_H
|
||||
|
||||
#include "decomp.h"
|
||||
#include "mxsmack.h"
|
||||
#include "mxvideopresenter.h"
|
||||
|
||||
// VTABLE: LEGO1 0x100dc348
|
||||
// SIZE 0x720
|
||||
class MxSmkPresenter : public MxVideoPresenter {
|
||||
public:
|
||||
MxSmkPresenter();
|
||||
virtual ~MxSmkPresenter() override;
|
||||
|
||||
// FUNCTION: LEGO1 0x100b3730
|
||||
inline virtual const char* ClassName() const override // vtable+0xc
|
||||
{
|
||||
// STRING: LEGO1 0x10101e38
|
||||
return "MxSmkPresenter";
|
||||
}
|
||||
|
||||
// FUNCTION: LEGO1 0x100b3740
|
||||
inline virtual MxBool IsA(const char* p_name) const override // vtable+0x10
|
||||
{
|
||||
return !strcmp(p_name, MxSmkPresenter::ClassName()) || MxVideoPresenter::IsA(p_name);
|
||||
}
|
||||
|
||||
virtual MxResult AddToManager() override; // vtable+0x34
|
||||
virtual void Destroy() override; // vtable+0x38
|
||||
virtual void LoadHeader(MxStreamChunk* p_chunk) override; // vtable+0x5c
|
||||
virtual void CreateBitmap() override; // vtable+0x60
|
||||
virtual void LoadFrame(MxStreamChunk* p_chunk) override; // vtable+0x68
|
||||
virtual void RealizePalette() override; // vtable+0x70
|
||||
virtual void VTable0x88(); // vtable+0x88
|
||||
|
||||
private:
|
||||
void Init();
|
||||
void Destroy(MxBool p_fromDestructor);
|
||||
|
||||
protected:
|
||||
MxSmack m_mxSmack; // 0x64
|
||||
MxU32 m_currentFrame; // 0x71c
|
||||
};
|
||||
|
||||
#endif // MXSMKPRESENTER_H
|
40
LEGO1/omni/include/mxsoundmanager.h
Normal file
40
LEGO1/omni/include/mxsoundmanager.h
Normal file
@@ -0,0 +1,40 @@
|
||||
#ifndef MXSOUNDMANAGER_H
|
||||
#define MXSOUNDMANAGER_H
|
||||
|
||||
#include "decomp.h"
|
||||
#include "mxatomid.h"
|
||||
#include "mxaudiomanager.h"
|
||||
|
||||
#include <dsound.h>
|
||||
|
||||
// VTABLE: LEGO1 0x100dc128
|
||||
// SIZE 0x3c
|
||||
class MxSoundManager : public MxAudioManager {
|
||||
public:
|
||||
MxSoundManager();
|
||||
virtual ~MxSoundManager() override; // vtable+0x0
|
||||
|
||||
virtual void Destroy() override; // vtable+0x18
|
||||
virtual void SetVolume(MxS32 p_volume) override; // vtable+0x2c
|
||||
virtual MxResult Create(MxU32 p_frequencyMS, MxBool p_createThread); // vtable+0x30
|
||||
virtual void Pause(); // vtable+0x34
|
||||
virtual void Resume(); // vtable+0x38
|
||||
|
||||
inline LPDIRECTSOUND GetDirectSound() { return m_directSound; }
|
||||
|
||||
MxS32 FUN_100aecf0(MxU32 p_undefined);
|
||||
|
||||
private:
|
||||
void Init();
|
||||
void Destroy(MxBool p_fromDestructor);
|
||||
MxPresenter* FUN_100aebd0(const MxAtomId& p_atomId, MxU32 p_objectId);
|
||||
|
||||
LPDIRECTSOUND m_directSound; // 0x30
|
||||
LPDIRECTSOUNDBUFFER m_dsBuffer; // 0x34
|
||||
undefined m_unk0x38[4];
|
||||
};
|
||||
|
||||
// SYNTHETIC: LEGO1 0x100ae7b0
|
||||
// MxSoundManager::`scalar deleting destructor'
|
||||
|
||||
#endif // MXSOUNDMANAGER_H
|
33
LEGO1/omni/include/mxsoundpresenter.h
Normal file
33
LEGO1/omni/include/mxsoundpresenter.h
Normal file
@@ -0,0 +1,33 @@
|
||||
#ifndef MXSOUNDPRESENTER_H
|
||||
#define MXSOUNDPRESENTER_H
|
||||
|
||||
#include "mxaudiopresenter.h"
|
||||
#include "mxomni.h"
|
||||
|
||||
// VTABLE: LEGO1 0x100d4b08
|
||||
// SIZE 0x54
|
||||
class MxSoundPresenter : public MxAudioPresenter {
|
||||
public:
|
||||
virtual ~MxSoundPresenter() override;
|
||||
|
||||
// FUNCTION: LEGO1 0x1000d4a0
|
||||
inline virtual const char* ClassName() const // vtable+0x0c
|
||||
{
|
||||
// STRING: LEGO1 0x100f07a0
|
||||
return "MxSoundPresenter";
|
||||
};
|
||||
|
||||
// FUNCTION: LEGO1 0x1000d4b0
|
||||
inline virtual MxBool IsA(const char* p_name) const // vtable+0x10
|
||||
{
|
||||
return !strcmp(p_name, MxSoundPresenter::ClassName()) || MxAudioPresenter::IsA(p_name);
|
||||
};
|
||||
|
||||
virtual MxResult AddToManager() override; // vtable+0x34
|
||||
virtual void Destroy() override; // vtable+0x38
|
||||
|
||||
protected:
|
||||
void Destroy(MxBool p_fromDestructor);
|
||||
};
|
||||
|
||||
#endif // MXSOUNDPRESENTER_H
|
52
LEGO1/omni/include/mxstillpresenter.h
Normal file
52
LEGO1/omni/include/mxstillpresenter.h
Normal file
@@ -0,0 +1,52 @@
|
||||
#ifndef MXSTILLPRESENTER_H
|
||||
#define MXSTILLPRESENTER_H
|
||||
|
||||
#include "decomp.h"
|
||||
#include "mxvideopresenter.h"
|
||||
|
||||
// VTABLE: LEGO1 0x100d7a38
|
||||
// SIZE 0x6c
|
||||
class MxStillPresenter : public MxVideoPresenter {
|
||||
public:
|
||||
MxStillPresenter() { m_bitmapInfo = NULL; }
|
||||
// FUNCTION: LEGO1 0x10043550
|
||||
virtual ~MxStillPresenter() override { Destroy(TRUE); }; // vtable+0x00
|
||||
|
||||
// FUNCTION: LEGO1 0x100435c0
|
||||
inline virtual const char* ClassName() const override // vtable+0xc
|
||||
{
|
||||
// STRING: LEGO1 0x100f0184
|
||||
return "MxStillPresenter";
|
||||
}
|
||||
|
||||
// FUNCTION: LEGO1 0x100435d0
|
||||
inline virtual MxBool IsA(const char* p_name) const override // vtable+0x10
|
||||
{
|
||||
return !strcmp(p_name, MxStillPresenter::ClassName()) || MxVideoPresenter::IsA(p_name);
|
||||
}
|
||||
|
||||
virtual void StartingTickle() override; // vtable+0x1c
|
||||
virtual void StreamingTickle() override; // vtable+0x20
|
||||
virtual void RepeatingTickle() override; // vtable+0x24
|
||||
virtual void ParseExtra() override; // vtable+0x30
|
||||
virtual void Destroy() override; // vtable+0x38
|
||||
virtual void Enable(MxBool p_enable) override; // vtable+0x54
|
||||
virtual void LoadHeader(MxStreamChunk* p_chunk) override; // vtable+0x5c
|
||||
virtual void CreateBitmap() override; // vtable+0x60
|
||||
virtual void NextFrame() override; // vtable+0x64
|
||||
virtual void LoadFrame(MxStreamChunk* p_chunk) override; // vtable+0x68
|
||||
virtual void RealizePalette() override; // vtable+0x70
|
||||
virtual void VTable0x88(MxS32 p_x, MxS32 p_y); // vtable+0x88
|
||||
virtual MxStillPresenter* Clone(); // vtable+0x8c
|
||||
|
||||
private:
|
||||
void Destroy(MxBool p_fromDestructor);
|
||||
|
||||
MxLong m_chunkTime; // 0x64
|
||||
MxBITMAPINFO* m_bitmapInfo; // 0x68
|
||||
};
|
||||
|
||||
// SYNTHETIC: LEGO1 0x100436e0
|
||||
// MxStillPresenter::`scalar deleting destructor'
|
||||
|
||||
#endif // MXSTILLPRESENTER_H
|
49
LEGO1/omni/include/mxstreamchunk.h
Normal file
49
LEGO1/omni/include/mxstreamchunk.h
Normal file
@@ -0,0 +1,49 @@
|
||||
#ifndef MXSTREAMCHUNK_H
|
||||
#define MXSTREAMCHUNK_H
|
||||
|
||||
#include "mxdschunk.h"
|
||||
#include "mxdsobject.h"
|
||||
|
||||
class MxDSBuffer;
|
||||
class MxStreamListMxDSSubscriber;
|
||||
|
||||
// VTABLE: LEGO1 0x100dc2a8
|
||||
// SIZE 0x20
|
||||
class MxStreamChunk : public MxDSChunk {
|
||||
public:
|
||||
inline MxStreamChunk() : m_buffer(NULL) {}
|
||||
virtual ~MxStreamChunk() override;
|
||||
|
||||
// FUNCTION: LEGO1 0x100b1fe0
|
||||
inline virtual const char* ClassName() const override // vtable+0xc
|
||||
{
|
||||
// STRING: LEGO1 0x10101e5c
|
||||
return "MxStreamChunk";
|
||||
}
|
||||
|
||||
// FUNCTION: LEGO1 0x100b1ff0
|
||||
inline virtual MxBool IsA(const char* p_name) const override // vtable+0x10
|
||||
{
|
||||
return !strcmp(p_name, MxStreamChunk::ClassName()) || MxDSChunk::IsA(p_name);
|
||||
}
|
||||
|
||||
inline MxDSBuffer* GetBuffer() { return m_buffer; }
|
||||
|
||||
MxResult ReadChunk(MxDSBuffer* p_buffer, MxU8* p_chunkData);
|
||||
MxU32 ReadChunkHeader(MxU8* p_chunkData);
|
||||
MxResult SendChunk(MxStreamListMxDSSubscriber& p_subscriberList, MxBool p_append, MxS16 p_obj24val);
|
||||
void SetBuffer(MxDSBuffer* p_buffer);
|
||||
|
||||
static MxU16* IntoFlags(MxU8* p_buffer);
|
||||
static MxU32* IntoObjectId(MxU8* p_buffer);
|
||||
static MxLong* IntoTime(MxU8* p_buffer);
|
||||
static MxU32* IntoLength(MxU8* p_buffer);
|
||||
|
||||
private:
|
||||
MxDSBuffer* m_buffer; // 0x1c
|
||||
};
|
||||
|
||||
// SYNTHETIC: LEGO1 0x100b20a0
|
||||
// MxStreamChunk::`scalar deleting destructor'
|
||||
|
||||
#endif // MXSTREAMCHUNK_H
|
55
LEGO1/omni/include/mxstreamchunklist.h
Normal file
55
LEGO1/omni/include/mxstreamchunklist.h
Normal file
@@ -0,0 +1,55 @@
|
||||
#ifndef MXSTREAMCHUNKLIST_H
|
||||
#define MXSTREAMCHUNKLIST_H
|
||||
|
||||
#include "decomp.h"
|
||||
#include "mxlist.h"
|
||||
|
||||
class MxStreamChunk;
|
||||
|
||||
// VTABLE: LEGO1 0x100dc5d0
|
||||
// class MxCollection<MxStreamChunk *>
|
||||
|
||||
// VTABLE: LEGO1 0x100dc5e8
|
||||
// class MxList<MxStreamChunk *>
|
||||
|
||||
// VTABLE: LEGO1 0x100dc600
|
||||
// SIZE 0x18
|
||||
class MxStreamChunkList : public MxList<MxStreamChunk*> {
|
||||
public:
|
||||
MxStreamChunkList() { m_customDestructor = Destroy; }
|
||||
|
||||
// FUNCTION: LEGO1 0x100b5900
|
||||
virtual MxS8 Compare(MxStreamChunk* p_a, MxStreamChunk* p_b) override
|
||||
{
|
||||
return p_a == p_b ? 0 : p_a < p_b ? -1 : 1;
|
||||
} // vtable+0x14
|
||||
|
||||
// FUNCTION: LEGO1 0x100b5920
|
||||
static void Destroy(MxStreamChunk* p_chunk) { delete p_chunk; }
|
||||
};
|
||||
|
||||
// VTABLE: LEGO1 0x100dc510
|
||||
class MxStreamChunkListCursor : public MxListCursor<MxStreamChunk*> {
|
||||
public:
|
||||
MxStreamChunkListCursor(MxStreamChunkList* p_list) : MxListCursor<MxStreamChunk*>(p_list){};
|
||||
};
|
||||
|
||||
// VTABLE: LEGO1 0x100dc528
|
||||
// class MxListCursor<MxStreamChunk *>
|
||||
|
||||
// TEMPLATE: LEGO1 0x100b5930
|
||||
// MxCollection<MxStreamChunk *>::Compare
|
||||
|
||||
// TEMPLATE: LEGO1 0x100b5990
|
||||
// MxCollection<MxStreamChunk *>::Destroy
|
||||
|
||||
// TEMPLATE: LEGO1 0x100b59a0
|
||||
// MxList<MxStreamChunk *>::~MxList<MxStreamChunk *>
|
||||
|
||||
// SYNTHETIC: LEGO1 0x100b5aa0
|
||||
// MxCollection<MxStreamChunk *>::`scalar deleting destructor'
|
||||
|
||||
// SYNTHETIC: LEGO1 0x100b5b10
|
||||
// MxList<MxStreamChunk *>::`scalar deleting destructor'
|
||||
|
||||
#endif // MXSTREAMCHUNKLIST_H
|
121
LEGO1/omni/include/mxstreamcontroller.h
Normal file
121
LEGO1/omni/include/mxstreamcontroller.h
Normal file
@@ -0,0 +1,121 @@
|
||||
#ifndef MXSTREAMCONTROLLER_H
|
||||
#define MXSTREAMCONTROLLER_H
|
||||
|
||||
#include "decomp.h"
|
||||
#include "mxatomid.h"
|
||||
#include "mxcore.h"
|
||||
#include "mxcriticalsection.h"
|
||||
#include "mxdsaction.h"
|
||||
#include "mxdsobject.h"
|
||||
#include "mxdssubscriber.h"
|
||||
#include "mxstl/stlcompat.h"
|
||||
#include "mxstreamlist.h"
|
||||
#include "mxstreamprovider.h"
|
||||
|
||||
class MxDSStreamingAction;
|
||||
|
||||
// VTABLE: LEGO1 0x100dc968
|
||||
// SIZE 0x64
|
||||
class MxStreamController : public MxCore {
|
||||
public:
|
||||
MxStreamController();
|
||||
virtual ~MxStreamController() override; // vtable+0x0
|
||||
|
||||
// FUNCTION: LEGO1 0x100c0f10
|
||||
inline virtual const char* ClassName() const override // vtable+0xc
|
||||
{
|
||||
// STRING: LEGO1 0x10102130
|
||||
return "MxStreamController";
|
||||
}
|
||||
|
||||
// FUNCTION: LEGO1 0x100c0f20
|
||||
inline virtual MxBool IsA(const char* p_name) const override // vtable+0x10
|
||||
{
|
||||
return !strcmp(p_name, MxStreamController::ClassName()) || MxCore::IsA(p_name);
|
||||
}
|
||||
|
||||
virtual MxResult Open(const char* p_filename); // vtable+0x14
|
||||
virtual MxResult VTable0x18(undefined4, undefined4); // vtable+0x18
|
||||
virtual MxResult VTable0x1c(undefined4, undefined4); // vtable+0x1c
|
||||
virtual MxResult VTable0x20(MxDSAction* p_action); // vtable+0x20
|
||||
virtual MxResult VTable0x24(MxDSAction* p_action); // vtable+0x24
|
||||
virtual MxDSStreamingAction* VTable0x28(); // vtable+0x28
|
||||
virtual MxResult VTable0x2c(MxDSAction* p_action, MxU32 p_bufferval); // vtable+0x2c
|
||||
virtual MxResult VTable0x30(MxDSAction* p_action); // vtable+0x30
|
||||
|
||||
void AddSubscriber(MxDSSubscriber* p_subscriber);
|
||||
void RemoveSubscriber(MxDSSubscriber* p_subscriber);
|
||||
MxResult FUN_100c1800(MxDSAction* p_action, MxU32 p_val);
|
||||
MxResult FUN_100c1a00(MxDSAction* p_action, MxU32 p_offset);
|
||||
MxPresenter* FUN_100c1e70(MxDSAction& p_action);
|
||||
MxResult FUN_100c1f00(MxDSAction* p_action);
|
||||
MxBool FUN_100c20d0(MxDSObject& p_obj);
|
||||
MxResult InsertActionToList54(MxDSAction* p_action);
|
||||
MxNextActionDataStart* FindNextActionDataStartFromStreamingAction(MxDSStreamingAction* p_action);
|
||||
|
||||
inline MxAtomId& GetAtom() { return m_atom; };
|
||||
inline MxStreamProvider* GetProvider() { return m_provider; };
|
||||
inline MxStreamListMxDSAction& GetUnk0x3c() { return m_unk0x3c; };
|
||||
inline MxStreamListMxDSAction& GetUnk0x54() { return m_unk0x54; };
|
||||
inline MxStreamListMxDSSubscriber& GetSubscriberList() { return m_subscriberList; };
|
||||
|
||||
protected:
|
||||
MxCriticalSection m_criticalSection; // 0x8
|
||||
MxAtomId m_atom; // 0x24
|
||||
MxStreamProvider* m_provider; // 0x28
|
||||
undefined4* m_unk0x2c; // 0x2c
|
||||
MxStreamListMxDSSubscriber m_subscriberList; // 0x30
|
||||
MxStreamListMxDSAction m_unk0x3c; // 0x3c
|
||||
MxStreamListMxNextActionDataStart m_nextActionList; // 0x48
|
||||
MxStreamListMxDSAction m_unk0x54; // 0x54
|
||||
MxDSAction* m_action0x60; // 0x60
|
||||
};
|
||||
|
||||
// TEMPLATE: LEGO1 0x100c0d60
|
||||
// list<MxDSAction *,allocator<MxDSAction *> >::~list<MxDSAction *,allocator<MxDSAction *> >
|
||||
|
||||
// TEMPLATE: LEGO1 0x100c0dd0
|
||||
// list<MxDSSubscriber *,allocator<MxDSSubscriber *> >::~list<MxDSSubscriber *,allocator<MxDSSubscriber *> >
|
||||
|
||||
// TEMPLATE: LEGO1 0x100c0e40
|
||||
// list<MxDSSubscriber *,allocator<MxDSSubscriber *> >::_Buynode
|
||||
|
||||
// clang-format off
|
||||
// TEMPLATE: LEGO1 0x100c0e70
|
||||
// list<MxNextActionDataStart *,allocator<MxNextActionDataStart *> >::~list<MxNextActionDataStart *,allocator<MxNextActionDataStart *> >
|
||||
// clang-format on
|
||||
|
||||
// TEMPLATE: LEGO1 0x100c0ee0
|
||||
// list<MxNextActionDataStart *,allocator<MxNextActionDataStart *> >::_Buynode
|
||||
|
||||
// SYNTHETIC: LEGO1 0x100c0fa0
|
||||
// MxStreamController::`scalar deleting destructor'
|
||||
|
||||
// FUNCTION: LEGO1 0x100c0fc0
|
||||
// MxStreamListMxDSSubscriber::~MxStreamListMxDSSubscriber
|
||||
|
||||
// FUNCTION: LEGO1 0x100c1010
|
||||
// MxStreamListMxDSAction::~MxStreamListMxDSAction
|
||||
|
||||
// FUNCTION: LEGO1 0x100c1060
|
||||
// MxStreamListMxNextActionDataStart::~MxStreamListMxNextActionDataStart
|
||||
|
||||
// TEMPLATE: LEGO1 0x100c10b0
|
||||
// MxStreamList<MxDSSubscriber *>::~MxStreamList<MxDSSubscriber *>
|
||||
|
||||
// TEMPLATE: LEGO1 0x100c1100
|
||||
// MxStreamList<MxDSAction *>::~MxStreamList<MxDSAction *>
|
||||
|
||||
// TEMPLATE: LEGO1 0x100c1150
|
||||
// MxStreamList<MxNextActionDataStart *>::~MxStreamList<MxNextActionDataStart *>
|
||||
|
||||
// TEMPLATE: LEGO1 0x100c11a0
|
||||
// List<MxDSSubscriber *>::~List<MxDSSubscriber *>
|
||||
|
||||
// TEMPLATE: LEGO1 0x100c11f0
|
||||
// List<MxDSAction *>::~List<MxDSAction *>
|
||||
|
||||
// TEMPLATE: LEGO1 0x100c1240
|
||||
// List<MxNextActionDataStart *>::~List<MxNextActionDataStart *>
|
||||
|
||||
#endif // MXSTREAMCONTROLLER_H
|
119
LEGO1/omni/include/mxstreamer.h
Normal file
119
LEGO1/omni/include/mxstreamer.h
Normal file
@@ -0,0 +1,119 @@
|
||||
#ifndef MXSTREAMER_H
|
||||
#define MXSTREAMER_H
|
||||
|
||||
#include "decomp.h"
|
||||
#include "mxcore.h"
|
||||
#include "mxdsobject.h"
|
||||
#include "mxnotificationparam.h"
|
||||
#include "mxstreamcontroller.h"
|
||||
#include "mxtypes.h"
|
||||
|
||||
#include <list>
|
||||
|
||||
// NOTE: This feels like some kind of templated class, maybe something from the
|
||||
// STL. But I haven't figured out what yet (it's definitely not a vector).
|
||||
class MxStreamerSubClass1 {
|
||||
public:
|
||||
inline MxStreamerSubClass1(undefined4 p_size)
|
||||
{
|
||||
m_buffer = NULL;
|
||||
m_size = p_size;
|
||||
undefined4* ptr = &m_unk0x08;
|
||||
for (int i = 0; i >= 0; i--) {
|
||||
ptr[i] = 0;
|
||||
}
|
||||
}
|
||||
|
||||
~MxStreamerSubClass1() { delete[] m_buffer; }
|
||||
|
||||
undefined4 GetSize() const { return m_size; }
|
||||
|
||||
void SetBuffer(undefined* p_buf) { m_buffer = p_buf; }
|
||||
inline undefined* GetBuffer() const { return m_buffer; }
|
||||
inline undefined* GetUnk08Ref() const { return (undefined*) &m_unk0x08; }
|
||||
|
||||
private:
|
||||
undefined* m_buffer;
|
||||
undefined4 m_size;
|
||||
undefined4 m_unk0x08;
|
||||
};
|
||||
|
||||
class MxStreamerSubClass2 : public MxStreamerSubClass1 {
|
||||
public:
|
||||
inline MxStreamerSubClass2() : MxStreamerSubClass1(0x40) {}
|
||||
};
|
||||
|
||||
class MxStreamerSubClass3 : public MxStreamerSubClass1 {
|
||||
public:
|
||||
inline MxStreamerSubClass3() : MxStreamerSubClass1(0x80) {}
|
||||
};
|
||||
|
||||
class MxStreamerNotification : public MxNotificationParam {
|
||||
public:
|
||||
inline MxStreamerNotification(NotificationId p_type, MxCore* p_sender, MxStreamController* p_ctrlr)
|
||||
: MxNotificationParam(p_type, p_sender)
|
||||
{
|
||||
m_controller = p_ctrlr;
|
||||
}
|
||||
|
||||
virtual ~MxStreamerNotification() override {}
|
||||
|
||||
virtual MxNotificationParam* Clone() override;
|
||||
|
||||
MxStreamController* GetController() { return m_controller; }
|
||||
|
||||
private:
|
||||
MxStreamController* m_controller;
|
||||
};
|
||||
|
||||
// VTABLE: LEGO1 0x100dc710
|
||||
// SIZE 0x2c
|
||||
class MxStreamer : public MxCore {
|
||||
public:
|
||||
enum OpenMode {
|
||||
e_DiskStream,
|
||||
e_RAMStream
|
||||
};
|
||||
|
||||
MxStreamer();
|
||||
virtual ~MxStreamer() override; // vtable+0x0
|
||||
|
||||
__declspec(dllexport) MxStreamController* Open(const char* p_name, MxU16 p_openMode);
|
||||
__declspec(dllexport) MxLong Close(const char* p_name);
|
||||
|
||||
virtual MxLong Notify(MxParam& p_param) override; // vtable+0x4
|
||||
|
||||
// FUNCTION: LEGO1 0x100b9000
|
||||
inline virtual const char* ClassName() const override // vtable+0x0c
|
||||
{
|
||||
// STRING: LEGO1 0x1010210c
|
||||
return "MxStreamer";
|
||||
}
|
||||
|
||||
// FUNCTION: LEGO1 0x100b9010
|
||||
inline virtual MxBool IsA(const char* p_name) const override // vtable+0x10
|
||||
{
|
||||
return !strcmp(p_name, MxStreamer::ClassName()) || MxCore::IsA(p_name);
|
||||
}
|
||||
|
||||
virtual MxResult Create(); // vtable+0x14
|
||||
|
||||
MxBool FUN_100b9b30(MxDSObject& p_dsObject);
|
||||
MxStreamController* GetOpenStream(const char* p_name);
|
||||
MxResult AddStreamControllerToOpenList(MxStreamController* p_stream);
|
||||
MxResult FUN_100b99b0(MxDSAction* p_action);
|
||||
MxResult DeleteObject(MxDSAction* p_dsAction);
|
||||
|
||||
inline const MxStreamerSubClass2& GetSubclass1() { return m_subclass1; }
|
||||
inline const MxStreamerSubClass3& GetSubclass2() { return m_subclass2; }
|
||||
|
||||
private:
|
||||
list<MxStreamController*> m_openStreams; // 0x8
|
||||
MxStreamerSubClass2 m_subclass1; // 0x14
|
||||
MxStreamerSubClass3 m_subclass2; // 0x20
|
||||
};
|
||||
|
||||
// SYNTHETIC: LEGO1 0x100b9120
|
||||
// MxStreamer::`scalar deleting destructor'
|
||||
|
||||
#endif // MXSTREAMER_H
|
54
LEGO1/omni/include/mxstreamlist.h
Normal file
54
LEGO1/omni/include/mxstreamlist.h
Normal file
@@ -0,0 +1,54 @@
|
||||
#ifndef MXSTREAMLIST_H
|
||||
#define MXSTREAMLIST_H
|
||||
|
||||
#include "mxdsstreamingaction.h"
|
||||
#include "mxdssubscriber.h"
|
||||
#include "mxnextactiondatastart.h"
|
||||
#include "mxstl/stlcompat.h"
|
||||
|
||||
template <class T>
|
||||
class MxStreamList : public list<T> {
|
||||
public:
|
||||
MxBool PopFront(T& p_obj)
|
||||
{
|
||||
if (this->empty())
|
||||
return FALSE;
|
||||
|
||||
p_obj = this->front();
|
||||
this->pop_front();
|
||||
return TRUE;
|
||||
}
|
||||
};
|
||||
|
||||
// SIZE 0xc
|
||||
class MxStreamListMxDSAction : public MxStreamList<MxDSAction*> {
|
||||
public:
|
||||
MxDSAction* Find(MxDSAction* p_action, MxBool p_delete);
|
||||
|
||||
// There chance this list actually holds MxDSStreamingListAction
|
||||
// instead of MxDSAction. Until then, we use this helper.
|
||||
MxBool PopFrontStreamingAction(MxDSStreamingAction*& p_obj)
|
||||
{
|
||||
if (empty())
|
||||
return FALSE;
|
||||
|
||||
p_obj = (MxDSStreamingAction*) front();
|
||||
pop_front();
|
||||
return TRUE;
|
||||
}
|
||||
};
|
||||
|
||||
// SIZE 0xc
|
||||
class MxStreamListMxNextActionDataStart : public MxStreamList<MxNextActionDataStart*> {
|
||||
public:
|
||||
MxNextActionDataStart* Find(MxU32 p_id, MxS16 p_value);
|
||||
MxNextActionDataStart* FindAndErase(MxU32 p_id, MxS16 p_value);
|
||||
};
|
||||
|
||||
// SIZE 0xc
|
||||
class MxStreamListMxDSSubscriber : public MxStreamList<MxDSSubscriber*> {
|
||||
public:
|
||||
MxDSSubscriber* Find(MxDSObject* p_object);
|
||||
};
|
||||
|
||||
#endif // MXSTREAMLIST_H
|
44
LEGO1/omni/include/mxstreamprovider.h
Normal file
44
LEGO1/omni/include/mxstreamprovider.h
Normal file
@@ -0,0 +1,44 @@
|
||||
#ifndef MXSTREAMPROVIDER_H
|
||||
#define MXSTREAMPROVIDER_H
|
||||
|
||||
#include "decomp.h"
|
||||
#include "mxcore.h"
|
||||
#include "mxdsfile.h"
|
||||
|
||||
class MxStreamController;
|
||||
class MxDSAction;
|
||||
|
||||
// VTABLE: LEGO1 0x100dd100
|
||||
// SIZE 0x10
|
||||
class MxStreamProvider : public MxCore {
|
||||
public:
|
||||
inline MxStreamProvider() : m_pLookup(NULL), m_pFile(NULL) {}
|
||||
|
||||
// FUNCTION: LEGO1 0x100d07e0
|
||||
inline virtual const char* ClassName() const override // vtable+0x0c
|
||||
{
|
||||
return "MxStreamProvider";
|
||||
}
|
||||
|
||||
// FUNCTION: LEGO1 0x100d07f0
|
||||
inline virtual MxBool IsA(const char* p_name) const override // vtable+0x10
|
||||
{
|
||||
return !strcmp(p_name, MxStreamProvider::ClassName()) || MxCore::IsA(p_name);
|
||||
}
|
||||
|
||||
virtual MxResult SetResourceToGet(MxStreamController* p_resource); // vtable+0x14
|
||||
virtual MxU32 GetFileSize() = 0; // vtable+0x18
|
||||
virtual MxS32 GetStreamBuffersNum() = 0; // vtable+0x1c
|
||||
virtual void VTable0x20(MxDSAction* p_action); // vtable+0x20
|
||||
virtual MxU32 GetLengthInDWords() = 0; // vtable+0x24
|
||||
virtual MxU32* GetBufferForDWords() = 0; // vtable+0x28
|
||||
|
||||
protected:
|
||||
MxStreamController* m_pLookup; // 0x08
|
||||
MxDSFile* m_pFile; // 0x0c
|
||||
};
|
||||
|
||||
// SYNTHETIC: LEGO1 0x100d0870
|
||||
// MxStreamProvider::`scalar deleting destructor'
|
||||
|
||||
#endif // MXSTREAMPROVIDER_H
|
30
LEGO1/omni/include/mxstring.h
Normal file
30
LEGO1/omni/include/mxstring.h
Normal file
@@ -0,0 +1,30 @@
|
||||
#ifndef MXSTRING_H
|
||||
#define MXSTRING_H
|
||||
|
||||
#include "mxcore.h"
|
||||
|
||||
// VTABLE: LEGO1 0x100dc110
|
||||
// SIZE 0x10
|
||||
class MxString : public MxCore {
|
||||
public:
|
||||
__declspec(dllexport) MxString(const MxString& p_str);
|
||||
__declspec(dllexport) virtual ~MxString();
|
||||
__declspec(dllexport) const MxString& operator=(const char* p_data);
|
||||
|
||||
MxString();
|
||||
MxString(const char*);
|
||||
void ToUpperCase();
|
||||
void ToLowerCase();
|
||||
MxString& operator=(const MxString& p_str);
|
||||
MxString operator+(const char* p_str);
|
||||
MxString& operator+=(const char* p_str);
|
||||
|
||||
inline MxS8 Compare(const MxString& p_str) const { return strcmp(m_data, p_str.m_data); }
|
||||
inline const char* GetData() const { return m_data; }
|
||||
|
||||
private:
|
||||
char* m_data; // 0x08
|
||||
MxU16 m_length; // 0x0c
|
||||
};
|
||||
|
||||
#endif // MXSTRING_H
|
41
LEGO1/omni/include/mxstringlist.h
Normal file
41
LEGO1/omni/include/mxstringlist.h
Normal file
@@ -0,0 +1,41 @@
|
||||
#ifndef MXSTRINGLIST_H
|
||||
#define MXSTRINGLIST_H
|
||||
|
||||
#include "mxlist.h"
|
||||
#include "mxstring.h"
|
||||
|
||||
// VTABLE: LEGO1 0x100dd040
|
||||
// SIZE 0x18
|
||||
class MxStringList : public MxList<MxString> {};
|
||||
|
||||
// VTABLE: LEGO1 0x100dd058
|
||||
class MxStringListCursor : public MxListCursor<MxString> {
|
||||
public:
|
||||
MxStringListCursor(MxStringList* p_list) : MxListCursor<MxString>(p_list){};
|
||||
};
|
||||
|
||||
// VTABLE: LEGO1 0x100dd070
|
||||
// class MxListCursor<MxString>
|
||||
|
||||
// TEMPLATE: LEGO1 0x100cb3c0
|
||||
// MxCollection<MxString>::Compare
|
||||
|
||||
// TEMPLATE: LEGO1 0x100cb470
|
||||
// MxCollection<MxString>::Destroy
|
||||
|
||||
// TEMPLATE: LEGO1 0x100cb4c0
|
||||
// MxList<MxString>::~MxList<MxString>
|
||||
|
||||
// TEMPLATE: LEGO1 0x100cbb40
|
||||
// MxList<MxString>::Append
|
||||
|
||||
// TEMPLATE: LEGO1 0x100cc2d0
|
||||
// MxList<MxString>::InsertEntry
|
||||
|
||||
// TEMPLATE: LEGO1 0x100cc3c0
|
||||
// MxListEntry<MxString>::MxListEntry<MxString>
|
||||
|
||||
// TEMPLATE: LEGO1 0x100cc450
|
||||
// MxListEntry<MxString>::GetValue
|
||||
|
||||
#endif // MXSTRINGLIST_H
|
55
LEGO1/omni/include/mxthread.h
Normal file
55
LEGO1/omni/include/mxthread.h
Normal file
@@ -0,0 +1,55 @@
|
||||
#ifndef MXTHREAD_H
|
||||
#define MXTHREAD_H
|
||||
|
||||
#include "compat.h"
|
||||
#include "mxsemaphore.h"
|
||||
#include "mxtypes.h"
|
||||
|
||||
class MxCore;
|
||||
|
||||
// VTABLE: LEGO1 0x100dc860
|
||||
// SIZE 0x1c
|
||||
class MxThread {
|
||||
public:
|
||||
// Note: Comes before virtual destructor
|
||||
virtual MxResult Run();
|
||||
|
||||
MxResult Start(MxS32 p_stack, MxS32 p_flag);
|
||||
|
||||
void Terminate();
|
||||
void Sleep(MxS32 p_milliseconds);
|
||||
|
||||
inline MxBool IsRunning() { return m_running; }
|
||||
|
||||
protected:
|
||||
MxThread();
|
||||
|
||||
public:
|
||||
virtual ~MxThread();
|
||||
|
||||
private:
|
||||
static unsigned ThreadProc(void* p_thread);
|
||||
|
||||
MxULong m_hThread; // 0x04
|
||||
MxU32 m_threadId; // 0x08
|
||||
MxBool m_running; // 0x0c
|
||||
MxSemaphore m_semaphore; // 0x10
|
||||
|
||||
protected:
|
||||
MxCore* m_target; // 0x18
|
||||
};
|
||||
|
||||
// VTABLE: LEGO1 0x100dc6d8
|
||||
// SIZE 0x20
|
||||
class MxTickleThread : public MxThread {
|
||||
public:
|
||||
MxTickleThread(MxCore* p_target, MxS32 p_frequencyMS);
|
||||
virtual ~MxTickleThread() {}
|
||||
|
||||
MxResult Run() override;
|
||||
|
||||
private:
|
||||
MxS32 m_frequencyMS; // 0x1c
|
||||
};
|
||||
|
||||
#endif // MXTHREAD_H
|
53
LEGO1/omni/include/mxticklemanager.h
Normal file
53
LEGO1/omni/include/mxticklemanager.h
Normal file
@@ -0,0 +1,53 @@
|
||||
#ifndef MXTICKLEMANAGER_H
|
||||
#define MXTICKLEMANAGER_H
|
||||
|
||||
#include "mxcore.h"
|
||||
#include "mxstl/stlcompat.h"
|
||||
#include "mxtypes.h"
|
||||
|
||||
class MxTickleClient {
|
||||
public:
|
||||
MxTickleClient(MxCore* p_client, MxTime p_interval);
|
||||
|
||||
inline MxCore* GetClient() const { return m_client; }
|
||||
|
||||
inline MxTime GetTickleInterval() const { return m_interval; }
|
||||
|
||||
inline MxTime GetLastUpdateTime() const { return m_lastUpdateTime; }
|
||||
|
||||
inline MxU16 GetFlags() const { return m_flags; }
|
||||
|
||||
inline void SetTickleInterval(MxTime p_interval) { m_interval = p_interval; }
|
||||
|
||||
inline void SetLastUpdateTime(MxTime p_lastUpdateTime) { m_lastUpdateTime = p_lastUpdateTime; }
|
||||
|
||||
inline void SetFlags(MxU16 p_flags) { m_flags = p_flags; }
|
||||
|
||||
private:
|
||||
MxCore* m_client; // 0x0
|
||||
MxTime m_interval; // 0x4
|
||||
MxTime m_lastUpdateTime; // 0x8
|
||||
MxU16 m_flags; // 0xc
|
||||
};
|
||||
|
||||
typedef list<MxTickleClient*> MxTickleClientPtrList;
|
||||
|
||||
// VTABLE: LEGO1 0x100d86d8
|
||||
class MxTickleManager : public MxCore {
|
||||
public:
|
||||
inline MxTickleManager() {}
|
||||
virtual ~MxTickleManager(); // vtable+0x0 (scalar deleting destructor)
|
||||
|
||||
virtual MxResult Tickle(); // vtable+0x8
|
||||
virtual void RegisterClient(MxCore* p_client, MxTime p_interval); // vtable+0x14
|
||||
virtual void UnregisterClient(MxCore* p_client); // vtable+0x18
|
||||
virtual void SetClientTickleInterval(MxCore* p_client, MxTime p_interval); // vtable+0x1c
|
||||
virtual MxTime GetClientTickleInterval(MxCore* p_client); // vtable+0x20
|
||||
|
||||
private:
|
||||
MxTickleClientPtrList m_clients; // 0x8
|
||||
};
|
||||
|
||||
#define TICKLE_MANAGER_NOT_FOUND 0x80000000
|
||||
|
||||
#endif // MXTICKLEMANAGER_H
|
32
LEGO1/omni/include/mxtimer.h
Normal file
32
LEGO1/omni/include/mxtimer.h
Normal file
@@ -0,0 +1,32 @@
|
||||
#ifndef MXTIMER_H
|
||||
#define MXTIMER_H
|
||||
|
||||
#include "mxcore.h"
|
||||
|
||||
// VTABLE: LEGO1 0x100dc0e0
|
||||
// SIZE 0x10
|
||||
class MxTimer : public MxCore {
|
||||
public:
|
||||
MxTimer();
|
||||
|
||||
void Start();
|
||||
void Stop();
|
||||
|
||||
__declspec(dllexport) MxLong GetRealTime();
|
||||
|
||||
inline MxLong GetTime()
|
||||
{
|
||||
if (this->m_isRunning)
|
||||
return g_lastTimeTimerStarted;
|
||||
else
|
||||
return g_lastTimeCalculated - this->m_startTime;
|
||||
}
|
||||
|
||||
private:
|
||||
MxLong m_startTime;
|
||||
MxBool m_isRunning;
|
||||
static MxLong g_lastTimeCalculated;
|
||||
static MxLong g_lastTimeTimerStarted;
|
||||
};
|
||||
|
||||
#endif // MXTIMER_H
|
75
LEGO1/omni/include/mxtransitionmanager.h
Normal file
75
LEGO1/omni/include/mxtransitionmanager.h
Normal file
@@ -0,0 +1,75 @@
|
||||
#ifndef MXTRANSITIONMANAGER_H
|
||||
#define MXTRANSITIONMANAGER_H
|
||||
|
||||
#include "legoomni.h"
|
||||
#include "mxcore.h"
|
||||
#include "mxvideopresenter.h"
|
||||
|
||||
#include <ddraw.h>
|
||||
|
||||
// VTABLE: LEGO1 0x100d7ea0
|
||||
class MxTransitionManager : public MxCore {
|
||||
public:
|
||||
MxTransitionManager();
|
||||
virtual ~MxTransitionManager() override; // vtable+0x0
|
||||
|
||||
__declspec(dllexport) void SetWaitIndicator(MxVideoPresenter* p_waitIndicator);
|
||||
|
||||
virtual MxResult Tickle(); // vtable+0x8
|
||||
|
||||
// FUNCTION: LEGO1 0x1004b950
|
||||
inline virtual const char* ClassName() const override // vtable+0x0c
|
||||
{
|
||||
return "MxTransitionManager";
|
||||
}
|
||||
|
||||
// FUNCTION: LEGO1 0x1004b960
|
||||
inline virtual MxBool IsA(const char* p_name) const override // vtable+0x10
|
||||
{
|
||||
return !strcmp(p_name, MxTransitionManager::ClassName()) || MxCore::IsA(p_name);
|
||||
}
|
||||
|
||||
virtual MxResult GetDDrawSurfaceFromVideoManager(); // vtable+0x14
|
||||
|
||||
enum TransitionType {
|
||||
NOT_TRANSITIONING,
|
||||
NO_ANIMATION,
|
||||
DISSOLVE,
|
||||
PIXELATION,
|
||||
SCREEN_WIPE,
|
||||
WINDOWS,
|
||||
BROKEN // Unknown what this is supposed to be, it locks the game up
|
||||
};
|
||||
|
||||
MxResult StartTransition(TransitionType p_animationType, MxS32 p_speed, MxBool p_doCopy, MxBool p_playMusicInAnim);
|
||||
|
||||
inline TransitionType GetTransitionType() { return m_transitionType; }
|
||||
|
||||
private:
|
||||
void EndTransition(MxBool p_notifyWorld);
|
||||
void TransitionNone();
|
||||
void TransitionDissolve();
|
||||
void TransitionPixelation();
|
||||
void TransitionWipe();
|
||||
void TransitionWindows();
|
||||
void TransitionBroken();
|
||||
|
||||
void SubmitCopyRect(LPDDSURFACEDESC p_ddsc);
|
||||
void SetupCopyRect(LPDDSURFACEDESC p_ddsc);
|
||||
|
||||
MxVideoPresenter* m_waitIndicator; // 0x08
|
||||
RECT m_copyRect; // 0x0c
|
||||
MxU8* m_copyBuffer; // 0x1c
|
||||
FlagBitfield m_copyFlags; // 0x20
|
||||
undefined4 m_unk0x24; // 0x24
|
||||
FlagBitfield m_unk0x28; // 0x28
|
||||
TransitionType m_transitionType; // 0x2c
|
||||
LPDIRECTDRAWSURFACE m_ddSurface; // 0x30
|
||||
MxU16 m_animationTimer; // 0x34
|
||||
MxU16 m_columnOrder[640]; // 0x36
|
||||
MxU16 m_randomShift[480]; // 0x536
|
||||
MxULong m_systemTime; // 0x8f8
|
||||
MxS32 m_animationSpeed; // 0x8fc
|
||||
};
|
||||
|
||||
#endif // MXTRANSITIONMANAGER_H
|
20
LEGO1/omni/include/mxtype17notificationparam.h
Normal file
20
LEGO1/omni/include/mxtype17notificationparam.h
Normal file
@@ -0,0 +1,20 @@
|
||||
#ifndef MXTYPE17NOTIFICATIONPARAM_H
|
||||
#define MXTYPE17NOTIFICATIONPARAM_H
|
||||
|
||||
#include "decomp.h"
|
||||
#include "mxnotificationparam.h"
|
||||
|
||||
// ??? This type is handled, but seemingly never created and no VTABLE fits
|
||||
class MxType17NotificationParam : public MxNotificationParam {
|
||||
public:
|
||||
inline MxU32 GetUnknown20() { return m_unk0x20; }
|
||||
inline MxU16 GetUnknown28() { return m_unk0x28; }
|
||||
|
||||
protected:
|
||||
undefined m_unk0xc[0x14];
|
||||
MxU32 m_unk0x20;
|
||||
undefined4 m_unk0x24;
|
||||
MxU16 m_unk0x28;
|
||||
};
|
||||
|
||||
#endif // MXTYPE17NOTIFICATIONPARAM_H
|
14
LEGO1/omni/include/mxtype18notificationparam.h
Normal file
14
LEGO1/omni/include/mxtype18notificationparam.h
Normal file
@@ -0,0 +1,14 @@
|
||||
#ifndef MXTYPE18NOTIFICATIONPARAM_H
|
||||
#define MXTYPE18NOTIFICATIONPARAM_H
|
||||
|
||||
#include "decomp.h"
|
||||
#include "mxnotificationparam.h"
|
||||
|
||||
// VTABLE: LEGO1 0x100d7e80
|
||||
// SIZE 0x10
|
||||
class MxType18NotificationParam : public MxNotificationParam {
|
||||
protected:
|
||||
undefined4 m_unk0xc; // 0xc
|
||||
};
|
||||
|
||||
#endif // MXTYPE18NOTIFICATIONPARAM_H
|
15
LEGO1/omni/include/mxtype19notificationparam.h
Normal file
15
LEGO1/omni/include/mxtype19notificationparam.h
Normal file
@@ -0,0 +1,15 @@
|
||||
#ifndef MXTYPE19NOTIFICATIONPARAM_H
|
||||
#define MXTYPE19NOTIFICATIONPARAM_H
|
||||
|
||||
#include "decomp.h"
|
||||
#include "mxnotificationparam.h"
|
||||
|
||||
// VTABLE: LEGO1 0x100d6230
|
||||
// SIZE 0x10
|
||||
class MxType19NotificationParam : public MxNotificationParam {
|
||||
protected:
|
||||
MxU16 m_unk0xc; // 0xc
|
||||
MxU8 m_unk0xe; // 0xe
|
||||
};
|
||||
|
||||
#endif // MXTYPE19NOTIFICATIONPARAM_H
|
73
LEGO1/omni/include/mxtypes.h
Normal file
73
LEGO1/omni/include/mxtypes.h
Normal file
@@ -0,0 +1,73 @@
|
||||
#ifndef MXTYPES_H
|
||||
#define MXTYPES_H
|
||||
|
||||
typedef unsigned char MxU8;
|
||||
typedef signed char MxS8;
|
||||
typedef unsigned short MxU16;
|
||||
typedef signed short MxS16;
|
||||
typedef unsigned int MxU32;
|
||||
typedef signed int MxS32;
|
||||
#ifdef _MSC_VER
|
||||
typedef unsigned __int64 MxU64;
|
||||
typedef signed __int64 MxS64;
|
||||
#else
|
||||
typedef unsigned long long int MxU64;
|
||||
typedef signed long long int MxS64;
|
||||
#endif
|
||||
typedef float MxFloat;
|
||||
typedef double MxDouble;
|
||||
|
||||
// On MSVC, a long is 32-bit, but on GCC/Clang, it's 64-bit. LEGO Island obviously
|
||||
// assumes the former in all cases, which could become an issue in the future.
|
||||
// The "longs" can't all be changed to "ints" (which are 32-bit on both) because
|
||||
// this will break DLL export compatibility. Therefore, we define MxLong/MxULong,
|
||||
// which is guaranteed to be 32-bit, and guaranteed to be a "long" on MSVC.
|
||||
#if defined(_MSC_VER)
|
||||
typedef long MxLong;
|
||||
typedef unsigned long MxULong;
|
||||
#else
|
||||
typedef int MxLong;
|
||||
typedef unsigned int MxULong;
|
||||
#endif
|
||||
|
||||
typedef MxS32 MxTime;
|
||||
|
||||
typedef MxLong MxResult;
|
||||
|
||||
#ifndef SUCCESS
|
||||
#define SUCCESS 0
|
||||
#endif
|
||||
|
||||
#ifndef FAILURE
|
||||
#define FAILURE -1
|
||||
#endif
|
||||
|
||||
typedef MxU8 MxBool;
|
||||
|
||||
#ifndef TRUE
|
||||
#define TRUE 1
|
||||
#endif
|
||||
|
||||
#ifndef FALSE
|
||||
#define FALSE 0
|
||||
#endif
|
||||
|
||||
#define TWOCC(a, b) (((a) << 0) | ((b) << 8))
|
||||
#define FOURCC(a, b, c, d) (((a) << 0) | ((b) << 8) | ((c) << 16) | ((d) << 24))
|
||||
|
||||
// Must be union with struct for match.
|
||||
typedef union {
|
||||
struct {
|
||||
MxU8 m_bit0 : 1;
|
||||
MxU8 m_bit1 : 1;
|
||||
MxU8 m_bit2 : 1;
|
||||
MxU8 m_bit3 : 1;
|
||||
MxU8 m_bit4 : 1;
|
||||
MxU8 m_bit5 : 1;
|
||||
MxU8 m_bit6 : 1;
|
||||
MxU8 m_bit7 : 1;
|
||||
};
|
||||
// BYTE all; // ?
|
||||
} FlagBitfield;
|
||||
|
||||
#endif // MXTYPES_H
|
34
LEGO1/omni/include/mxvariable.h
Normal file
34
LEGO1/omni/include/mxvariable.h
Normal file
@@ -0,0 +1,34 @@
|
||||
#ifndef MXVARIABLE_H
|
||||
#define MXVARIABLE_H
|
||||
|
||||
#include "mxcore.h"
|
||||
#include "mxstring.h"
|
||||
|
||||
// VTABLE: LEGO1 0x100d7498
|
||||
// SIZE 0x24
|
||||
class MxVariable {
|
||||
public:
|
||||
MxVariable() {}
|
||||
MxVariable(const char* p_key)
|
||||
{
|
||||
m_key = p_key;
|
||||
m_key.ToUpperCase();
|
||||
}
|
||||
MxVariable(const char* p_key, const char* p_value)
|
||||
{
|
||||
m_key = p_key;
|
||||
m_key.ToUpperCase();
|
||||
m_value = p_value;
|
||||
}
|
||||
virtual MxString* GetValue();
|
||||
virtual void SetValue(const char* p_value);
|
||||
virtual void Destroy();
|
||||
|
||||
inline const MxString* GetKey() const { return &m_key; }
|
||||
|
||||
protected:
|
||||
MxString m_key;
|
||||
MxString m_value;
|
||||
};
|
||||
|
||||
#endif // MXVARIABLE_H
|
59
LEGO1/omni/include/mxvariabletable.h
Normal file
59
LEGO1/omni/include/mxvariabletable.h
Normal file
@@ -0,0 +1,59 @@
|
||||
#ifndef MXVARIABLETABLE_H
|
||||
#define MXVARIABLETABLE_H
|
||||
|
||||
#include "mxhashtable.h"
|
||||
#include "mxtypes.h"
|
||||
#include "mxvariable.h"
|
||||
|
||||
// VTABLE: LEGO1 0x100dc1c8
|
||||
// SIZE 0x28
|
||||
class MxVariableTable : public MxHashTable<MxVariable*> {
|
||||
public:
|
||||
MxVariableTable() { m_customDestructor = Destroy; }
|
||||
__declspec(dllexport) void SetVariable(const char* p_key, const char* p_value);
|
||||
__declspec(dllexport) void SetVariable(MxVariable* p_var);
|
||||
__declspec(dllexport) const char* GetVariable(const char* p_key);
|
||||
|
||||
static void Destroy(MxVariable* p_obj) { p_obj->Destroy(); }
|
||||
|
||||
virtual MxS8 Compare(MxVariable*, MxVariable*) override; // vtable+0x14
|
||||
virtual MxU32 Hash(MxVariable*) override; // vtable+0x18
|
||||
};
|
||||
|
||||
// VTABLE: LEGO1 0x100dc1b0
|
||||
// class MxCollection<MxVariable *>
|
||||
|
||||
// VTABLE: LEGO1 0x100dc1e8
|
||||
// class MxHashTable<MxVariable *>
|
||||
|
||||
// TEMPLATE: LEGO1 0x100afcd0
|
||||
// MxCollection<MxVariable *>::Compare
|
||||
|
||||
// TEMPLATE: LEGO1 0x100afce0
|
||||
// MxCollection<MxVariable *>::~MxCollection<MxVariable *>
|
||||
|
||||
// TEMPLATE: LEGO1 0x100afd30
|
||||
// MxCollection<MxVariable *>::Destroy
|
||||
|
||||
// SYNTHETIC: LEGO1 0x100afd40
|
||||
// MxCollection<MxVariable *>::`scalar deleting destructor'
|
||||
|
||||
// TEMPLATE: LEGO1 0x100afdb0
|
||||
// MxVariableTable::Destroy
|
||||
|
||||
// TEMPLATE: LEGO1 0x100afdc0
|
||||
// MxHashTable<MxVariable *>::Hash
|
||||
|
||||
// TEMPLATE: LEGO1 0x100b0bd0
|
||||
// MxHashTable<MxVariable *>::~MxHashTable<MxVariable *>
|
||||
|
||||
// SYNTHETIC: LEGO1 0x100b0ca0
|
||||
// MxHashTable<MxVariable *>::`scalar deleting destructor'
|
||||
|
||||
// TEMPLATE: LEGO1 0x100b7ab0
|
||||
// MxHashTable<MxVariable *>::Resize
|
||||
|
||||
// TEMPLATE: LEGO1 0x100b7b80
|
||||
// MxHashTable<MxVariable *>::NodeInsert
|
||||
|
||||
#endif // MXVARIABLETABLE_H
|
56
LEGO1/omni/include/mxvideomanager.h
Normal file
56
LEGO1/omni/include/mxvideomanager.h
Normal file
@@ -0,0 +1,56 @@
|
||||
#ifndef MXVIDEOMANAGER_H
|
||||
#define MXVIDEOMANAGER_H
|
||||
|
||||
#include "mxdisplaysurface.h"
|
||||
#include "mxmediamanager.h"
|
||||
#include "mxrect32.h"
|
||||
#include "mxregion.h"
|
||||
#include "mxvideoparam.h"
|
||||
|
||||
#include <d3d.h>
|
||||
|
||||
// VTABLE: LEGO1 0x100dc810
|
||||
// SIZE 0x64
|
||||
class MxVideoManager : public MxMediaManager {
|
||||
public:
|
||||
MxVideoManager();
|
||||
virtual ~MxVideoManager() override;
|
||||
|
||||
virtual MxResult Tickle() override; // vtable+0x8
|
||||
virtual void Destroy() override; // vtable+0x18
|
||||
virtual MxResult VTable0x28(
|
||||
MxVideoParam& p_videoParam,
|
||||
LPDIRECTDRAW p_pDirectDraw,
|
||||
LPDIRECT3D2 p_pDirect3D,
|
||||
LPDIRECTDRAWSURFACE p_ddSurface1,
|
||||
LPDIRECTDRAWSURFACE p_ddSurface2,
|
||||
LPDIRECTDRAWCLIPPER p_ddClipper,
|
||||
MxU32 p_frequencyMS,
|
||||
MxBool p_createThread
|
||||
); // vtable+0x28
|
||||
virtual MxResult Create(MxVideoParam& p_videoParam, MxU32 p_frequencyMS, MxBool p_createThread); // vtable+0x2c
|
||||
|
||||
__declspec(dllexport) void InvalidateRect(MxRect32&);
|
||||
__declspec(dllexport) virtual MxResult RealizePalette(MxPalette*); // vtable+0x30
|
||||
virtual void VTable0x34(MxU32 p_x, MxU32 p_y, MxU32 p_width, MxU32 p_height); // vtable+0x34
|
||||
|
||||
MxResult Init();
|
||||
void Destroy(MxBool p_fromDestructor);
|
||||
void SortPresenterList();
|
||||
void UpdateRegion();
|
||||
|
||||
inline MxVideoParam& GetVideoParam() { return this->m_videoParam; }
|
||||
inline LPDIRECTDRAW GetDirectDraw() { return this->m_pDirectDraw; }
|
||||
inline MxDisplaySurface* GetDisplaySurface() { return this->m_displaySurface; }
|
||||
inline MxRegion* GetRegion() { return this->m_region; }
|
||||
|
||||
protected:
|
||||
MxVideoParam m_videoParam; // 0x2c
|
||||
LPDIRECTDRAW m_pDirectDraw; // 0x50
|
||||
LPDIRECT3D2 m_pDirect3D; // 0x54
|
||||
MxDisplaySurface* m_displaySurface; // 0x58
|
||||
MxRegion* m_region; // 0x5c
|
||||
MxBool m_unk0x60; // 0x60
|
||||
};
|
||||
|
||||
#endif // MXVIDEOMANAGER_H
|
47
LEGO1/omni/include/mxvideoparam.h
Normal file
47
LEGO1/omni/include/mxvideoparam.h
Normal file
@@ -0,0 +1,47 @@
|
||||
#ifndef MXVIDEOPARAM_H
|
||||
#define MXVIDEOPARAM_H
|
||||
|
||||
#include "compat.h"
|
||||
#include "mxpalette.h"
|
||||
#include "mxrect32.h"
|
||||
#include "mxtypes.h"
|
||||
#include "mxvariabletable.h"
|
||||
#include "mxvideoparamflags.h"
|
||||
|
||||
#include <ddraw.h>
|
||||
|
||||
// SIZE 0x24
|
||||
class MxVideoParam {
|
||||
public:
|
||||
__declspec(dllexport) MxVideoParam();
|
||||
__declspec(dllexport) MxVideoParam(MxVideoParam& p_videoParam);
|
||||
__declspec(dllexport) MxVideoParam(
|
||||
COMPAT_CONST MxRect32& p_rect,
|
||||
MxPalette* p_palette,
|
||||
MxULong p_backBuffers,
|
||||
COMPAT_CONST MxVideoParamFlags& p_flags
|
||||
);
|
||||
__declspec(dllexport) MxVideoParam& operator=(const MxVideoParam& p_videoParam);
|
||||
__declspec(dllexport) ~MxVideoParam();
|
||||
__declspec(dllexport) void SetDeviceName(char* p_deviceId);
|
||||
|
||||
inline MxVideoParamFlags& Flags() { return m_flags; }
|
||||
|
||||
inline void SetPalette(MxPalette* p_palette) { this->m_palette = p_palette; }
|
||||
inline void SetBackBuffers(MxU32 p_backBuffers) { this->m_backBuffers = p_backBuffers; }
|
||||
|
||||
inline MxRect32& GetRect() { return this->m_rect; }
|
||||
inline MxPalette* GetPalette() { return this->m_palette; }
|
||||
inline MxU32 GetBackBuffers() { return this->m_backBuffers; }
|
||||
inline char* GetDeviceName() { return this->m_deviceId; }
|
||||
|
||||
private:
|
||||
MxRect32 m_rect; // 0x00
|
||||
MxPalette* m_palette; // 0x10
|
||||
MxU32 m_backBuffers; // 0x14
|
||||
MxVideoParamFlags m_flags; // 0x18
|
||||
int m_unk0x1c; // 0x1c
|
||||
char* m_deviceId; // 0x20
|
||||
};
|
||||
|
||||
#endif // MXVIDEOPARAM_H
|
Some files were not shown because too many files have changed in this diff Show More
Reference in New Issue
Block a user