PixelBullet  0.0.1
A C++ game engine
Loading...
Searching...
No Matches
pixelbullet::Application Class Reference

Main application class. More...

#include <application.h>

Public Member Functions

 Application (ApplicationSpecification specification, const ApplicationBootstrap &bootstrap)
virtual ~Application ()
 Application (const Application &)=delete
Applicationoperator= (const Application &)=delete
 Application (Application &&)=delete
Applicationoperator= (Application &&)=delete
void OnEvent (pixelbullet::core::Event &e)
template<typename T, typename... Args>
T * PushLayer (Args &&... args)
template<typename T, typename... Args>
T * PushOverlay (Args &&... args)
const ApplicationSpecificationGetSpecification () const
WindowGetWindow ()
GraphicsGetGraphics ()
AudioGetAudio ()
FilesystemGetFilesystem ()
const FilesystemGetFilesystem () const
GraphicsResourceCacheGetGraphicsResourceCache ()
const GraphicsResourceCacheGetGraphicsResourceCache () const
void Start () noexcept
void Stop () noexcept
bool IsRunning () const noexcept

Static Public Member Functions

static int Launch (const ApplicationBootstrap &bootstrap, ApplicationFactory factory)

Detailed Description

Main application class.

Manages the application lifecycle, events, and layer stack.

Constructor & Destructor Documentation

◆ Application() [1/3]

pixelbullet::Application::Application ( ApplicationSpecification specification,
const ApplicationBootstrap & bootstrap )
explicit

Constructs the application with a given specification.

Parameters
specificationReference to the application specification.

◆ ~Application()

pixelbullet::Application::~Application ( )
virtual

Destroys the application.

◆ Application() [2/3]

pixelbullet::Application::Application ( const Application & )
delete

Deleted copy constructor.

◆ Application() [3/3]

pixelbullet::Application::Application ( Application && )
delete

Deleted move constructor.

Member Function Documentation

◆ GetAudio()

Audio & pixelbullet::Application::GetAudio ( )

Retrieves the audio system.

Returns
Reference to the Audio.

◆ GetGraphics()

Graphics & pixelbullet::Application::GetGraphics ( )

Retrieves the graphics system.

Returns
Reference to the Graphics.

◆ GetSpecification()

const ApplicationSpecification & pixelbullet::Application::GetSpecification ( ) const

Retrieves the application specification.

Returns
Constant reference to the application specification.

◆ GetWindow()

Window & pixelbullet::Application::GetWindow ( )

Retrieves the main application window.

Returns
Reference to the Window.

◆ OnEvent()

void pixelbullet::Application::OnEvent ( pixelbullet::core::Event & e)

Handles an incoming event.

Parameters
epixelbullet::core::Event to handle.

◆ operator=() [1/2]

Application & pixelbullet::Application::operator= ( Application && )
delete

Deleted move assignment operator.

◆ operator=() [2/2]

Application & pixelbullet::Application::operator= ( const Application & )
delete

Deleted copy assignment operator.

◆ PushLayer()

template<typename T, typename... Args>
T * pixelbullet::Application::PushLayer ( Args &&... args)
inline

Pushes a layer onto the layer stack.

Parameters
layerUnique pointer to the layer.

◆ PushOverlay()

template<typename T, typename... Args>
T * pixelbullet::Application::PushOverlay ( Args &&... args)
inline

Pushes an overlay onto the layer stack.

Parameters
layerUnique pointer to the overlay layer.

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