Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(1227)

Side by Side Diff: bench/nanobench.h

Issue 1486153002: Revert of Make NVPR a GL context option instead of a GL context (Closed) Base URL: https://skia.googlesource.com/skia.git@commandbuffer-as-api-02-other-tests-refactor
Patch Set: Created 5 years ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
« no previous file with comments | « no previous file | bench/nanobench.cpp » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 /* 1 /*
2 * Copyright 2015 Google Inc. 2 * Copyright 2015 Google Inc.
3 * 3 *
4 * Use of this source code is governed by a BSD-style license that can be 4 * Use of this source code is governed by a BSD-style license that can be
5 * found in the LICENSE file. 5 * found in the LICENSE file.
6 */ 6 */
7 7
8 #ifndef nanobench_DEFINED 8 #ifndef nanobench_DEFINED
9 #define nanobench_DEFINED 9 #define nanobench_DEFINED
10 10
(...skipping 11 matching lines...) Expand all
22 class SkCanvas; 22 class SkCanvas;
23 23
24 struct Config { 24 struct Config {
25 const char* name; 25 const char* name;
26 Benchmark::Backend backend; 26 Benchmark::Backend backend;
27 SkColorType color; 27 SkColorType color;
28 SkAlphaType alpha; 28 SkAlphaType alpha;
29 int samples; 29 int samples;
30 #if SK_SUPPORT_GPU 30 #if SK_SUPPORT_GPU
31 GrContextFactory::GLContextType ctxType; 31 GrContextFactory::GLContextType ctxType;
32 GrContextFactory::GLContextOptions ctxOptions;
33 bool useDFText; 32 bool useDFText;
34 #else 33 #else
35 int bogusInt; 34 int bogusInt;
36 int bogusIntOption;
37 bool bogusBool; 35 bool bogusBool;
38 #endif 36 #endif
39 }; 37 };
40 38
41 struct Target { 39 struct Target {
42 explicit Target(const Config& c) : config(c) { } 40 explicit Target(const Config& c) : config(c) { }
43 virtual ~Target() { } 41 virtual ~Target() { }
44 42
45 const Config config; 43 const Config config;
46 SkAutoTDelete<SkSurface> surface; 44 SkAutoTDelete<SkSurface> surface;
(...skipping 33 matching lines...) Expand 10 before | Expand all | Expand 10 after
80 78
81 SkCanvas* getCanvas() const { 79 SkCanvas* getCanvas() const {
82 if (!surface.get()) { 80 if (!surface.get()) {
83 return nullptr; 81 return nullptr;
84 } 82 }
85 return surface->getCanvas(); 83 return surface->getCanvas();
86 } 84 }
87 }; 85 };
88 86
89 #endif // nanobench_DEFINED 87 #endif // nanobench_DEFINED
OLDNEW
« no previous file with comments | « no previous file | bench/nanobench.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698