Isle
Loading...
Searching...
No Matches
mxvideomanager.h
Go to the documentation of this file.
1#ifndef MXVIDEOMANAGER_H
2#define MXVIDEOMANAGER_H
3
4#include "mxmediamanager.h"
5#include "mxvideoparam.h"
6
7#include <d3d.h>
8
10class MxRect32;
11class MxRegion;
12
13// VTABLE: LEGO1 0x100dc810
14// SIZE 0x64
31public:
39 ~MxVideoManager() override;
40
46 MxResult Tickle() override; // vtable+0x08
47
52 void Destroy() override; // vtable+0x18
53
69 virtual MxResult VTable0x28(
70 MxVideoParam& p_videoParam,
71 LPDIRECTDRAW p_pDirectDraw,
72 LPDIRECT3D2 p_pDirect3D,
73 LPDIRECTDRAWSURFACE p_ddSurface1,
74 LPDIRECTDRAWSURFACE p_ddSurface2,
75 LPDIRECTDRAWCLIPPER p_ddClipper,
76 MxU32 p_frequencyMS,
77 MxBool p_createThread
78 ); // vtable+0x28
79
90 virtual MxResult Create(MxVideoParam& p_videoParam, MxU32 p_frequencyMS, MxBool p_createThread); // vtable+0x2c
91
97 virtual MxResult RealizePalette(MxPalette* p_palette); // vtable+0x30
98
107 virtual void UpdateView(MxU32 p_x, MxU32 p_y, MxU32 p_width, MxU32 p_height); // vtable+0x34
108
113 MxResult Init();
114
119 void Destroy(MxBool p_fromDestructor);
120
125 void InvalidateRect(MxRect32& p_rect);
126
130 void SortPresenterList();
131
135 void UpdateRegion();
136
153 MxRegion* GetRegion() { return this->m_region; }
154
155 // SYNTHETIC: LEGO1 0x100be280
156 // MxVideoManager::`scalar deleting destructor'
157
158protected:
165};
166
167#endif // MXVIDEOMANAGER_H
Provides a DirectDraw-based drawing surface for blitting bitmaps, managing palette,...
[AI] Central class for managing the lifecycle and thread-safety of MxPresenter objects for audio/vide...
virtual MxResult Create()
[AI] Allocates and initializes the internal presenter list for this manager, ensuring thread safety.
[AI] Encapsulates a DirectDraw 8-bit (256 color) palette for use with DirectX rendering.
Definition: mxpalette.h:17
[AI] Rectangle using 32-bit signed integer coordinates.
Definition: mxgeometry.h:706
[AI] Represents a 2D region as a set of vertical spans each containing one or more horizontal segment...
Definition: mxregion.h:327
[AI] Video subsystem manager for DirectDraw/Direct3D video rendering and presenter control.
MxRegion * GetRegion()
[AI] Gets region-tracking structure managing currently invalidated rectangles.
MxResult Tickle() override
[AI] Runs the per-frame tick/update including presenter tickle, surface update, and region display.
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)
[AI] Main DirectDraw/Direct3D allocator and presenter chain creation.
LPDIRECT3D2 m_pDirect3D
[AI] Direct3D2 interface pointer, for 3D presentation and device context. [0x54]
MxResult Init()
[AI] Initializes video resources and zeros pointers for this manager.
virtual MxResult RealizePalette(MxPalette *p_palette)
[AI] Applies (realizes) the palette to both MxVideoParam and hardware palette, and updates the displa...
virtual void UpdateView(MxU32 p_x, MxU32 p_y, MxU32 p_width, MxU32 p_height)
[AI] Updates the visible video sub-rectangle inside the overall frame; typically for sub-region blits...
void UpdateRegion()
[AI] Updates the portion of the display surface that is marked dirty based on m_region,...
MxBool m_unk0x60
[AI] TRUE if manager owns the DirectDraw/Direct3D objects and should release them; FALSE if external....
LPDIRECTDRAW GetDirectDraw()
[AI] Returns the current DirectDraw COM interface managed by this class (may be owned or external).
void InvalidateRect(MxRect32 &p_rect)
[AI] Invalidates a rectangular region in the display; marks it for redraw on next tick.
void Destroy() override
[AI] Releases all display/video resources, any DirectDraw/Direct3D handles, and associated objects.
~MxVideoManager() override
[AI] Destructor; cleans up all allocated resources (DirectDraw, display surface, etc....
MxVideoParam m_videoParam
[AI] Video configuration, containing palette, source/dest rectangles, and other state....
MxVideoParam & GetVideoParam()
[AI] Retrieves the current video parameter configuration used by this manager.
MxRegion * m_region
[AI] Tracks regions that have been invalidated and need to be updated/redrawn. [0x5c]
MxDisplaySurface * m_displaySurface
[AI] Concrete blitting/output surface where final image is copied each frame. [0x58]
LPDIRECTDRAW m_pDirectDraw
[AI] DirectDraw interface pointer. May be allocated here, or passed in/injected. [0x50]
MxVideoManager()
[AI] Constructs a new MxVideoManager and initializes resources.
void SortPresenterList()
[AI] Sorts presenters in descending Z order for proper overdraw order during tickle (bubble-sort).
MxDisplaySurface * GetDisplaySurface()
[AI] Returns the display surface used for video output; for direct drawing and palette operations.
[AI] Video parameter configuration for display and rendering, encapsulates resolution,...
Definition: mxvideoparam.h:14
struct IDirect3D2 * LPDIRECT3D2
Definition: d3d.h:86
struct IDirectDrawClipper FAR * LPDIRECTDRAWCLIPPER
Definition: ddraw.h:79
struct IDirectDrawSurface FAR * LPDIRECTDRAWSURFACE
Definition: ddraw.h:74
struct IDirectDraw FAR * LPDIRECTDRAW
Definition: ddraw.h:72
MxU8 MxBool
[AI]
Definition: mxtypes.h:124
MxLong MxResult
[AI]
Definition: mxtypes.h:106
unsigned int MxU32
[AI]
Definition: mxtypes.h:32