Started implementing PerformanceHelper class

This commit is contained in:
Alexander Bock
2016-06-06 03:53:42 +02:00
parent 1430f6b9c2
commit ff0b916b90
4 changed files with 46 additions and 0 deletions
@@ -25,9 +25,26 @@
#ifndef __PERFORMANCEHELPER_H__
#define __PERFORMANCEHELPER_H__
#include <chrono>
#include <string>
namespace openspace {
namespace performance {
class PerformanceManager;
class PerformanceHelper {
public:
PerformanceHelper(std::string identifier, performance::PerformanceManager* manager);
~PerformanceHelper();
private:
std::string _identifier;
performance::PerformanceManager* _manager;
std::chrono::high_resolution_clock::time_point _startTime;
};
} // namespace performance
} // namespace openspace
@@ -25,6 +25,7 @@
#ifndef __PERFORMANCEMANAGER_H__
#define __PERFORMANCEMANAGER_H__
#include <chrono>
#include <vector>
namespace ghoul {
@@ -45,6 +46,8 @@ public:
~PerformanceManager();
bool isMeasuringPerformance() const;
void storeIndividualPerformanceMeasurement(std::string identifier, long long us);
void storeScenePerformanceMeasurements(const std::vector<SceneGraphNode*>& sceneNodes);
private: