Claire's Game Engine
Full C++ Engine using OpenGL
|
The Window class encapsulates an SDL window used for rendering the game. It handles window creation, access to window dimensions, and cleanup. More...
#include <Window.h>
Public Member Functions | |
Window (int pWidth, int pHeight, std::string pTitle) | |
Constructs a Window with specified width, height, and title. | |
Window (const Window &)=delete | |
Window & | operator= (const Window &)=delete |
Vector2 | GetDimensions () const |
Gets the dimensions of the window. | |
SDL_Window * | GetSdlWindow () const |
Gets the raw SDL_Window pointer. | |
bool | Open () |
Initializes the SDL video subsystem and creates the window. | |
void | Update () |
Updates the window per frame (currently unused). | |
void | Close () |
Closes and destroys the SDL window. | |
The Window class encapsulates an SDL window used for rendering the game. It handles window creation, access to window dimensions, and cleanup.
Window::Window | ( | int | pWidth, |
int | pHeight, | ||
std::string | pTitle ) |
Constructs a Window with specified width, height, and title.
pWidth | Width of the window in pixels. |
pHeight | Height of the window in pixels. |
pTitle | Title text for the window. |
|
delete |
void Window::Close | ( | ) |
Closes and destroys the SDL window.
Vector2 Window::GetDimensions | ( | ) | const |
Gets the dimensions of the window.
SDL_Window * Window::GetSdlWindow | ( | ) | const |
Gets the raw SDL_Window pointer.
bool Window::Open | ( | ) |
Initializes the SDL video subsystem and creates the window.
void Window::Update | ( | ) |
Updates the window per frame (currently unused).