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 */ | |
18 class GrGLTestInterface : public GrGLInterface { | 14 class GrGLTestInterface : public GrGLInterface { |
19 public: | 15 public: |
20 virtual GrGLvoid activeTexture(GrGLenum texture) {} | 16 virtual GrGLvoid activeTexture(GrGLenum texture) {} |
21 virtual GrGLvoid attachShader(GrGLuint program, GrGLuint shader) {} | 17 virtual GrGLvoid attachShader(GrGLuint program, GrGLuint shader) {} |
22 virtual GrGLvoid beginQuery(GrGLenum target, GrGLuint id) {} | 18 virtual GrGLvoid beginQuery(GrGLenum target, GrGLuint id) {} |
23 virtual GrGLvoid bindAttribLocation(GrGLuint program, GrGLuint index, const
char* name) {} | 19 virtual GrGLvoid bindAttribLocation(GrGLuint program, GrGLuint index, const
char* name) {} |
24 virtual GrGLvoid bindBuffer(GrGLenum target, GrGLuint buffer) {} | 20 virtual GrGLvoid bindBuffer(GrGLenum target, GrGLuint buffer) {} |
25 virtual GrGLvoid bindFramebuffer(GrGLenum target, GrGLuint framebuffer) {} | 21 virtual GrGLvoid bindFramebuffer(GrGLenum target, GrGLuint framebuffer) {} |
26 virtual GrGLvoid bindRenderbuffer(GrGLenum target, GrGLuint renderbuffer) {} | 22 virtual GrGLvoid bindRenderbuffer(GrGLenum target, GrGLuint renderbuffer) {} |
27 virtual GrGLvoid bindTexture(GrGLenum target, GrGLuint texture) {} | 23 virtual GrGLvoid bindTexture(GrGLenum target, GrGLuint texture) {} |
(...skipping 300 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
328 // This must be called by leaf class | 324 // This must be called by leaf class |
329 void init(GrGLStandard standard) { | 325 void init(GrGLStandard standard) { |
330 fStandard = standard; | 326 fStandard = standard; |
331 fExtensions.init(standard, fFunctions.fGetString, fFunctions.fGetStringi
, | 327 fExtensions.init(standard, fFunctions.fGetString, fFunctions.fGetStringi
, |
332 fFunctions.fGetIntegerv, nullptr, GR_EGL_NO_DISPLAY); | 328 fFunctions.fGetIntegerv, nullptr, GR_EGL_NO_DISPLAY); |
333 } | 329 } |
334 GrGLTestInterface(); | 330 GrGLTestInterface(); |
335 }; | 331 }; |
336 | 332 |
337 #endif | 333 #endif |
OLD | NEW |