ddr: Fix windowed mode regressions

This commit is contained in:
QCDLZCLW3K
2022-05-30 02:00:49 +00:00
parent da736d2968
commit 4cc81f48f3
6 changed files with 53 additions and 8 deletions
+4 -6
View File
@@ -33,10 +33,6 @@ static bool my_dll_entry_main(void);
bool standard_def;
bool _15khz;
static const hook_d3d9_irp_handler_t ddrhook2_d3d9_handlers[] = {
gfx_d3d9_irp_handler,
};
static bool my_dll_entry_init(char *sidcode, struct property_node *param)
{
int argc;
@@ -87,6 +83,10 @@ static bool my_dll_entry_init(char *sidcode, struct property_node *param)
args_free(argc, argv);
#if AVS_VERSION >= 1508
gfx_set_is_modern();
#endif
iohook_push_handler(p3io_emu_dispatch_irp);
iohook_push_handler(extio_dispatch_irp);
iohook_push_handler(spike_dispatch_irp);
@@ -97,8 +97,6 @@ static bool my_dll_entry_init(char *sidcode, struct property_node *param)
iohook_push_handler(com4_dispatch_irp);
}
hook_d3d9_init(ddrhook2_d3d9_handlers, lengthof(ddrhook2_d3d9_handlers));
rs232_hook_init();
ddrhook2_master_insert_hooks(NULL);
+7
View File
@@ -16,6 +16,11 @@ static HMODULE(STDCALL *real_LoadLibraryA)(const char *name);
static HMODULE STDCALL my_LoadLibraryA(const char *name);
static const hook_d3d9_irp_handler_t ddrhook2_d3d9_handlers[] = {
gfx_d3d9_irp_handler,
};
static const struct hook_symbol master_kernel32_syms[] = {
{
.name = "LoadLibraryA",
@@ -58,6 +63,8 @@ void ddrhook2_master_insert_hooks(HMODULE target)
dinput_init(target);
gfx_insert_hooks(target);
hook_d3d9_init(ddrhook2_d3d9_handlers, lengthof(ddrhook2_d3d9_handlers));
/* Insert dynamic loader hooks so that we can hook late-loaded modules */
hook_table_apply(