diff mbox

[Branch,~glmark2-dev/glmark2/trunk] Rev 181: Android: Handle the SceneDefaultOptions special scene properly.

Message ID 20120113150714.16017.94718.launchpad@ackee.canonical.com
State Accepted
Headers show

Commit Message

alexandros.frantzis@linaro.org Jan. 13, 2012, 3:07 p.m. UTC
------------------------------------------------------------
revno: 181
committer: Alexandros Frantzis <alexandros.frantzis@linaro.org>
branch nick: trunk
timestamp: Fri 2012-01-13 16:05:54 +0200
message:
  Android: Handle the SceneDefaultOptions special scene properly.
  
  The SceneDefaultOptions is distinguishable by its empty name.
modified:
  src/android.cpp


--
lp:glmark2
https://code.launchpad.net/~glmark2-dev/glmark2/trunk

You are subscribed to branch lp:glmark2.
To unsubscribe from this branch go to https://code.launchpad.net/~glmark2-dev/glmark2/trunk/+edit-subscription
diff mbox

Patch

=== modified file 'src/android.cpp'
--- src/android.cpp	2012-01-13 14:03:23 +0000
+++ src/android.cpp	2012-01-13 14:05:54 +0000
@@ -100,10 +100,15 @@ 
     static unsigned int benchmarks_run = 0;
 
     if (!scene) {
-        if (bench_iter != g_benchmarks.end()) {
+        /* Find the next normal scene */
+        while (bench_iter != g_benchmarks.end()) {
             scene = &(*bench_iter)->setup_scene();
+            if (!scene->name().empty())
+                break;
+            bench_iter++;
         }
-        else {
+
+        if (bench_iter == g_benchmarks.end()) {
             if (benchmarks_run)
                 score /= benchmarks_run;
             Log::info("glmark2 Score: %u\n", score);