| OLD | NEW |
| 1 // Copyright (c) 2010 The Chromium OS Authors. All rights reserved. | 1 // Copyright (c) 2010 The Chromium OS Authors. All rights reserved. |
| 2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
| 3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
| 4 | 4 |
| 5 #ifndef BENCH_GL_TESTBASE_H_ | 5 #ifndef BENCH_GL_TESTBASE_H_ |
| 6 #define BENCH_GL_TESTBASE_H_ | 6 #define BENCH_GL_TESTBASE_H_ |
| 7 | 7 |
| 8 #include "base/basictypes.h" | 8 #include "base/basictypes.h" |
| 9 | 9 |
| 10 #include "main.h" | 10 #include "main.h" |
| 11 | 11 |
| 12 #define DISABLE_SOME_TESTS_FOR_INTEL_DRIVER 1 |
| 12 | 13 |
| 13 namespace glbench { | 14 namespace glbench { |
| 14 | 15 |
| 15 class TestBase; | 16 class TestBase; |
| 16 | 17 |
| 17 // Runs test->TestFunc() passing it sequential powers of two (8, 16, 32,...) | 18 // Runs test->TestFunc() passing it sequential powers of two (8, 16, 32,...) |
| 18 // recording time it took. The data is then fitted linearly, obtaining slope | 19 // recording time it took. The data is then fitted linearly, obtaining slope |
| 19 // and bias such that: | 20 // and bias such that: |
| 20 // time it took to run x iterations = slope * x + bias | 21 // time it took to run x iterations = slope * x + bias |
| 21 // Returns false if one iteration of the test takes longer than | 22 // Returns false if one iteration of the test takes longer than |
| (...skipping 51 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 73 virtual bool TestFunc(int); | 74 virtual bool TestFunc(int); |
| 74 | 75 |
| 75 protected: | 76 protected: |
| 76 // Passed to glDrawElements. | 77 // Passed to glDrawElements. |
| 77 GLsizei count_; | 78 GLsizei count_; |
| 78 }; | 79 }; |
| 79 | 80 |
| 80 } // namespace glbench | 81 } // namespace glbench |
| 81 | 82 |
| 82 #endif // BENCH_GL_TESTBASE_H_ | 83 #endif // BENCH_GL_TESTBASE_H_ |
| OLD | NEW |