Untitled 2D game engine pre-alpha
A 2D game engine made with Vulkan in C++
 
Loading...
Searching...
No Matches
window.h
Go to the documentation of this file.
1
8
9#pragma once
10#include <opinionated_type_names.h>
11#include "constants_and_types.h"
12
18namespace window
19{
21 extern const char* title;
23 extern bool isResizable;
25 extern Colour backgroundColour;
27 //#define backgroundColor = backgroundColour;
28
32 void Init();
34 inline auto& Initialise = Init;
36 inline auto& Initialize = Init;
37
43 void Close();
45 inline auto& Exit = Close;
47 inline auto& Terminate = Close;
48
52 void SetRenderResolution(u32 width, u32 height);
56 void SetWindowResolution(u32 width, u32 height);
65};
Constants and types used within the engine.
Handles window creation and Vulkan initialization and main loop. code can be found in window....
Definition window.cpp:135
const char * title
Title of the window.
Definition window.cpp:136
auto & Exit
Alias for Close()
Definition window.h:45
auto & Initialize
Alias for Init()
Definition window.h:36
void SetWindowResolution(u32 width, u32 height)
Sets the window resolution.
Definition window.cpp:217
u32Vec2 GetWindowResolution()
Gets the window resolution.
Definition window.cpp:239
Colour backgroundColour
Background colour, has alias backgroundColor.
Definition window.cpp:138
void SetRenderResolution(u32 width, u32 height)
Sets the render resolution.
Definition window.cpp:230
void Close()
Closes the window and cleans up Vulkan.
Definition window.cpp:182
auto & Initialise
Alias for Init()
Definition window.h:34
bool isResizable
Going to be flags later on...
Definition window.cpp:137
void Init()
alias for backgroundColour
Definition window.cpp:140
u32Vec2 GetRenderResolution()
Gets the render resolution.
Definition window.cpp:238
auto & Terminate
Alias for Close()
Definition window.h:47
2D vector of 32 bit width unsigned integers