diff options
| author | Malkierian <malkierian@gmail.com> | 2024-12-09 15:06:02 -0700 |
|---|---|---|
| committer | Alejandro Asenjo Nitti <96613413+sonicdcer@users.noreply.github.com> | 2024-12-09 19:30:38 -0500 |
| commit | 354de2f364cc9c6396961217bed01b3054f67d4e (patch) | |
| tree | 929f0580f41a7fc69eddd8d5ad7d2335e6de70b3 /src/port/Engine.cpp | |
| parent | 7a333a68c2f2f372d936c1efd900c315de627848 (diff) | |
Add better cull region calculation, change gCurrentScreenWidth to 1600 to allow aspect ratios up to 6.2.
Diffstat (limited to 'src/port/Engine.cpp')
| -rw-r--r-- | src/port/Engine.cpp | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/src/port/Engine.cpp b/src/port/Engine.cpp index 57ca68ff..99e1cf2a 100644 --- a/src/port/Engine.cpp +++ b/src/port/Engine.cpp @@ -588,4 +588,12 @@ extern "C" void* GameEngine_Malloc(size_t size) { memset(static_cast<uint8_t*>(MemoryPool.memory) + MemoryPool.length, 0, MemoryPool.length - chunk); SPDLOG_INFO("Memory pool resized from {} to {}", MemoryPool.length - chunk, MemoryPool.length); return GameEngine_Malloc(size); +} + +extern "C" float GetWindowWidth() { + return Ship::Context::GetInstance()->GetWindow()->GetWidth(); +} + +extern "C" float GetWindowHeight() { + return Ship::Context::GetInstance()->GetWindow()->GetHeight(); }
\ No newline at end of file |
