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

Side by Side Diff: dm/DMGpuSupport.h

Issue 1494473005: Add option to draw wireframe batch bounds (Closed) Base URL: https://skia.googlesource.com/skia.git@master
Patch Set: init vbo id to 0 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 | dm/DMSrcSink.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 2014 Google Inc. 2 * Copyright 2014 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 DMGpuSupport_DEFINED 8 #ifndef DMGpuSupport_DEFINED
9 #define DMGpuSupport_DEFINED 9 #define DMGpuSupport_DEFINED
10 10
11 // Provides Ganesh to DM, 11 // Provides Ganesh to DM,
12 // or if it's not available, fakes it enough so most code doesn't have to know t hat. 12 // or if it's not available, fakes it enough so most code doesn't have to know t hat.
13 13
14 #include "SkSurface.h" 14 #include "SkSurface.h"
15 15
16 // This should be safe to include even in no-gpu builds. Include by relative pat h so it
17 // can be found in non-gpu builds.
18 #include "../include/gpu/GrContextOptions.h"
19
16 #if SK_SUPPORT_GPU 20 #if SK_SUPPORT_GPU
17 21
18 // Ganesh is available. Yippee! 22 // Ganesh is available. Yippee!
19 23
20 # include "GrContext.h" 24 # include "GrContext.h"
21 # include "GrContextFactory.h" 25 # include "GrContextFactory.h"
22 26
23 namespace DM { 27 namespace DM {
24 28
25 static const bool kGPUDisabled = false; 29 static const bool kGPUDisabled = false;
(...skipping 22 matching lines...) Expand all
48 kGLES_GrGLStandard 52 kGLES_GrGLStandard
49 }; 53 };
50 static const int kGrGLStandardCnt = 3; 54 static const int kGrGLStandardCnt = 3;
51 55
52 class GrContext { 56 class GrContext {
53 public: 57 public:
54 void dumpCacheStats(SkString*) const {} 58 void dumpCacheStats(SkString*) const {}
55 void dumpGpuStats(SkString*) const {} 59 void dumpGpuStats(SkString*) const {}
56 }; 60 };
57 61
58 struct GrContextOptions {
59 bool fImmediateMode;
60 bool fClipBatchToBounds;
61 };
62
63 class GrContextFactory { 62 class GrContextFactory {
64 public: 63 public:
65 GrContextFactory() {}; 64 GrContextFactory() {};
66 explicit GrContextFactory(const GrContextOptions&) {} 65 explicit GrContextFactory(const GrContextOptions&) {}
67 66
68 typedef int GLContextType; 67 typedef int GLContextType;
69 68
70 static const GLContextType kANGLE_GLContextType = 0, 69 static const GLContextType kANGLE_GLContextType = 0,
71 kANGLE_GL_GLContextType = 0, 70 kANGLE_GL_GLContextType = 0,
72 kCommandBuffer_GLContextType = 0, 71 kCommandBuffer_GLContextType = 0,
(...skipping 19 matching lines...) Expand all
92 int, 91 int,
93 bool) { 92 bool) {
94 return nullptr; 93 return nullptr;
95 } 94 }
96 95
97 } // namespace DM 96 } // namespace DM
98 97
99 #endif//SK_SUPPORT_GPU 98 #endif//SK_SUPPORT_GPU
100 99
101 #endif//DMGpuSupport_DEFINED 100 #endif//DMGpuSupport_DEFINED
OLDNEW
« no previous file with comments | « no previous file | dm/DMSrcSink.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698