diff options
Diffstat (limited to 'src/render/mglfunctions.h')
-rw-r--r-- | src/render/mglfunctions.h | 15 |
1 files changed, 15 insertions, 0 deletions
diff --git a/src/render/mglfunctions.h b/src/render/mglfunctions.h index e68da7f11..59f05e190 100644 --- a/src/render/mglfunctions.h +++ b/src/render/mglfunctions.h @@ -43,5 +43,20 @@ else \ logger->log(std::string("assigned function: ") + name); +#define assignFunctionEmu(func, name) m##func \ + = reinterpret_cast<func##_t>(getFunction(name)); \ + if (m##func == nullptr) \ + { \ + m##func = emu##func; \ + logger->log(std::string("emulated function: ") + name); \ + } \ + else \ + { \ + logger->log(std::string("assigned function: ") + name); \ + } + +#define emulateFunction(func) m##func = emu##func; \ + logger->log("emulated function: #func") + #endif // USE_OPENGL #endif // RENDER_MGLFUNCTIONS_H |