blob: cef6cbb1657f068fe07b2811a70262ce1f81aa20 [file] [log] [blame]
/*
* Copyright 2011, The Android Open Source Project
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*
* THIS FILE WAS GENERATED BY A SCRIPT. DO NOT EDIT.
*/
#include <cutils/log.h>
#include <utils/Timers.h>
#include <GLES2/gl2.h>
#include "gltrace.pb.h"
#include "gltrace_context.h"
#include "gltrace_fixup.h"
#include "gltrace_transport.h"
namespace android {
namespace gltrace {
// Definitions for GL2 APIs
void GLTrace_glActiveTexture(GLenum texture) {
GLMessage glmsg;
GLTraceContext *glContext = getGLTraceContext();
glmsg.set_function(GLMessage::glActiveTexture);
// copy argument texture
GLMessage_DataType *arg_texture = glmsg.add_args();
arg_texture->set_isarray(false);
arg_texture->set_type(GLMessage::DataType::ENUM);
arg_texture->add_intvalue((int)texture);
// call function
nsecs_t wallStartTime = systemTime(SYSTEM_TIME_MONOTONIC);
nsecs_t threadStartTime = systemTime(SYSTEM_TIME_THREAD);
glContext->hooks->gl.glActiveTexture(texture);
nsecs_t threadEndTime = systemTime(SYSTEM_TIME_THREAD);
nsecs_t wallEndTime = systemTime(SYSTEM_TIME_MONOTONIC);
void *pointerArgs[] = {
};
fixupGLMessage(glContext, wallStartTime, wallEndTime,
threadStartTime, threadEndTime,
&glmsg, pointerArgs);
glContext->traceGLMessage(&glmsg);
}
void GLTrace_glAttachShader(GLuint program, GLuint shader) {
GLMessage glmsg;
GLTraceContext *glContext = getGLTraceContext();
glmsg.set_function(GLMessage::glAttachShader);
// copy argument program
GLMessage_DataType *arg_program = glmsg.add_args();
arg_program->set_isarray(false);
arg_program->set_type(GLMessage::DataType::INT);
arg_program->add_intvalue(program);
// copy argument shader
GLMessage_DataType *arg_shader = glmsg.add_args();
arg_shader->set_isarray(false);
arg_shader->set_type(GLMessage::DataType::INT);
arg_shader->add_intvalue(shader);
// call function
nsecs_t wallStartTime = systemTime(SYSTEM_TIME_MONOTONIC);
nsecs_t threadStartTime = systemTime(SYSTEM_TIME_THREAD);
glContext->hooks->gl.glAttachShader(program, shader);
nsecs_t threadEndTime = systemTime(SYSTEM_TIME_THREAD);
nsecs_t wallEndTime = systemTime(SYSTEM_TIME_MONOTONIC);
void *pointerArgs[] = {
};
fixupGLMessage(glContext, wallStartTime, wallEndTime,
threadStartTime, threadEndTime,
&glmsg, pointerArgs);
glContext->traceGLMessage(&glmsg);
}
void GLTrace_glBindAttribLocation(GLuint program, GLuint index, const GLchar* name) {
GLMessage glmsg;
GLTraceContext *glContext = getGLTraceContext();
glmsg.set_function(GLMessage::glBindAttribLocation);
// copy argument program
GLMessage_DataType *arg_program = glmsg.add_args();
arg_program->set_isarray(false);
arg_program->set_type(GLMessage::DataType::INT);
arg_program->add_intvalue(program);
// copy argument index
GLMessage_DataType *arg_index = glmsg.add_args();
arg_index->set_isarray(false);
arg_index->set_type(GLMessage::DataType::INT);
arg_index->add_intvalue(index);
// copy argument name
GLMessage_DataType *arg_name = glmsg.add_args();
arg_name->set_isarray(false);
arg_name->set_type(GLMessage::DataType::INT);
arg_name->add_intvalue((int)name);
// call function
nsecs_t wallStartTime = systemTime(SYSTEM_TIME_MONOTONIC);
nsecs_t threadStartTime = systemTime(SYSTEM_TIME_THREAD);
glContext->hooks->gl.glBindAttribLocation(program, index, name);
nsecs_t threadEndTime = systemTime(SYSTEM_TIME_THREAD);
nsecs_t wallEndTime = systemTime(SYSTEM_TIME_MONOTONIC);
void *pointerArgs[] = {
(void *) name,
};
fixupGLMessage(glContext, wallStartTime, wallEndTime,
threadStartTime, threadEndTime,
&glmsg, pointerArgs);
glContext->traceGLMessage(&glmsg);
}
void GLTrace_glBindBuffer(GLenum target, GLuint buffer) {
GLMessage glmsg;
GLTraceContext *glContext = getGLTraceContext();
glmsg.set_function(GLMessage::glBindBuffer);
// copy argument target
GLMessage_DataType *arg_target = glmsg.add_args();
arg_target->set_isarray(false);
arg_target->set_type(GLMessage::DataType::ENUM);
arg_target->add_intvalue((int)target);
// copy argument buffer
GLMessage_DataType *arg_buffer = glmsg.add_args();
arg_buffer->set_isarray(false);
arg_buffer->set_type(GLMessage::DataType::INT);
arg_buffer->add_intvalue(buffer);
// call function
nsecs_t wallStartTime = systemTime(SYSTEM_TIME_MONOTONIC);
nsecs_t threadStartTime = systemTime(SYSTEM_TIME_THREAD);
glContext->hooks->gl.glBindBuffer(target, buffer);
nsecs_t threadEndTime = systemTime(SYSTEM_TIME_THREAD);
nsecs_t wallEndTime = systemTime(SYSTEM_TIME_MONOTONIC);
void *pointerArgs[] = {
};
fixupGLMessage(glContext, wallStartTime, wallEndTime,
threadStartTime, threadEndTime,
&glmsg, pointerArgs);
glContext->traceGLMessage(&glmsg);
}
void GLTrace_glBindFramebuffer(GLenum target, GLuint framebuffer) {
GLMessage glmsg;
GLTraceContext *glContext = getGLTraceContext();
glmsg.set_function(GLMessage::glBindFramebuffer);
// copy argument target
GLMessage_DataType *arg_target = glmsg.add_args();
arg_target->set_isarray(false);
arg_target->set_type(GLMessage::DataType::ENUM);
arg_target->add_intvalue((int)target);
// copy argument framebuffer
GLMessage_DataType *arg_framebuffer = glmsg.add_args();
arg_framebuffer->set_isarray(false);
arg_framebuffer->set_type(GLMessage::DataType::INT);
arg_framebuffer->add_intvalue(framebuffer);
// call function
nsecs_t wallStartTime = systemTime(SYSTEM_TIME_MONOTONIC);
nsecs_t threadStartTime = systemTime(SYSTEM_TIME_THREAD);
glContext->hooks->gl.glBindFramebuffer(target, framebuffer);
nsecs_t threadEndTime = systemTime(SYSTEM_TIME_THREAD);
nsecs_t wallEndTime = systemTime(SYSTEM_TIME_MONOTONIC);
void *pointerArgs[] = {
};
fixupGLMessage(glContext, wallStartTime, wallEndTime,
threadStartTime, threadEndTime,
&glmsg, pointerArgs);
glContext->traceGLMessage(&glmsg);
}
void GLTrace_glBindRenderbuffer(GLenum target, GLuint renderbuffer) {
GLMessage glmsg;
GLTraceContext *glContext = getGLTraceContext();
glmsg.set_function(GLMessage::glBindRenderbuffer);
// copy argument target
GLMessage_DataType *arg_target = glmsg.add_args();
arg_target->set_isarray(false);
arg_target->set_type(GLMessage::DataType::ENUM);
arg_target->add_intvalue((int)target);
// copy argument renderbuffer
GLMessage_DataType *arg_renderbuffer = glmsg.add_args();
arg_renderbuffer->set_isarray(false);
arg_renderbuffer->set_type(GLMessage::DataType::INT);
arg_renderbuffer->add_intvalue(renderbuffer);
// call function
nsecs_t wallStartTime = systemTime(SYSTEM_TIME_MONOTONIC);
nsecs_t threadStartTime = systemTime(SYSTEM_TIME_THREAD);
glContext->hooks->gl.glBindRenderbuffer(target, renderbuffer);
nsecs_t threadEndTime = systemTime(SYSTEM_TIME_THREAD);
nsecs_t wallEndTime = systemTime(SYSTEM_TIME_MONOTONIC);
void *pointerArgs[] = {
};
fixupGLMessage(glContext, wallStartTime, wallEndTime,
threadStartTime, threadEndTime,
&glmsg, pointerArgs);
glContext->traceGLMessage(&glmsg);
}
void GLTrace_glBindTexture(GLenum target, GLuint texture) {
GLMessage glmsg;
GLTraceContext *glContext = getGLTraceContext();
glmsg.set_function(GLMessage::glBindTexture);
// copy argument target
GLMessage_DataType *arg_target = glmsg.add_args();
arg_target->set_isarray(false);
arg_target->set_type(GLMessage::DataType::ENUM);
arg_target->add_intvalue((int)target);
// copy argument texture
GLMessage_DataType *arg_texture = glmsg.add_args();
arg_texture->set_isarray(false);
arg_texture->set_type(GLMessage::DataType::INT);
arg_texture->add_intvalue(texture);
// call function
nsecs_t wallStartTime = systemTime(SYSTEM_TIME_MONOTONIC);
nsecs_t threadStartTime = systemTime(SYSTEM_TIME_THREAD);
glContext->hooks->gl.glBindTexture(target, texture);
nsecs_t threadEndTime = systemTime(SYSTEM_TIME_THREAD);
nsecs_t wallEndTime = systemTime(SYSTEM_TIME_MONOTONIC);
void *pointerArgs[] = {
};
fixupGLMessage(glContext, wallStartTime, wallEndTime,
threadStartTime, threadEndTime,
&glmsg, pointerArgs);
glContext->traceGLMessage(&glmsg);
}
void GLTrace_glBlendColor(GLclampf red, GLclampf green, GLclampf blue, GLclampf alpha) {
GLMessage glmsg;
GLTraceContext *glContext = getGLTraceContext();
glmsg.set_function(GLMessage::glBlendColor);
// copy argument red
GLMessage_DataType *arg_red = glmsg.add_args();
arg_red->set_isarray(false);
arg_red->set_type(GLMessage::DataType::FLOAT);
arg_red->add_floatvalue(red);
// copy argument green
GLMessage_DataType *arg_green = glmsg.add_args();
arg_green->set_isarray(false);
arg_green->set_type(GLMessage::DataType::FLOAT);
arg_green->add_floatvalue(green);
// copy argument blue
GLMessage_DataType *arg_blue = glmsg.add_args();
arg_blue->set_isarray(false);
arg_blue->set_type(GLMessage::DataType::FLOAT);
arg_blue->add_floatvalue(blue);
// copy argument alpha
GLMessage_DataType *arg_alpha = glmsg.add_args();
arg_alpha->set_isarray(false);
arg_alpha->set_type(GLMessage::DataType::FLOAT);
arg_alpha->add_floatvalue(alpha);
// call function
nsecs_t wallStartTime = systemTime(SYSTEM_TIME_MONOTONIC);
nsecs_t threadStartTime = systemTime(SYSTEM_TIME_THREAD);
glContext->hooks->gl.glBlendColor(red, green, blue, alpha);
nsecs_t threadEndTime = systemTime(SYSTEM_TIME_THREAD);
nsecs_t wallEndTime = systemTime(SYSTEM_TIME_MONOTONIC);
void *pointerArgs[] = {
};
fixupGLMessage(glContext, wallStartTime, wallEndTime,
threadStartTime, threadEndTime,
&glmsg, pointerArgs);
glContext->traceGLMessage(&glmsg);
}
void GLTrace_glBlendEquation(GLenum mode) {
GLMessage glmsg;
GLTraceContext *glContext = getGLTraceContext();
glmsg.set_function(GLMessage::glBlendEquation);
// copy argument mode
GLMessage_DataType *arg_mode = glmsg.add_args();
arg_mode->set_isarray(false);
arg_mode->set_type(GLMessage::DataType::ENUM);
arg_mode->add_intvalue((int)mode);
// call function
nsecs_t wallStartTime = systemTime(SYSTEM_TIME_MONOTONIC);
nsecs_t threadStartTime = systemTime(SYSTEM_TIME_THREAD);
glContext->hooks->gl.glBlendEquation(mode);
nsecs_t threadEndTime = systemTime(SYSTEM_TIME_THREAD);
nsecs_t wallEndTime = systemTime(SYSTEM_TIME_MONOTONIC);
void *pointerArgs[] = {
};
fixupGLMessage(glContext, wallStartTime, wallEndTime,
threadStartTime, threadEndTime,
&glmsg, pointerArgs);
glContext->traceGLMessage(&glmsg);
}
void GLTrace_glBlendEquationSeparate(GLenum modeRGB, GLenum modeAlpha) {
GLMessage glmsg;
GLTraceContext *glContext = getGLTraceContext();
glmsg.set_function(GLMessage::glBlendEquationSeparate);
// copy argument modeRGB
GLMessage_DataType *arg_modeRGB = glmsg.add_args();
arg_modeRGB->set_isarray(false);
arg_modeRGB->set_type(GLMessage::DataType::ENUM);
arg_modeRGB->add_intvalue((int)modeRGB);
// copy argument modeAlpha
GLMessage_DataType *arg_modeAlpha = glmsg.add_args();
arg_modeAlpha->set_isarray(false);
arg_modeAlpha->set_type(GLMessage::DataType::ENUM);
arg_modeAlpha->add_intvalue((int)modeAlpha);
// call function
nsecs_t wallStartTime = systemTime(SYSTEM_TIME_MONOTONIC);
nsecs_t threadStartTime = systemTime(SYSTEM_TIME_THREAD);
glContext->hooks->gl.glBlendEquationSeparate(modeRGB, modeAlpha);
nsecs_t threadEndTime = systemTime(SYSTEM_TIME_THREAD);
nsecs_t wallEndTime = systemTime(SYSTEM_TIME_MONOTONIC);
void *pointerArgs[] = {
};
fixupGLMessage(glContext, wallStartTime, wallEndTime,
threadStartTime, threadEndTime,
&glmsg, pointerArgs);
glContext->traceGLMessage(&glmsg);
}
void GLTrace_glBlendFunc(GLenum sfactor, GLenum dfactor) {
GLMessage glmsg;
GLTraceContext *glContext = getGLTraceContext();
glmsg.set_function(GLMessage::glBlendFunc);
// copy argument sfactor
GLMessage_DataType *arg_sfactor = glmsg.add_args();
arg_sfactor->set_isarray(false);
arg_sfactor->set_type(GLMessage::DataType::ENUM);
arg_sfactor->add_intvalue((int)sfactor);
// copy argument dfactor
GLMessage_DataType *arg_dfactor = glmsg.add_args();
arg_dfactor->set_isarray(false);
arg_dfactor->set_type(GLMessage::DataType::ENUM);
arg_dfactor->add_intvalue((int)dfactor);
// call function
nsecs_t wallStartTime = systemTime(SYSTEM_TIME_MONOTONIC);
nsecs_t threadStartTime = systemTime(SYSTEM_TIME_THREAD);
glContext->hooks->gl.glBlendFunc(sfactor, dfactor);
nsecs_t threadEndTime = systemTime(SYSTEM_TIME_THREAD);
nsecs_t wallEndTime = systemTime(SYSTEM_TIME_MONOTONIC);
void *pointerArgs[] = {
};
fixupGLMessage(glContext, wallStartTime, wallEndTime,
threadStartTime, threadEndTime,
&glmsg, pointerArgs);
glContext->traceGLMessage(&glmsg);
}
void GLTrace_glBlendFuncSeparate(GLenum srcRGB, GLenum dstRGB, GLenum srcAlpha, GLenum dstAlpha) {
GLMessage glmsg;
GLTraceContext *glContext = getGLTraceContext();
glmsg.set_function(GLMessage::glBlendFuncSeparate);
// copy argument srcRGB
GLMessage_DataType *arg_srcRGB = glmsg.add_args();
arg_srcRGB->set_isarray(false);
arg_srcRGB->set_type(GLMessage::DataType::ENUM);
arg_srcRGB->add_intvalue((int)srcRGB);
// copy argument dstRGB
GLMessage_DataType *arg_dstRGB = glmsg.add_args();
arg_dstRGB->set_isarray(false);
arg_dstRGB->set_type(GLMessage::DataType::ENUM);
arg_dstRGB->add_intvalue((int)dstRGB);
// copy argument srcAlpha
GLMessage_DataType *arg_srcAlpha = glmsg.add_args();
arg_srcAlpha->set_isarray(false);
arg_srcAlpha->set_type(GLMessage::DataType::ENUM);
arg_srcAlpha->add_intvalue((int)srcAlpha);
// copy argument dstAlpha
GLMessage_DataType *arg_dstAlpha = glmsg.add_args();
arg_dstAlpha->set_isarray(false);
arg_dstAlpha->set_type(GLMessage::DataType::ENUM);
arg_dstAlpha->add_intvalue((int)dstAlpha);
// call function
nsecs_t wallStartTime = systemTime(SYSTEM_TIME_MONOTONIC);
nsecs_t threadStartTime = systemTime(SYSTEM_TIME_THREAD);
glContext->hooks->gl.glBlendFuncSeparate(srcRGB, dstRGB, srcAlpha, dstAlpha);
nsecs_t threadEndTime = systemTime(SYSTEM_TIME_THREAD);
nsecs_t wallEndTime = systemTime(SYSTEM_TIME_MONOTONIC);
void *pointerArgs[] = {
};
fixupGLMessage(glContext, wallStartTime, wallEndTime,
threadStartTime, threadEndTime,
&glmsg, pointerArgs);
glContext->traceGLMessage(&glmsg);
}
void GLTrace_glBufferData(GLenum target, GLsizeiptr size, const GLvoid* data, GLenum usage) {
GLMessage glmsg;
GLTraceContext *glContext = getGLTraceContext();
glmsg.set_function(GLMessage::glBufferData);
// copy argument target
GLMessage_DataType *arg_target = glmsg.add_args();
arg_target->set_isarray(false);
arg_target->set_type(GLMessage::DataType::ENUM);
arg_target->add_intvalue((int)target);
// copy argument size
GLMessage_DataType *arg_size = glmsg.add_args();
arg_size->set_isarray(false);
arg_size->set_type(GLMessage::DataType::INT);
arg_size->add_intvalue(size);
// copy argument data
GLMessage_DataType *arg_data = glmsg.add_args();
arg_data->set_isarray(false);
arg_data->set_type(GLMessage::DataType::INT);
arg_data->add_intvalue((int)data);
// copy argument usage
GLMessage_DataType *arg_usage = glmsg.add_args();
arg_usage->set_isarray(false);
arg_usage->set_type(GLMessage::DataType::ENUM);
arg_usage->add_intvalue((int)usage);
// call function
nsecs_t wallStartTime = systemTime(SYSTEM_TIME_MONOTONIC);
nsecs_t threadStartTime = systemTime(SYSTEM_TIME_THREAD);
glContext->hooks->gl.glBufferData(target, size, data, usage);
nsecs_t threadEndTime = systemTime(SYSTEM_TIME_THREAD);
nsecs_t wallEndTime = systemTime(SYSTEM_TIME_MONOTONIC);
void *pointerArgs[] = {
(void *) data,
};
fixupGLMessage(glContext, wallStartTime, wallEndTime,
threadStartTime, threadEndTime,
&glmsg, pointerArgs);
glContext->traceGLMessage(&glmsg);
}
void GLTrace_glBufferSubData(GLenum target, GLintptr offset, GLsizeiptr size, const GLvoid* data) {
GLMessage glmsg;
GLTraceContext *glContext = getGLTraceContext();
glmsg.set_function(GLMessage::glBufferSubData);
// copy argument target
GLMessage_DataType *arg_target = glmsg.add_args();
arg_target->set_isarray(false);
arg_target->set_type(GLMessage::DataType::ENUM);
arg_target->add_intvalue((int)target);
// copy argument offset
GLMessage_DataType *arg_offset = glmsg.add_args();
arg_offset->set_isarray(false);
arg_offset->set_type(GLMessage::DataType::INT);
arg_offset->add_intvalue(offset);
// copy argument size
GLMessage_DataType *arg_size = glmsg.add_args();
arg_size->set_isarray(false);
arg_size->set_type(GLMessage::DataType::INT);
arg_size->add_intvalue(size);
// copy argument data
GLMessage_DataType *arg_data = glmsg.add_args();
arg_data->set_isarray(false);
arg_data->set_type(GLMessage::DataType::INT);
arg_data->add_intvalue((int)data);
// call function
nsecs_t wallStartTime = systemTime(SYSTEM_TIME_MONOTONIC);
nsecs_t threadStartTime = systemTime(SYSTEM_TIME_THREAD);
glContext->hooks->gl.glBufferSubData(target, offset, size, data);
nsecs_t threadEndTime = systemTime(SYSTEM_TIME_THREAD);
nsecs_t wallEndTime = systemTime(SYSTEM_TIME_MONOTONIC);
void *pointerArgs[] = {
(void *) data,
};
fixupGLMessage(glContext, wallStartTime, wallEndTime,
threadStartTime, threadEndTime,
&glmsg, pointerArgs);
glContext->traceGLMessage(&glmsg);
}
GLenum GLTrace_glCheckFramebufferStatus(GLenum target) {
GLMessage glmsg;
GLTraceContext *glContext = getGLTraceContext();
glmsg.set_function(GLMessage::glCheckFramebufferStatus);
// copy argument target
GLMessage_DataType *arg_target = glmsg.add_args();
arg_target->set_isarray(false);
arg_target->set_type(GLMessage::DataType::ENUM);
arg_target->add_intvalue((int)target);
// call function
nsecs_t wallStartTime = systemTime(SYSTEM_TIME_MONOTONIC);
nsecs_t threadStartTime = systemTime(SYSTEM_TIME_THREAD);
GLenum retValue = glContext->hooks->gl.glCheckFramebufferStatus(target);
nsecs_t threadEndTime = systemTime(SYSTEM_TIME_THREAD);
nsecs_t wallEndTime = systemTime(SYSTEM_TIME_MONOTONIC);
// set return value
GLMessage_DataType *rt = glmsg.mutable_returnvalue();
rt->set_isarray(false);
rt->set_type(GLMessage::DataType::ENUM);
rt->add_intvalue((int)retValue);
void *pointerArgs[] = {
};
fixupGLMessage(glContext, wallStartTime, wallEndTime,
threadStartTime, threadEndTime,
&glmsg, pointerArgs);
glContext->traceGLMessage(&glmsg);
return retValue;
}
void GLTrace_glClear(GLbitfield mask) {
GLMessage glmsg;
GLTraceContext *glContext = getGLTraceContext();
glmsg.set_function(GLMessage::glClear);
// copy argument mask
GLMessage_DataType *arg_mask = glmsg.add_args();
arg_mask->set_isarray(false);
arg_mask->set_type(GLMessage::DataType::INT);
arg_mask->add_intvalue(mask);
// call function
nsecs_t wallStartTime = systemTime(SYSTEM_TIME_MONOTONIC);
nsecs_t threadStartTime = systemTime(SYSTEM_TIME_THREAD);
glContext->hooks->gl.glClear(mask);
nsecs_t threadEndTime = systemTime(SYSTEM_TIME_THREAD);
nsecs_t wallEndTime = systemTime(SYSTEM_TIME_MONOTONIC);
void *pointerArgs[] = {
};
fixupGLMessage(glContext, wallStartTime, wallEndTime,
threadStartTime, threadEndTime,
&glmsg, pointerArgs);
glContext->traceGLMessage(&glmsg);
}
void GLTrace_glClearColor(GLclampf red, GLclampf green, GLclampf blue, GLclampf alpha) {
GLMessage glmsg;
GLTraceContext *glContext = getGLTraceContext();
glmsg.set_function(GLMessage::glClearColor);
// copy argument red
GLMessage_DataType *arg_red = glmsg.add_args();
arg_red->set_isarray(false);
arg_red->set_type(GLMessage::DataType::FLOAT);
arg_red->add_floatvalue(red);
// copy argument green
GLMessage_DataType *arg_green = glmsg.add_args();
arg_green->set_isarray(false);
arg_green->set_type(GLMessage::DataType::FLOAT);
arg_green->add_floatvalue(green);
// copy argument blue
GLMessage_DataType *arg_blue = glmsg.add_args();
arg_blue->set_isarray(false);
arg_blue->set_type(GLMessage::DataType::FLOAT);
arg_blue->add_floatvalue(blue);
// copy argument alpha
GLMessage_DataType *arg_alpha = glmsg.add_args();
arg_alpha->set_isarray(false);
arg_alpha->set_type(GLMessage::DataType::FLOAT);
arg_alpha->add_floatvalue(alpha);
// call function
nsecs_t wallStartTime = systemTime(SYSTEM_TIME_MONOTONIC);
nsecs_t threadStartTime = systemTime(SYSTEM_TIME_THREAD);
glContext->hooks->gl.glClearColor(red, green, blue, alpha);
nsecs_t threadEndTime = systemTime(SYSTEM_TIME_THREAD);
nsecs_t wallEndTime = systemTime(SYSTEM_TIME_MONOTONIC);
void *pointerArgs[] = {
};
fixupGLMessage(glContext, wallStartTime, wallEndTime,
threadStartTime, threadEndTime,
&glmsg, pointerArgs);
glContext->traceGLMessage(&glmsg);
}
void GLTrace_glClearDepthf(GLclampf depth) {
GLMessage glmsg;
GLTraceContext *glContext = getGLTraceContext();
glmsg.set_function(GLMessage::glClearDepthf);
// copy argument depth
GLMessage_DataType *arg_depth = glmsg.add_args();
arg_depth->set_isarray(false);
arg_depth->set_type(GLMessage::DataType::FLOAT);
arg_depth->add_floatvalue(depth);
// call function
nsecs_t wallStartTime = systemTime(SYSTEM_TIME_MONOTONIC);
nsecs_t threadStartTime = systemTime(SYSTEM_TIME_THREAD);
glContext->hooks->gl.glClearDepthf(depth);
nsecs_t threadEndTime = systemTime(SYSTEM_TIME_THREAD);
nsecs_t wallEndTime = systemTime(SYSTEM_TIME_MONOTONIC);
void *pointerArgs[] = {
};
fixupGLMessage(glContext, wallStartTime, wallEndTime,
threadStartTime, threadEndTime,
&glmsg, pointerArgs);
glContext->traceGLMessage(&glmsg);
}
void GLTrace_glClearStencil(GLint s) {
GLMessage glmsg;
GLTraceContext *glContext = getGLTraceContext();
glmsg.set_function(GLMessage::glClearStencil);
// copy argument s
GLMessage_DataType *arg_s = glmsg.add_args();
arg_s->set_isarray(false);
arg_s->set_type(GLMessage::DataType::INT);
arg_s->add_intvalue(s);
// call function
nsecs_t wallStartTime = systemTime(SYSTEM_TIME_MONOTONIC);
nsecs_t threadStartTime = systemTime(SYSTEM_TIME_THREAD);
glContext->hooks->gl.glClearStencil(s);
nsecs_t threadEndTime = systemTime(SYSTEM_TIME_THREAD);
nsecs_t wallEndTime = systemTime(SYSTEM_TIME_MONOTONIC);
void *pointerArgs[] = {
};
fixupGLMessage(glContext, wallStartTime, wallEndTime,
threadStartTime, threadEndTime,
&glmsg, pointerArgs);
glContext->traceGLMessage(&glmsg);
}
void GLTrace_glColorMask(GLboolean red, GLboolean green, GLboolean blue, GLboolean alpha) {
GLMessage glmsg;
GLTraceContext *glContext = getGLTraceContext();
glmsg.set_function(GLMessage::glColorMask);
// copy argument red
GLMessage_DataType *arg_red = glmsg.add_args();
arg_red->set_isarray(false);
arg_red->set_type(GLMessage::DataType::BOOL);
arg_red->add_boolvalue(red);
// copy argument green
GLMessage_DataType *arg_green = glmsg.add_args();
arg_green->set_isarray(false);
arg_green->set_type(GLMessage::DataType::BOOL);
arg_green->add_boolvalue(green);
// copy argument blue
GLMessage_DataType *arg_blue = glmsg.add_args();
arg_blue->set_isarray(false);
arg_blue->set_type(GLMessage::DataType::BOOL);
arg_blue->add_boolvalue(blue);
// copy argument alpha
GLMessage_DataType *arg_alpha = glmsg.add_args();
arg_alpha->set_isarray(false);
arg_alpha->set_type(GLMessage::DataType::BOOL);
arg_alpha->add_boolvalue(alpha);
// call function
nsecs_t wallStartTime = systemTime(SYSTEM_TIME_MONOTONIC);
nsecs_t threadStartTime = systemTime(SYSTEM_TIME_THREAD);
glContext->hooks->gl.glColorMask(red, green, blue, alpha);
nsecs_t threadEndTime = systemTime(SYSTEM_TIME_THREAD);
nsecs_t wallEndTime = systemTime(SYSTEM_TIME_MONOTONIC);
void *pointerArgs[] = {
};
fixupGLMessage(glContext, wallStartTime, wallEndTime,
threadStartTime, threadEndTime,
&glmsg, pointerArgs);
glContext->traceGLMessage(&glmsg);
}
void GLTrace_glCompileShader(GLuint shader) {
GLMessage glmsg;
GLTraceContext *glContext = getGLTraceContext();
glmsg.set_function(GLMessage::glCompileShader);
// copy argument shader
GLMessage_DataType *arg_shader = glmsg.add_args();
arg_shader->set_isarray(false);
arg_shader->set_type(GLMessage::DataType::INT);
arg_shader->add_intvalue(shader);
// call function
nsecs_t wallStartTime = systemTime(SYSTEM_TIME_MONOTONIC);
nsecs_t threadStartTime = systemTime(SYSTEM_TIME_THREAD);
glContext->hooks->gl.glCompileShader(shader);
nsecs_t threadEndTime = systemTime(SYSTEM_TIME_THREAD);
nsecs_t wallEndTime = systemTime(SYSTEM_TIME_MONOTONIC);
void *pointerArgs[] = {
};
fixupGLMessage(glContext, wallStartTime, wallEndTime,
threadStartTime, threadEndTime,
&glmsg, pointerArgs);
glContext->traceGLMessage(&glmsg);
}
void GLTrace_glCompressedTexImage2D(GLenum target, GLint level, GLenum internalformat, GLsizei width, GLsizei height, GLint border, GLsizei imageSize, const GLvoid* data) {
GLMessage glmsg;
GLTraceContext *glContext = getGLTraceContext();
glmsg.set_function(GLMessage::glCompressedTexImage2D);
// copy argument target
GLMessage_DataType *arg_target = glmsg.add_args();
arg_target->set_isarray(false);
arg_target->set_type(GLMessage::DataType::ENUM);
arg_target->add_intvalue((int)target);
// copy argument level
GLMessage_DataType *arg_level = glmsg.add_args();
arg_level->set_isarray(false);
arg_level->set_type(GLMessage::DataType::INT);
arg_level->add_intvalue(level);
// copy argument internalformat
GLMessage_DataType *arg_internalformat = glmsg.add_args();
arg_internalformat->set_isarray(false);
arg_internalformat->set_type(GLMessage::DataType::ENUM);
arg_internalformat->add_intvalue((int)internalformat);
// copy argument width
GLMessage_DataType *arg_width = glmsg.add_args();
arg_width->set_isarray(false);
arg_width->set_type(GLMessage::DataType::INT);
arg_width->add_intvalue(width);
// copy argument height
GLMessage_DataType *arg_height = glmsg.add_args();
arg_height->set_isarray(false);
arg_height->set_type(GLMessage::DataType::INT);
arg_height->add_intvalue(height);
// copy argument border
GLMessage_DataType *arg_border = glmsg.add_args();
arg_border->set_isarray(false);
arg_border->set_type(GLMessage::DataType::INT);
arg_border->add_intvalue(border);
// copy argument imageSize
GLMessage_DataType *arg_imageSize = glmsg.add_args();
arg_imageSize->set_isarray(false);
arg_imageSize->set_type(GLMessage::DataType::INT);
arg_imageSize->add_intvalue(imageSize);
// copy argument data
GLMessage_DataType *arg_data = glmsg.add_args();
arg_data->set_isarray(false);
arg_data->set_type(GLMessage::DataType::INT);
arg_data->add_intvalue((int)data);
// call function
nsecs_t wallStartTime = systemTime(SYSTEM_TIME_MONOTONIC);
nsecs_t threadStartTime = systemTime(SYSTEM_TIME_THREAD);
glContext->hooks->gl.glCompressedTexImage2D(target, level, internalformat, width, height, border, imageSize, data);
nsecs_t threadEndTime = systemTime(SYSTEM_TIME_THREAD);
nsecs_t wallEndTime = systemTime(SYSTEM_TIME_MONOTONIC);
void *pointerArgs[] = {
(void *) data,
};
fixupGLMessage(glContext, wallStartTime, wallEndTime,
threadStartTime, threadEndTime,
&glmsg, pointerArgs);
glContext->traceGLMessage(&glmsg);
}
void GLTrace_glCompressedTexSubImage2D(GLenum target, GLint level, GLint xoffset, GLint yoffset, GLsizei width, GLsizei height, GLenum format, GLsizei imageSize, const GLvoid* data) {
GLMessage glmsg;
GLTraceContext *glContext = getGLTraceContext();
glmsg.set_function(GLMessage::glCompressedTexSubImage2D);
// copy argument target
GLMessage_DataType *arg_target = glmsg.add_args();
arg_target->set_isarray(false);
arg_target->set_type(GLMessage::DataType::ENUM);
arg_target->add_intvalue((int)target);
// copy argument level
GLMessage_DataType *arg_level = glmsg.add_args();
arg_level->set_isarray(false);
arg_level->set_type(GLMessage::DataType::INT);
arg_level->add_intvalue(level);
// copy argument xoffset
GLMessage_DataType *arg_xoffset = glmsg.add_args();
arg_xoffset->set_isarray(false);
arg_xoffset->set_type(GLMessage::DataType::INT);
arg_xoffset->add_intvalue(xoffset);
// copy argument yoffset
GLMessage_DataType *arg_yoffset = glmsg.add_args();
arg_yoffset->set_isarray(false);
arg_yoffset->set_type(GLMessage::DataType::INT);
arg_yoffset->add_intvalue(yoffset);
// copy argument width
GLMessage_DataType *arg_width = glmsg.add_args();
arg_width->set_isarray(false);
arg_width->set_type(GLMessage::DataType::INT);
arg_width->add_intvalue(width);
// copy argument height
GLMessage_DataType *arg_height = glmsg.add_args();
arg_height->set_isarray(false);
arg_height->set_type(GLMessage::DataType::INT);
arg_height->add_intvalue(height);
// copy argument format
GLMessage_DataType *arg_format = glmsg.add_args();
arg_format->set_isarray(false);
arg_format->set_type(GLMessage::DataType::ENUM);
arg_format->add_intvalue((int)format);
// copy argument imageSize
GLMessage_DataType *arg_imageSize = glmsg.add_args();
arg_imageSize->set_isarray(false);
arg_imageSize->set_type(GLMessage::DataType::INT);
arg_imageSize->add_intvalue(imageSize);
// copy argument data
GLMessage_DataType *arg_data = glmsg.add_args();
arg_data->set_isarray(false);
arg_data->set_type(GLMessage::DataType::INT);
arg_data->add_intvalue((int)data);
// call function
nsecs_t wallStartTime = systemTime(SYSTEM_TIME_MONOTONIC);
nsecs_t threadStartTime = systemTime(SYSTEM_TIME_THREAD);
glContext->hooks->gl.glCompressedTexSubImage2D(target, level, xoffset, yoffset, width, height, format, imageSize, data);
nsecs_t threadEndTime = systemTime(SYSTEM_TIME_THREAD);
nsecs_t wallEndTime = systemTime(SYSTEM_TIME_MONOTONIC);
void *pointerArgs[] = {
(void *) data,
};
fixupGLMessage(glContext, wallStartTime, wallEndTime,
threadStartTime, threadEndTime,
&glmsg, pointerArgs);
glContext->traceGLMessage(&glmsg);
}
void GLTrace_glCopyTexImage2D(GLenum target, GLint level, GLenum internalformat, GLint x, GLint y, GLsizei width, GLsizei height, GLint border) {
GLMessage glmsg;
GLTraceContext *glContext = getGLTraceContext();
glmsg.set_function(GLMessage::glCopyTexImage2D);
// copy argument target
GLMessage_DataType *arg_target = glmsg.add_args();
arg_target->set_isarray(false);
arg_target->set_type(GLMessage::DataType::ENUM);
arg_target->add_intvalue((int)target);
// copy argument level
GLMessage_DataType *arg_level = glmsg.add_args();
arg_level->set_isarray(false);
arg_level->set_type(GLMessage::DataType::INT);
arg_level->add_intvalue(level);
// copy argument internalformat
GLMessage_DataType *arg_internalformat = glmsg.add_args();
arg_internalformat->set_isarray(false);
arg_internalformat->set_type(GLMessage::DataType::ENUM);
arg_internalformat->add_intvalue((int)internalformat);
// copy argument x
GLMessage_DataType *arg_x = glmsg.add_args();
arg_x->set_isarray(false);
arg_x->set_type(GLMessage::DataType::INT);
arg_x->add_intvalue(x);
// copy argument y
GLMessage_DataType *arg_y = glmsg.add_args();
arg_y->set_isarray(false);
arg_y->set_type(GLMessage::DataType::INT);
arg_y->add_intvalue(y);
// copy argument width
GLMessage_DataType *arg_width = glmsg.add_args();
arg_width->set_isarray(false);
arg_width->set_type(GLMessage::DataType::INT);
arg_width->add_intvalue(width);
// copy argument height
GLMessage_DataType *arg_height = glmsg.add_args();
arg_height->set_isarray(false);
arg_height->set_type(GLMessage::DataType::INT);
arg_height->add_intvalue(height);
// copy argument border
GLMessage_DataType *arg_border = glmsg.add_args();
arg_border->set_isarray(false);
arg_border->set_type(GLMessage::DataType::INT);
arg_border->add_intvalue(border);
// call function
nsecs_t wallStartTime = systemTime(SYSTEM_TIME_MONOTONIC);
nsecs_t threadStartTime = systemTime(SYSTEM_TIME_THREAD);
glContext->hooks->gl.glCopyTexImage2D(target, level, internalformat, x, y, width, height, border);
nsecs_t threadEndTime = systemTime(SYSTEM_TIME_THREAD);
nsecs_t wallEndTime = systemTime(SYSTEM_TIME_MONOTONIC);
void *pointerArgs[] = {
};
fixupGLMessage(glContext, wallStartTime, wallEndTime,
threadStartTime, threadEndTime,
&glmsg, pointerArgs);
glContext->traceGLMessage(&glmsg);
}
void GLTrace_glCopyTexSubImage2D(GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint x, GLint y, GLsizei width, GLsizei height) {
GLMessage glmsg;
GLTraceContext *glContext = getGLTraceContext();
glmsg.set_function(GLMessage::glCopyTexSubImage2D);
// copy argument target
GLMessage_DataType *arg_target = glmsg.add_args();
arg_target->set_isarray(false);
arg_target->set_type(GLMessage::DataType::ENUM);
arg_target->add_intvalue((int)target);
// copy argument level
GLMessage_DataType *arg_level = glmsg.add_args();
arg_level->set_isarray(false);
arg_level->set_type(GLMessage::DataType::INT);
arg_level->add_intvalue(level);
// copy argument xoffset
GLMessage_DataType *arg_xoffset = glmsg.add_args();
arg_xoffset->set_isarray(false);
arg_xoffset->set_type(GLMessage::DataType::INT);
arg_xoffset->add_intvalue(xoffset);
// copy argument yoffset
GLMessage_DataType *arg_yoffset = glmsg.add_args();
arg_yoffset->set_isarray(false);
arg_yoffset->set_type(GLMessage::DataType::INT);
arg_yoffset->add_intvalue(yoffset);
// copy argument x
GLMessage_DataType *arg_x = glmsg.add_args();
arg_x->set_isarray(false);
arg_x->set_type(GLMessage::DataType::INT);
arg_x->add_intvalue(x);
// copy argument y
GLMessage_DataType *arg_y = glmsg.add_args();
arg_y->set_isarray(false);
arg_y->set_type(GLMessage::DataType::INT);
arg_y->add_intvalue(y);
// copy argument width
GLMessage_DataType *arg_width = glmsg.add_args();
arg_width->set_isarray(false);
arg_width->set_type(GLMessage::DataType::INT);
arg_width->add_intvalue(width);
// copy argument height
GLMessage_DataType *arg_height = glmsg.add_args();
arg_height->set_isarray(false);
arg_height->set_type(GLMessage::DataType::INT);
arg_height->add_intvalue(height);
// call function
nsecs_t wallStartTime = systemTime(SYSTEM_TIME_MONOTONIC);
nsecs_t threadStartTime = systemTime(SYSTEM_TIME_THREAD);
glContext->hooks->gl.glCopyTexSubImage2D(target, level, xoffset, yoffset, x, y, width, height);
nsecs_t threadEndTime = systemTime(SYSTEM_TIME_THREAD);
nsecs_t wallEndTime = systemTime(SYSTEM_TIME_MONOTONIC);
void *pointerArgs[] = {
};
fixupGLMessage(glContext, wallStartTime, wallEndTime,
threadStartTime, threadEndTime,
&glmsg, pointerArgs);
glContext->traceGLMessage(&glmsg);
}
GLuint GLTrace_glCreateProgram(void) {
GLMessage glmsg;
GLTraceContext *glContext = getGLTraceContext();
glmsg.set_function(GLMessage::glCreateProgram);
// call function
nsecs_t wallStartTime = systemTime(SYSTEM_TIME_MONOTONIC);
nsecs_t threadStartTime = systemTime(SYSTEM_TIME_THREAD);
GLuint retValue = glContext->hooks->gl.glCreateProgram();
nsecs_t threadEndTime = systemTime(SYSTEM_TIME_THREAD);
nsecs_t wallEndTime = systemTime(SYSTEM_TIME_MONOTONIC);
// set return value
GLMessage_DataType *rt = glmsg.mutable_returnvalue();
rt->set_isarray(false);
rt->set_type(GLMessage::DataType::INT);
rt->add_intvalue(retValue);
void *pointerArgs[] = {
};
fixupGLMessage(glContext, wallStartTime, wallEndTime,
threadStartTime, threadEndTime,
&glmsg, pointerArgs);
glContext->traceGLMessage(&glmsg);
return retValue;
}
GLuint GLTrace_glCreateShader(GLenum type) {
GLMessage glmsg;
GLTraceContext *glContext = getGLTraceContext();
glmsg.set_function(GLMessage::glCreateShader);
// copy argument type
GLMessage_DataType *arg_type = glmsg.add_args();
arg_type->set_isarray(false);
arg_type->set_type(GLMessage::DataType::ENUM);
arg_type->add_intvalue((int)type);
// call function
nsecs_t wallStartTime = systemTime(SYSTEM_TIME_MONOTONIC);
nsecs_t threadStartTime = systemTime(SYSTEM_TIME_THREAD);
GLuint retValue = glContext->hooks->gl.glCreateShader(type);
nsecs_t threadEndTime = systemTime(SYSTEM_TIME_THREAD);
nsecs_t wallEndTime = systemTime(SYSTEM_TIME_MONOTONIC);
// set return value
GLMessage_DataType *rt = glmsg.mutable_returnvalue();
rt->set_isarray(false);
rt->set_type(GLMessage::DataType::INT);
rt->add_intvalue(retValue);
void *pointerArgs[] = {
};
fixupGLMessage(glContext, wallStartTime, wallEndTime,
threadStartTime, threadEndTime,
&glmsg, pointerArgs);
glContext->traceGLMessage(&glmsg);
return retValue;
}
void GLTrace_glCullFace(GLenum mode) {
GLMessage glmsg;
GLTraceContext *glContext = getGLTraceContext();
glmsg.set_function(GLMessage::glCullFace);
// copy argument mode
GLMessage_DataType *arg_mode = glmsg.add_args();
arg_mode->set_isarray(false);
arg_mode->set_type(GLMessage::DataType::ENUM);
arg_mode->add_intvalue((int)mode);
// call function
nsecs_t wallStartTime = systemTime(SYSTEM_TIME_MONOTONIC);
nsecs_t threadStartTime = systemTime(SYSTEM_TIME_THREAD);
glContext->hooks->gl.glCullFace(mode);
nsecs_t threadEndTime = systemTime(SYSTEM_TIME_THREAD);
nsecs_t wallEndTime = systemTime(SYSTEM_TIME_MONOTONIC);
void *pointerArgs[] = {
};
fixupGLMessage(glContext, wallStartTime, wallEndTime,
threadStartTime, threadEndTime,
&glmsg, pointerArgs);
glContext->traceGLMessage(&glmsg);
}
void GLTrace_glDeleteBuffers(GLsizei n, const GLuint* buffers) {
GLMessage glmsg;
GLTraceContext *glContext = getGLTraceContext();
glmsg.set_function(GLMessage::glDeleteBuffers);
// copy argument n
GLMessage_DataType *arg_n = glmsg.add_args();
arg_n->set_isarray(false);
arg_n->set_type(GLMessage::DataType::INT);
arg_n->add_intvalue(n);
// copy argument buffers
GLMessage_DataType *arg_buffers = glmsg.add_args();
arg_buffers->set_isarray(false);
arg_buffers->set_type(GLMessage::DataType::INT);
arg_buffers->add_intvalue((int)buffers);
// call function
nsecs_t wallStartTime = systemTime(SYSTEM_TIME_MONOTONIC);
nsecs_t threadStartTime = systemTime(SYSTEM_TIME_THREAD);
glContext->hooks->gl.glDeleteBuffers(n, buffers);
nsecs_t threadEndTime = systemTime(SYSTEM_TIME_THREAD);
nsecs_t wallEndTime = systemTime(SYSTEM_TIME_MONOTONIC);
void *pointerArgs[] = {
(void *) buffers,
};
fixupGLMessage(glContext, wallStartTime, wallEndTime,
threadStartTime, threadEndTime,
&glmsg, pointerArgs);
glContext->traceGLMessage(&glmsg);
}
void GLTrace_glDeleteFramebuffers(GLsizei n, const GLuint* framebuffers) {
GLMessage glmsg;
GLTraceContext *glContext = getGLTraceContext();
glmsg.set_function(GLMessage::glDeleteFramebuffers);
// copy argument n
GLMessage_DataType *arg_n = glmsg.add_args();
arg_n->set_isarray(false);
arg_n->set_type(GLMessage::DataType::INT);
arg_n->add_intvalue(n);
// copy argument framebuffers
GLMessage_DataType *arg_framebuffers = glmsg.add_args();
arg_framebuffers->set_isarray(false);
arg_framebuffers->set_type(GLMessage::DataType::INT);
arg_framebuffers->add_intvalue((int)framebuffers);
// call function
nsecs_t wallStartTime = systemTime(SYSTEM_TIME_MONOTONIC);
nsecs_t threadStartTime = systemTime(SYSTEM_TIME_THREAD);
glContext->hooks->gl.glDeleteFramebuffers(n, framebuffers);
nsecs_t threadEndTime = systemTime(SYSTEM_TIME_THREAD);
nsecs_t wallEndTime = systemTime(SYSTEM_TIME_MONOTONIC);
void *pointerArgs[] = {
(void *) framebuffers,
};
fixupGLMessage(glContext, wallStartTime, wallEndTime,
threadStartTime, threadEndTime,
&glmsg, pointerArgs);
glContext->traceGLMessage(&glmsg);
}
void GLTrace_glDeleteProgram(GLuint program) {
GLMessage glmsg;
GLTraceContext *glContext = getGLTraceContext();
glmsg.set_function(GLMessage::glDeleteProgram);
// copy argument program
GLMessage_DataType *arg_program = glmsg.add_args();
arg_program->set_isarray(false);
arg_program->set_type(GLMessage::DataType::INT);
arg_program->add_intvalue(program);
// call function
nsecs_t wallStartTime = systemTime(SYSTEM_TIME_MONOTONIC);
nsecs_t threadStartTime = systemTime(SYSTEM_TIME_THREAD);
glContext->hooks->gl.glDeleteProgram(program);
nsecs_t threadEndTime = systemTime(SYSTEM_TIME_THREAD);
nsecs_t wallEndTime = systemTime(SYSTEM_TIME_MONOTONIC);
void *pointerArgs[] = {
};
fixupGLMessage(glContext, wallStartTime, wallEndTime,
threadStartTime, threadEndTime,
&glmsg, pointerArgs);
glContext->traceGLMessage(&glmsg);
}
void GLTrace_glDeleteRenderbuffers(GLsizei n, const GLuint* renderbuffers) {
GLMessage glmsg;
GLTraceContext *glContext = getGLTraceContext();
glmsg.set_function(GLMessage::glDeleteRenderbuffers);
// copy argument n
GLMessage_DataType *arg_n = glmsg.add_args();
arg_n->set_isarray(false);
arg_n->set_type(GLMessage::DataType::INT);
arg_n->add_intvalue(n);
// copy argument renderbuffers
GLMessage_DataType *arg_renderbuffers = glmsg.add_args();
arg_renderbuffers->set_isarray(false);
arg_renderbuffers->set_type(GLMessage::DataType::INT);
arg_renderbuffers->add_intvalue((int)renderbuffers);
// call function
nsecs_t wallStartTime = systemTime(SYSTEM_TIME_MONOTONIC);
nsecs_t threadStartTime = systemTime(SYSTEM_TIME_THREAD);
glContext->hooks->gl.glDeleteRenderbuffers(n, renderbuffers);
nsecs_t threadEndTime = systemTime(SYSTEM_TIME_THREAD);
nsecs_t wallEndTime = systemTime(SYSTEM_TIME_MONOTONIC);
void *pointerArgs[] = {
(void *) renderbuffers,
};
fixupGLMessage(glContext, wallStartTime, wallEndTime,
threadStartTime, threadEndTime,
&glmsg, pointerArgs);
glContext->traceGLMessage(&glmsg);
}
void GLTrace_glDeleteShader(GLuint shader) {
GLMessage glmsg;
GLTraceContext *glContext = getGLTraceContext();
glmsg.set_function(GLMessage::glDeleteShader);
// copy argument shader
GLMessage_DataType *arg_shader = glmsg.add_args();
arg_shader->set_isarray(false);
arg_shader->set_type(GLMessage::DataType::INT);
arg_shader->add_intvalue(shader);
// call function
nsecs_t wallStartTime = systemTime(SYSTEM_TIME_MONOTONIC);
nsecs_t threadStartTime = systemTime(SYSTEM_TIME_THREAD);
glContext->hooks->gl.glDeleteShader(shader);
nsecs_t threadEndTime = systemTime(SYSTEM_TIME_THREAD);
nsecs_t wallEndTime = systemTime(SYSTEM_TIME_MONOTONIC);
void *pointerArgs[] = {
};
fixupGLMessage(glContext, wallStartTime, wallEndTime,
threadStartTime, threadEndTime,
&glmsg, pointerArgs);
glContext->traceGLMessage(&glmsg);
}
void GLTrace_glDeleteTextures(GLsizei n, const GLuint* textures) {
GLMessage glmsg;
GLTraceContext *glContext = getGLTraceContext();
glmsg.set_function(GLMessage::glDeleteTextures);
// copy argument n
GLMessage_DataType *arg_n = glmsg.add_args();
arg_n->set_isarray(false);
arg_n->set_type(GLMessage::DataType::INT);
arg_n->add_intvalue(n);
// copy argument textures
GLMessage_DataType *arg_textures = glmsg.add_args();
arg_textures->set_isarray(false);
arg_textures->set_type(GLMessage::DataType::INT);
arg_textures->add_intvalue((int)textures);
// call function
nsecs_t wallStartTime = systemTime(SYSTEM_TIME_MONOTONIC);
nsecs_t threadStartTime = systemTime(SYSTEM_TIME_THREAD);
glContext->hooks->gl.glDeleteTextures(n, textures);
nsecs_t threadEndTime = systemTime(SYSTEM_TIME_THREAD);
nsecs_t wallEndTime = systemTime(SYSTEM_TIME_MONOTONIC);
void *pointerArgs[] = {
(void *) textures,
};
fixupGLMessage(glContext, wallStartTime, wallEndTime,
threadStartTime, threadEndTime,
&glmsg, pointerArgs);
glContext->traceGLMessage(&glmsg);
}
void GLTrace_glDepthFunc(GLenum func) {
GLMessage glmsg;
GLTraceContext *glContext = getGLTraceContext();
glmsg.set_function(GLMessage::glDepthFunc);
// copy argument func
GLMessage_DataType *arg_func = glmsg.add_args();
arg_func->set_isarray(false);
arg_func->set_type(GLMessage::DataType::ENUM);
arg_func->add_intvalue((int)func);
// call function
nsecs_t wallStartTime = systemTime(SYSTEM_TIME_MONOTONIC);
nsecs_t threadStartTime = systemTime(SYSTEM_TIME_THREAD);
glContext->hooks->gl.glDepthFunc(func);
nsecs_t threadEndTime = systemTime(SYSTEM_TIME_THREAD);
nsecs_t wallEndTime = systemTime(SYSTEM_TIME_MONOTONIC);
void *pointerArgs[] = {
};
fixupGLMessage(glContext, wallStartTime, wallEndTime,
threadStartTime, threadEndTime,
&glmsg, pointerArgs);
glContext->traceGLMessage(&glmsg);
}
void GLTrace_glDepthMask(GLboolean flag) {
GLMessage glmsg;
GLTraceContext *glContext = getGLTraceContext();
glmsg.set_function(GLMessage::glDepthMask);
// copy argument flag
GLMessage_DataType *arg_flag = glmsg.add_args();
arg_flag->set_isarray(false);
arg_flag->set_type(GLMessage::DataType::BOOL);
arg_flag->add_boolvalue(flag);
// call function
nsecs_t wallStartTime = systemTime(SYSTEM_TIME_MONOTONIC);
nsecs_t threadStartTime = systemTime(SYSTEM_TIME_THREAD);
glContext->hooks->gl.glDepthMask(flag);
nsecs_t threadEndTime = systemTime(SYSTEM_TIME_THREAD);
nsecs_t wallEndTime = systemTime(SYSTEM_TIME_MONOTONIC);
void *pointerArgs[] = {
};
fixupGLMessage(glContext, wallStartTime, wallEndTime,
threadStartTime, threadEndTime,
&glmsg, pointerArgs);
glContext->traceGLMessage(&glmsg);
}
void GLTrace_glDepthRangef(GLclampf zNear, GLclampf zFar) {
GLMessage glmsg;
GLTraceContext *glContext = getGLTraceContext();
glmsg.set_function(GLMessage::glDepthRangef);
// copy argument zNear
GLMessage_DataType *arg_zNear = glmsg.add_args();
arg_zNear->set_isarray(false);
arg_zNear->set_type(GLMessage::DataType::FLOAT);
arg_zNear->add_floatvalue(zNear);
// copy argument zFar
GLMessage_DataType *arg_zFar = glmsg.add_args();
arg_zFar->set_isarray(false);
arg_zFar->set_type(GLMessage::DataType::FLOAT);
arg_zFar->add_floatvalue(zFar);
// call function
nsecs_t wallStartTime = systemTime(SYSTEM_TIME_MONOTONIC);
nsecs_t threadStartTime = systemTime(SYSTEM_TIME_THREAD);
glContext->hooks->gl.glDepthRangef(zNear, zFar);
nsecs_t threadEndTime = systemTime(SYSTEM_TIME_THREAD);
nsecs_t wallEndTime = systemTime(SYSTEM_TIME_MONOTONIC);
void *pointerArgs[] = {
};
fixupGLMessage(glContext, wallStartTime, wallEndTime,
threadStartTime, threadEndTime,
&glmsg, pointerArgs);
glContext->traceGLMessage(&glmsg);
}
void GLTrace_glDetachShader(GLuint program, GLuint shader) {
GLMessage glmsg;
GLTraceContext *glContext = getGLTraceContext();
glmsg.set_function(GLMessage::glDetachShader);
// copy argument program
GLMessage_DataType *arg_program = glmsg.add_args();
arg_program->set_isarray(false);
arg_program->set_type(GLMessage::DataType::INT);
arg_program->add_intvalue(program);
// copy argument shader
GLMessage_DataType *arg_shader = glmsg.add_args();
arg_shader->set_isarray(false);
arg_shader->set_type(GLMessage::DataType::INT);
arg_shader->add_intvalue(shader);
// call function
nsecs_t wallStartTime = systemTime(SYSTEM_TIME_MONOTONIC);
nsecs_t threadStartTime = systemTime(SYSTEM_TIME_THREAD);
glContext->hooks->gl.glDetachShader(program, shader);
nsecs_t threadEndTime = systemTime(SYSTEM_TIME_THREAD);
nsecs_t wallEndTime = systemTime(SYSTEM_TIME_MONOTONIC);
void *pointerArgs[] = {
};
fixupGLMessage(glContext, wallStartTime, wallEndTime,
threadStartTime, threadEndTime,
&glmsg, pointerArgs);
glContext->traceGLMessage(&glmsg);
}
void GLTrace_glDisable(GLenum cap) {
GLMessage glmsg;
GLTraceContext *glContext = getGLTraceContext();
glmsg.set_function(GLMessage::glDisable);
// copy argument cap
GLMessage_DataType *arg_cap = glmsg.add_args();
arg_cap->set_isarray(false);
arg_cap->set_type(GLMessage::DataType::ENUM);
arg_cap->add_intvalue((int)cap);
// call function
nsecs_t wallStartTime = systemTime(SYSTEM_TIME_MONOTONIC);
nsecs_t threadStartTime = systemTime(SYSTEM_TIME_THREAD);
glContext->hooks->gl.glDisable(cap);
nsecs_t threadEndTime = systemTime(SYSTEM_TIME_THREAD);
nsecs_t wallEndTime = systemTime(SYSTEM_TIME_MONOTONIC);
void *pointerArgs[] = {
};
fixupGLMessage(glContext, wallStartTime, wallEndTime,
threadStartTime, threadEndTime,
&glmsg, pointerArgs);
glContext->traceGLMessage(&glmsg);
}
void GLTrace_glDisableVertexAttribArray(GLuint index) {
GLMessage glmsg;
GLTraceContext *glContext = getGLTraceContext();
glmsg.set_function(GLMessage::glDisableVertexAttribArray);
// copy argument index
GLMessage_DataType *arg_index = glmsg.add_args();
arg_index->set_isarray(false);
arg_index->set_type(GLMessage::DataType::INT);
arg_index->add_intvalue(index);
// call function
nsecs_t wallStartTime = systemTime(SYSTEM_TIME_MONOTONIC);
nsecs_t threadStartTime = systemTime(SYSTEM_TIME_THREAD);
glContext->hooks->gl.glDisableVertexAttribArray(index);
nsecs_t threadEndTime = systemTime(SYSTEM_TIME_THREAD);
nsecs_t wallEndTime = systemTime(SYSTEM_TIME_MONOTONIC);
void *pointerArgs[] = {
};
fixupGLMessage(glContext, wallStartTime, wallEndTime,
threadStartTime, threadEndTime,
&glmsg, pointerArgs);
glContext->traceGLMessage(&glmsg);
}
void GLTrace_glDrawArrays(GLenum mode, GLint first, GLsizei count) {
GLMessage glmsg;
GLTraceContext *glContext = getGLTraceContext();
glmsg.set_function(GLMessage::glDrawArrays);
// copy argument mode
GLMessage_DataType *arg_mode = glmsg.add_args();
arg_mode->set_isarray(false);
arg_mode->set_type(GLMessage::DataType::ENUM);
arg_mode->add_intvalue((int)mode);
// copy argument first
GLMessage_DataType *arg_first = glmsg.add_args();
arg_first->set_isarray(false);
arg_first->set_type(GLMessage::DataType::INT);
arg_first->add_intvalue(first);
// copy argument count
GLMessage_DataType *arg_count = glmsg.add_args();
arg_count->set_isarray(false);
arg_count->set_type(GLMessage::DataType::INT);
arg_count->add_intvalue(count);
// call function
nsecs_t wallStartTime = systemTime(SYSTEM_TIME_MONOTONIC);
nsecs_t threadStartTime = systemTime(SYSTEM_TIME_THREAD);
glContext->hooks->gl.glDrawArrays(mode, first, count);
nsecs_t threadEndTime = systemTime(SYSTEM_TIME_THREAD);
nsecs_t wallEndTime = systemTime(SYSTEM_TIME_MONOTONIC);
void *pointerArgs[] = {
};
fixupGLMessage(glContext, wallStartTime, wallEndTime,
threadStartTime, threadEndTime,
&glmsg, pointerArgs);
glContext->traceGLMessage(&glmsg);
}
void GLTrace_glDrawElements(GLenum mode, GLsizei count, GLenum type, const GLvoid* indices) {
GLMessage glmsg;
GLTraceContext *glContext = getGLTraceContext();
glmsg.set_function(GLMessage::glDrawElements);
// copy argument mode
GLMessage_DataType *arg_mode = glmsg.add_args();
arg_mode->set_isarray(false);
arg_mode->set_type(GLMessage::DataType::ENUM);
arg_mode->add_intvalue((int)mode);
// copy argument count
GLMessage_DataType *arg_count = glmsg.add_args();
arg_count->set_isarray(false);
arg_count->set_type(GLMessage::DataType::INT);
arg_count->add_intvalue(count);
// copy argument type
GLMessage_DataType *arg_type = glmsg.add_args();
arg_type->set_isarray(false);
arg_type->set_type(GLMessage::DataType::ENUM);
arg_type->add_intvalue((int)type);
// copy argument indices
GLMessage_DataType *arg_indices = glmsg.add_args();
arg_indices->set_isarray(false);
arg_indices->set_type(GLMessage::DataType::INT);
arg_indices->add_intvalue((int)indices);
// call function
nsecs_t wallStartTime = systemTime(SYSTEM_TIME_MONOTONIC);
nsecs_t threadStartTime = systemTime(SYSTEM_TIME_THREAD);
glContext->hooks->gl.glDrawElements(mode, count, type, indices);
nsecs_t threadEndTime = systemTime(SYSTEM_TIME_THREAD);
nsecs_t wallEndTime = systemTime(SYSTEM_TIME_MONOTONIC);
void *pointerArgs[] = {
(void *) indices,
};
fixupGLMessage(glContext, wallStartTime, wallEndTime,
threadStartTime, threadEndTime,
&glmsg, pointerArgs);
glContext->traceGLMessage(&glmsg);
}
void GLTrace_glEnable(GLenum cap) {
GLMessage glmsg;
GLTraceContext *glContext = getGLTraceContext();
glmsg.set_function(GLMessage::glEnable);
// copy argument cap
GLMessage_DataType *arg_cap = glmsg.add_args();
arg_cap->set_isarray(false);
arg_cap->set_type(GLMessage::DataType::ENUM);
arg_cap->add_intvalue((int)cap);
// call function
nsecs_t wallStartTime = systemTime(SYSTEM_TIME_MONOTONIC);
nsecs_t threadStartTime = systemTime(SYSTEM_TIME_THREAD);
glContext->hooks->gl.glEnable(cap);
nsecs_t threadEndTime = systemTime(SYSTEM_TIME_THREAD);
nsecs_t wallEndTime = systemTime(SYSTEM_TIME_MONOTONIC);
void *pointerArgs[] = {
};
fixupGLMessage(glContext, wallStartTime, wallEndTime,
threadStartTime, threadEndTime,
&glmsg, pointerArgs);
glContext->traceGLMessage(&glmsg);
}
void GLTrace_glEnableVertexAttribArray(GLuint index) {
GLMessage glmsg;
GLTraceContext *glContext = getGLTraceContext();
glmsg.set_function(GLMessage::glEnableVertexAttribArray);
// copy argument index
GLMessage_DataType *arg_index = glmsg.add_args();
arg_index->set_isarray(false);
arg_index->set_type(GLMessage::DataType::INT);
arg_index->add_intvalue(index);
// call function
nsecs_t wallStartTime = systemTime(SYSTEM_TIME_MONOTONIC);
nsecs_t threadStartTime = systemTime(SYSTEM_TIME_THREAD);
glContext->hooks->gl.glEnableVertexAttribArray(index);
nsecs_t threadEndTime = systemTime(SYSTEM_TIME_THREAD);
nsecs_t wallEndTime = systemTime(SYSTEM_TIME_MONOTONIC);
void *pointerArgs[] = {
};
fixupGLMessage(glContext, wallStartTime, wallEndTime,
threadStartTime, threadEndTime,
&glmsg, pointerArgs);
glContext->traceGLMessage(&glmsg);
}
void GLTrace_glFinish(void) {
GLMessage glmsg;
GLTraceContext *glContext = getGLTraceContext();
glmsg.set_function(GLMessage::glFinish);
// call function
nsecs_t wallStartTime = systemTime(SYSTEM_TIME_MONOTONIC);
nsecs_t threadStartTime = systemTime(SYSTEM_TIME_THREAD);
glContext->hooks->gl.glFinish();
nsecs_t threadEndTime = systemTime(SYSTEM_TIME_THREAD);
nsecs_t wallEndTime = systemTime(SYSTEM_TIME_MONOTONIC);
void *pointerArgs[] = {
};
fixupGLMessage(glContext, wallStartTime, wallEndTime,
threadStartTime, threadEndTime,
&glmsg, pointerArgs);
glContext->traceGLMessage(&glmsg);
}
void GLTrace_glFlush(void) {
GLMessage glmsg;
GLTraceContext *glContext = getGLTraceContext();
glmsg.set_function(GLMessage::glFlush);
// call function
nsecs_t wallStartTime = systemTime(SYSTEM_TIME_MONOTONIC);
nsecs_t threadStartTime = systemTime(SYSTEM_TIME_THREAD);
glContext->hooks->gl.glFlush();
nsecs_t threadEndTime = systemTime(SYSTEM_TIME_THREAD);
nsecs_t wallEndTime = systemTime(SYSTEM_TIME_MONOTONIC);
void *pointerArgs[] = {
};
fixupGLMessage(glContext, wallStartTime, wallEndTime,
threadStartTime, threadEndTime,
&glmsg, pointerArgs);
glContext->traceGLMessage(&glmsg);
}
void GLTrace_glFramebufferRenderbuffer(GLenum target, GLenum attachment, GLenum renderbuffertarget, GLuint renderbuffer) {
GLMessage glmsg;
GLTraceContext *glContext = getGLTraceContext();
glmsg.set_function(GLMessage::glFramebufferRenderbuffer);
// copy argument target
GLMessage_DataType *arg_target = glmsg.add_args();
arg_target->set_isarray(false);
arg_target->set_type(GLMessage::DataType::ENUM);
arg_target->add_intvalue((int)target);
// copy argument attachment
GLMessage_DataType *arg_attachment = glmsg.add_args();
arg_attachment->set_isarray(false);
arg_attachment->set_type(GLMessage::DataType::ENUM);
arg_attachment->add_intvalue((int)attachment);
// copy argument renderbuffertarget
GLMessage_DataType *arg_renderbuffertarget = glmsg.add_args();
arg_renderbuffertarget->set_isarray(false);
arg_renderbuffertarget->set_type(GLMessage::DataType::ENUM);
arg_renderbuffertarget->add_intvalue((int)renderbuffertarget);
// copy argument renderbuffer
GLMessage_DataType *arg_renderbuffer = glmsg.add_args();
arg_renderbuffer->set_isarray(false);
arg_renderbuffer->set_type(GLMessage::DataType::INT);
arg_renderbuffer->add_intvalue(renderbuffer);
// call function
nsecs_t wallStartTime = systemTime(SYSTEM_TIME_MONOTONIC);
nsecs_t threadStartTime = systemTime(SYSTEM_TIME_THREAD);
glContext->hooks->gl.glFramebufferRenderbuffer(target, attachment, renderbuffertarget, renderbuffer);
nsecs_t threadEndTime = systemTime(SYSTEM_TIME_THREAD);
nsecs_t wallEndTime = systemTime(SYSTEM_TIME_MONOTONIC);
void *pointerArgs[] = {
};
fixupGLMessage(glContext, wallStartTime, wallEndTime,
threadStartTime, threadEndTime,
&glmsg, pointerArgs);
glContext->traceGLMessage(&glmsg);
}
void GLTrace_glFramebufferTexture2D(GLenum target, GLenum attachment, GLenum textarget, GLuint texture, GLint level) {
GLMessage glmsg;
GLTraceContext *glContext = getGLTraceContext();
glmsg.set_function(GLMessage::glFramebufferTexture2D);
// copy argument target
GLMessage_DataType *arg_target = glmsg.add_args();
arg_target->set_isarray(false);
arg_target->set_type(GLMessage::DataType::ENUM);
arg_target->add_intvalue((int)target);
// copy argument attachment
GLMessage_DataType *arg_attachment = glmsg.add_args();
arg_attachment->set_isarray(false);
arg_attachment->set_type(GLMessage::DataType::ENUM);
arg_attachment->add_intvalue((int)attachment);
// copy argument textarget
GLMessage_DataType *arg_textarget = glmsg.add_args();
arg_textarget->set_isarray(false);
arg_textarget->set_type(GLMessage::DataType::ENUM);
arg_textarget->add_intvalue((int)textarget);
// copy argument texture
GLMessage_DataType *arg_texture = glmsg.add_args();
arg_texture->set_isarray(false);
arg_texture->set_type(GLMessage::DataType::INT);
arg_texture->add_intvalue(texture);
// copy argument level
GLMessage_DataType *arg_level = glmsg.add_args();
arg_level->set_isarray(false);
arg_level->set_type(GLMessage::DataType::INT);
arg_level->add_intvalue(level);
// call function
nsecs_t wallStartTime = systemTime(SYSTEM_TIME_MONOTONIC);
nsecs_t threadStartTime = systemTime(SYSTEM_TIME_THREAD);
glContext->hooks->gl.glFramebufferTexture2D(target, attachment, textarget, texture, level);
nsecs_t threadEndTime = systemTime(SYSTEM_TIME_THREAD);
nsecs_t wallEndTime = systemTime(SYSTEM_TIME_MONOTONIC);
void *pointerArgs[] = {
};
fixupGLMessage(glContext, wallStartTime, wallEndTime,
threadStartTime, threadEndTime,
&glmsg, pointerArgs);
glContext->traceGLMessage(&glmsg);
}
void GLTrace_glFrontFace(GLenum mode) {
GLMessage glmsg;
GLTraceContext *glContext = getGLTraceContext();
glmsg.set_function(GLMessage::glFrontFace);
// copy argument mode
GLMessage_DataType *arg_mode = glmsg.add_args();
arg_mode->set_isarray(false);
arg_mode->set_type(GLMessage::DataType::ENUM);
arg_mode->add_intvalue((int)mode);
// call function
nsecs_t wallStartTime = systemTime(SYSTEM_TIME_MONOTONIC);
nsecs_t threadStartTime = systemTime(SYSTEM_TIME_THREAD);
glContext->hooks->gl.glFrontFace(mode);
nsecs_t threadEndTime = systemTime(SYSTEM_TIME_THREAD);
nsecs_t wallEndTime = systemTime(SYSTEM_TIME_MONOTONIC);
void *pointerArgs[] = {
};
fixupGLMessage(glContext, wallStartTime, wallEndTime,
threadStartTime, threadEndTime,
&glmsg, pointerArgs);
glContext->traceGLMessage(&glmsg);
}
void GLTrace_glGenBuffers(GLsizei n, GLuint* buffers) {
GLMessage glmsg;
GLTraceContext *glContext = getGLTraceContext();
glmsg.set_function(GLMessage::glGenBuffers);
// copy argument n
GLMessage_DataType *arg_n = glmsg.add_args();
arg_n->set_isarray(false);
arg_n->set_type(GLMessage::DataType::INT);
arg_n->add_intvalue(n);
// copy argument buffers
GLMessage_DataType *arg_buffers = glmsg.add_args();
arg_buffers->set_isarray(false);
arg_buffers->set_type(GLMessage::DataType::INT);
arg_buffers->add_intvalue((int)buffers);
// call function
nsecs_t wallStartTime = systemTime(SYSTEM_TIME_MONOTONIC);
nsecs_t threadStartTime = systemTime(SYSTEM_TIME_THREAD);
glContext->hooks->gl.glGenBuffers(n, buffers);
nsecs_t threadEndTime = systemTime(SYSTEM_TIME_THREAD);
nsecs_t wallEndTime = systemTime(SYSTEM_TIME_MONOTONIC);
void *pointerArgs[] = {
(void *) buffers,
};
fixupGLMessage(glContext, wallStartTime, wallEndTime,
threadStartTime, threadEndTime,
&glmsg, pointerArgs);
glContext->traceGLMessage(&glmsg);
}
void GLTrace_glGenerateMipmap(GLenum target) {
GLMessage glmsg;
GLTraceContext *glContext = getGLTraceContext();
glmsg.set_function(GLMessage::glGenerateMipmap);
// copy argument target
GLMessage_DataType *arg_target = glmsg.add_args();
arg_target->set_isarray(false);
arg_target->set_type(GLMessage::DataType::ENUM);
arg_target->add_intvalue((int)target);
// call function
nsecs_t wallStartTime = systemTime(SYSTEM_TIME_MONOTONIC);
nsecs_t threadStartTime = systemTime(SYSTEM_TIME_THREAD);
glContext->hooks->gl.glGenerateMipmap(target);
nsecs_t threadEndTime = systemTime(SYSTEM_TIME_THREAD);
nsecs_t wallEndTime = systemTime(SYSTEM_TIME_MONOTONIC);
void *pointerArgs[] = {
};
fixupGLMessage(glContext, wallStartTime, wallEndTime,
threadStartTime, threadEndTime,
&glmsg, pointerArgs);
glContext->traceGLMessage(&glmsg);
}
void GLTrace_glGenFramebuffers(GLsizei n, GLuint* framebuffers) {
GLMessage glmsg;
GLTraceContext *glContext = getGLTraceContext();
glmsg.set_function(GLMessage::glGenFramebuffers);
// copy argument n
GLMessage_DataType *arg_n = glmsg.add_args();
arg_n->set_isarray(false);
arg_n->set_type(GLMessage::DataType::INT);
arg_n->add_intvalue(n);
// copy argument framebuffers
GLMessage_DataType *arg_framebuffers = glmsg.add_args();
arg_framebuffers->set_isarray(false);
arg_framebuffers->set_type(GLMessage::DataType::INT);
arg_framebuffers->add_intvalue((int)framebuffers);
// call function
nsecs_t wallStartTime = systemTime(SYSTEM_TIME_MONOTONIC);
nsecs_t threadStartTime = systemTime(SYSTEM_TIME_THREAD);
glContext->hooks->gl.glGenFramebuffers(n, framebuffers);
nsecs_t threadEndTime = systemTime(SYSTEM_TIME_THREAD);
nsecs_t wallEndTime = systemTime(SYSTEM_TIME_MONOTONIC);
void *pointerArgs[] = {
(void *) framebuffers,
};
fixupGLMessage(glContext, wallStartTime, wallEndTime,
threadStartTime, threadEndTime,
&glmsg, pointerArgs);
glContext->traceGLMessage(&glmsg);
}
void GLTrace_glGenRenderbuffers(GLsizei n, GLuint* renderbuffers) {
GLMessage glmsg;
GLTraceContext *glContext = getGLTraceContext();
glmsg.set_function(GLMessage::glGenRenderbuffers);
// copy argument n
GLMessage_DataType *arg_n = glmsg.add_args();
arg_n->set_isarray(false);
arg_n->set_type(GLMessage::DataType::INT);
arg_n->add_intvalue(n);
// copy argument renderbuffers
GLMessage_DataType *arg_renderbuffers = glmsg.add_args();
arg_renderbuffers->set_isarray(false);
arg_renderbuffers->set_type(GLMessage::DataType::INT);
arg_renderbuffers->add_intvalue((int)renderbuffers);
// call function
nsecs_t wallStartTime = systemTime(SYSTEM_TIME_MONOTONIC);
nsecs_t threadStartTime = systemTime(SYSTEM_TIME_THREAD);
glContext->hooks->gl.glGenRenderbuffers(n, renderbuffers);
nsecs_t threadEndTime = systemTime(SYSTEM_TIME_THREAD);
nsecs_t wallEndTime = systemTime(SYSTEM_TIME_MONOTONIC);
void *pointerArgs[] = {
(void *) renderbuffers,
};
fixupGLMessage(glContext, wallStartTime, wallEndTime,
threadStartTime, threadEndTime,
&glmsg, pointerArgs);
glContext->traceGLMessage(&glmsg);
}
void GLTrace_glGenTextures(GLsizei n, GLuint* textures) {
GLMessage glmsg;
GLTraceContext *glContext = getGLTraceContext();
glmsg.set_function(GLMessage::glGenTextures);
// copy argument n
GLMessage_DataType *arg_n = glmsg.add_args();
arg_n->set_isarray(false);
arg_n->set_type(GLMessage::DataType::INT);
arg_n->add_intvalue(n);
// copy argument textures
GLMessage_DataType *arg_textures = glmsg.add_args();
arg_textures->set_isarray(false);
arg_textures->set_type(GLMessage::DataType::INT);
arg_textures->add_intvalue((int)textures);
// call function
nsecs_t wallStartTime = systemTime(SYSTEM_TIME_MONOTONIC);
nsecs_t threadStartTime = systemTime(SYSTEM_TIME_THREAD);
glContext->hooks->gl.glGenTextures(n, textures);
nsecs_t threadEndTime = systemTime(SYSTEM_TIME_THREAD);
nsecs_t wallEndTime = systemTime(SYSTEM_TIME_MONOTONIC);
void *pointerArgs[] = {
(void *) textures,
};
fixupGLMessage(glContext, wallStartTime, wallEndTime,
threadStartTime, threadEndTime,
&glmsg, pointerArgs);
glContext->traceGLMessage(&glmsg);
}
void GLTrace_glGetActiveAttrib(GLuint program, GLuint index, GLsizei bufsize, GLsizei* length, GLint* size, GLenum* type, GLchar* name) {
GLMessage glmsg;
GLTraceContext *glContext = getGLTraceContext();
glmsg.set_function(GLMessage::glGetActiveAttrib);
// copy argument program
GLMessage_DataType *arg_program = glmsg.add_args();
arg_program->set_isarray(false);
arg_program->set_type(GLMessage::DataType::INT);
arg_program->add_intvalue(program);
// copy argument index
GLMessage_DataType *arg_index = glmsg.add_args();
arg_index->set_isarray(false);
arg_index->set_type(GLMessage::DataType::INT);
arg_index->add_intvalue(index);
// copy argument bufsize
GLMessage_DataType *arg_bufsize = glmsg.add_args();
arg_bufsize->set_isarray(false);
arg_bufsize->set_type(GLMessage::DataType::INT);
arg_bufsize->add_intvalue(bufsize);
// copy argument length
GLMessage_DataType *arg_length = glmsg.add_args();
arg_length->set_isarray(false);
arg_length->set_type(GLMessage::DataType::INT);
arg_length->add_intvalue((int)length);
// copy argument size
GLMessage_DataType *arg_size = glmsg.add_args();
arg_size->set_isarray(false);
arg_size->set_type(GLMessage::DataType::INT);
arg_size->add_intvalue((int)size);
// copy argument type
GLMessage_DataType *arg_type = glmsg.add_args();
arg_type->set_isarray(false);
arg_type->set_type(GLMessage::DataType::INT);
arg_type->add_intvalue((int)type);
// copy argument name
GLMessage_DataType *arg_name = glmsg.add_args();
arg_name->set_isarray(false);
arg_name->set_type(GLMessage::DataType::INT);
arg_name->add_intvalue((int)name);
// call function
nsecs_t wallStartTime = systemTime(SYSTEM_TIME_MONOTONIC);
nsecs_t threadStartTime = systemTime(SYSTEM_TIME_THREAD);
glContext->hooks->gl.glGetActiveAttrib(program, index, bufsize, length, size, type, name);
nsecs_t threadEndTime = systemTime(SYSTEM_TIME_THREAD);
nsecs_t wallEndTime = systemTime(SYSTEM_TIME_MONOTONIC);
void *pointerArgs[] = {
(void *) length,
(void *) size,
(void *) type,
(void *) name,
};
fixupGLMessage(glContext, wallStartTime, wallEndTime,
threadStartTime, threadEndTime,
&glmsg, pointerArgs);
glContext->traceGLMessage(&glmsg);
}
void GLTrace_glGetActiveUniform(GLuint program, GLuint index, GLsizei bufsize, GLsizei* length, GLint* size, GLenum* type, GLchar* name) {
GLMessage glmsg;
GLTraceContext *glContext = getGLTraceContext();
glmsg.set_function(GLMessage::glGetActiveUniform);
// copy argument program
GLMessage_DataType *arg_program = glmsg.add_args();
arg_program->set_isarray(false);
arg_program->set_type(GLMessage::DataType::INT);
arg_program->add_intvalue(program);
// copy argument index
GLMessage_DataType *arg_index = glmsg.add_args();
arg_index->set_isarray(false);
arg_index->set_type(GLMessage::DataType::INT);
arg_index->add_intvalue(index);
// copy argument bufsize
GLMessage_DataType *arg_bufsize = glmsg.add_args();
arg_bufsize->set_isarray(false);
arg_bufsize->set_type(GLMessage::DataType::INT);
arg_bufsize->add_intvalue(bufsize);
// copy argument length
GLMessage_DataType *arg_length = glmsg.add_args();
arg_length->set_isarray(false);
arg_length->set_type(GLMessage::DataType::INT);
arg_length->add_intvalue((int)length);
// copy argument size
GLMessage_DataType *arg_size = glmsg.add_args();
arg_size->set_isarray(false);
arg_size->set_type(GLMessage::DataType::INT);
arg_size->add_intvalue((int)size);
// copy argument type
GLMessage_DataType *arg_type = glmsg.add_args();
arg_type->set_isarray(false);
arg_type->set_type(GLMessage::DataType::INT);
arg_type->add_intvalue((int)type);
// copy argument name
GLMessage_DataType *arg_name = glmsg.add_args();
arg_name->set_isarray(false);
arg_name->set_type(GLMessage::DataType::INT);
arg_name->add_intvalue((int)name);
// call function
nsecs_t wallStartTime = systemTime(SYSTEM_TIME_MONOTONIC);
nsecs_t threadStartTime = systemTime(SYSTEM_TIME_THREAD);
glContext->hooks->gl.glGetActiveUniform(program, index, bufsize, length, size, type, name);
nsecs_t threadEndTime = systemTime(SYSTEM_TIME_THREAD);
nsecs_t wallEndTime = systemTime(SYSTEM_TIME_MONOTONIC);
void *pointerArgs[] = {
(void *) length,
(void *) size,
(void *) type,
(void *) name,
};
fixupGLMessage(glContext, wallStartTime, wallEndTime,
threadStartTime, threadEndTime,
&glmsg, pointerArgs);
glContext->traceGLMessage(&glmsg);
}
void GLTrace_glGetAttachedShaders(GLuint program, GLsizei maxcount, GLsizei* count, GLuint* shaders) {
GLMessage glmsg;
GLTraceContext *glContext = getGLTraceContext();
glmsg.set_function(GLMessage::glGetAttachedShaders);
// copy argument program
GLMessage_DataType *arg_program = glmsg.add_args();
arg_program->set_isarray(false);
arg_program->set_type(GLMessage::DataType::INT);
arg_program->add_intvalue(program);
// copy argument maxcount
GLMessage_DataType *arg_maxcount = glmsg.add_args();
arg_maxcount->set_isarray(false);
arg_maxcount->set_type(GLMessage::DataType::INT);
arg_maxcount->add_intvalue(maxcount);
// copy argument count
GLMessage_DataType *arg_count = glmsg.add_args();
arg_count->set_isarray(false);
arg_count->set_type(GLMessage::DataType::INT);
arg_count->add_intvalue((int)count);
// copy argument shaders
GLMessage_DataType *arg_shaders = glmsg.add_args();
arg_shaders->set_isarray(false);
arg_shaders->set_type(GLMessage::DataType::INT);
arg_shaders->add_intvalue((int)shaders);
// call function
nsecs_t wallStartTime = systemTime(SYSTEM_TIME_MONOTONIC);
nsecs_t threadStartTime = systemTime(SYSTEM_TIME_THREAD);
glContext->hooks->gl.glGetAttachedShaders(program, maxcount, count, shaders);
nsecs_t threadEndTime = systemTime(SYSTEM_TIME_THREAD);
nsecs_t wallEndTime = systemTime(SYSTEM_TIME_MONOTONIC);
void *pointerArgs[] = {
(void *) count,
(void *) shaders,
};
fixupGLMessage(glContext, wallStartTime, wallEndTime,
threadStartTime, threadEndTime,
&glmsg, pointerArgs);
glContext->traceGLMessage(&glmsg);
}
int GLTrace_glGetAttribLocation(GLuint program, const GLchar* name) {
GLMessage glmsg;
GLTraceContext *glContext = getGLTraceContext();
glmsg.set_function(GLMessage::glGetAttribLocation);
// copy argument program
GLMessage_DataType *arg_program = glmsg.add_args();
arg_program->set_isarray(false);
arg_program->set_type(GLMessage::DataType::INT);
arg_program->add_intvalue(program);
// copy argument name
GLMessage_DataType *arg_name = glmsg.add_args();
arg_name->set_isarray(false);
arg_name->set_type(GLMessage::DataType::INT);
arg_name->add_intvalue((int)name);
// call function
nsecs_t wallStartTime = systemTime(SYSTEM_TIME_MONOTONIC);
nsecs_t threadStartTime = systemTime(SYSTEM_TIME_THREAD);
int retValue = glContext->hooks->gl.glGetAttribLocation(program, name);
nsecs_t threadEndTime = systemTime(SYSTEM_TIME_THREAD);
nsecs_t wallEndTime = systemTime(SYSTEM_TIME_MONOTONIC);
// set return value
GLMessage_DataType *rt = glmsg.mutable_returnvalue();
rt->set_isarray(false);
rt->set_type(GLMessage::DataType::INT);
rt->add_intvalue(retValue);
void *pointerArgs[] = {
(void *) name,
};
fixupGLMessage(glContext, wallStartTime, wallEndTime,
threadStartTime, threadEndTime,
&glmsg, pointerArgs);
glContext->traceGLMessage(&glmsg);
return retValue;
}
void GLTrace_glGetBooleanv(GLenum pname, GLboolean* params) {
GLMessage glmsg;
GLTraceContext *glContext = getGLTraceContext();
glmsg.set_function(GLMessage::glGetBooleanv);
// copy argument pname
GLMessage_DataType *arg_pname = glmsg.add_args();
arg_pname->set_isarray(false);
arg_pname->set_type(GLMessage::DataType::ENUM);
arg_pname->add_intvalue((int)pname);
// copy argument params
GLMessage_DataType *arg_params = glmsg.add_args();
arg_params->set_isarray(false);
arg_params->set_type(GLMessage::DataType::INT);
arg_params->add_intvalue((int)params);
// call function
nsecs_t wallStartTime = systemTime(SYSTEM_TIME_MONOTONIC);
nsecs_t threadStartTime = systemTime(SYSTEM_TIME_THREAD);
glContext->hooks->gl.glGetBooleanv(pname, params);
nsecs_t threadEndTime = systemTime(SYSTEM_TIME_THREAD);
nsecs_t wallEndTime = systemTime(SYSTEM_TIME_MONOTONIC);
void *pointerArgs[] = {
(void *) params,
};
fixupGLMessage(glContext, wallStartTime, wallEndTime,
threadStartTime, threadEndTime,
&glmsg, pointerArgs);
glContext->traceGLMessage(&glmsg);
}
void GLTrace_glGetBufferParameteriv(GLenum target, GLenum pname, GLint* params) {
GLMessage glmsg;
GLTraceContext *glContext = getGLTraceContext();
glmsg.set_function(GLMessage::glGetBufferParameteriv);
// copy argument target
GLMessage_DataType *arg_target = glmsg.add_args();
arg_target->set_isarray(false);
arg_target->set_type(GLMessage::DataType::ENUM);
arg_target->add_intvalue((int)target);
// copy argument pname
GLMessage_DataType *arg_pname = glmsg.add_args();
arg_pname->set_isarray(false);
arg_pname->set_type(GLMessage::DataType::ENUM);
arg_pname->add_intvalue((int)pname);
// copy argument params
GLMessage_DataType *arg_params = glmsg.add_args();
arg_params->set_isarray(false);
arg_params->set_type(GLMessage::DataType::INT);
arg_params->add_intvalue((int)params);
// call function
nsecs_t wallStartTime = systemTime(SYSTEM_TIME_MONOTONIC);
nsecs_t threadStartTime = systemTime(SYSTEM_TIME_THREAD);
glContext->hooks->gl.glGetBufferParameteriv(target, pname, params);
nsecs_t threadEndTime = systemTime(SYSTEM_TIME_THREAD);
nsecs_t wallEndTime = systemTime(SYSTEM_TIME_MONOTONIC);
void *pointerArgs[] = {
(void *) params,
};
fixupGLMessage(glContext, wallStartTime, wallEndTime,
threadStartTime, threadEndTime,
&glmsg, pointerArgs);
glContext->traceGLMessage(&glmsg);
}
GLenum GLTrace_glGetError(void) {
GLMessage glmsg;
GLTraceContext *glContext = getGLTraceContext();
glmsg.set_function(GLMessage::glGetError);
// call function
nsecs_t wallStartTime = systemTime(SYSTEM_TIME_MONOTONIC);
nsecs_t threadStartTime = systemTime(SYSTEM_TIME_THREAD);
GLenum retValue = glContext->hooks->gl.glGetError();
nsecs_t threadEndTime = systemTime(SYSTEM_TIME_THREAD);
nsecs_t wallEndTime = systemTime(SYSTEM_TIME_MONOTONIC);
// set return value
GLMessage_DataType *rt = glmsg.mutable_returnvalue();
rt->set_isarray(false);
rt->set_type(GLMessage::DataType::ENUM);
rt->add_intvalue((int)retValue);
void *pointerArgs[] = {
};
fixupGLMessage(glContext, wallStartTime, wallEndTime,
threadStartTime, threadEndTime,
&glmsg, pointerArgs);
glContext->traceGLMessage(&glmsg);
return retValue;
}
void GLTrace_glGetFloatv(GLenum pname, GLfloat* params) {
GLMessage glmsg;
GLTraceContext *glContext = getGLTraceContext();
glmsg.set_function(GLMessage::glGetFloatv);
// copy argument pname
GLMessage_DataType *arg_pname = glmsg.add_args();
arg_pname->set_isarray(false);
arg_pname->set_type(GLMessage::DataType::ENUM);
arg_pname->add_intvalue((int)pname);
// copy argument params
GLMessage_DataType *arg_params = glmsg.add_args();
arg_params->set_isarray(false);
arg_params->set_type(GLMessage::DataType::INT);
arg_params->add_intvalue((int)params);
// call function
nsecs_t wallStartTime = systemTime(SYSTEM_TIME_MONOTONIC);
nsecs_t threadStartTime = systemTime(SYSTEM_TIME_THREAD);
glContext->hooks->gl.glGetFloatv(pname, params);
nsecs_t threadEndTime = systemTime(SYSTEM_TIME_THREAD);
nsecs_t wallEndTime = systemTime(SYSTEM_TIME_MONOTONIC);
void *pointerArgs[] = {
(void *) params,
};
fixupGLMessage(glContext, wallStartTime, wallEndTime,
threadStartTime, threadEndTime,
&glmsg, pointerArgs);
glContext->traceGLMessage(&glmsg);
}
void GLTrace_glGetFramebufferAttachmentParameteriv(GLenum target, GLenum attachment, GLenum pname, GLint* params) {
GLMessage glmsg;
GLTraceContext *glContext = getGLTraceContext();
glmsg.set_function(GLMessage::glGetFramebufferAttachmentParameteriv);
// copy argument target
GLMessage_DataType *arg_target = glmsg.add_args();
arg_target->set_isarray(false);
arg_target->set_type(GLMessage::DataType::ENUM);
arg_target->add_intvalue((int)target);
// copy argument attachment
GLMessage_DataType *arg_attachment = glmsg.add_args();
arg_attachment->set_isarray(false);
arg_attachment->set_type(GLMessage::DataType::ENUM);
arg_attachment->add_intvalue((int)attachment);
// copy argument pname
GLMessage_DataType *arg_pname = glmsg.add_args();
arg_pname->set_isarray(false);
arg_pname->set_type(GLMessage::DataType::ENUM);
arg_pname->add_intvalue((int)pname);
// copy argument params
GLMessage_DataType *arg_params = glmsg.add_args();
arg_params->set_isarray(false);
arg_params->set_type(GLMessage::DataType::INT);
arg_params->add_intvalue((int)params);
// call function
nsecs_t wallStartTime = systemTime(SYSTEM_TIME_MONOTONIC);
nsecs_t threadStartTime = systemTime(SYSTEM_TIME_THREAD);
glContext->hooks->gl.glGetFramebufferAttachmentParameteriv(target, attachment, pname, params);
nsecs_t threadEndTime = systemTime(SYSTEM_TIME_THREAD);
nsecs_t wallEndTime = systemTime(SYSTEM_TIME_MONOTONIC);
void *pointerArgs[] = {
(void *) params,
};
fixupGLMessage(glContext, wallStartTime, wallEndTime,
threadStartTime, threadEndTime,
&glmsg, pointerArgs);
glContext->traceGLMessage(&glmsg);
}
void GLTrace_glGetIntegerv(GLenum pname, GLint* params) {
GLMessage glmsg;
GLTraceContext *glContext = getGLTraceContext();
glmsg.set_function(GLMessage::glGetIntegerv);
// copy argument pname
GLMessage_DataType *arg_pname = glmsg.add_args();
arg_pname->set_isarray(false);
arg_pname->set_type(GLMessage::DataType::ENUM);
arg_pname->add_intvalue((int)pname);
// copy argument params
GLMessage_DataType *arg_params = glmsg.add_args();
arg_params->set_isarray(false);
arg_params->set_type(GLMessage::DataType::INT);
arg_params->add_intvalue((int)params);
// call function
nsecs_t wallStartTime = systemTime(SYSTEM_TIME_MONOTONIC);
nsecs_t threadStartTime = systemTime(SYSTEM_TIME_THREAD);
glContext->hooks->gl.glGetIntegerv(pname, params);
nsecs_t threadEndTime = systemTime(SYSTEM_TIME_THREAD);
nsecs_t wallEndTime = systemTime(SYSTEM_TIME_MONOTONIC);
void *pointerArgs[] = {
(void *) params,
};
fixupGLMessage(glContext, wallStartTime, wallEndTime,
threadStartTime, threadEndTime,
&glmsg, pointerArgs);
glContext->traceGLMessage(&glmsg);
}
void GLTrace_glGetProgramiv(GLuint program, GLenum pname, GLint* params) {
GLMessage glmsg;
GLTraceContext *glContext = getGLTraceContext();
glmsg.set_function(GLMessage::glGetProgramiv);
// copy argument program
GLMessage_DataType *arg_program = glmsg.add_args();
arg_program->set_isarray(false);
arg_program->set_type(GLMessage::DataType::INT);
arg_program->add_intvalue(program);
// copy argument pname
GLMessage_DataType *arg_pname = glmsg.add_args();
arg_pname->set_isarray(false);
arg_pname->set_type(GLMessage::DataType::ENUM);
arg_pname->add_intvalue((int)pname);
// copy argument params
GLMessage_DataType *arg_params = glmsg.add_args();
arg_params->set_isarray(false);
arg_params->set_type(GLMessage::DataType::INT);
arg_params->add_intvalue((int)params);
// call function
nsecs_t wallStartTime = systemTime(SYSTEM_TIME_MONOTONIC);
nsecs_t threadStartTime = systemTime(SYSTEM_TIME_THREAD);
glContext->hooks->gl.glGetProgramiv(program, pname, params);
nsecs_t threadEndTime = systemTime(SYSTEM_TIME_THREAD);
nsecs_t wallEndTime = systemTime(SYSTEM_TIME_MONOTONIC);
void *pointerArgs[] = {
(void *) params,
};
fixupGLMessage(glContext, wallStartTime, wallEndTime,
threadStartTime, threadEndTime,
&glmsg, pointerArgs);
glContext->traceGLMessage(&glmsg);
}
void GLTrace_glGetProgramInfoLog(GLuint program, GLsizei bufsize, GLsizei* length, GLchar* infolog) {
GLMessage glmsg;
GLTraceContext *glContext = getGLTraceContext();
glmsg.set_function(GLMessage::glGetProgramInfoLog);
// copy argument program
GLMessage_DataType *arg_program = glmsg.add_args();
arg_program->set_isarray(false);
arg_program->set_type(GLMessage::DataType::INT);
arg_program->add_intvalue(program);
// copy argument bufsize
GLMessage_DataType *arg_bufsize = glmsg.add_args();
arg_bufsize->set_isarray(false);
arg_bufsize->set_type(GLMessage::DataType::INT);
arg_bufsize->add_intvalue(bufsize);
// copy argument length
GLMessage_DataType *arg_length = glmsg.add_args();
arg_length->set_isarray(false);
arg_length->set_type(GLMessage::DataType::INT);
arg_length->add_intvalue((int)length);
// copy argument infolog
GLMessage_DataType *arg_infolog = glmsg.add_args();
arg_infolog->set_isarray(false);
arg_infolog->set_type(GLMessage::DataType::INT);
arg_infolog->add_intvalue((int)infolog);
// call function
nsecs_t wallStartTime = systemTime(SYSTEM_TIME_MONOTONIC);
nsecs_t threadStartTime = systemTime(SYSTEM_TIME_THREAD);
glContext->hooks->gl.glGetProgramInfoLog(program, bufsize, length, infolog);
nsecs_t threadEndTime = systemTime(SYSTEM_TIME_THREAD);
nsecs_t wallEndTime = systemTime(SYSTEM_TIME_MONOTONIC);
void *pointerArgs[] = {
(void *) length,
(void *) infolog,
};
fixupGLMessage(glContext, wallStartTime, wallEndTime,
threadStartTime, threadEndTime,
&glmsg, pointerArgs);
glContext->traceGLMessage(&glmsg);
}
void GLTrace_glGetRenderbufferParameteriv(GLenum target, GLenum pname, GLint* params) {
GLMessage glmsg;
GLTraceContext *glContext = getGLTraceContext();
glmsg.set_function(GLMessage::glGetRenderbufferParameteriv);
// copy argument target
GLMessage_DataType *arg_target = glmsg.add_args();
arg_target->set_isarray(false);
arg_target->set_type(GLMessage::DataType::ENUM);
arg_target->add_intvalue((int)target);
// copy argument pname
GLMessage_DataType *arg_pname = glmsg.add_args();
arg_pname->set_isarray(false);
arg_pname->set_type(GLMessage::DataType::ENUM);
arg_pname->add_intvalue((int)pname);
// copy argument params
GLMessage_DataType *arg_params = glmsg.add_args();
arg_params->set_isarray(false);
arg_params->set_type(GLMessage::DataType::INT);
arg_params->add_intvalue((int)params);
// call function
nsecs_t wallStartTime = systemTime(SYSTEM_TIME_MONOTONIC);
nsecs_t threadStartTime = systemTime(SYSTEM_TIME_THREAD);
glContext->hooks->gl.glGetRenderbufferParameteriv(target, pname, params);
nsecs_t threadEndTime = systemTime(SYSTEM_TIME_THREAD);
nsecs_t wallEndTime = systemTime(SYSTEM_TIME_MONOTONIC);
void *pointerArgs[] =