2013-04-04 00:32:52 -04:00
|
|
|
#include "pbd/xml++.h"
|
|
|
|
#include "canvas/types.h"
|
|
|
|
|
|
|
|
extern double double_random ();
|
|
|
|
extern ArdourCanvas::Rect rect_random (double);
|
|
|
|
|
|
|
|
namespace ArdourCanvas {
|
|
|
|
class ImageCanvas;
|
|
|
|
}
|
|
|
|
|
|
|
|
class Benchmark
|
|
|
|
{
|
|
|
|
public:
|
|
|
|
Benchmark (std::string const &);
|
|
|
|
virtual ~Benchmark () {}
|
|
|
|
|
|
|
|
void set_iterations (int);
|
|
|
|
double run ();
|
2015-10-05 10:17:49 -04:00
|
|
|
|
2013-04-04 00:32:52 -04:00
|
|
|
virtual void do_run (ArdourCanvas::ImageCanvas &) = 0;
|
|
|
|
virtual void finish (ArdourCanvas::ImageCanvas &) {}
|
|
|
|
|
|
|
|
private:
|
|
|
|
ArdourCanvas::ImageCanvas* _canvas;
|
|
|
|
int _iterations;
|
|
|
|
};
|