Radium Engine  1.5.20
Loading...
Searching...
No Matches
FrameTimerData.hpp
1#pragma once
2
3#include <Gui/RaGui.hpp>
4
5#include <iomanip>
6#include <iostream>
7
8#include <Core/Tasks/TaskQueue.hpp>
9#include <Core/Utils/Log.hpp>
10#include <Core/Utils/Timer.hpp>
11#include <Engine/Rendering/Renderer.hpp>
12
13namespace Ra {
14
16struct RA_GUI_API FrameTimerData {
17 uint numFrame;
18 Core::Utils::TimePoint frameStart;
19 Core::Utils::TimePoint tasksStart;
24
25 void print( std::ostream& ostream ) const;
26};
27
28#if 0
29 class LoggableFrameTimerData
30 {
31 public:
32 LoggableFrameTimerData( uint average );
33 virtual ~LoggableFrameTimerData() {}
34 void addFrame( const FrameTimerData& data );
35
36 //void log(el::base::type::ostream_t& os) const override;
37
38 private:
39 // Print timings relative to the beginning of the frame.
40 void printTimerData( el::base::type::ostream_t& os ) const;
41 void printAverageTimerData( el::base::type::ostream_t& os ) const;
42
43 private:
44 mutable std::vector<FrameTimerData> m_frames;
45 uint m_average;
46 };
47#endif
48
49} // namespace Ra
hepler function to manage enum as underlying types in VariableSet
Definition Cage.cpp:3
This struct holds all timings for one frame of the engine.