OLD | NEW |
1 /* | 1 /* |
2 * Copyright 2016 Google Inc. | 2 * Copyright 2016 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 GrGLTestInterface_DEFINED | 8 #ifndef GrGLTestInterface_DEFINED |
9 #define GrGLTestInterface_DEFINED | 9 #define GrGLTestInterface_DEFINED |
10 | 10 |
11 #include "gl/GrGLInterface.h" | 11 #include "gl/GrGLInterface.h" |
12 #include "GrGLDefines.h" | 12 #include "GrGLDefines.h" |
13 | 13 |
| 14 /** |
| 15 * Base class for interfaces used for Skia testing. We would like to move this t
o tools/gpu/gl |
| 16 * when Chromium is no longer using GrGLCreateNullInterface in its unit testing. |
| 17 */ |
14 class GrGLTestInterface : public GrGLInterface { | 18 class GrGLTestInterface : public GrGLInterface { |
15 public: | 19 public: |
16 virtual GrGLvoid activeTexture(GrGLenum texture) {} | 20 virtual GrGLvoid activeTexture(GrGLenum texture) {} |
17 virtual GrGLvoid attachShader(GrGLuint program, GrGLuint shader) {} | 21 virtual GrGLvoid attachShader(GrGLuint program, GrGLuint shader) {} |
18 virtual GrGLvoid beginQuery(GrGLenum target, GrGLuint id) {} | 22 virtual GrGLvoid beginQuery(GrGLenum target, GrGLuint id) {} |
19 virtual GrGLvoid bindAttribLocation(GrGLuint program, GrGLuint index, const
char* name) {} | 23 virtual GrGLvoid bindAttribLocation(GrGLuint program, GrGLuint index, const
char* name) {} |
20 virtual GrGLvoid bindBuffer(GrGLenum target, GrGLuint buffer) {} | 24 virtual GrGLvoid bindBuffer(GrGLenum target, GrGLuint buffer) {} |
21 virtual GrGLvoid bindFramebuffer(GrGLenum target, GrGLuint framebuffer) {} | 25 virtual GrGLvoid bindFramebuffer(GrGLenum target, GrGLuint framebuffer) {} |
22 virtual GrGLvoid bindRenderbuffer(GrGLenum target, GrGLuint renderbuffer) {} | 26 virtual GrGLvoid bindRenderbuffer(GrGLenum target, GrGLuint renderbuffer) {} |
23 virtual GrGLvoid bindTexture(GrGLenum target, GrGLuint texture) {} | 27 virtual GrGLvoid bindTexture(GrGLenum target, GrGLuint texture) {} |
(...skipping 300 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
324 // This must be called by leaf class | 328 // This must be called by leaf class |
325 void init(GrGLStandard standard) { | 329 void init(GrGLStandard standard) { |
326 fStandard = standard; | 330 fStandard = standard; |
327 fExtensions.init(standard, fFunctions.fGetString, fFunctions.fGetStringi
, | 331 fExtensions.init(standard, fFunctions.fGetString, fFunctions.fGetStringi
, |
328 fFunctions.fGetIntegerv, nullptr, GR_EGL_NO_DISPLAY); | 332 fFunctions.fGetIntegerv, nullptr, GR_EGL_NO_DISPLAY); |
329 } | 333 } |
330 GrGLTestInterface(); | 334 GrGLTestInterface(); |
331 }; | 335 }; |
332 | 336 |
333 #endif | 337 #endif |
OLD | NEW |