|
AMFP Enhanced
C++ reference: the code this unofficial fork added
|
GUI virtual-size aspect calculation, kept free of engine types so it can be unit tested on its own (tests/cpp/test_gui_aspect.cpp). More...
Go to the source code of this file.
Classes | |
| struct | cLuxGuiAspectResult |
Functions | |
| cLuxGuiAspectResult | LuxCalcGuiAspect (float afVirtualX, float afVirtualY, float afScreenX, float afScreenY, bool abFixAspect) |
| abFixAspect=false reproduces the stock exe exactly (the extra width is scaled by the virtual WIDTH, so everything is about 7.7% too narrow at 16:9). | |
GUI virtual-size aspect calculation, kept free of engine types so it can be unit tested on its own (tests/cpp/test_gui_aspect.cpp).
The GUI is authored for a 4:3 virtual canvas (e.g. 800x600). On a wider screen the canvas is widened so one virtual unit stays square, and the original 4:3 area is centred.
Definition in file LuxGuiAspect.h.
|
inline |
abFixAspect=false reproduces the stock exe exactly (the extra width is scaled by the virtual WIDTH, so everything is about 7.7% too narrow at 16:9).
Definition at line 21 of file LuxGuiAspect.h.