update with better fps reporting
git-svn-id: http://skia.googlecode.com/svn/trunk@506 2bbb7eff-a529-9590-31e7-b0007b416f81
diff --git a/bench/benchmain.cpp b/bench/benchmain.cpp
index 598eb84..7443604 100644
--- a/bench/benchmain.cpp
+++ b/bench/benchmain.cpp
@@ -172,8 +172,10 @@
} gConfigs[] = {
{ SkBitmap::kARGB_8888_Config, "8888" },
{ SkBitmap::kRGB_565_Config, "565", },
+#if 0
{ SkBitmap::kARGB_4444_Config, "4444", },
{ SkBitmap::kA8_Config, "A8", }
+#endif
};
static int findConfig(const char config[]) {
@@ -370,9 +372,10 @@
}
}
if (repeatDraw > 1) {
+ double duration = SkTime::GetMSecs() - now;
SkString str;
- str.printf(" %4s:%7.2f", configName,
- (SkTime::GetMSecs() - now) / (double)repeatDraw);
+ str.printf(" %4s: msecs = %7.2f, fps = %7.2f", configName,
+ duration / repeatDraw, repeatDraw * 1000.0 / duration);
log_progress(str);
}
if (outDir.size() > 0) {