aboutsummaryrefslogtreecommitdiffhomepage
path: root/src/gpu/gl/GrGLGpu.h
diff options
context:
space:
mode:
authorGravatar bsalomon <bsalomon@google.com>2015-11-20 19:34:37 -0800
committerGravatar Commit bot <commit-bot@chromium.org>2015-11-20 19:34:37 -0800
commit27a048700778d4cebfc23301d1780649791b0e03 (patch)
tree93c88e37327c6519baaabb1faff0acef4bbb15c3 /src/gpu/gl/GrGLGpu.h
parentac8cabd729c75fdf774c0701b6ea7fd3ea5b9382 (diff)
Initial version of external_oes texture support and unit test
Diffstat (limited to 'src/gpu/gl/GrGLGpu.h')
-rw-r--r--src/gpu/gl/GrGLGpu.h15
1 files changed, 12 insertions, 3 deletions
diff --git a/src/gpu/gl/GrGLGpu.h b/src/gpu/gl/GrGLGpu.h
index c8da150a0d..637a1cf161 100644
--- a/src/gpu/gl/GrGLGpu.h
+++ b/src/gpu/gl/GrGLGpu.h
@@ -322,7 +322,7 @@ private:
SkAutoTUnref<GrGLContext> fGLContext;
- void createCopyProgram();
+ void createCopyPrograms();
// GL program-related state
ProgramCache* fProgramCache;
@@ -497,8 +497,17 @@ private:
GrGLint fTextureUniform;
GrGLint fTexCoordXformUniform;
GrGLint fPosXformUniform;
- GrGLuint fArrayBuffer;
- } fCopyProgram;
+ } fCopyPrograms[2];
+ GrGLuint fCopyProgramArrayBuffer;
+
+ static int TextureTargetToCopyProgramIdx(GrGLenum target) {
+ if (target == GR_GL_TEXTURE_2D) {
+ return 0;
+ } else {
+ SkASSERT(target == GR_GL_TEXTURE_EXTERNAL);
+ return 1;
+ }
+ }
TriState fMSAAEnabled;