Fixing minor stuff, refactoring

This commit is contained in:
Vladislav Khorev committed 2026-03-07 20:51:34 +03:00
1 parent 3c2c06ca40
commit a06cb77a66
7 files changed
+15 -102

No files matched your search

+4 -4
View File
@@ -13,8 +13,8 @@ namespace ZL {
int Environment::windowHeaderHeight = 0;
int Environment::width = 0;
int Environment::height = 0;
int Environment::width = CONST_DEFAULT_WIDTH;
int Environment::height = CONST_DEFAULT_HEIGHT;
float Environment::zoom = DEFAULT_ZOOM;
@@ -49,10 +49,10 @@ void Environment::computeProjectionDimensions()
if (width >= height) {
// Landscape: fix height to 720, scale width to preserve aspect
projectionHeight = refShortSide;
projectionWidth = refShortSide * aspect;
projectionWidth = refShortSide * aspect;
} else {
// Portrait: fix width to 720, scale height to preserve aspect
projectionWidth = refShortSide;
projectionWidth = refShortSide;
projectionHeight = refShortSide / aspect;
}
}