matf-rg-engine 1.0.0
Base for project for the Computer Graphics course at Faculty of Mathematics, University of Belgrade
Loading...
Searching...
No Matches
Private Member Functions | Private Attributes | List of all members
engine::test::app::MainController Class Referencefinal

#include <MainController.hpp>

Inheritance diagram for engine::test::app::MainController:
Inheritance graph
[legend]
Collaboration diagram for engine::test::app::MainController:
Collaboration graph
[legend]

Private Member Functions

void initialize () override
 Initializes the controller. Executes in the core::App::initialize.
 
bool loop () override
 Checks whether the main loop should continue. Executes in the core::App::loop.
 
void poll_events () override
 Process internal and external events. Executes in the core::App::poll_events.
 
void update () override
 Update the controller state and prepare for drawing. Executes in the core::App::update.
 
void begin_draw () override
 Perform preparation for drawing. Executes in the core::App::draw, before Controller::draw.
 
void draw () override
 Draw the world state. Executes in the core::App::draw.
 
void end_draw () override
 Finalize drawing. Executes in the core::App::draw, after Controller::draw.
 
void draw_skybox ()
 
void draw_backpack ()
 
void update_camera ()
 

Private Attributes

float m_backpack_scale {1.0f}
 
bool m_draw_gui {false}
 
bool m_cursor_enabled {true}
 

Additional Inherited Members

- Public Member Functions inherited from engine::core::Controller
virtual std::string_view name () const
 
virtual ~Controller ()=default
 
void before (Controller *next)
 
void after (Controller *prev)
 
const std::vector< Controller * > & next () const
 
bool is_enabled () const
 Controller will execute as long this function returns true.
 
void set_enable (bool value)
 Enables or disables the controller based on value. The ControllerManager executes only the enabled controllers, except for the Controller::poll_events function, that's executed always. By default, controllers are enabled when registered.
 
- Static Public Member Functions inherited from engine::core::Controller
template<typename TController >
static TControllerget (std::source_location location=std::source_location::current())
 Serves as a single access point for all the Controller types throughout the code base. Make sure to register the controller via App::register_controller before calling this function.
 

Member Function Documentation

◆ initialize()

void engine::test::app::MainController::initialize ( )
overrideprivatevirtual

Initializes the controller. Executes in the core::App::initialize.

Reimplemented from engine::core::Controller.

◆ loop()

bool engine::test::app::MainController::loop ( )
overrideprivatevirtual

Checks whether the main loop should continue. Executes in the core::App::loop.

Returns
true if the render loop should continue.

Reimplemented from engine::core::Controller.

◆ poll_events()

void engine::test::app::MainController::poll_events ( )
overrideprivatevirtual

Process internal and external events. Executes in the core::App::poll_events.

Reimplemented from engine::core::Controller.

◆ update()

void engine::test::app::MainController::update ( )
overrideprivatevirtual

Update the controller state and prepare for drawing. Executes in the core::App::update.

Reimplemented from engine::core::Controller.

◆ begin_draw()

void engine::test::app::MainController::begin_draw ( )
overrideprivatevirtual

Perform preparation for drawing. Executes in the core::App::draw, before Controller::draw.

Reimplemented from engine::core::Controller.

◆ draw()

void engine::test::app::MainController::draw ( )
overrideprivatevirtual

Draw the world state. Executes in the core::App::draw.

Reimplemented from engine::core::Controller.

◆ end_draw()

void engine::test::app::MainController::end_draw ( )
overrideprivatevirtual

Finalize drawing. Executes in the core::App::draw, after Controller::draw.

Reimplemented from engine::core::Controller.

◆ draw_skybox()

void engine::test::app::MainController::draw_skybox ( )
private

◆ draw_backpack()

void engine::test::app::MainController::draw_backpack ( )
private

◆ update_camera()

void engine::test::app::MainController::update_camera ( )
private

Member Data Documentation

◆ m_backpack_scale

float engine::test::app::MainController::m_backpack_scale {1.0f}
private

◆ m_draw_gui

bool engine::test::app::MainController::m_draw_gui {false}
private

◆ m_cursor_enabled

bool engine::test::app::MainController::m_cursor_enabled {true}
private

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