| Fling Engine 0.00.1 Fling Engine is a game engine written in Vulkan

Public Member Functions | Static Public Member Functions | Protected Attributes
Fling::FlingWindow Class Referenceabstract

Base class that represents a window to the Fling Engine. More...

`#include <FlingWindow.h>`

Inherits Fling::NonCopyable.

Inherited by Fling::DesktopWindow.

## Public Member Functions
virtual | ~FlingWindow ()=default
virtual void | Update ()=0
| Per frame update of this window. More...
virtual void | CreateSurface (void *t_GraphicsInstance, void *t_SurfData)=0
| Create the rendering surface for this window. More...
virtual void | RecreateSwapChain ()=0
| Any work that this window needs to do for swap chain recreation. More...
virtual UINT32 | GetWidth () const =0
| The current width of this window. More...
virtual UINT32 | GetHeight () const =0
| The current height of this window. More...
virtual float | GetAspectRatio () const =0
| The current aspect ratio of this windows. More...
virtual int | ShouldClose ()=0
| Int representing if this window should close or not. More...
virtual void | SetMouseVisible (bool t_IsVisible)=0
| Set whether the window hides the mouse cursor. More...
virtual bool | GetMouseVisible ()=0
| Gets current visibility of mouse cursor. More...
virtual void | SetWindowIcon (Guid t_ID)=0
| Set this window's icon. More...
virtual bool | IsMinimized () const =0
| Check if this window is currently minimized. More...
virtual void | SetWindowMode (WindowMode t_WindowMode)=0
| Changes window mode between fullscreen, window, and borderless window. More...
virtual WindowMode | GetWindowMode ()=0
| Gets current window mode. More...
Public Member Functions inherited from Fling::NonCopyable
| NonCopyable (const NonCopyable &)=delete
| NonCopyable (NonCopyable &&)=default
NonCopyable & | operator= (const NonCopyable &)=delete
NonCopyable & | operator= (NonCopyable &&)=default

## Static Public Member Functions
static FlingWindow * | Create (const WindowProps &t_Props)
| Create a window with the given data. More...

## Protected Attributes
bool | m_IsMouseVisible = true
| Tracks mouse visibility in window. More...
WindowMode | m_WindowMode = WindowMode::Windowed
| Tracks current window mode. More...

## Additional Inherited Members
Protected Member Functions inherited from Fling::NonCopyable
| NonCopyable ()=default
virtual | ~NonCopyable ()=default

## Detailed Description

Base class that represents a window to the Fling Engine.

## Constructor & Destructor Documentation

## ◆ ~FlingWindow()

virtual Fling::FlingWindow::~FlingWindow | ( |  | ) |
| virtual default

## Member Function Documentation

## ◆ Create()

FlingWindow * Fling::FlingWindow::Create | ( | const WindowProps & | t_Props | ) |
| static

Create a window with the given data.

Implemented per platform

## ◆ CreateSurface()

virtual void Fling::FlingWindow::CreateSurface | ( | void * | t_GraphicsInstance,
|  | void * | t_SurfData
| ) |  |
| pure virtual

Create the rendering surface for this window.

Implemented in Fling::DesktopWindow.

## ◆ GetAspectRatio()

virtual float Fling::FlingWindow::GetAspectRatio | ( |  | ) | const
| pure virtual

The current aspect ratio of this windows.

Implemented in Fling::DesktopWindow.

## ◆ GetHeight()

virtual UINT32 Fling::FlingWindow::GetHeight | ( |  | ) | const
| pure virtual

The current height of this window.

Implemented in Fling::DesktopWindow.

## ◆ GetMouseVisible()

virtual bool Fling::FlingWindow::GetMouseVisible | ( |  | ) |
| pure virtual

Gets current visibility of mouse cursor.

Implemented in Fling::DesktopWindow.

## ◆ GetWidth()

virtual UINT32 Fling::FlingWindow::GetWidth | ( |  | ) | const
| pure virtual

The current width of this window.

Implemented in Fling::DesktopWindow.

## ◆ GetWindowMode()

virtual WindowMode Fling::FlingWindow::GetWindowMode | ( |  | ) |
| pure virtual

Gets current window mode.

Implemented in Fling::DesktopWindow.

## ◆ IsMinimized()

virtual bool Fling::FlingWindow::IsMinimized | ( |  | ) | const
| pure virtual

Check if this window is currently minimized.

Returns
  True if the window is currently minimized

Implemented in Fling::DesktopWindow.

## ◆ RecreateSwapChain()

virtual void Fling::FlingWindow::RecreateSwapChain | ( |  | ) |
| pure virtual

Any work that this window needs to do for swap chain recreation.

Implemented in Fling::DesktopWindow.

## ◆ SetMouseVisible()

virtual void Fling::FlingWindow::SetMouseVisible | ( | bool | t_IsVisible | ) |
| pure virtual

Set whether the window hides the mouse cursor.

Implemented in Fling::DesktopWindow.

## ◆ SetWindowIcon()

virtual void Fling::FlingWindow::SetWindowIcon | ( | Guid | t_ID | ) |
| pure virtual

Set this window's icon.

Parameters

  t_ID | the GUID of the window icon

Implemented in Fling::DesktopWindow.

## ◆ SetWindowMode()

virtual void Fling::FlingWindow::SetWindowMode | ( | WindowMode | t_WindowMode | ) |
| pure virtual

Changes window mode between fullscreen, window, and borderless window.

Implemented in Fling::DesktopWindow.

## ◆ ShouldClose()

virtual int Fling::FlingWindow::ShouldClose | ( |  | ) |
| pure virtual

Int representing if this window should close or not.

Implemented in Fling::DesktopWindow.

## ◆ Update()

virtual void Fling::FlingWindow::Update | ( |  | ) |
| pure virtual

Per frame update of this window.

Implemented in Fling::DesktopWindow.

## Field Documentation

## ◆ m_IsMouseVisible

bool Fling::FlingWindow::m_IsMouseVisible = true
| protected

Tracks mouse visibility in window.

## ◆ m_WindowMode

WindowMode Fling::FlingWindow::m_WindowMode = WindowMode::Windowed
| protected

Tracks current window mode.

The documentation for this class was generated from the following files:

- FlingEngine/Graphics/inc/FlingWindow.h
- FlingEngine/Graphics/src/DesktopWindow.cpp