Shkyera Engine
Easy to use, game engine for Python
Loading...
Searching...
No Matches
shkyera::ProfilerWidget Class Reference

#include <ProfilerWidget.hpp>

Inheritance diagram for shkyera::ProfilerWidget:
[legend]

Public Member Functions

 ProfilerWidget (std::string name)
 
virtual void draw () override
 Implementation of the abstract draw method to render the profiler widget.
 
 Widget (std::string name)
 Constructor to create a widget with a specified name.
 
- Public Member Functions inherited from shkyera::Widget
 Widget (std::string name)
 Constructor to create a widget with a specified name.
 
virtual ~Widget ()=default
 Default virtual destructor.
 

Private Member Functions

void reset ()
 

Private Attributes

bool mResetOnEachFrame = false
 
size_t mFramesSinceLastReset = 0
 
std::chrono::high_resolution_clock::time_point mTimeOfLastReset = std::chrono::high_resolution_clock::now()
 

Additional Inherited Members

- Public Attributes inherited from shkyera::Widget
std::string _name
 The name of the widget.
 

Constructor & Destructor Documentation

◆ ProfilerWidget()

shkyera::ProfilerWidget::ProfilerWidget ( std::string  name)

Member Function Documentation

◆ draw()

void shkyera::ProfilerWidget::draw ( )
overridevirtual

Implementation of the abstract draw method to render the profiler widget.

Implements shkyera::Widget.

◆ reset()

void shkyera::ProfilerWidget::reset ( )
private

◆ Widget()

shkyera::Widget::Widget ( std::string  name)

Constructor to create a widget with a specified name.

Parameters
nameThe name of the widget.

Member Data Documentation

◆ mFramesSinceLastReset

size_t shkyera::ProfilerWidget::mFramesSinceLastReset = 0
private

◆ mResetOnEachFrame

bool shkyera::ProfilerWidget::mResetOnEachFrame = false
private

◆ mTimeOfLastReset

std::chrono::high_resolution_clock::time_point shkyera::ProfilerWidget::mTimeOfLastReset = std::chrono::high_resolution_clock::now()
private

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