summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorDavid Li <davidxli@google.com>2011-04-21 14:15:10 -0700
committerDavid Li <davidxli@google.com>2011-04-21 14:15:10 -0700
commit5036a05aca326dd63a6f4c837e4a71e48f143970 (patch)
tree3f40332dab6c10f91d16cfebba43672f9ff7fb95
parenta4643490bb56c83a8236fdfe0e538b24c98dc591 (diff)
downloadframeworks_base-5036a05aca326dd63a6f4c837e4a71e48f143970.zip
frameworks_base-5036a05aca326dd63a6f4c837e4a71e48f143970.tar.gz
frameworks_base-5036a05aca326dd63a6f4c837e4a71e48f143970.tar.bz2
GLES2Dbg: noop - format & comment
Change-Id: Ibb36508181d4322e236b6595b28d253f282c36d7 Signed-off-by: David Li <davidxli@google.com>
-rwxr-xr-xopengl/libs/GLES2_dbg/generate_api_cpp.py8
-rwxr-xr-xopengl/libs/GLES2_dbg/generate_debugger_message_proto.py4
2 files changed, 6 insertions, 6 deletions
diff --git a/opengl/libs/GLES2_dbg/generate_api_cpp.py b/opengl/libs/GLES2_dbg/generate_api_cpp.py
index aeba213..96cde57 100755
--- a/opengl/libs/GLES2_dbg/generate_api_cpp.py
+++ b/opengl/libs/GLES2_dbg/generate_api_cpp.py
@@ -38,7 +38,7 @@ def generate_api(lines):
"glShaderSource", "glTexImage2D", "glTexSubImage2D"]
# these also needs to be forwarded to DbgContext
- contextFunctions = ["glUseProgram", "glEnableVertexAttribArray", "glDisableVertexAttribArray",
+ contextFunctions = ["glUseProgram", "glEnableVertexAttribArray", "glDisableVertexAttribArray",
"glVertexAttribPointer", "glBindBuffer", "glBufferData", "glBufferSubData", "glDeleteBuffers",]
for line in lines:
@@ -114,10 +114,10 @@ def generate_api(lines):
else:
getData += " msg.mutable_data()->assign(reinterpret_cast<const char *>(%s), %s * sizeof(%s));" % (paramName, annotation, paramType)
paramType += "*"
- else:
+ else:
if paramType == "GLfloat" or paramType == "GLclampf" or paramType.find("*") >= 0:
setMsgParameters += " msg.set_arg%d(ToInt(%s));\n" % (paramIndex, paramName)
- else:
+ else:
setMsgParameters += " msg.set_arg%d(%s);\n" % (paramIndex, paramName)
if paramIndex < len(parameters) - 1:
arguments += ', '
@@ -156,7 +156,7 @@ def generate_api(lines):
} caller;"""
print setCallerMembers
print setMsgParameters
-
+
if line.find("*") >= 0 or line.find(":") >= 0:
print " // FIXME: check for pointer usage"
if inout in ["in", "inout"]:
diff --git a/opengl/libs/GLES2_dbg/generate_debugger_message_proto.py b/opengl/libs/GLES2_dbg/generate_debugger_message_proto.py
index 57e008c..535b13e 100755
--- a/opengl/libs/GLES2_dbg/generate_debugger_message_proto.py
+++ b/opengl/libs/GLES2_dbg/generate_debugger_message_proto.py
@@ -25,7 +25,7 @@ def generate_egl_entries(output, lines, i):
line = line.split(",")[1].strip() #extract EGL function name
output.write(" %s = %d;\n" % (line, i))
i += 1
- return i
+ return i
def generate_gl_entries(output,lines,i):
@@ -118,7 +118,7 @@ message Message
optional int32 arg4 = 16;
optional int32 arg5 = 17;
optional int32 arg6 = 18;
- optional int32 arg7 = 19;
+ optional int32 arg7 = 19; // glDrawArrays/Elements sets this to active number of attributes
optional int32 arg8 = 20;
optional bytes data = 10; // variable length data used for GL call