2023-06-29 04:10:08 -04:00
|
|
|
#ifndef MXVIDEOPRESENTER_H
|
|
|
|
#define MXVIDEOPRESENTER_H
|
|
|
|
|
2023-07-02 03:00:28 -04:00
|
|
|
#include "decomp.h"
|
2023-10-24 19:38:27 -04:00
|
|
|
#include "mxbitmap.h"
|
|
|
|
#include "mxmediapresenter.h"
|
2023-12-29 16:30:17 -05:00
|
|
|
#include "mxrect32.h"
|
2023-07-02 03:00:28 -04:00
|
|
|
|
2023-12-06 07:10:45 -05:00
|
|
|
// VTABLE: LEGO1 0x100d4be8
|
2023-11-14 15:25:14 -05:00
|
|
|
// SIZE 0x64
|
2023-10-24 19:38:27 -04:00
|
|
|
class MxVideoPresenter : public MxMediaPresenter {
|
2023-06-29 04:10:08 -04:00
|
|
|
public:
|
2023-11-14 15:25:14 -05:00
|
|
|
enum {
|
2024-01-17 11:53:53 -05:00
|
|
|
c_bit1 = 0x01,
|
|
|
|
c_bit2 = 0x02,
|
|
|
|
c_bit3 = 0x04,
|
|
|
|
c_bit4 = 0x08,
|
|
|
|
c_bit5 = 0x10,
|
2023-11-14 15:25:14 -05:00
|
|
|
};
|
2023-07-02 05:07:11 -04:00
|
|
|
|
2023-11-14 15:25:14 -05:00
|
|
|
MxVideoPresenter() { Init(); }
|
2024-01-11 10:02:55 -05:00
|
|
|
|
|
|
|
// FUNCTION: LEGO1 0x1000c740
|
|
|
|
virtual ~MxVideoPresenter() override { Destroy(TRUE); }; // vtable+0x0
|
2023-10-05 06:31:20 -04:00
|
|
|
|
2023-12-06 07:10:45 -05:00
|
|
|
// FUNCTION: LEGO1 0x1000c820
|
2023-10-24 19:38:27 -04:00
|
|
|
inline virtual const char* ClassName() const override // vtable+0x0c
|
|
|
|
{
|
2023-12-27 15:59:42 -05:00
|
|
|
// STRING: LEGO1 0x100f0760
|
2023-10-24 19:38:27 -04:00
|
|
|
return "MxVideoPresenter";
|
|
|
|
}
|
2023-06-29 04:10:08 -04:00
|
|
|
|
2023-12-06 07:10:45 -05:00
|
|
|
// FUNCTION: LEGO1 0x1000c830
|
2023-12-13 05:48:14 -05:00
|
|
|
inline virtual MxBool IsA(const char* p_name) const override // vtable+0x10
|
2023-10-24 19:38:27 -04:00
|
|
|
{
|
2023-12-13 05:48:14 -05:00
|
|
|
return !strcmp(p_name, MxVideoPresenter::ClassName()) || MxMediaPresenter::IsA(p_name);
|
2023-10-24 19:38:27 -04:00
|
|
|
}
|
2023-07-02 03:00:28 -04:00
|
|
|
|
2024-01-11 10:02:55 -05:00
|
|
|
virtual void ReadyTickle() override; // vtable+0x18
|
|
|
|
virtual void StartingTickle() override; // vtable+0x1c
|
|
|
|
virtual void StreamingTickle() override; // vtable+0x20
|
|
|
|
virtual void RepeatingTickle() override; // vtable+0x24
|
|
|
|
virtual void Unk5Tickle() override; // vtable+0x28
|
|
|
|
virtual MxResult AddToManager() override; // vtable+0x34
|
|
|
|
|
|
|
|
// FUNCTION: LEGO1 0x1000c7a0
|
|
|
|
virtual void Destroy() override { Destroy(FALSE); }; // vtable+0x38
|
|
|
|
|
2023-11-14 15:25:14 -05:00
|
|
|
virtual void EndAction() override; // vtable+0x40
|
2023-11-26 09:03:40 -05:00
|
|
|
virtual MxResult PutData() override; // vtable+0x4c
|
2023-10-25 06:02:36 -04:00
|
|
|
virtual MxBool IsHit(MxS32 p_x, MxS32 p_y) override; // vtable+0x50
|
2024-01-11 10:02:55 -05:00
|
|
|
|
|
|
|
// FUNCTION: LEGO1 0x1000c700
|
|
|
|
virtual void LoadHeader(MxStreamChunk* p_chunk){}; // vtable+0x5c
|
|
|
|
|
|
|
|
// FUNCTION: LEGO1 0x1000c710
|
|
|
|
virtual void CreateBitmap(){}; // vtable+0x60
|
|
|
|
|
|
|
|
virtual void NextFrame(); // vtable+0x64
|
|
|
|
|
|
|
|
// FUNCTION: LEGO1 0x1000c720
|
|
|
|
virtual void LoadFrame(MxStreamChunk* p_chunk){}; // vtable+0x68
|
|
|
|
|
|
|
|
virtual void PutFrame(); // vtable+0x6c
|
|
|
|
|
|
|
|
// FUNCTION: LEGO1 0x1000c730
|
|
|
|
virtual void RealizePalette(){}; // vtable+0x70
|
2024-01-12 19:34:38 -05:00
|
|
|
|
|
|
|
virtual undefined VTable0x74(); // vtable+0x74
|
2024-01-11 10:02:55 -05:00
|
|
|
|
|
|
|
// FUNCTION: LEGO1 0x1000c7b0
|
|
|
|
virtual LPDIRECTDRAWSURFACE VTable0x78() { return m_unk0x58; }; // vtable+0x78
|
|
|
|
|
|
|
|
// FUNCTION: LEGO1 0x1000c7c0
|
|
|
|
virtual MxBool VTable0x7c() { return (m_bitmap != NULL) || (m_alpha != NULL); }; // vtable+0x7c
|
|
|
|
|
|
|
|
// FUNCTION: LEGO1 0x1000c7e0
|
|
|
|
virtual MxS32 GetWidth() { return m_alpha ? m_alpha->m_width : m_bitmap->GetBmiWidth(); }; // vtable+0x80
|
|
|
|
|
|
|
|
// FUNCTION: LEGO1 0x1000c800
|
|
|
|
virtual MxS32 GetHeight() { return m_alpha ? m_alpha->m_height : m_bitmap->GetBmiHeightAbs(); }; // vtable+0x84
|
2023-07-02 03:00:28 -04:00
|
|
|
|
2024-01-14 16:28:46 -05:00
|
|
|
// VTABLE: LEGO1 0x100dc2bc
|
2023-10-24 19:38:27 -04:00
|
|
|
// SIZE 0xc
|
|
|
|
struct AlphaMask {
|
|
|
|
MxU8* m_bitmask;
|
|
|
|
MxU16 m_width;
|
|
|
|
MxU16 m_height;
|
2023-10-16 16:09:08 -04:00
|
|
|
|
2023-10-24 19:38:27 -04:00
|
|
|
AlphaMask(const MxBitmap&);
|
|
|
|
AlphaMask(const AlphaMask&);
|
|
|
|
virtual ~AlphaMask();
|
2023-10-25 06:02:36 -04:00
|
|
|
|
|
|
|
MxS32 IsHit(MxU32 p_x, MxU32 p_y);
|
2024-01-18 08:34:14 -05:00
|
|
|
|
|
|
|
// SYNTHETIC: LEGO1 0x100b2650
|
|
|
|
// MxVideoPresenter::AlphaMask::`scalar deleting destructor'
|
2023-10-24 19:38:27 -04:00
|
|
|
};
|
2023-10-07 12:48:36 -04:00
|
|
|
|
2023-12-29 16:30:17 -05:00
|
|
|
inline MxS32 PrepareRects(MxRect32& p_rectDest, MxRect32& p_rectSrc);
|
2023-11-25 14:08:10 -05:00
|
|
|
inline MxBitmap* GetBitmap() { return m_bitmap; }
|
|
|
|
|
2024-01-18 08:34:14 -05:00
|
|
|
// SYNTHETIC: LEGO1 0x1000c910
|
|
|
|
// MxVideoPresenter::`scalar deleting destructor'
|
|
|
|
|
2023-11-25 14:08:10 -05:00
|
|
|
private:
|
|
|
|
void Init();
|
|
|
|
|
|
|
|
protected:
|
|
|
|
void Destroy(MxBool p_fromDestructor);
|
|
|
|
|
2023-12-13 05:48:14 -05:00
|
|
|
MxBitmap* m_bitmap; // 0x50
|
|
|
|
AlphaMask* m_alpha; // 0x54
|
|
|
|
LPDIRECTDRAWSURFACE m_unk0x58; // 0x58
|
|
|
|
MxS16 m_unk0x5c; // 0x5c
|
|
|
|
MxU8 m_flags; // 0x5e
|
|
|
|
MxLong m_unk0x60; // 0x60
|
2023-06-29 04:10:08 -04:00
|
|
|
};
|
|
|
|
|
|
|
|
#endif // MXVIDEOPRESENTER_H
|