blob: 12d8e7c0e8c867b605e2dda8304dddab731aa598 [file] [log] [blame]
Siva Velusamydb974682011-11-30 15:05:37 -08001/*
2 * Copyright (C) 2011 The Android Open Source Project
3 *
4 * Licensed under the Apache License, Version 2.0 (the "License");
5 * you may not use this file except in compliance with the License.
6 * You may obtain a copy of the License at
7 *
8 * http://www.apache.org/licenses/LICENSE-2.0
9 *
10 * Unless required by applicable law or agreed to in writing, software
11 * distributed under the License is distributed on an "AS IS" BASIS,
12 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13 * See the License for the specific language governing permissions and
14 * limitations under the License.
15 */
16
17package android.gltrace;
18
19option optimize_for = LITE_RUNTIME;
20
21option java_package = "com.android.ide.eclipse.gltrace";
22option java_outer_classname = "GLProtoBuf";
23
24message GLMessage {
25 enum Function {
26 glActiveTexture = 0;
27 glAlphaFunc = 1;
28 glAlphaFuncx = 2;
29 glAlphaFuncxOES = 3;
30 glAttachShader = 4;
31 glBeginPerfMonitorAMD = 5;
32 glBindAttribLocation = 6;
33 glBindBuffer = 7;
34 glBindFramebuffer = 8;
35 glBindFramebufferOES = 9;
36 glBindRenderbuffer = 10;
37 glBindRenderbufferOES = 11;
38 glBindTexture = 12;
39 glBindVertexArrayOES = 13;
40 glBlendColor = 14;
41 glBlendEquation = 15;
42 glBlendEquationOES = 16;
43 glBlendEquationSeparate = 17;
44 glBlendEquationSeparateOES = 18;
45 glBlendFunc = 19;
46 glBlendFuncSeparate = 20;
47 glBlendFuncSeparateOES = 21;
48 glBufferData = 22;
49 glBufferSubData = 23;
50 glCheckFramebufferStatus = 24;
51 glCheckFramebufferStatusOES = 25;
52 glClearColor = 26;
53 glClearColorx = 27;
54 glClearColorxOES = 28;
55 glClearDepthf = 29;
56 glClearDepthfOES = 30;
57 glClearDepthx = 31;
58 glClearDepthxOES = 32;
59 glClear = 33;
60 glClearStencil = 34;
61 glClientActiveTexture = 35;
62 glClipPlanef = 36;
63 glClipPlanefIMG = 37;
64 glClipPlanefOES = 38;
65 glClipPlanex = 39;
66 glClipPlanexIMG = 40;
67 glClipPlanexOES = 41;
68 glColor4f = 42;
69 glColor4ub = 43;
70 glColor4x = 44;
71 glColor4xOES = 45;
72 glColorMask = 46;
73 glColorPointer = 47;
74 glCompileShader = 48;
75 glCompressedTexImage2D = 49;
76 glCompressedTexImage3DOES = 50;
77 glCompressedTexSubImage2D = 51;
78 glCompressedTexSubImage3DOES = 52;
79 glCopyTexImage2D = 53;
80 glCopyTexSubImage2D = 54;
81 glCopyTexSubImage3DOES = 55;
82 glCoverageMaskNV = 56;
83 glCoverageOperationNV = 57;
84 glCreateProgram = 58;
85 glCreateShader = 59;
86 glCullFace = 60;
87 glCurrentPaletteMatrixOES = 61;
88 glDeleteBuffers = 62;
89 glDeleteFencesNV = 63;
90 glDeleteFramebuffers = 64;
91 glDeleteFramebuffersOES = 65;
92 glDeletePerfMonitorsAMD = 66;
93 glDeleteProgram = 67;
94 glDeleteRenderbuffers = 68;
95 glDeleteRenderbuffersOES = 69;
96 glDeleteShader = 70;
97 glDeleteTextures = 71;
98 glDeleteVertexArraysOES = 72;
99 glDepthFunc = 73;
100 glDepthMask = 74;
101 glDepthRangef = 75;
102 glDepthRangefOES = 76;
103 glDepthRangex = 77;
104 glDepthRangexOES = 78;
105 glDetachShader = 79;
106 glDisableClientState = 80;
107 glDisableDriverControlQCOM = 81;
108 glDisable = 82;
109 glDisableVertexAttribArray = 83;
110 glDiscardFramebufferEXT = 84;
111 glDrawArrays = 85;
112 glDrawElements = 86;
113 glDrawTexfOES = 87;
114 glDrawTexfvOES = 88;
115 glDrawTexiOES = 89;
116 glDrawTexivOES = 90;
117 glDrawTexsOES = 91;
118 glDrawTexsvOES = 92;
119 glDrawTexxOES = 93;
120 glDrawTexxvOES = 94;
121 glEGLImageTargetRenderbufferStorageOES = 95;
122 glEGLImageTargetTexture2DOES = 96;
123 glEnableClientState = 97;
124 glEnableDriverControlQCOM = 98;
125 glEnable = 99;
126 glEnableVertexAttribArray = 100;
127 glEndPerfMonitorAMD = 101;
128 glEndTilingQCOM = 102;
129 glExtGetBufferPointervQCOM = 103;
130 glExtGetBuffersQCOM = 104;
131 glExtGetFramebuffersQCOM = 105;
132 glExtGetProgramBinarySourceQCOM = 106;
133 glExtGetProgramsQCOM = 107;
134 glExtGetRenderbuffersQCOM = 108;
135 glExtGetShadersQCOM = 109;
136 glExtGetTexLevelParameterivQCOM = 110;
137 glExtGetTexSubImageQCOM = 111;
138 glExtGetTexturesQCOM = 112;
139 glExtIsProgramBinaryQCOM = 113;
140 glExtTexObjectStateOverrideiQCOM = 114;
141 glFinishFenceNV = 115;
142 glFinish = 116;
143 glFlush = 117;
144 glFogf = 118;
145 glFogfv = 119;
146 glFogx = 120;
147 glFogxOES = 121;
148 glFogxv = 122;
149 glFogxvOES = 123;
150 glFramebufferRenderbuffer = 124;
151 glFramebufferRenderbufferOES = 125;
152 glFramebufferTexture2D = 126;
153 glFramebufferTexture2DMultisampleIMG = 127;
154 glFramebufferTexture2DOES = 128;
155 glFramebufferTexture3DOES = 129;
156 glFrontFace = 130;
157 glFrustumf = 131;
158 glFrustumfOES = 132;
159 glFrustumx = 133;
160 glFrustumxOES = 134;
161 glGenBuffers = 135;
162 glGenerateMipmap = 136;
163 glGenerateMipmapOES = 137;
164 glGenFencesNV = 138;
165 glGenFramebuffers = 139;
166 glGenFramebuffersOES = 140;
167 glGenPerfMonitorsAMD = 141;
168 glGenRenderbuffers = 142;
169 glGenRenderbuffersOES = 143;
170 glGenTextures = 144;
171 glGenVertexArraysOES = 145;
172 glGetActiveAttrib = 146;
173 glGetActiveUniform = 147;
174 glGetAttachedShaders = 148;
175 glGetAttribLocation = 149;
176 glGetBooleanv = 150;
177 glGetBufferParameteriv = 151;
178 glGetBufferPointervOES = 152;
179 glGetClipPlanef = 153;
180 glGetClipPlanefOES = 154;
181 glGetClipPlanex = 155;
182 glGetClipPlanexOES = 156;
183 glGetDriverControlsQCOM = 157;
184 glGetDriverControlStringQCOM = 158;
185 glGetError = 159;
186 glGetFenceivNV = 160;
187 glGetFixedv = 161;
188 glGetFixedvOES = 162;
189 glGetFloatv = 163;
190 glGetFramebufferAttachmentParameteriv = 164;
191 glGetFramebufferAttachmentParameterivOES = 165;
192 glGetIntegerv = 166;
193 glGetLightfv = 167;
194 glGetLightxv = 168;
195 glGetLightxvOES = 169;
196 glGetMaterialfv = 170;
197 glGetMaterialxv = 171;
198 glGetMaterialxvOES = 172;
199 glGetPerfMonitorCounterDataAMD = 173;
200 glGetPerfMonitorCounterInfoAMD = 174;
201 glGetPerfMonitorCountersAMD = 175;
202 glGetPerfMonitorCounterStringAMD = 176;
203 glGetPerfMonitorGroupsAMD = 177;
204 glGetPerfMonitorGroupStringAMD = 178;
205 glGetPointerv = 179;
206 glGetProgramBinaryOES = 180;
207 glGetProgramInfoLog = 181;
208 glGetProgramiv = 182;
209 glGetRenderbufferParameteriv = 183;
210 glGetRenderbufferParameterivOES = 184;
211 glGetShaderInfoLog = 185;
212 glGetShaderiv = 186;
213 glGetShaderPrecisionFormat = 187;
214 glGetShaderSource = 188;
215 glGetString = 189;
216 glGetTexEnvfv = 190;
217 glGetTexEnviv = 191;
218 glGetTexEnvxv = 192;
219 glGetTexEnvxvOES = 193;
220 glGetTexGenfvOES = 194;
221 glGetTexGenivOES = 195;
222 glGetTexGenxvOES = 196;
223 glGetTexParameterfv = 197;
224 glGetTexParameteriv = 198;
225 glGetTexParameterxv = 199;
226 glGetTexParameterxvOES = 200;
227 glGetUniformfv = 201;
228 glGetUniformiv = 202;
229 glGetUniformLocation = 203;
230 glGetVertexAttribfv = 204;
231 glGetVertexAttribiv = 205;
232 glGetVertexAttribPointerv = 206;
233 glHint = 207;
234 glIsBuffer = 208;
235 glIsEnabled = 209;
236 glIsFenceNV = 210;
237 glIsFramebuffer = 211;
238 glIsFramebufferOES = 212;
239 glIsProgram = 213;
240 glIsRenderbuffer = 214;
241 glIsRenderbufferOES = 215;
242 glIsShader = 216;
243 glIsTexture = 217;
244 glIsVertexArrayOES = 218;
245 glLightf = 219;
246 glLightfv = 220;
247 glLightModelf = 221;
248 glLightModelfv = 222;
249 glLightModelx = 223;
250 glLightModelxOES = 224;
251 glLightModelxv = 225;
252 glLightModelxvOES = 226;
253 glLightx = 227;
254 glLightxOES = 228;
255 glLightxv = 229;
256 glLightxvOES = 230;
257 glLineWidth = 231;
258 glLineWidthx = 232;
259 glLineWidthxOES = 233;
260 glLinkProgram = 234;
261 glLoadIdentity = 235;
262 glLoadMatrixf = 236;
263 glLoadMatrixx = 237;
264 glLoadMatrixxOES = 238;
265 glLoadPaletteFromModelViewMatrixOES = 239;
266 glLogicOp = 240;
267 glMapBufferOES = 241;
268 glMaterialf = 242;
269 glMaterialfv = 243;
270 glMaterialx = 244;
271 glMaterialxOES = 245;
272 glMaterialxv = 246;
273 glMaterialxvOES = 247;
274 glMatrixIndexPointerOES = 248;
275 glMatrixMode = 249;
276 glMultiDrawArraysEXT = 250;
277 glMultiDrawElementsEXT = 251;
278 glMultiTexCoord4f = 252;
279 glMultiTexCoord4x = 253;
280 glMultiTexCoord4xOES = 254;
281 glMultMatrixf = 255;
282 glMultMatrixx = 256;
283 glMultMatrixxOES = 257;
284 glNormal3f = 258;
285 glNormal3x = 259;
286 glNormal3xOES = 260;
287 glNormalPointer = 261;
288 glOrthof = 262;
289 glOrthofOES = 263;
290 glOrthox = 264;
291 glOrthoxOES = 265;
292 glPixelStorei = 266;
293 glPointParameterf = 267;
294 glPointParameterfv = 268;
295 glPointParameterx = 269;
296 glPointParameterxOES = 270;
297 glPointParameterxv = 271;
298 glPointParameterxvOES = 272;
299 glPointSize = 273;
300 glPointSizePointerOES = 274;
301 glPointSizex = 275;
302 glPointSizexOES = 276;
303 glPolygonOffset = 277;
304 glPolygonOffsetx = 278;
305 glPolygonOffsetxOES = 279;
306 glPopMatrix = 280;
307 glProgramBinaryOES = 281;
308 glPushMatrix = 282;
309 glQueryMatrixxOES = 283;
310 glReadPixels = 284;
311 glReleaseShaderCompiler = 285;
312 glRenderbufferStorage = 286;
313 glRenderbufferStorageMultisampleIMG = 287;
314 glRenderbufferStorageOES = 288;
315 glRotatef = 289;
316 glRotatex = 290;
317 glRotatexOES = 291;
318 glSampleCoverage = 292;
319 glSampleCoveragex = 293;
320 glSampleCoveragexOES = 294;
321 glScalef = 295;
322 glScalex = 296;
323 glScalexOES = 297;
324 glScissor = 298;
325 glSelectPerfMonitorCountersAMD = 299;
326 glSetFenceNV = 300;
327 glShadeModel = 301;
328 glShaderBinary = 302;
329 glShaderSource = 303;
330 glStartTilingQCOM = 304;
331 glStencilFunc = 305;
332 glStencilFuncSeparate = 306;
333 glStencilMask = 307;
334 glStencilMaskSeparate = 308;
335 glStencilOp = 309;
336 glStencilOpSeparate = 310;
337 glTestFenceNV = 311;
338 glTexCoordPointer = 312;
339 glTexEnvf = 313;
340 glTexEnvfv = 314;
341 glTexEnvi = 315;
342 glTexEnviv = 316;
343 glTexEnvx = 317;
344 glTexEnvxOES = 318;
345 glTexEnvxv = 319;
346 glTexEnvxvOES = 320;
347 glTexGenfOES = 321;
348 glTexGenfvOES = 322;
349 glTexGeniOES = 323;
350 glTexGenivOES = 324;
351 glTexGenxOES = 325;
352 glTexGenxvOES = 326;
353 glTexImage2D = 327;
354 glTexImage3DOES = 328;
355 glTexParameterf = 329;
356 glTexParameterfv = 330;
357 glTexParameteri = 331;
358 glTexParameteriv = 332;
359 glTexParameterx = 333;
360 glTexParameterxOES = 334;
361 glTexParameterxv = 335;
362 glTexParameterxvOES = 336;
363 glTexSubImage2D = 337;
364 glTexSubImage3DOES = 338;
365 glTranslatef = 339;
366 glTranslatex = 340;
367 glTranslatexOES = 341;
368 glUniform1f = 342;
369 glUniform1fv = 343;
370 glUniform1i = 344;
371 glUniform1iv = 345;
372 glUniform2f = 346;
373 glUniform2fv = 347;
374 glUniform2i = 348;
375 glUniform2iv = 349;
376 glUniform3f = 350;
377 glUniform3fv = 351;
378 glUniform3i = 352;
379 glUniform3iv = 353;
380 glUniform4f = 354;
381 glUniform4fv = 355;
382 glUniform4i = 356;
383 glUniform4iv = 357;
384 glUniformMatrix2fv = 358;
385 glUniformMatrix3fv = 359;
386 glUniformMatrix4fv = 360;
387 glUnmapBufferOES = 361;
388 glUseProgram = 362;
389 glValidateProgram = 363;
390 glVertexAttrib1f = 364;
391 glVertexAttrib1fv = 365;
392 glVertexAttrib2f = 366;
393 glVertexAttrib2fv = 367;
394 glVertexAttrib3f = 368;
395 glVertexAttrib3fv = 369;
396 glVertexAttrib4f = 370;
397 glVertexAttrib4fv = 371;
398 glVertexAttribPointer = 372;
399 glVertexPointer = 373;
400 glViewport = 374;
401 glWeightPointerOES = 375;
402
403 eglGetDisplay = 2000;
404 eglInitialize = 2001;
405 eglTerminate = 2002;
406 eglGetConfigs = 2003;
407 eglChooseConfig = 2004;
408 eglGetConfigAttrib = 2005;
409 eglCreateWindowSurface = 2006;
410 eglCreatePixmapSurface = 2007;
411 eglCreatePbufferSurface = 2008;
412 eglDestroySurface = 2009;
413 eglQuerySurface = 2010;
414 eglCreateContext = 2011;
415 eglDestroyContext = 2012;
416 eglMakeCurrent = 2013;
417 eglGetCurrentContext = 2014;
418 eglGetCurrentSurface = 2015;
419 eglGetCurrentDisplay = 2016;
420 eglQueryContext = 2017;
421 eglWaitGL = 2018;
422 eglWaitNative = 2019;
423 eglSwapBuffers = 2020;
424 eglCopyBuffers = 2021;
425 eglGetError = 2022;
426 eglQueryString = 2023;
427 eglGetProcAddress = 2024;
428 eglSurfaceAttrib = 2025;
429 eglBindTexImage = 2026;
430 eglReleaseTexImage = 2027;
431 eglSwapInterval = 2028;
432 eglBindAPI = 2029;
433 eglQueryAPI = 2030;
434 eglWaitClient = 2031;
435 eglReleaseThread = 2032;
436 eglCreatePbufferFromClientBuffer = 2033;
437 eglLockSurfaceKHR = 2034;
438 eglUnlockSurfaceKHR = 2035;
439 eglCreateImageKHR = 2036;
440 eglDestroyImageKHR = 2037;
441 eglCreateSyncKHR = 2038;
442 eglDestroySyncKHR = 2039;
443 eglClientWaitSyncKHR = 2040;
444 eglGetSyncAttribKHR = 2041;
445 eglSetSwapRectangleANDROID = 2042;
446 eglGetRenderBufferANDROID = 2043;
447 eglGetSystemTimeFrequencyNV = 2044;
448 eglGetSystemTimeNV = 2045;
449
450 invalid = 3000;
451 frameBufferContents = 3001;
452 }
453
454 // A GL call's return data and arguments are formatted into this DataType
455 message DataType {
456 enum Type {
457 VOID = 1; // GLvoid
458 CHAR = 2; // GLchar
459 BYTE = 3; // GLbyte, GLubyte
460 INT = 4; // GLbitfield, GLshort, GLint, GLsizei, GLushort, GLuint, GLfixed
461 FLOAT = 5; // GLfloat, GLclampf
Siva Velusamyc0f838f2011-12-05 11:12:31 -0800462 BOOL = 6; // GLboolean
Siva Velusamydb974682011-11-30 15:05:37 -0800463 ENUM = 7; // GLenum
464 };
465
466 required Type type = 1 [default = VOID];
467 required bool isArray = 2 [default = false];
468
469 repeated int32 intValue = 3;
470 repeated float floatValue = 4;
471 repeated bytes charValue = 5;
472 repeated bytes rawBytes = 6;
473 repeated bool boolValue = 7;
474 }
475
Siva Velusamyc0f838f2011-12-05 11:12:31 -0800476 message FrameBuffer {
477 required int32 width = 1;
478 required int32 height = 2;
479 repeated bytes contents = 3;
480 }
481
Siva Velusamydb974682011-11-30 15:05:37 -0800482 required int32 context_id = 1; // GL context ID
483 required Function function = 2 [default = invalid]; // GL function called
484 repeated DataType args = 3; // GL function's arguments
485 optional DataType returnValue = 4; // GL function's return value
486 optional float duration = 5; // duration of GL call
Siva Velusamyc0f838f2011-12-05 11:12:31 -0800487 optional FrameBuffer fb = 6; // contents of the framebuffer
Siva Velusamydb974682011-11-30 15:05:37 -0800488};