Rendu
A lightweight rendering engine for experimentations
Loading...
Searching...
No Matches
Public Member Functions | Private Member Functions | Private Attributes | List of all members
StenciledApp Class Referencefinal

Application for the stencil demo. More...

#include <StenciledApp.hpp>

Public Member Functions

 StenciledApp (RenderingConfig &config, Window &window)
 
void draw () override
 
void update () override
 
void physics (double fullTime, double frameTime) override
 
void resize () override
 
- Public Member Functions inherited from CameraApp
 CameraApp (RenderingConfig &config, Window &window)
 
virtual void update () override
 
virtual void physics (double fullTime, double frameTime)
 
- Public Member Functions inherited from Application
 Application (RenderingConfig &config, Window &window)
 
virtual void draw ()=0
 
virtual void update ()
 
virtual void finish ()
 
virtual void resize ()=0
 
double timeElapsed ()
 
double frameTime ()
 
double frameRate ()
 
Windowwindow ()
 
virtual ~Application ()
 
 Application (const Application &)=delete
 
Applicationoperator= (const Application &)=delete
 
 Application (Application &&)=delete
 
Applicationoperator= (Application &&)=delete
 

Private Member Functions

void setScene (const std::shared_ptr< Scene > &scene)
 

Private Attributes

std::unique_ptr< StenciledRenderer_renderer
 Stenciled renderer.
 
Texture _finalRender
 The final render.
 
std::vector< std::shared_ptr< Scene > > _scenes
 The existing scenes.
 
std::vector< std::string > _sceneNames
 The associated scene names.
 
size_t _currentScene = 0
 Currently selected scene.
 

Additional Inherited Members

- Protected Member Functions inherited from CameraApp
void freezeCamera (bool shouldFreeze)
 
- Protected Attributes inherited from CameraApp
ControllableCamera _userCamera
 The interactive camera.
 
- Protected Attributes inherited from Application
RenderingConfig_config
 The current configuration.
 
std::unique_ptr< DebugViewer_debug
 Debug viewer.
 

Detailed Description

Application for the stencil demo.

Inherits CameraApp.

Constructor & Destructor Documentation

◆ StenciledApp()

StenciledApp::StenciledApp ( RenderingConfig config,
Window window 
)
explicit

Constructor.

Parameters
configthe configuration to apply when setting up
windowthe window to render to

Member Function Documentation

◆ draw()

void StenciledApp::draw ( )
overridevirtual

Draw call.

Implements Application.

◆ physics()

void StenciledApp::physics ( double  fullTime,
double  frameTime 
)
overridevirtual

Perform physics simulation update.

Parameters
fullTimethe time elapsed since the beginning of the render loop
frameTimethe duration of the last frame
Note
This function can be called multiple times per frame.

Reimplemented from CameraApp.

◆ resize()

void StenciledApp::resize ( )
overridevirtual

Handle a window resize event, the configuration has been updated with the new size.

Implements Application.

◆ setScene()

void StenciledApp::setScene ( const std::shared_ptr< Scene > &  scene)
private

Select the scene to display.

Parameters
scenethe scene to use

◆ update()

void StenciledApp::update ( )
overridevirtual

Per-frame update.

Reimplemented from CameraApp.


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