![]() |
The LARC Game Engine
A Simple Game Engine from the Laboratory for Recreational Computing
|
The window class. More...
#include <Window.h>
Public Member Functions | |
template<typename t0 , typename t1 , typename t2 > | |
int | WinMain (_In_ HINSTANCE, bool, const t0 &, const t1 &, const t2 &) |
WinMain. | |
![]() | |
void | Load () |
Load game settings. More... | |
Additional Inherited Members | |
![]() | |
void | SetWinSize (int, int) |
Set window size information. More... | |
![]() | |
static HWND | m_Hwnd = 0 |
Window handle. | |
static HINSTANCE | m_hInst = 0 |
Instance handle. | |
static bool | m_bExitSizeMove |
User just finished moving/resizing window. | |
![]() | |
static XMLElement * | m_pXmlSettings = nullptr |
Pointer to the settings tag in the XML settings file. | |
static float | m_fAspectRatio = 1.0f |
Aspect ratio, width/ht. | |
![]() | |
static char | m_szName [MAX_PATH] |
Name of this game. | |
static int | m_nWinWidth = 0 |
Window width in pixels. | |
static int | m_nWinHeight = 0 |
Window height in pixels. | |
static Vector2 | m_vWinCenter = Vector2::Zero |
Window center. | |
CWindow handles Windows specific things. This will help you to keep the rest of your code as OS-independent as possible. Gnarly things that it handles includes making a window whose client area is a specific width and height, and making sure that the window maintains its aspect ratio if the user is brave enough to resize it by dragging on one of the window's edges or corners.