summaryrefslogtreecommitdiff
path: root/libs/hwui/Extensions.cpp
diff options
context:
space:
mode:
author xiaozhengdong <xiaozhengdong@xiaomi.com> 2015-08-04 16:55:35 +0800
committer xiaozhengdong <xiaozhengdong@xiaomi.com> 2015-08-04 19:46:01 +0800
commitd538d30e2f498de12a46e2aa3b0814c8d9526226 (patch)
tree3ab1643d6affabaf8fc4f3f74343d42ea10cd7f7 /libs/hwui/Extensions.cpp
parent40f0efe03df87cf340de089bcb09010a88f8a120 (diff)
hwui: add extension to support unpack operations in OpenGL ES 2.0
OpenGL ES 3.0+ lets us specify the row length for unpack operations such as glTexSubImage2D(). This allows us to upload a sub-rectangle of a texture. Also, the GL_EXT_unpack_subimage extension can also support this feature in OpenGL ES 2.0 Change-Id: Id43c2c55c5eaefbace67087c955f0b4324fb2c35 Signed-off-by: xiaozhengdong <xiaozhengdong@xiaomi.com>
Diffstat (limited to 'libs/hwui/Extensions.cpp')
-rw-r--r--libs/hwui/Extensions.cpp1
1 files changed, 1 insertions, 0 deletions
diff --git a/libs/hwui/Extensions.cpp b/libs/hwui/Extensions.cpp
index 84e7e650c52e..25004b69c496 100644
--- a/libs/hwui/Extensions.cpp
+++ b/libs/hwui/Extensions.cpp
@@ -61,6 +61,7 @@ Extensions::Extensions(): Singleton<Extensions>() {
mHasTiledRendering = hasGlExtension("GL_QCOM_tiled_rendering");
mHas1BitStencil = hasGlExtension("GL_OES_stencil1");
mHas4BitStencil = hasGlExtension("GL_OES_stencil4");
+ mHasUnpackSubImage = hasGlExtension("GL_EXT_unpack_subimage");
// Query EGL extensions
findExtensions(eglQueryString(eglGetCurrentDisplay(), EGL_EXTENSIONS), mEglExtensionList);