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

Unified Diff: src/gpu/gl/angle/GrGLCreateANGLEInterface.cpp

Issue 13941006: Add glCopyTexSubImage2D to GrGLInterface (Closed) Base URL: http://skia.googlecode.com/svn/trunk/
Patch Set: Created 7 years, 8 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
Index: src/gpu/gl/angle/GrGLCreateANGLEInterface.cpp
===================================================================
--- src/gpu/gl/angle/GrGLCreateANGLEInterface.cpp (revision 8610)
+++ src/gpu/gl/angle/GrGLCreateANGLEInterface.cpp (working copy)
@@ -17,8 +17,8 @@
#include "GLES2/gl2ext.h"
#include "EGL/egl.h"
-#define GR_GET_PROC(procType, baseName) \
- interface->f ## baseName = (procType) GetProcAddress(ghANGLELib, "gl" #baseName);
+#define GET_PROC(name) \
+ interface->f ## name = (GrGL ## name ## Proc) GetProcAddress(ghANGLELib, "gl" #name);
const GrGLInterface* GrGLCreateANGLEInterface() {
@@ -39,117 +39,116 @@
glInterface.reset(interface);
interface->fBindingsExported = kES2_GrGLBinding;
- GR_GET_PROC(GrGLActiveTextureProc, ActiveTexture);
- GR_GET_PROC(GrGLAttachShaderProc, AttachShader);
- GR_GET_PROC(GrGLBindAttribLocationProc, BindAttribLocation);
- GR_GET_PROC(GrGLBindBufferProc, BindBuffer);
- GR_GET_PROC(GrGLBindTextureProc, BindTexture);
+ GET_PROC(ActiveTexture);
+ GET_PROC(AttachShader);
+ GET_PROC(BindAttribLocation);
+ GET_PROC(BindBuffer);
+ GET_PROC(BindTexture);
interface->fBindVertexArray =
(GrGLBindVertexArrayProc) eglGetProcAddress("glBindVertexArrayOES");
- GR_GET_PROC(GrGLBlendColorProc, BlendColor);
- GR_GET_PROC(GrGLBlendFuncProc, BlendFunc);
- GR_GET_PROC(GrGLBufferDataProc, BufferData);
- GR_GET_PROC(GrGLBufferSubDataProc, BufferSubData);
- GR_GET_PROC(GrGLClearProc, Clear);
- GR_GET_PROC(GrGLClearColorProc, ClearColor);
- GR_GET_PROC(GrGLClearStencilProc, ClearStencil);
- GR_GET_PROC(GrGLColorMaskProc, ColorMask);
- GR_GET_PROC(GrGLCompileShaderProc, CompileShader);
- GR_GET_PROC(GrGLCompressedTexImage2DProc, CompressedTexImage2D);
- GR_GET_PROC(GrGLCreateProgramProc, CreateProgram);
- GR_GET_PROC(GrGLCreateShaderProc, CreateShader);
- GR_GET_PROC(GrGLCullFaceProc, CullFace);
- GR_GET_PROC(GrGLDeleteBuffersProc, DeleteBuffers);
- GR_GET_PROC(GrGLDeleteProgramProc, DeleteProgram);
- GR_GET_PROC(GrGLDeleteShaderProc, DeleteShader);
- GR_GET_PROC(GrGLDeleteTexturesProc, DeleteTextures);
+ GET_PROC(BlendColor);
+ GET_PROC(BlendFunc);
+ GET_PROC(BufferData);
+ GET_PROC(BufferSubData);
+ GET_PROC(Clear);
+ GET_PROC(ClearColor);
+ GET_PROC(ClearStencil);
+ GET_PROC(ColorMask);
+ GET_PROC(CompileShader);
+ GET_PROC(CompressedTexImage2D);
+ GET_PROC(CopyTexSubImage2D);
+ GET_PROC(CreateProgram);
+ GET_PROC(CreateShader);
+ GET_PROC(CullFace);
+ GET_PROC(DeleteBuffers);
+ GET_PROC(DeleteProgram);
+ GET_PROC(DeleteShader);
+ GET_PROC(DeleteTextures);
interface->fDeleteVertexArrays =
(GrGLDeleteVertexArraysProc) eglGetProcAddress("glDeleteVertexArraysOES");
- GR_GET_PROC(GrGLDepthMaskProc, DepthMask);
- GR_GET_PROC(GrGLDisableProc, Disable);
- GR_GET_PROC(GrGLDisableVertexAttribArrayProc, DisableVertexAttribArray);
- GR_GET_PROC(GrGLDrawArraysProc, DrawArrays);
- GR_GET_PROC(GrGLDrawElementsProc, DrawElements);
- GR_GET_PROC(GrGLEnableProc, Enable);
- GR_GET_PROC(GrGLEnableVertexAttribArrayProc, EnableVertexAttribArray);
- GR_GET_PROC(GrGLFinishProc, Finish);
- GR_GET_PROC(GrGLFlushProc, Flush);
- GR_GET_PROC(GrGLFrontFaceProc, FrontFace);
- GR_GET_PROC(GrGLGenBuffersProc, GenBuffers);
- GR_GET_PROC(GrGLGenTexturesProc, GenTextures);
+ GET_PROC(DepthMask);
+ GET_PROC(Disable);
+ GET_PROC(DisableVertexAttribArray);
+ GET_PROC(DrawArrays);
+ GET_PROC(DrawElements);
+ GET_PROC(Enable);
+ GET_PROC(EnableVertexAttribArray);
+ GET_PROC(Finish);
+ GET_PROC(Flush);
+ GET_PROC(FrontFace);
+ GET_PROC(GenBuffers);
+ GET_PROC(GenTextures);
interface->fGenVertexArrays =
(GrGLGenVertexArraysProc) eglGetProcAddress("glGenVertexArraysOES");
- GR_GET_PROC(GrGLGetBufferParameterivProc, GetBufferParameteriv);
- GR_GET_PROC(GrGLGetErrorProc, GetError);
- GR_GET_PROC(GrGLGetIntegervProc, GetIntegerv);
- GR_GET_PROC(GrGLGetProgramInfoLogProc, GetProgramInfoLog);
- GR_GET_PROC(GrGLGetProgramivProc, GetProgramiv);
- GR_GET_PROC(GrGLGetShaderInfoLogProc, GetShaderInfoLog);
- GR_GET_PROC(GrGLGetShaderivProc, GetShaderiv);
- GR_GET_PROC(GrGLGetStringProc, GetString);
- GR_GET_PROC(GrGLGetUniformLocationProc, GetUniformLocation);
- GR_GET_PROC(GrGLLineWidthProc, LineWidth);
- GR_GET_PROC(GrGLLinkProgramProc, LinkProgram);
- GR_GET_PROC(GrGLPixelStoreiProc, PixelStorei);
- GR_GET_PROC(GrGLReadPixelsProc, ReadPixels);
- GR_GET_PROC(GrGLScissorProc, Scissor);
- GR_GET_PROC(GrGLShaderSourceProc, ShaderSource);
- GR_GET_PROC(GrGLStencilFuncProc, StencilFunc);
- GR_GET_PROC(GrGLStencilFuncSeparateProc, StencilFuncSeparate);
- GR_GET_PROC(GrGLStencilMaskProc, StencilMask);
- GR_GET_PROC(GrGLStencilMaskSeparateProc, StencilMaskSeparate);
- GR_GET_PROC(GrGLStencilOpProc, StencilOp);
- GR_GET_PROC(GrGLStencilOpSeparateProc, StencilOpSeparate);
- GR_GET_PROC(GrGLTexImage2DProc, TexImage2D);
- GR_GET_PROC(GrGLTexParameteriProc, TexParameteri);
- GR_GET_PROC(GrGLTexParameterivProc, TexParameteriv);
- GR_GET_PROC(GrGLTexSubImage2DProc, TexSubImage2D);
+ GET_PROC(GetBufferParameteriv);
+ GET_PROC(GetError);
+ GET_PROC(GetIntegerv);
+ GET_PROC(GetProgramInfoLog);
+ GET_PROC(GetProgramiv);
+ GET_PROC(GetShaderInfoLog);
+ GET_PROC(GetShaderiv);
+ GET_PROC(GetString);
+ GET_PROC(GetUniformLocation);
+ GET_PROC(LineWidth);
+ GET_PROC(LinkProgram);
+ GET_PROC(PixelStorei);
+ GET_PROC(ReadPixels);
+ GET_PROC(Scissor);
+ GET_PROC(ShaderSource);
+ GET_PROC(StencilFunc);
+ GET_PROC(StencilFuncSeparate);
+ GET_PROC(StencilMask);
+ GET_PROC(StencilMaskSeparate);
+ GET_PROC(StencilOp);
+ GET_PROC(StencilOpSeparate);
+ GET_PROC(TexImage2D);
+ GET_PROC(TexParameteri);
+ GET_PROC(TexParameteriv);
+ GET_PROC(TexSubImage2D);
#if GL_ARB_texture_storage
- GR_GET_PROC(GrGLTexStorage2DProc, TexStorage2D);
+ GET_PROC(TexStorage2D);
#elif GL_EXT_texture_storage
interface->fTexStorage2D = (GrGLTexStorage2DProc) eglGetProcAddress("glTexStorage2DEXT");
#endif
- GR_GET_PROC(GrGLUniform1fProc, Uniform1f);
- GR_GET_PROC(GrGLUniform1iProc, Uniform1i);
- GR_GET_PROC(GrGLUniform1fvProc, Uniform1fv);
- GR_GET_PROC(GrGLUniform1ivProc, Uniform1iv);
+ GET_PROC(Uniform1f);
+ GET_PROC(Uniform1i);
+ GET_PROC(Uniform1fv);
+ GET_PROC(Uniform1iv);
- GR_GET_PROC(GrGLUniform2fProc, Uniform2f);
- GR_GET_PROC(GrGLUniform2iProc, Uniform2i);
- GR_GET_PROC(GrGLUniform2fvProc, Uniform2fv);
- GR_GET_PROC(GrGLUniform2ivProc, Uniform2iv);
+ GET_PROC(Uniform2f);
+ GET_PROC(Uniform2i);
+ GET_PROC(Uniform2fv);
+ GET_PROC(Uniform2iv);
- GR_GET_PROC(GrGLUniform3fProc, Uniform3f);
- GR_GET_PROC(GrGLUniform3iProc, Uniform3i);
- GR_GET_PROC(GrGLUniform3fvProc, Uniform3fv);
- GR_GET_PROC(GrGLUniform3ivProc, Uniform3iv);
+ GET_PROC(Uniform3f);
+ GET_PROC(Uniform3i);
+ GET_PROC(Uniform3fv);
+ GET_PROC(Uniform3iv);
- GR_GET_PROC(GrGLUniform4fProc, Uniform4f);
- GR_GET_PROC(GrGLUniform4iProc, Uniform4i);
- GR_GET_PROC(GrGLUniform4fvProc, Uniform4fv);
- GR_GET_PROC(GrGLUniform4ivProc, Uniform4iv);
+ GET_PROC(Uniform4f);
+ GET_PROC(Uniform4i);
+ GET_PROC(Uniform4fv);
+ GET_PROC(Uniform4iv);
- GR_GET_PROC(GrGLUniformMatrix2fvProc, UniformMatrix2fv);
- GR_GET_PROC(GrGLUniformMatrix3fvProc, UniformMatrix3fv);
- GR_GET_PROC(GrGLUniformMatrix4fvProc, UniformMatrix4fv);
- GR_GET_PROC(GrGLUseProgramProc, UseProgram);
- GR_GET_PROC(GrGLVertexAttrib4fvProc, VertexAttrib4fv);
- GR_GET_PROC(GrGLVertexAttribPointerProc, VertexAttribPointer);
- GR_GET_PROC(GrGLViewportProc, Viewport);
- GR_GET_PROC(GrGLBindFramebufferProc, BindFramebuffer);
- GR_GET_PROC(GrGLBindRenderbufferProc, BindRenderbuffer);
- GR_GET_PROC(GrGLCheckFramebufferStatusProc, CheckFramebufferStatus);
- GR_GET_PROC(GrGLDeleteFramebuffersProc, DeleteFramebuffers);
- GR_GET_PROC(GrGLDeleteRenderbuffersProc, DeleteRenderbuffers);
- GR_GET_PROC(GrGLFramebufferRenderbufferProc, FramebufferRenderbuffer);
- GR_GET_PROC(GrGLFramebufferTexture2DProc, FramebufferTexture2D);
- GR_GET_PROC(GrGLGenFramebuffersProc, GenFramebuffers);
- GR_GET_PROC(GrGLGenRenderbuffersProc, GenRenderbuffers);
- GR_GET_PROC(GrGLGetFramebufferAttachmentParameterivProc,
- GetFramebufferAttachmentParameteriv);
- GR_GET_PROC(GrGLGetRenderbufferParameterivProc,
- GetRenderbufferParameteriv);
- GR_GET_PROC(GrGLRenderbufferStorageProc, RenderbufferStorage);
+ GET_PROC(UniformMatrix2fv);
+ GET_PROC(UniformMatrix3fv);
+ GET_PROC(UniformMatrix4fv);
+ GET_PROC(UseProgram);
+ GET_PROC(VertexAttrib4fv);
+ GET_PROC(VertexAttribPointer);
+ GET_PROC(Viewport);
+ GET_PROC(BindFramebuffer);
+ GET_PROC(BindRenderbuffer);
+ GET_PROC(CheckFramebufferStatus);
+ GET_PROC(DeleteFramebuffers);
+ GET_PROC(DeleteRenderbuffers);
+ GET_PROC(FramebufferRenderbuffer);
+ GET_PROC(FramebufferTexture2D);
+ GET_PROC(GenFramebuffers);
+ GET_PROC(GenRenderbuffers);
+ GET_PROC(GetFramebufferAttachmentParameteriv);
+ GET_PROC(GetRenderbufferParameteriv);
+ GET_PROC(RenderbufferStorage);
interface->fMapBuffer = (GrGLMapBufferProc) eglGetProcAddress("glMapBufferOES");
interface->fUnmapBuffer = (GrGLUnmapBufferProc) eglGetProcAddress("glUnmapBufferOES");
« no previous file with comments | « src/gpu/gl/android/GrGLCreateNativeInterface_android.cpp ('k') | src/gpu/gl/debug/GrGLCreateDebugInterface.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698