aboutsummaryrefslogtreecommitdiffhomepage
diff options
context:
space:
mode:
-rw-r--r--include/gpu/gl/GrGLFunctions.h1
-rw-r--r--include/gpu/gl/GrGLInterface.h1
-rw-r--r--src/gpu/gl/GrGLAssembleInterface.cpp1
-rw-r--r--src/gpu/gl/GrGLCreateNullInterface.cpp1
-rw-r--r--src/gpu/gl/GrGLInterface.cpp3
-rw-r--r--src/gpu/gl/GrGLNoOpInterface.cpp11
-rw-r--r--src/gpu/gl/GrGLNoOpInterface.h10
-rw-r--r--src/gpu/gl/android/GrGLCreateNativeInterface_android.cpp1
-rw-r--r--src/gpu/gl/angle/GrGLCreateANGLEInterface.cpp1
-rw-r--r--src/gpu/gl/debug/GrGLCreateDebugInterface.cpp1
-rw-r--r--src/gpu/gl/iOS/GrGLCreateNativeInterface_iOS.cpp1
11 files changed, 31 insertions, 1 deletions
diff --git a/include/gpu/gl/GrGLFunctions.h b/include/gpu/gl/GrGLFunctions.h
index 51db053276..5ac77a2556 100644
--- a/include/gpu/gl/GrGLFunctions.h
+++ b/include/gpu/gl/GrGLFunctions.h
@@ -87,6 +87,7 @@ extern "C" {
typedef GrGLvoid (GR_GL_FUNCTION_TYPE* GrGLColorMaskProc)(GrGLboolean red, GrGLboolean green, GrGLboolean blue, GrGLboolean alpha);
typedef GrGLvoid (GR_GL_FUNCTION_TYPE* GrGLCompileShaderProc)(GrGLuint shader);
typedef GrGLvoid (GR_GL_FUNCTION_TYPE* GrGLCompressedTexImage2DProc)(GrGLenum target, GrGLint level, GrGLenum internalformat, GrGLsizei width, GrGLsizei height, GrGLint border, GrGLsizei imageSize, const GrGLvoid* data);
+ typedef GrGLvoid (GR_GL_FUNCTION_TYPE* GrGLCompressedTexSubImage2DProc)(GrGLenum target, GrGLint level, GrGLint xoffset, GrGLint yoffset, GrGLsizei width, GrGLsizei height, GrGLenum format, GrGLsizei imageSize, const GrGLvoid* data);
typedef GrGLvoid (GR_GL_FUNCTION_TYPE* GrGLCopyTexSubImage2DProc)(GrGLenum target, GrGLint level, GrGLint xoffset, GrGLint yoffset, GrGLint x, GrGLint y, GrGLsizei width, GrGLsizei height);
typedef GrGLuint (GR_GL_FUNCTION_TYPE* GrGLCreateProgramProc)(void);
typedef GrGLuint (GR_GL_FUNCTION_TYPE* GrGLCreateShaderProc)(GrGLenum type);
diff --git a/include/gpu/gl/GrGLInterface.h b/include/gpu/gl/GrGLInterface.h
index 2b33e8e641..6c5ab24fdc 100644
--- a/include/gpu/gl/GrGLInterface.h
+++ b/include/gpu/gl/GrGLInterface.h
@@ -168,6 +168,7 @@ public:
GLPtr<GrGLColorMaskProc> fColorMask;
GLPtr<GrGLCompileShaderProc> fCompileShader;
GLPtr<GrGLCompressedTexImage2DProc> fCompressedTexImage2D;
+ GLPtr<GrGLCompressedTexSubImage2DProc> fCompressedTexSubImage2D;
GLPtr<GrGLCopyTexSubImage2DProc> fCopyTexSubImage2D;
GLPtr<GrGLCreateProgramProc> fCreateProgram;
GLPtr<GrGLCreateShaderProc> fCreateShader;
diff --git a/src/gpu/gl/GrGLAssembleInterface.cpp b/src/gpu/gl/GrGLAssembleInterface.cpp
index e4337259a2..98dabffe13 100644
--- a/src/gpu/gl/GrGLAssembleInterface.cpp
+++ b/src/gpu/gl/GrGLAssembleInterface.cpp
@@ -65,6 +65,7 @@ const GrGLInterface* GrGLAssembleGLInterface(void* ctx, GrGLGetProc get) {
GET_PROC(ColorMask);
GET_PROC(CompileShader);
GET_PROC(CompressedTexImage2D);
+ GET_PROC(CompressedTexSubImage2D);
GET_PROC(CopyTexSubImage2D);
GET_PROC(CreateProgram);
GET_PROC(CreateShader);
diff --git a/src/gpu/gl/GrGLCreateNullInterface.cpp b/src/gpu/gl/GrGLCreateNullInterface.cpp
index 6cfa8c29d0..d047e730f7 100644
--- a/src/gpu/gl/GrGLCreateNullInterface.cpp
+++ b/src/gpu/gl/GrGLCreateNullInterface.cpp
@@ -308,6 +308,7 @@ const GrGLInterface* GrGLCreateNullInterface() {
functions->fColorMask = noOpGLColorMask;
functions->fCompileShader = noOpGLCompileShader;
functions->fCompressedTexImage2D = noOpGLCompressedTexImage2D;
+ functions->fCompressedTexSubImage2D = noOpGLCompressedTexSubImage2D;
functions->fCopyTexSubImage2D = noOpGLCopyTexSubImage2D;
functions->fCreateProgram = nullGLCreateProgram;
functions->fCreateShader = nullGLCreateShader;
diff --git a/src/gpu/gl/GrGLInterface.cpp b/src/gpu/gl/GrGLInterface.cpp
index ee184d0a56..5062d92c5e 100644
--- a/src/gpu/gl/GrGLInterface.cpp
+++ b/src/gpu/gl/GrGLInterface.cpp
@@ -357,7 +357,8 @@ bool GrGLInterface::validate() const {
if (kGL_GrGLStandard != fStandard ||
(glVer >= GR_GL_VER(1,3)) ||
fExtensions.has("GL_ARB_texture_compression")) {
- if (NULL == fFunctions.fCompressedTexImage2D) {
+ if (NULL == fFunctions.fCompressedTexImage2D ||
+ NULL == fFunctions.fCompressedTexSubImage2D) {
RETURN_FALSE_INTERFACE
}
}
diff --git a/src/gpu/gl/GrGLNoOpInterface.cpp b/src/gpu/gl/GrGLNoOpInterface.cpp
index a433c0e1d8..df32d2a7cf 100644
--- a/src/gpu/gl/GrGLNoOpInterface.cpp
+++ b/src/gpu/gl/GrGLNoOpInterface.cpp
@@ -100,6 +100,17 @@ GrGLvoid GR_GL_FUNCTION_TYPE noOpGLCompressedTexImage2D(GrGLenum target,
const GrGLvoid* data) {
}
+GrGLvoid GR_GL_FUNCTION_TYPE noOpGLCompressedTexSubImage2D(GrGLenum target,
+ GrGLint level,
+ GrGLint xoffset,
+ GrGLint yoffset,
+ GrGLsizei width,
+ GrGLsizei height,
+ GrGLenum format,
+ GrGLsizei imageSize,
+ const GrGLvoid* data) {
+}
+
GrGLvoid GR_GL_FUNCTION_TYPE noOpGLCopyTexSubImage2D(GrGLenum target,
GrGLint level,
GrGLint xoffset,
diff --git a/src/gpu/gl/GrGLNoOpInterface.h b/src/gpu/gl/GrGLNoOpInterface.h
index 2efc11381a..3e146d330b 100644
--- a/src/gpu/gl/GrGLNoOpInterface.h
+++ b/src/gpu/gl/GrGLNoOpInterface.h
@@ -55,6 +55,16 @@ GrGLvoid GR_GL_FUNCTION_TYPE noOpGLCompressedTexImage2D(GrGLenum target,
GrGLsizei imageSize,
const GrGLvoid* data);
+GrGLvoid GR_GL_FUNCTION_TYPE noOpGLCompressedTexSubImage2D(GrGLenum target,
+ GrGLint level,
+ GrGLint xoffset,
+ GrGLint yoffset,
+ GrGLsizei width,
+ GrGLsizei height,
+ GrGLenum format,
+ GrGLsizei imageSize,
+ const GrGLvoid* data);
+
GrGLvoid GR_GL_FUNCTION_TYPE noOpGLCopyTexSubImage2D(GrGLenum target,
GrGLint level,
GrGLint xoffset,
diff --git a/src/gpu/gl/android/GrGLCreateNativeInterface_android.cpp b/src/gpu/gl/android/GrGLCreateNativeInterface_android.cpp
index 85341ac6eb..781e29bc9d 100644
--- a/src/gpu/gl/android/GrGLCreateNativeInterface_android.cpp
+++ b/src/gpu/gl/android/GrGLCreateNativeInterface_android.cpp
@@ -44,6 +44,7 @@ static GrGLInterface* create_es_interface(GrGLVersion version,
functions->fColorMask = glColorMask;
functions->fCompileShader = glCompileShader;
functions->fCompressedTexImage2D = glCompressedTexImage2D;
+ functions->fCompressedTexSubImage2D = glCompressedTexSubImage2D;
functions->fCopyTexSubImage2D = glCopyTexSubImage2D;
functions->fCreateProgram = glCreateProgram;
functions->fCreateShader = glCreateShader;
diff --git a/src/gpu/gl/angle/GrGLCreateANGLEInterface.cpp b/src/gpu/gl/angle/GrGLCreateANGLEInterface.cpp
index cb2fc95336..6552f7c179 100644
--- a/src/gpu/gl/angle/GrGLCreateANGLEInterface.cpp
+++ b/src/gpu/gl/angle/GrGLCreateANGLEInterface.cpp
@@ -55,6 +55,7 @@ const GrGLInterface* GrGLCreateANGLEInterface() {
GET_PROC(ColorMask);
GET_PROC(CompileShader);
GET_PROC(CompressedTexImage2D);
+ GET_PROC(CompressedTexSubImage2D);
GET_PROC(CopyTexSubImage2D);
GET_PROC(CreateProgram);
GET_PROC(CreateShader);
diff --git a/src/gpu/gl/debug/GrGLCreateDebugInterface.cpp b/src/gpu/gl/debug/GrGLCreateDebugInterface.cpp
index 7c430b4b73..788179cd84 100644
--- a/src/gpu/gl/debug/GrGLCreateDebugInterface.cpp
+++ b/src/gpu/gl/debug/GrGLCreateDebugInterface.cpp
@@ -855,6 +855,7 @@ const GrGLInterface* GrGLCreateDebugInterface() {
functions->fColorMask = noOpGLColorMask;
functions->fCompileShader = noOpGLCompileShader;
functions->fCompressedTexImage2D = noOpGLCompressedTexImage2D;
+ functions->fCompressedTexSubImage2D = noOpGLCompressedTexSubImage2D;
functions->fCopyTexSubImage2D = noOpGLCopyTexSubImage2D;
functions->fCreateProgram = debugGLCreateProgram;
functions->fCreateShader = debugGLCreateShader;
diff --git a/src/gpu/gl/iOS/GrGLCreateNativeInterface_iOS.cpp b/src/gpu/gl/iOS/GrGLCreateNativeInterface_iOS.cpp
index 08e7ac8a01..d853e3663c 100644
--- a/src/gpu/gl/iOS/GrGLCreateNativeInterface_iOS.cpp
+++ b/src/gpu/gl/iOS/GrGLCreateNativeInterface_iOS.cpp
@@ -31,6 +31,7 @@ const GrGLInterface* GrGLCreateNativeInterface() {
functions->fColorMask = glColorMask;
functions->fCompileShader = glCompileShader;
functions->fCompressedTexImage2D = glCompressedTexImage2D;
+ functions->fCompressedTexSubImage2D = glCompressedTexSubImage2D;
functions->fCopyTexSubImage2D = glCopyTexSubImage2D;
functions->fCreateProgram = glCreateProgram;
functions->fCreateShader = glCreateShader;