diff --git a/LEGO1/library_msvc.h b/LEGO1/library_msvc.h index acfce983..28e29187 100644 --- a/LEGO1/library_msvc.h +++ b/LEGO1/library_msvc.h @@ -40,6 +40,9 @@ // LIBRARY: LEGO1 0x1008b608 // __ftol +// LIBRARY: LEGO1 0x1008b630 +// _srand + // LIBRARY: LEGO1 0x1008b680 // _strncmp @@ -82,6 +85,9 @@ // LIBRARY: LEGO1 0x1008ca60 // _abort +// LIBRARY: LEGO1 0x100977c0 +// _itoa + // LIBRARY: LEGO1 0x10097b10 // _strchr diff --git a/LEGO1/omni/include/mxdiskstreamprovider.h b/LEGO1/omni/include/mxdiskstreamprovider.h index 6df049da..517fa463 100644 --- a/LEGO1/omni/include/mxdiskstreamprovider.h +++ b/LEGO1/omni/include/mxdiskstreamprovider.h @@ -20,9 +20,6 @@ class MxDiskStreamProviderThread : public MxThread { MxResult Run() override; MxResult StartWithTarget(MxDiskStreamProvider* p_target); - - // SYNTHETIC: LEGO1 0x100d10a0 - // MxDiskStreamProviderThread::`scalar deleting destructor' }; // VTABLE: LEGO1 0x100dd138 @@ -58,9 +55,6 @@ class MxDiskStreamProvider : public MxStreamProvider { virtual MxU32 GetLengthInDWords() override; // vtable+0x24 virtual MxU32* GetBufferForDWords() override; // vtable+0x28 - // SYNTHETIC: LEGO1 0x100d1220 - // MxDiskStreamProvider::`scalar deleting destructor' - private: MxDiskStreamProviderThread m_thread; // 0x10 MxSemaphore m_busySemaphore; // 0x2c @@ -70,4 +64,13 @@ class MxDiskStreamProvider : public MxStreamProvider { MxStreamListMxDSAction m_list; // 0x54 }; +// SYNTHETIC: LEGO1 0x100d10a0 +// MxDiskStreamProviderThread::`scalar deleting destructor' + +// SYNTHETIC: LEGO1 0x100d1110 +// MxDiskStreamProviderThread::~MxDiskStreamProviderThread + +// SYNTHETIC: LEGO1 0x100d1220 +// MxDiskStreamProvider::`scalar deleting destructor' + #endif // MXDISKSTREAMPROVIDER_H diff --git a/LEGO1/omni/include/mxdsaction.h b/LEGO1/omni/include/mxdsaction.h index b4d6192e..b51c75a2 100644 --- a/LEGO1/omni/include/mxdsaction.h +++ b/LEGO1/omni/include/mxdsaction.h @@ -43,6 +43,7 @@ class MxDSAction : public MxDSObject { return !strcmp(p_name, MxDSAction::ClassName()) || MxDSObject::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 MxLong GetDuration(); // vtable+24; diff --git a/LEGO1/omni/include/mxdsactionlist.h b/LEGO1/omni/include/mxdsactionlist.h index 60c3db6d..7ae9ab56 100644 --- a/LEGO1/omni/include/mxdsactionlist.h +++ b/LEGO1/omni/include/mxdsactionlist.h @@ -44,6 +44,9 @@ class MxDSActionListCursor : public MxListCursor { // TEMPLATE: LEGO1 0x100c9cc0 // MxCollection::Compare +// TEMPLATE: LEGO1 0x100c9cd0 +// MxCollection::~MxCollection + // TEMPLATE: LEGO1 0x100c9d20 // MxCollection::Destroy diff --git a/LEGO1/omni/include/mxstreamprovider.h b/LEGO1/omni/include/mxstreamprovider.h index 17bba38d..803038e3 100644 --- a/LEGO1/omni/include/mxstreamprovider.h +++ b/LEGO1/omni/include/mxstreamprovider.h @@ -41,4 +41,7 @@ class MxStreamProvider : public MxCore { // SYNTHETIC: LEGO1 0x100d0870 // MxStreamProvider::`scalar deleting destructor' +// SYNTHETIC: LEGO1 0x100d08e0 +// MxStreamProvider::~MxStreamProvider + #endif // MXSTREAMPROVIDER_H diff --git a/LEGO1/omni/src/action/mxdsaction.cpp b/LEGO1/omni/src/action/mxdsaction.cpp index b24ff347..66ffd5b5 100644 --- a/LEGO1/omni/src/action/mxdsaction.cpp +++ b/LEGO1/omni/src/action/mxdsaction.cpp @@ -99,6 +99,12 @@ MxU32 MxDSAction::GetSizeOnDisk() return totalSizeOnDisk; } +// FUNCTION: LEGO1 0x100adbd0 +undefined4 MxDSAction::VTable0x14() +{ + return MxDSObject::VTable0x14(); +} + // FUNCTION: LEGO1 0x100adc10 MxDSAction& MxDSAction::operator=(MxDSAction& p_dsAction) { diff --git a/LEGO1/omni/src/stream/mxdiskstreamprovider.cpp b/LEGO1/omni/src/stream/mxdiskstreamprovider.cpp index 08046ad4..7694287b 100644 --- a/LEGO1/omni/src/stream/mxdiskstreamprovider.cpp +++ b/LEGO1/omni/src/stream/mxdiskstreamprovider.cpp @@ -215,18 +215,20 @@ void MxDiskStreamProvider::PerformWork() } } + MxDSBuffer* buffer; + { MxAutoLocker lock(&m_criticalSection); if (!m_list.PopFrontStreamingAction(streamingAction)) - return; + goto done; } if (streamingAction->GetUnknowna0()->GetWriteOffset() < 0x20000) { g_unk0x10102878--; } - MxDSBuffer* buffer = streamingAction->GetUnknowna0(); + buffer = streamingAction->GetUnknowna0(); if (m_pFile->GetPosition() == streamingAction->GetBufferOffset() || m_pFile->Seek(streamingAction->GetBufferOffset(), 0) == 0) { @@ -251,6 +253,7 @@ void MxDiskStreamProvider::PerformWork() } } +done: if (streamingAction) { controller->FUN_100c8670(streamingAction); } diff --git a/LEGO1/omni/src/stream/mxramstreamprovider.cpp b/LEGO1/omni/src/stream/mxramstreamprovider.cpp index 232e347b..40a12c8a 100644 --- a/LEGO1/omni/src/stream/mxramstreamprovider.cpp +++ b/LEGO1/omni/src/stream/mxramstreamprovider.cpp @@ -47,12 +47,12 @@ MxRAMStreamProvider::~MxRAMStreamProvider() m_bufferSize = 0; m_fileSize = 0; - free(m_pBufferOfFileSize); + delete[] m_pBufferOfFileSize; m_pBufferOfFileSize = NULL; m_lengthInDWords = 0; - free(m_bufferForDWords); + delete[] m_bufferForDWords; m_bufferForDWords = NULL; }