mirror of
https://gitlab.com/Mr_Goldberg/goldberg_emulator.git
synced 2025-12-05 11:44:53 +01:00
Moved hooks calls and added hook retry
With that change, I no longer re-hook rendering functions as Hook_Manager::FoundRenderer removes all hooks and then we hook the true functions in the renderer specialization. Added a retry count.
This commit is contained in:
parent
5b0306dccc
commit
ca0ef4380a
8 changed files with 83 additions and 106 deletions
|
|
@ -31,6 +31,7 @@ protected:
|
|||
// If you do that, you should consider moving the renderer hooks to its own class and keep this one generic ?
|
||||
std::vector<Base_Hook*> _hooks;
|
||||
|
||||
unsigned int _hook_retries;
|
||||
bool _renderer_found; // Is the renderer hooked ?
|
||||
bool _ogl_hooked; // wglMakeCurrent is hooked ? (opengl)
|
||||
Base_Hook* rendererdetect_hook;
|
||||
|
|
@ -39,10 +40,10 @@ protected:
|
|||
Hook_Manager();
|
||||
virtual ~Hook_Manager();
|
||||
|
||||
void UnHookAllRendererDetector();
|
||||
// Setup opengl device
|
||||
void hook_opengl();
|
||||
|
||||
bool stop_retry();
|
||||
void HookLoadLibrary();
|
||||
|
||||
#if defined(_WIN32) || defined(WIN32) || defined(_WIN64) || defined(WIN64)
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue