mirror of
https://github.com/LostArtefacts/TR2X.git
synced 2024-12-02 19:06:47 +00:00
port WinVidGetDisplayAdapter
This commit is contained in:
parent
4404648764
commit
db6c1bf949
@ -69,10 +69,10 @@
|
||||
</g>
|
||||
<g transform="translate(0 116)">
|
||||
<text x="0" y="7.50">Tomb2.exe progress according to the physical function order:</text>
|
||||
<text class="todo" style="font-size: 12px; " x="747" y="9"><tspan text-anchor="end"><tspan class="decompiled">42.20% (514)</tspan> · <tspan class="known">55.34% (674)</tspan> · <tspan class="todo">0% (0)</tspan> · <tspan class="unused">2.46% (30)</tspan></tspan></text>
|
||||
<text class="todo" style="font-size: 12px; " x="747" y="9"><tspan text-anchor="end"><tspan class="decompiled">42.28% (515)</tspan> · <tspan class="known">55.25% (673)</tspan> · <tspan class="todo">0% (0)</tspan> · <tspan class="unused">2.46% (30)</tspan></tspan></text>
|
||||
<g transform="translate(0 20)">
|
||||
<rect width="315.24" height="6" x="0" y="0" class="decompiled"/>
|
||||
<rect width="413.36" height="6" x="315.24" y="0" class="known"/>
|
||||
<rect width="315.85" height="6" x="0" y="0" class="decompiled"/>
|
||||
<rect width="412.75" height="6" x="315.85" y="0" class="known"/>
|
||||
<rect width="18.40" height="6" x="728.60" y="0" class="unused"/>
|
||||
</g>
|
||||
<g transform="translate(0 31)">
|
||||
@ -944,7 +944,7 @@
|
||||
<rect width="12" height="12" x="225" y="255" class="decompiled"><title>bool __cdecl WinVidCreateGameWindow(void);</title></rect>
|
||||
<rect width="12" height="12" x="240" y="255" class="decompiled"><title>void __cdecl WinVidFreeWindow(void);</title></rect>
|
||||
<rect width="12" height="12" x="255" y="255" class="decompiled"><title>void __cdecl WinVidExitMessage(void);</title></rect>
|
||||
<rect width="12" height="12" x="270" y="255" class="known"><title>DISPLAY_ADAPTER_NODE *__cdecl WinVidGetDisplayAdapter(GUID *lpGuid);</title></rect>
|
||||
<rect width="12" height="12" x="270" y="255" class="decompiled"><title>DISPLAY_ADAPTER_NODE *__cdecl WinVidGetDisplayAdapter(GUID *lpGuid);</title></rect>
|
||||
<rect width="12" height="12" x="285" y="255" class="known"><title>void __cdecl WinVidStart(void);</title></rect>
|
||||
<rect width="12" height="12" x="300" y="255" class="known"><title>void __cdecl WinVidFinish(void);</title></rect>
|
||||
<rect width="12" height="12" x="315" y="255" class="known"><title>void __thiscall DisplayModeListInit(DISPLAY_MODE_LIST *pList);</title></rect>
|
||||
@ -1298,10 +1298,10 @@
|
||||
</g>
|
||||
<g transform="translate(0 546)">
|
||||
<text x="0" y="7.50">Tomb2.exe progress according to the function sizes:</text>
|
||||
<text class="todo" style="font-size: 12px; " x="747" y="9"><tspan text-anchor="end"><tspan class="decompiled">39.24%</tspan> · <tspan class="known">60.44%</tspan> · <tspan class="todo">0%</tspan> · <tspan class="unused">0.33%</tspan></tspan></text>
|
||||
<text class="todo" style="font-size: 12px; " x="747" y="9"><tspan text-anchor="end"><tspan class="decompiled">39.26%</tspan> · <tspan class="known">60.42%</tspan> · <tspan class="todo">0%</tspan> · <tspan class="unused">0.33%</tspan></tspan></text>
|
||||
<g transform="translate(0 20)">
|
||||
<rect width="293.09" height="6" x="0" y="0" class="decompiled"/>
|
||||
<rect width="451.47" height="6" x="293.09" y="0" class="known"/>
|
||||
<rect width="293.25" height="6" x="0" y="0" class="decompiled"/>
|
||||
<rect width="451.31" height="6" x="293.25" y="0" class="known"/>
|
||||
<rect width="2.44" height="6" x="744.56" y="0" class="unused"/>
|
||||
</g>
|
||||
<g transform="translate(0 31)">
|
||||
@ -2130,7 +2130,7 @@
|
||||
<rect width="4.84" height="4.73" x="632.98" y="339.78" class="known"><title>BOOL __cdecl ReadFileSync(HANDLE handle, LPVOID lpBuffer, DWORD nBytesToRead, LPDWORD lpnBytesRead, LPOVERLAPPED lpOverlapped);</title></rect>
|
||||
<rect width="4.84" height="4.62" x="632.98" y="347.51" class="known"><title>void __cdecl AddDynamicLight(int32_t x, int32_t y, int32_t z, int32_t intensity, int32_t falloff);</title></rect>
|
||||
<rect width="4.84" height="4.62" x="632.98" y="355.13" class="decompiled"><title>int32_t __cdecl CalculateWindowWidth(int32_t width, int32_t height);</title></rect>
|
||||
<rect width="4.84" height="4.62" x="632.98" y="362.75" class="known"><title>DISPLAY_ADAPTER_NODE *__cdecl WinVidGetDisplayAdapter(GUID *lpGuid);</title></rect>
|
||||
<rect width="4.84" height="4.62" x="632.98" y="362.75" class="decompiled"><title>DISPLAY_ADAPTER_NODE *__cdecl WinVidGetDisplayAdapter(GUID *lpGuid);</title></rect>
|
||||
<rect width="4.84" height="4.62" x="632.98" y="370.38" class="known"><title>DISPLAY_MODE *__thiscall InsertDisplayModeInListHead(DISPLAY_MODE_LIST *modeList);</title></rect>
|
||||
<rect width="4.96" height="4.50" x="640.82" y="261.54" class="decompiled"><title>const SOUND_ADAPTER_NODE *__cdecl S_Audio_Sample_GetAdapter(GUID *guid);</title></rect>
|
||||
<rect width="4.96" height="4.50" x="648.79" y="261.54" class="known"><title>void __cdecl WinStopFMV(bool is_playback);</title></rect>
|
||||
|
Before Width: | Height: | Size: 360 KiB After Width: | Height: | Size: 360 KiB |
@ -3056,7 +3056,7 @@ typedef struct {
|
||||
0x00446A60 0x00C6 +R bool __cdecl WinVidCreateGameWindow(void);
|
||||
0x00446B30 0x0022 +R void __cdecl WinVidFreeWindow(void);
|
||||
0x00446B60 0x004D +R void __cdecl WinVidExitMessage(void);
|
||||
0x00446BB0 0x0048 -R DISPLAY_ADAPTER_NODE *__cdecl WinVidGetDisplayAdapter(GUID *lpGuid);
|
||||
0x00446BB0 0x0048 +R DISPLAY_ADAPTER_NODE *__cdecl WinVidGetDisplayAdapter(GUID *lpGuid);
|
||||
0x00446C00 0x0374 -R void __cdecl WinVidStart(void);
|
||||
0x00446F80 0x0013 -R void __cdecl WinVidFinish(void);
|
||||
0x00446FA0 0x000D -R void __thiscall DisplayModeListInit(DISPLAY_MODE_LIST *pList);
|
||||
|
@ -2865,3 +2865,17 @@ void __cdecl WinVidExitMessage(void)
|
||||
while (WinVidSpinMessageLoop(false)) { }
|
||||
g_GameWindowHandle = NULL;
|
||||
}
|
||||
|
||||
DISPLAY_ADAPTER_NODE *__cdecl WinVidGetDisplayAdapter(const GUID *guid_ptr)
|
||||
{
|
||||
if (guid_ptr != NULL) {
|
||||
for (DISPLAY_ADAPTER_NODE *adapter = g_DisplayAdapterList.head;
|
||||
adapter != NULL; adapter = adapter->next) {
|
||||
if (memcmp(&adapter->body.adapter_guid, guid_ptr, sizeof(GUID))
|
||||
== 0) {
|
||||
return adapter;
|
||||
}
|
||||
}
|
||||
}
|
||||
return g_PrimaryDisplayAdapter;
|
||||
}
|
||||
|
@ -124,3 +124,4 @@ bool __cdecl WinVidCheckGameWindowPalette(HWND hWnd);
|
||||
bool __cdecl WinVidCreateGameWindow(void);
|
||||
void __cdecl WinVidFreeWindow(void);
|
||||
void __cdecl WinVidExitMessage(void);
|
||||
DISPLAY_ADAPTER_NODE *__cdecl WinVidGetDisplayAdapter(const GUID *guid_ptr);
|
||||
|
@ -443,7 +443,6 @@
|
||||
#define ControlLavaBlob ((void __cdecl (*)(int16_t fx_num))0x00442F40)
|
||||
#define GiantYetiControl ((void __cdecl (*)(int16_t item_num))0x00443050)
|
||||
#define YetiControl ((void __cdecl (*)(int16_t item_num))0x00443350)
|
||||
#define WinVidGetDisplayAdapter ((DISPLAY_ADAPTER_NODE *__cdecl (*)(GUID *lpGuid))0x00446BB0)
|
||||
#define WinVidStart ((void __cdecl (*)(void))0x00446C00)
|
||||
#define WinVidFinish ((void __cdecl (*)(void))0x00446F80)
|
||||
#define DisplayModeListInit ((void __thiscall (*)(DISPLAY_MODE_LIST *pList))0x00446FA0)
|
||||
|
@ -163,6 +163,7 @@ static void Inject_Decomp(const bool enable)
|
||||
INJECT(enable, 0x00446A60, WinVidCreateGameWindow);
|
||||
INJECT(enable, 0x00446B30, WinVidFreeWindow);
|
||||
INJECT(enable, 0x00446B60, WinVidExitMessage);
|
||||
INJECT(enable, 0x00446BB0, WinVidGetDisplayAdapter);
|
||||
}
|
||||
|
||||
static void Inject_Background(const bool enable)
|
||||
|
Loading…
Reference in New Issue
Block a user