summaryrefslogtreecommitdiffstats
path: root/opengl/libs/GLES2_dbg/src/api.h
diff options
context:
space:
mode:
authorDavid Li <davidxli@google.com>2011-03-24 16:42:44 -0700
committerAndroid (Google) Code Review <android-gerrit@google.com>2011-03-24 16:42:44 -0700
commit63b81568a4923b32f2131d66bbeb30c79cc0bf08 (patch)
treef63eb79349649e3dee200badd5bd4294bcd54f1e /opengl/libs/GLES2_dbg/src/api.h
parentdff626c56ac42bdcc7af5a300eefccd3fee3d166 (diff)
parent6a5ca485d10a283eb3b21152d53c74ee629f5db9 (diff)
downloadframeworks_base-63b81568a4923b32f2131d66bbeb30c79cc0bf08.zip
frameworks_base-63b81568a4923b32f2131d66bbeb30c79cc0bf08.tar.gz
frameworks_base-63b81568a4923b32f2131d66bbeb30c79cc0bf08.tar.bz2
Merge "GLES2Dbg: use libLZF for compressing images"
Diffstat (limited to 'opengl/libs/GLES2_dbg/src/api.h')
-rw-r--r--opengl/libs/GLES2_dbg/src/api.h4
1 files changed, 3 insertions, 1 deletions
diff --git a/opengl/libs/GLES2_dbg/src/api.h b/opengl/libs/GLES2_dbg/src/api.h
index be94dfc..069ac9e 100644
--- a/opengl/libs/GLES2_dbg/src/api.h
+++ b/opengl/libs/GLES2_dbg/src/api.h
@@ -17,7 +17,9 @@
#define EXTEND_Debug_glCopyTexImage2D \
void * pixels = malloc(width * height * 4); \
getGLTraceThreadSpecific()->gl.glReadPixels(x, y, width, height, GL_RGBA, GL_UNSIGNED_BYTE, pixels); \
- msg.set_data(pixels, width * height * 4); \
+ DbgContext * const dbg = getDbgContextThreadSpecific(); \
+ const unsigned compressed = dbg->Compress(pixels, width * height * 4); \
+ msg.set_data(dbg->lzf_buf, compressed); \
free(pixels);
#define EXTEND_Debug_glCopyTexSubImage2D EXTEND_Debug_glCopyTexImage2D