diff options
Diffstat (limited to 'modules/benchmark/drawing.c')
-rw-r--r-- | modules/benchmark/drawing.c | 14 |
1 files changed, 12 insertions, 2 deletions
diff --git a/modules/benchmark/drawing.c b/modules/benchmark/drawing.c index e92b9d62..1b1419be 100644 --- a/modules/benchmark/drawing.c +++ b/modules/benchmark/drawing.c @@ -19,15 +19,25 @@ #include "benchmark.h" #include "guibench.h" +#define BENCH_REVISION 3 + void benchmark_gui(void) { bench_value r = EMPTY_BENCH_VALUE; + double frametime[5]; + int framecount[5]; shell_view_set_enabled(FALSE); - shell_status_update("Running drawing benchmark..."); + shell_status_update("Running GPU Drawing..."); - r.result = guibench(); //TODO: explain in code comments + r.result = guibench(frametime,framecount); + r.revision = BENCH_REVISION; +#if GTK_CHECK_VERSION(3,0,0) + snprintf(r.extra, 255, "g:3 f:%0.4f/%0.4f/%0.4f/%0.4f/%0.4f c:%d/%d/%d/%d/%d",frametime[0],frametime[1],frametime[2],frametime[3],frametime[4],framecount[0],framecount[1],framecount[2],framecount[3],framecount[4]); +#else + snprintf(r.extra, 255, "g:2 f:%0.4f/%0.4f/%0.4f/%0.4f/%0.4f c:%d/%d/%d/%d/%d",frametime[0],frametime[1],frametime[2],frametime[3],frametime[4],framecount[0],framecount[1],framecount[2],framecount[3],framecount[4]); +#endif bench_results[BENCHMARK_GUI] = r; } |