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

Unified Diff: src/gpu/gl/iOS/GrGLCreateNativeInterface_iOS.cpp

Issue 133073009: Move GrGLInterface function pointers into a nested struct (Closed) Base URL: https://skia.googlecode.com/svn/trunk
Patch Set: upload again, rietveld diff failed. Created 6 years, 11 months 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « src/gpu/gl/debug/GrGLCreateDebugInterface.cpp ('k') | src/gpu/gl/mac/GrGLCreateNativeInterface_mac.cpp » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/gpu/gl/iOS/GrGLCreateNativeInterface_iOS.cpp
diff --git a/src/gpu/gl/iOS/GrGLCreateNativeInterface_iOS.cpp b/src/gpu/gl/iOS/GrGLCreateNativeInterface_iOS.cpp
index d00ffdfec8004017be2adc23cced3e117e4a874e..3f3007a008dd94fae8ebc46fcaa0b892fdbb1281 100644
--- a/src/gpu/gl/iOS/GrGLCreateNativeInterface_iOS.cpp
+++ b/src/gpu/gl/iOS/GrGLCreateNativeInterface_iOS.cpp
@@ -15,131 +15,131 @@
const GrGLInterface* GrGLCreateNativeInterface() {
GrGLInterface* interface = SkNEW(GrGLInterface);
- interface->fActiveTexture = glActiveTexture;
- interface->fAttachShader = glAttachShader;
- interface->fBindAttribLocation = glBindAttribLocation;
- interface->fBindBuffer = glBindBuffer;
- interface->fBindTexture = glBindTexture;
- interface->fBlendColor = glBlendColor;
- interface->fBlendFunc = glBlendFunc;
- interface->fBufferData = (GrGLBufferDataProc)glBufferData;
- interface->fBufferSubData = (GrGLBufferSubDataProc)glBufferSubData;
- interface->fClear = glClear;
- interface->fClearColor = glClearColor;
- interface->fClearStencil = glClearStencil;
- interface->fColorMask = glColorMask;
- interface->fCompileShader = glCompileShader;
- interface->fCompressedTexImage2D = glCompressedTexImage2D;
- interface->fCopyTexSubImage2D = glCopyTexSubImage2D;
- interface->fCreateProgram = glCreateProgram;
- interface->fCreateShader = glCreateShader;
- interface->fCullFace = glCullFace;
- interface->fDeleteBuffers = glDeleteBuffers;
- interface->fDeleteProgram = glDeleteProgram;
- interface->fDeleteShader = glDeleteShader;
- interface->fDeleteTextures = glDeleteTextures;
- interface->fDepthMask = glDepthMask;
- interface->fDisable = glDisable;
- interface->fDisableVertexAttribArray = glDisableVertexAttribArray;
- interface->fDrawArrays = glDrawArrays;
- interface->fDrawBuffer = NULL;
- interface->fDrawBuffers = NULL;
- interface->fDrawElements = glDrawElements;
- interface->fEnable = glEnable;
- interface->fEnableVertexAttribArray = glEnableVertexAttribArray;
- interface->fFinish = glFinish;
- interface->fFlush = glFlush;
- interface->fFrontFace = glFrontFace;
- interface->fGenBuffers = glGenBuffers;
- interface->fGenerateMipmap = glGenerateMipmap;
- interface->fGetBufferParameteriv = glGetBufferParameteriv;
- interface->fGetError = glGetError;
- interface->fGetIntegerv = glGetIntegerv;
- interface->fGetProgramInfoLog = glGetProgramInfoLog;
- interface->fGetProgramiv = glGetProgramiv;
- interface->fGetShaderInfoLog = glGetShaderInfoLog;
- interface->fGetShaderiv = glGetShaderiv;
- interface->fGetString = glGetString;
- interface->fGenTextures = glGenTextures;
- interface->fGetUniformLocation = glGetUniformLocation;
- interface->fLineWidth = glLineWidth;
- interface->fLinkProgram = glLinkProgram;
- interface->fPixelStorei = glPixelStorei;
- interface->fReadBuffer = NULL;
- interface->fReadPixels = glReadPixels;
- interface->fScissor = glScissor;
- interface->fShaderSource = glShaderSource;
- interface->fStencilFunc = glStencilFunc;
- interface->fStencilFuncSeparate = glStencilFuncSeparate;
- interface->fStencilMask = glStencilMask;
- interface->fStencilMaskSeparate = glStencilMaskSeparate;
- interface->fStencilOp = glStencilOp;
- interface->fStencilOpSeparate = glStencilOpSeparate;
+ functions->fActiveTexture = glActiveTexture;
+ functions->fAttachShader = glAttachShader;
+ functions->fBindAttribLocation = glBindAttribLocation;
+ functions->fBindBuffer = glBindBuffer;
+ functions->fBindTexture = glBindTexture;
+ functions->fBlendColor = glBlendColor;
+ functions->fBlendFunc = glBlendFunc;
+ functions->fBufferData = (GrGLBufferDataProc)glBufferData;
+ functions->fBufferSubData = (GrGLBufferSubDataProc)glBufferSubData;
+ functions->fClear = glClear;
+ functions->fClearColor = glClearColor;
+ functions->fClearStencil = glClearStencil;
+ functions->fColorMask = glColorMask;
+ functions->fCompileShader = glCompileShader;
+ functions->fCompressedTexImage2D = glCompressedTexImage2D;
+ functions->fCopyTexSubImage2D = glCopyTexSubImage2D;
+ functions->fCreateProgram = glCreateProgram;
+ functions->fCreateShader = glCreateShader;
+ functions->fCullFace = glCullFace;
+ functions->fDeleteBuffers = glDeleteBuffers;
+ functions->fDeleteProgram = glDeleteProgram;
+ functions->fDeleteShader = glDeleteShader;
+ functions->fDeleteTextures = glDeleteTextures;
+ functions->fDepthMask = glDepthMask;
+ functions->fDisable = glDisable;
+ functions->fDisableVertexAttribArray = glDisableVertexAttribArray;
+ functions->fDrawArrays = glDrawArrays;
+ functions->fDrawBuffer = NULL;
+ functions->fDrawBuffers = NULL;
+ functions->fDrawElements = glDrawElements;
+ functions->fEnable = glEnable;
+ functions->fEnableVertexAttribArray = glEnableVertexAttribArray;
+ functions->fFinish = glFinish;
+ functions->fFlush = glFlush;
+ functions->fFrontFace = glFrontFace;
+ functions->fGenBuffers = glGenBuffers;
+ functions->fGenerateMipmap = glGenerateMipmap;
+ functions->fGetBufferParameteriv = glGetBufferParameteriv;
+ functions->fGetError = glGetError;
+ functions->fGetIntegerv = glGetIntegerv;
+ functions->fGetProgramInfoLog = glGetProgramInfoLog;
+ functions->fGetProgramiv = glGetProgramiv;
+ functions->fGetShaderInfoLog = glGetShaderInfoLog;
+ functions->fGetShaderiv = glGetShaderiv;
+ functions->fGetString = glGetString;
+ functions->fGenTextures = glGenTextures;
+ functions->fGetUniformLocation = glGetUniformLocation;
+ functions->fLineWidth = glLineWidth;
+ functions->fLinkProgram = glLinkProgram;
+ functions->fPixelStorei = glPixelStorei;
+ functions->fReadBuffer = NULL;
+ functions->fReadPixels = glReadPixels;
+ functions->fScissor = glScissor;
+ functions->fShaderSource = glShaderSource;
+ functions->fStencilFunc = glStencilFunc;
+ functions->fStencilFuncSeparate = glStencilFuncSeparate;
+ functions->fStencilMask = glStencilMask;
+ functions->fStencilMaskSeparate = glStencilMaskSeparate;
+ functions->fStencilOp = glStencilOp;
+ functions->fStencilOpSeparate = glStencilOpSeparate;
// mac uses GLenum for internalFormat param (non-standard)
// amounts to int vs. uint.
- interface->fTexImage2D = (GrGLTexImage2DProc)glTexImage2D;
+ functions->fTexImage2D = (GrGLTexImage2DProc)glTexImage2D;
#if GL_ARB_texture_storage
- interface->fTexStorage2D = glTexStorage2D;
+ functions->fTexStorage2D = glTexStorage2D;
#elif GL_EXT_texture_storage
- interface->fTexStorage2D = glTexStorage2DEXT;
+ functions->fTexStorage2D = glTexStorage2DEXT;
#endif
#if GL_EXT_discard_framebuffer
- interface->fDiscardFramebuffer = glDiscardFramebufferEXT;
+ functions->fDiscardFramebuffer = glDiscardFramebufferEXT;
#endif
- interface->fTexParameteri = glTexParameteri;
- interface->fTexParameteriv = glTexParameteriv;
- interface->fTexSubImage2D = glTexSubImage2D;
- interface->fUniform1f = glUniform1f;
- interface->fUniform1i = glUniform1i;
- interface->fUniform1fv = glUniform1fv;
- interface->fUniform1iv = glUniform1iv;
- interface->fUniform2f = glUniform2f;
- interface->fUniform2i = glUniform2i;
- interface->fUniform2fv = glUniform2fv;
- interface->fUniform2iv = glUniform2iv;
- interface->fUniform3f = glUniform3f;
- interface->fUniform3i = glUniform3i;
- interface->fUniform3fv = glUniform3fv;
- interface->fUniform3iv = glUniform3iv;
- interface->fUniform4f = glUniform4f;
- interface->fUniform4i = glUniform4i;
- interface->fUniform4fv = glUniform4fv;
- interface->fUniform4iv = glUniform4iv;
- interface->fUniform4fv = glUniform4fv;
- interface->fUniformMatrix2fv = glUniformMatrix2fv;
- interface->fUniformMatrix3fv = glUniformMatrix3fv;
- interface->fUniformMatrix4fv = glUniformMatrix4fv;
- interface->fUseProgram = glUseProgram;
- interface->fVertexAttrib4fv = glVertexAttrib4fv;
- interface->fVertexAttribPointer = glVertexAttribPointer;
- interface->fViewport = glViewport;
- interface->fGenFramebuffers = glGenFramebuffers;
- interface->fGetFramebufferAttachmentParameteriv = glGetFramebufferAttachmentParameteriv;
- interface->fGetRenderbufferParameteriv = glGetRenderbufferParameteriv;
- interface->fBindFramebuffer = glBindFramebuffer;
- interface->fFramebufferTexture2D = glFramebufferTexture2D;
- interface->fCheckFramebufferStatus = glCheckFramebufferStatus;
- interface->fDeleteFramebuffers = glDeleteFramebuffers;
- interface->fRenderbufferStorage = glRenderbufferStorage;
- interface->fGenRenderbuffers = glGenRenderbuffers;
- interface->fDeleteRenderbuffers = glDeleteRenderbuffers;
- interface->fFramebufferRenderbuffer = glFramebufferRenderbuffer;
- interface->fBindRenderbuffer = glBindRenderbuffer;
+ functions->fTexParameteri = glTexParameteri;
+ functions->fTexParameteriv = glTexParameteriv;
+ functions->fTexSubImage2D = glTexSubImage2D;
+ functions->fUniform1f = glUniform1f;
+ functions->fUniform1i = glUniform1i;
+ functions->fUniform1fv = glUniform1fv;
+ functions->fUniform1iv = glUniform1iv;
+ functions->fUniform2f = glUniform2f;
+ functions->fUniform2i = glUniform2i;
+ functions->fUniform2fv = glUniform2fv;
+ functions->fUniform2iv = glUniform2iv;
+ functions->fUniform3f = glUniform3f;
+ functions->fUniform3i = glUniform3i;
+ functions->fUniform3fv = glUniform3fv;
+ functions->fUniform3iv = glUniform3iv;
+ functions->fUniform4f = glUniform4f;
+ functions->fUniform4i = glUniform4i;
+ functions->fUniform4fv = glUniform4fv;
+ functions->fUniform4iv = glUniform4iv;
+ functions->fUniform4fv = glUniform4fv;
+ functions->fUniformMatrix2fv = glUniformMatrix2fv;
+ functions->fUniformMatrix3fv = glUniformMatrix3fv;
+ functions->fUniformMatrix4fv = glUniformMatrix4fv;
+ functions->fUseProgram = glUseProgram;
+ functions->fVertexAttrib4fv = glVertexAttrib4fv;
+ functions->fVertexAttribPointer = glVertexAttribPointer;
+ functions->fViewport = glViewport;
+ functions->fGenFramebuffers = glGenFramebuffers;
+ functions->fGetFramebufferAttachmentParameteriv = glGetFramebufferAttachmentParameteriv;
+ functions->fGetRenderbufferParameteriv = glGetRenderbufferParameteriv;
+ functions->fBindFramebuffer = glBindFramebuffer;
+ functions->fFramebufferTexture2D = glFramebufferTexture2D;
+ functions->fCheckFramebufferStatus = glCheckFramebufferStatus;
+ functions->fDeleteFramebuffers = glDeleteFramebuffers;
+ functions->fRenderbufferStorage = glRenderbufferStorage;
+ functions->fGenRenderbuffers = glGenRenderbuffers;
+ functions->fDeleteRenderbuffers = glDeleteRenderbuffers;
+ functions->fFramebufferRenderbuffer = glFramebufferRenderbuffer;
+ functions->fBindRenderbuffer = glBindRenderbuffer;
#if GL_OES_mapbuffer
- interface->fMapBuffer = glMapBufferOES;
- interface->fUnmapBuffer = glUnmapBufferOES;
+ functions->fMapBuffer = glMapBufferOES;
+ functions->fUnmapBuffer = glUnmapBufferOES;
#endif
#if GL_APPLE_framebuffer_multisample
- interface->fRenderbufferStorageMultisample = glRenderbufferStorageMultisampleAPPLE;
- interface->fResolveMultisampleFramebuffer = glResolveMultisampleFramebufferAPPLE;
+ functions->fRenderbufferStorageMultisample = glRenderbufferStorageMultisampleAPPLE;
+ functions->fResolveMultisampleFramebuffer = glResolveMultisampleFramebufferAPPLE;
#endif
#if GL_OES_vertex_array_object
- interface->fBindVertexArray = glBindVertexArrayOES;
- interface->fDeleteVertexArrays = glDeleteVertexArraysOES;
- interface->fGenVertexArrays = glGenVertexArraysOES;
+ functions->fBindVertexArray = glBindVertexArrayOES;
+ functions->fDeleteVertexArrays = glDeleteVertexArraysOES;
+ functions->fGenVertexArrays = glGenVertexArraysOES;
#endif
interface->fStandard = kGLES_GrGLStandard;
« no previous file with comments | « src/gpu/gl/debug/GrGLCreateDebugInterface.cpp ('k') | src/gpu/gl/mac/GrGLCreateNativeInterface_mac.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698