Engine²
Open-source game engine written in C++.
Loading...
Searching...
No Matches
Window::System Namespace Reference

Functions

void CreateWindowSystem (Engine::Core &core)
 Create a GLFW window.
void EnableVSync (Engine::Core &core)
 Enable VSync.
void PollEvents (Engine::Core &core)
 Poll GLFW events.
void InitGLFW (const Engine::Core &core)
 Initialize the GLFW.
void SetupGLFWHints (const Engine::Core &core)
 Setup GLFW Hints.
void LinkGLFWContextToGL (Engine::Core &core)
 Link the GLFW context to GL.
void SwapBuffers (Engine::Core &core)
 Swap the buffers.
void StopSystems (Engine::Core &core)
 Stop the window systems.
void StoreCoreInWindow (Engine::Core &core)
 Store a pointer to the currently used Core in the GLFW window.
void DestroyWindow (Engine::Core &core)
 Destroy the GLFW window.
void SetupWindowCallbacks (Engine::Core &core)
 Setup window callbacks.

Variables

const int DEFAULT_WIDTH = 800
const int DEFAULT_HEIGHT = 800

Function Documentation

◆ CreateWindowSystem()

void Window::System::CreateWindowSystem ( Engine::Core & core)

Create a GLFW window.

This function creates a GLFW window.

Parameters
coreThe Engine² Core.

◆ DestroyWindow()

void Window::System::DestroyWindow ( Engine::Core & core)

Destroy the GLFW window.

This function destroys the GLFW window.

Parameters
coreThe Engine² Core.

◆ EnableVSync()

void Window::System::EnableVSync ( Engine::Core & core)

Enable VSync.

This function enables VSync.

Parameters
coreThe Engine² Core.

◆ InitGLFW()

void Window::System::InitGLFW ( const Engine::Core & core)

Initialize the GLFW.

This function initialize GLFW.

Parameters
coreThe Engine² Core.

◆ LinkGLFWContextToGL()

void Window::System::LinkGLFWContextToGL ( Engine::Core & core)

Link the GLFW context to GL.

This function link the GLFW context to GL.

Parameters
coreThe Engine² Core.

◆ PollEvents()

void Window::System::PollEvents ( Engine::Core & core)

Poll GLFW events.

This function polls GLFW events.

Parameters
coreThe Engine² Core.

◆ SetupGLFWHints()

void Window::System::SetupGLFWHints ( const Engine::Core & core)

Setup GLFW Hints.

This function setup the GLFW Hints.

Parameters
coreThe Engine² Core.

◆ SetupWindowCallbacks()

void Window::System::SetupWindowCallbacks ( Engine::Core & core)

Setup window callbacks.

This function sets up the window callbacks.

Parameters
coreThe Engine² Core.

◆ StopSystems()

void Window::System::StopSystems ( Engine::Core & core)

Stop the window systems.

This function stops the window systems.

Parameters
coreThe Engine² Core.

◆ StoreCoreInWindow()

void Window::System::StoreCoreInWindow ( Engine::Core & core)

Store a pointer to the currently used Core in the GLFW window.

Parameters
coreThe Engine² Core.
Note
This can be used later to access the Core from the GLFW window, for example in callbacks where the Core is not directly accessible.

◆ SwapBuffers()

void Window::System::SwapBuffers ( Engine::Core & core)

Swap the buffers.

This function swaps the buffers.

Parameters
coreThe Engine² Core.

Variable Documentation

◆ DEFAULT_HEIGHT

const int Window::System::DEFAULT_HEIGHT = 800

◆ DEFAULT_WIDTH

const int Window::System::DEFAULT_WIDTH = 800