diff options
author | Siva Velusamy <vsiva@google.com> | 2012-06-11 11:14:23 -0700 |
---|---|---|
committer | Siva Velusamy <vsiva@google.com> | 2012-06-11 11:16:56 -0700 |
commit | 3ef9e9671c224af82d2efec1a1e9a275fb9acf44 (patch) | |
tree | 83157f70bf94210d8c62b2ac94b2e7f78a5b8f02 /opengl/libs/GLES_trace/src/gltrace_fixup.cpp | |
parent | af1cb83516589034aedcbf211f1b66bd80250136 (diff) | |
download | frameworks_native-3ef9e9671c224af82d2efec1a1e9a275fb9acf44.zip frameworks_native-3ef9e9671c224af82d2efec1a1e9a275fb9acf44.tar.gz frameworks_native-3ef9e9671c224af82d2efec1a1e9a275fb9acf44.tar.bz2 |
gltrace: Fixup vertex attrib pointers only for GLES2
Change-Id: Ibf280c2a4372ce6e598e164eef0d72b7c0a6d1c2
Diffstat (limited to 'opengl/libs/GLES_trace/src/gltrace_fixup.cpp')
-rw-r--r-- | opengl/libs/GLES_trace/src/gltrace_fixup.cpp | 11 |
1 files changed, 11 insertions, 0 deletions
diff --git a/opengl/libs/GLES_trace/src/gltrace_fixup.cpp b/opengl/libs/GLES_trace/src/gltrace_fixup.cpp index 3597b26..1bd790e 100644 --- a/opengl/libs/GLES_trace/src/gltrace_fixup.cpp +++ b/opengl/libs/GLES_trace/src/gltrace_fixup.cpp @@ -15,6 +15,7 @@ */ #include <cutils/log.h> +#include <EGL/egldefs.h> #include <GLES/gl.h> #include <GLES/glext.h> #include <GLES2/gl2.h> @@ -592,6 +593,11 @@ void trace_VertexAttribPointerData(GLTraceContext *context, } void trace_VertexAttribPointerDataForGlDrawArrays(GLTraceContext *context, GLMessage *glmsg) { + if (context->getVersion() == egl_connection_t::GLESv1_INDEX) { + // only supported for GLES2 and above + return; + } + /* void glDrawArrays(GLenum mode, GLint first, GLsizei count) */ GLsizei count = glmsg->args(2).intvalue(0); @@ -604,6 +610,11 @@ void trace_VertexAttribPointerDataForGlDrawArrays(GLTraceContext *context, GLMes void trace_VertexAttribPointerDataForGlDrawElements(GLTraceContext *context, GLMessage *glmsg, GLvoid *indices) { + if (context->getVersion() == egl_connection_t::GLESv1_INDEX) { + // only supported for GLES2 and above + return; + } + /* void glDrawElements(GLenum mode, GLsizei count, GLenum type, const GLvoid* indices) */ GLsizei count = glmsg->args(1).intvalue(0); GLenum type = glmsg->args(2).intvalue(0); |