Merge lp:~linaro-graphics-wg/glmark2/frame-time into lp:glmark2/2011.11

Proposed by Alexandros Frantzis
Status: Merged
Merged at revision: 222
Proposed branch: lp:~linaro-graphics-wg/glmark2/frame-time
Merge into: lp:glmark2/2011.11
Diff against target: 34 lines (+9/-4)
2 files modified
src/android.cpp (+4/-2)
src/main-loop.cpp (+5/-2)
To merge this branch: bzr merge lp:~linaro-graphics-wg/glmark2/frame-time
Reviewer Review Type Date Requested Status
Jesse Barker Approve
Review via email: mp+110531@code.launchpad.net

Description of the change

Display average frame time in addition to FPS for each scene.

To post a comment you must log in.
Revision history for this message
Jesse Barker (jesse-barker) wrote :

Seems fine.

review: Approve

Preview Diff

[H/L] Next/Prev Comment, [J/K] Next/Prev File, [N/P] Next/Prev Hunk
=== modified file 'src/android.cpp'
--- src/android.cpp 2012-05-15 12:28:51 +0000
+++ src/android.cpp 2012-06-15 13:54:30 +0000
@@ -48,8 +48,10 @@
4848
49 virtual void log_scene_result()49 virtual void log_scene_result()
50 {50 {
51 Log::info("%s FPS: %u", scene_->info_string().c_str(),51 Log::info("%s FPS: %u FrameTime: %.3f ms\n",
52 scene_->average_fps());52 scene_->info_string().c_str(),
53 scene_->average_fps(),
54 1000.0 / scene_->average_fps());
53 }55 }
54};56};
5557
5658
=== modified file 'src/main-loop.cpp'
--- src/main-loop.cpp 2012-02-15 17:09:14 +0000
+++ src/main-loop.cpp 2012-06-15 13:54:30 +0000
@@ -134,8 +134,11 @@
134void134void
135MainLoop::log_scene_result()135MainLoop::log_scene_result()
136{136{
137 static const std::string format(Log::continuation_prefix + " FPS: %u\n");137 static const std::string format_fps(Log::continuation_prefix + " FPS: %u");
138 Log::info(format.c_str(), scene_->average_fps());138 static const std::string format_ms(Log::continuation_prefix + " FrameTime: %.3f ms\n");
139
140 Log::info(format_fps.c_str(), scene_->average_fps());
141 Log::info(format_ms.c_str(), 1000.0 / scene_->average_fps());
139}142}
140143
141void144void

Subscribers

People subscribed via source and target branches