27 lines
407 B
C++
27 lines
407 B
C++
#ifndef BENCHMARKER_H
|
|
#define BENCHMARKER_H
|
|
|
|
#include <SFML/System/Clock.hpp>
|
|
|
|
class BenchMark {
|
|
private:
|
|
sf::Clock clock{};
|
|
double last{0.0};
|
|
double lowest{0.0};
|
|
double highest{0.0};
|
|
double average{0.0};
|
|
size_t count{0};
|
|
|
|
public:
|
|
void bench();
|
|
double mark();
|
|
|
|
void reset();
|
|
double getLast() const;
|
|
double getLowest() const;
|
|
double getHighest() const;
|
|
double getAverage() const;
|
|
};
|
|
|
|
#endif
|