Various annotations

This commit is contained in:
Christian Semmler 2023-12-25 13:23:48 -05:00
parent b8e77b14a0
commit a3b6934b5f
7 changed files with 23 additions and 14 deletions

View File

@ -13,8 +13,8 @@ class MxCriticalSection {
void Leave();
private:
CRITICAL_SECTION m_criticalSection;
HANDLE m_mutex;
CRITICAL_SECTION m_criticalSection; // 0x00
HANDLE m_mutex; // 0x18
};
#endif // MXCRITICALSECTION_H

View File

@ -9,6 +9,7 @@
#include "mxstring.h"
#include "mxthread.h"
DECOMP_SIZE_ASSERT(MxDiskStreamProviderThread, 0x1c)
DECOMP_SIZE_ASSERT(MxDiskStreamProvider, 0x60);
// GLOBAL: LEGO1 0x10102878

View File

@ -13,17 +13,17 @@ class MxDiskStreamProvider;
class MxDSStreamingAction;
// VTABLE: LEGO1 0x100dd130
// SIZE 0x1c
class MxDiskStreamProviderThread : public MxThread {
public:
// Only inlined, no offset
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();

View File

@ -1,6 +1,10 @@
#include "mxsemaphore.h"
#include "decomp.h"
DECOMP_SIZE_ASSERT(MxSemaphore, 0x08)
// FUNCTION: LEGO1 0x100c87d0
MxSemaphore::MxSemaphore()
{

View File

@ -5,6 +5,7 @@
#include <windows.h>
// SIZE 0x08
class MxSemaphore {
public:
MxSemaphore();
@ -18,7 +19,7 @@ class MxSemaphore {
void Release(MxU32 p_releaseCount);
private:
HANDLE m_hSemaphore;
HANDLE m_hSemaphore; // 0x04
};
#endif // MX_SEMAPHORE_H

View File

@ -1,11 +1,15 @@
#include "mxthread.h"
#include "decomp.h"
#include "mxomni.h"
#include "mxtimer.h"
#include <process.h>
DECOMP_SIZE_ASSERT(MxThread, 0x1c)
DECOMP_SIZE_ASSERT(MxTickleThread, 0x20)
// FUNCTION: LEGO1 0x100b8bb0
MxTickleThread::MxTickleThread(MxCore* p_target, MxS32 p_frequencyMS)
{

View File

@ -8,6 +8,7 @@
class MxCore;
// VTABLE: LEGO1 0x100dc860
// SIZE 0x1c
class MxThread {
public:
// Note: Comes before virtual destructor
@ -18,7 +19,6 @@ class MxThread {
void Terminate();
void Sleep(MxS32 p_milliseconds);
// Inferred, not in DLL
inline MxBool IsRunning() { return m_running; }
protected:
@ -30,27 +30,26 @@ class MxThread {
private:
static unsigned ThreadProc(void* p_thread);
MxULong m_hThread;
MxU32 m_threadId;
MxBool m_running;
MxSemaphore m_semaphore;
MxULong m_hThread; // 0x04
MxU32 m_threadId; // 0x08
MxBool m_running; // 0x0c
MxSemaphore m_semaphore; // 0x10
protected:
MxCore* m_target;
MxCore* m_target; // 0x18
};
// VTABLE: LEGO1 0x100dc6d8
// SIZE 0x20
class MxTickleThread : public MxThread {
public:
MxTickleThread(MxCore* p_target, MxS32 p_frequencyMS);
// Only inlined, no offset
virtual ~MxTickleThread() {}
MxResult Run() override;
private:
MxS32 m_frequencyMS;
MxS32 m_frequencyMS; // 0x1c
};
#endif // MXTHREAD_H