• Home
  • Line#
  • Scopes#
  • Navigate#
  • Raw
  • Download
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file.
4 
5 // This file is auto-generated from
6 // gpu/command_buffer/build_gles2_cmd_buffer.py
7 // DO NOT EDIT!
8 
9 #ifndef GPU_COMMAND_BUFFER_CLIENT_GLES2_CMD_HELPER_AUTOGEN_H_
10 #define GPU_COMMAND_BUFFER_CLIENT_GLES2_CMD_HELPER_AUTOGEN_H_
11 
ActiveTexture(GLenum texture)12   void ActiveTexture(GLenum texture) {
13     gles2::cmds::ActiveTexture* c = GetCmdSpace<gles2::cmds::ActiveTexture>();
14     if (c) {
15       c->Init(texture);
16     }
17   }
18 
AttachShader(GLuint program,GLuint shader)19   void AttachShader(GLuint program, GLuint shader) {
20     gles2::cmds::AttachShader* c = GetCmdSpace<gles2::cmds::AttachShader>();
21     if (c) {
22       c->Init(program, shader);
23     }
24   }
25 
BindAttribLocation(GLuint program,GLuint index,uint32 name_shm_id,uint32 name_shm_offset,uint32 data_size)26   void BindAttribLocation(
27       GLuint program, GLuint index, uint32 name_shm_id, uint32 name_shm_offset,
28       uint32 data_size) {
29     gles2::cmds::BindAttribLocation* c =
30         GetCmdSpace<gles2::cmds::BindAttribLocation>();
31     if (c) {
32       c->Init(program, index, name_shm_id, name_shm_offset, data_size);
33     }
34   }
35 
BindAttribLocationBucket(GLuint program,GLuint index,uint32 name_bucket_id)36   void BindAttribLocationBucket(
37       GLuint program, GLuint index, uint32 name_bucket_id) {
38     gles2::cmds::BindAttribLocationBucket* c =
39         GetCmdSpace<gles2::cmds::BindAttribLocationBucket>();
40     if (c) {
41       c->Init(program, index, name_bucket_id);
42     }
43   }
44 
BindBuffer(GLenum target,GLuint buffer)45   void BindBuffer(GLenum target, GLuint buffer) {
46     gles2::cmds::BindBuffer* c = GetCmdSpace<gles2::cmds::BindBuffer>();
47     if (c) {
48       c->Init(target, buffer);
49     }
50   }
51 
BindFramebuffer(GLenum target,GLuint framebuffer)52   void BindFramebuffer(GLenum target, GLuint framebuffer) {
53     gles2::cmds::BindFramebuffer* c =
54         GetCmdSpace<gles2::cmds::BindFramebuffer>();
55     if (c) {
56       c->Init(target, framebuffer);
57     }
58   }
59 
BindRenderbuffer(GLenum target,GLuint renderbuffer)60   void BindRenderbuffer(GLenum target, GLuint renderbuffer) {
61     gles2::cmds::BindRenderbuffer* c =
62         GetCmdSpace<gles2::cmds::BindRenderbuffer>();
63     if (c) {
64       c->Init(target, renderbuffer);
65     }
66   }
67 
BindTexture(GLenum target,GLuint texture)68   void BindTexture(GLenum target, GLuint texture) {
69     gles2::cmds::BindTexture* c = GetCmdSpace<gles2::cmds::BindTexture>();
70     if (c) {
71       c->Init(target, texture);
72     }
73   }
74 
BlendColor(GLclampf red,GLclampf green,GLclampf blue,GLclampf alpha)75   void BlendColor(
76       GLclampf red, GLclampf green, GLclampf blue, GLclampf alpha) {
77     gles2::cmds::BlendColor* c = GetCmdSpace<gles2::cmds::BlendColor>();
78     if (c) {
79       c->Init(red, green, blue, alpha);
80     }
81   }
82 
BlendEquation(GLenum mode)83   void BlendEquation(GLenum mode) {
84     gles2::cmds::BlendEquation* c = GetCmdSpace<gles2::cmds::BlendEquation>();
85     if (c) {
86       c->Init(mode);
87     }
88   }
89 
BlendEquationSeparate(GLenum modeRGB,GLenum modeAlpha)90   void BlendEquationSeparate(GLenum modeRGB, GLenum modeAlpha) {
91     gles2::cmds::BlendEquationSeparate* c =
92         GetCmdSpace<gles2::cmds::BlendEquationSeparate>();
93     if (c) {
94       c->Init(modeRGB, modeAlpha);
95     }
96   }
97 
BlendFunc(GLenum sfactor,GLenum dfactor)98   void BlendFunc(GLenum sfactor, GLenum dfactor) {
99     gles2::cmds::BlendFunc* c = GetCmdSpace<gles2::cmds::BlendFunc>();
100     if (c) {
101       c->Init(sfactor, dfactor);
102     }
103   }
104 
BlendFuncSeparate(GLenum srcRGB,GLenum dstRGB,GLenum srcAlpha,GLenum dstAlpha)105   void BlendFuncSeparate(
106       GLenum srcRGB, GLenum dstRGB, GLenum srcAlpha, GLenum dstAlpha) {
107     gles2::cmds::BlendFuncSeparate* c =
108         GetCmdSpace<gles2::cmds::BlendFuncSeparate>();
109     if (c) {
110       c->Init(srcRGB, dstRGB, srcAlpha, dstAlpha);
111     }
112   }
113 
BufferData(GLenum target,GLsizeiptr size,uint32 data_shm_id,uint32 data_shm_offset,GLenum usage)114   void BufferData(
115       GLenum target, GLsizeiptr size, uint32 data_shm_id,
116       uint32 data_shm_offset, GLenum usage) {
117     gles2::cmds::BufferData* c = GetCmdSpace<gles2::cmds::BufferData>();
118     if (c) {
119       c->Init(target, size, data_shm_id, data_shm_offset, usage);
120     }
121   }
122 
BufferSubData(GLenum target,GLintptr offset,GLsizeiptr size,uint32 data_shm_id,uint32 data_shm_offset)123   void BufferSubData(
124       GLenum target, GLintptr offset, GLsizeiptr size, uint32 data_shm_id,
125       uint32 data_shm_offset) {
126     gles2::cmds::BufferSubData* c = GetCmdSpace<gles2::cmds::BufferSubData>();
127     if (c) {
128       c->Init(target, offset, size, data_shm_id, data_shm_offset);
129     }
130   }
131 
CheckFramebufferStatus(GLenum target,uint32 result_shm_id,uint32 result_shm_offset)132   void CheckFramebufferStatus(
133       GLenum target, uint32 result_shm_id, uint32 result_shm_offset) {
134     gles2::cmds::CheckFramebufferStatus* c =
135         GetCmdSpace<gles2::cmds::CheckFramebufferStatus>();
136     if (c) {
137       c->Init(target, result_shm_id, result_shm_offset);
138     }
139   }
140 
Clear(GLbitfield mask)141   void Clear(GLbitfield mask) {
142     gles2::cmds::Clear* c = GetCmdSpace<gles2::cmds::Clear>();
143     if (c) {
144       c->Init(mask);
145     }
146   }
147 
ClearColor(GLclampf red,GLclampf green,GLclampf blue,GLclampf alpha)148   void ClearColor(
149       GLclampf red, GLclampf green, GLclampf blue, GLclampf alpha) {
150     gles2::cmds::ClearColor* c = GetCmdSpace<gles2::cmds::ClearColor>();
151     if (c) {
152       c->Init(red, green, blue, alpha);
153     }
154   }
155 
ClearDepthf(GLclampf depth)156   void ClearDepthf(GLclampf depth) {
157     gles2::cmds::ClearDepthf* c = GetCmdSpace<gles2::cmds::ClearDepthf>();
158     if (c) {
159       c->Init(depth);
160     }
161   }
162 
ClearStencil(GLint s)163   void ClearStencil(GLint s) {
164     gles2::cmds::ClearStencil* c = GetCmdSpace<gles2::cmds::ClearStencil>();
165     if (c) {
166       c->Init(s);
167     }
168   }
169 
ColorMask(GLboolean red,GLboolean green,GLboolean blue,GLboolean alpha)170   void ColorMask(
171       GLboolean red, GLboolean green, GLboolean blue, GLboolean alpha) {
172     gles2::cmds::ColorMask* c = GetCmdSpace<gles2::cmds::ColorMask>();
173     if (c) {
174       c->Init(red, green, blue, alpha);
175     }
176   }
177 
CompileShader(GLuint shader)178   void CompileShader(GLuint shader) {
179     gles2::cmds::CompileShader* c = GetCmdSpace<gles2::cmds::CompileShader>();
180     if (c) {
181       c->Init(shader);
182     }
183   }
184 
CompressedTexImage2D(GLenum target,GLint level,GLenum internalformat,GLsizei width,GLsizei height,GLint border,GLsizei imageSize,uint32 data_shm_id,uint32 data_shm_offset)185   void CompressedTexImage2D(
186       GLenum target, GLint level, GLenum internalformat, GLsizei width,
187       GLsizei height, GLint border, GLsizei imageSize, uint32 data_shm_id,
188       uint32 data_shm_offset) {
189     gles2::cmds::CompressedTexImage2D* c =
190         GetCmdSpace<gles2::cmds::CompressedTexImage2D>();
191     if (c) {
192       c->Init(
193           target, level, internalformat, width, height, border, imageSize,
194           data_shm_id, data_shm_offset);
195     }
196   }
197 
CompressedTexImage2DBucket(GLenum target,GLint level,GLenum internalformat,GLsizei width,GLsizei height,GLint border,GLuint bucket_id)198   void CompressedTexImage2DBucket(
199       GLenum target, GLint level, GLenum internalformat, GLsizei width,
200       GLsizei height, GLint border, GLuint bucket_id) {
201     gles2::cmds::CompressedTexImage2DBucket* c =
202         GetCmdSpace<gles2::cmds::CompressedTexImage2DBucket>();
203     if (c) {
204       c->Init(target, level, internalformat, width, height, border, bucket_id);
205     }
206   }
207 
CompressedTexSubImage2D(GLenum target,GLint level,GLint xoffset,GLint yoffset,GLsizei width,GLsizei height,GLenum format,GLsizei imageSize,uint32 data_shm_id,uint32 data_shm_offset)208   void CompressedTexSubImage2D(
209       GLenum target, GLint level, GLint xoffset, GLint yoffset, GLsizei width,
210       GLsizei height, GLenum format, GLsizei imageSize, uint32 data_shm_id,
211       uint32 data_shm_offset) {
212     gles2::cmds::CompressedTexSubImage2D* c =
213         GetCmdSpace<gles2::cmds::CompressedTexSubImage2D>();
214     if (c) {
215       c->Init(
216           target, level, xoffset, yoffset, width, height, format, imageSize,
217           data_shm_id, data_shm_offset);
218     }
219   }
220 
CompressedTexSubImage2DBucket(GLenum target,GLint level,GLint xoffset,GLint yoffset,GLsizei width,GLsizei height,GLenum format,GLuint bucket_id)221   void CompressedTexSubImage2DBucket(
222       GLenum target, GLint level, GLint xoffset, GLint yoffset, GLsizei width,
223       GLsizei height, GLenum format, GLuint bucket_id) {
224     gles2::cmds::CompressedTexSubImage2DBucket* c =
225         GetCmdSpace<gles2::cmds::CompressedTexSubImage2DBucket>();
226     if (c) {
227       c->Init(
228           target, level, xoffset, yoffset, width, height, format, bucket_id);
229     }
230   }
231 
CopyTexImage2D(GLenum target,GLint level,GLenum internalformat,GLint x,GLint y,GLsizei width,GLsizei height,GLint border)232   void CopyTexImage2D(
233       GLenum target, GLint level, GLenum internalformat, GLint x, GLint y,
234       GLsizei width, GLsizei height, GLint border) {
235     gles2::cmds::CopyTexImage2D* c =
236         GetCmdSpace<gles2::cmds::CopyTexImage2D>();
237     if (c) {
238       c->Init(target, level, internalformat, x, y, width, height, border);
239     }
240   }
241 
CopyTexSubImage2D(GLenum target,GLint level,GLint xoffset,GLint yoffset,GLint x,GLint y,GLsizei width,GLsizei height)242   void CopyTexSubImage2D(
243       GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint x,
244       GLint y, GLsizei width, GLsizei height) {
245     gles2::cmds::CopyTexSubImage2D* c =
246         GetCmdSpace<gles2::cmds::CopyTexSubImage2D>();
247     if (c) {
248       c->Init(target, level, xoffset, yoffset, x, y, width, height);
249     }
250   }
251 
CreateProgram(uint32 client_id)252   void CreateProgram(uint32 client_id) {
253     gles2::cmds::CreateProgram* c = GetCmdSpace<gles2::cmds::CreateProgram>();
254     if (c) {
255       c->Init(client_id);
256     }
257   }
258 
CreateShader(GLenum type,uint32 client_id)259   void CreateShader(GLenum type, uint32 client_id) {
260     gles2::cmds::CreateShader* c = GetCmdSpace<gles2::cmds::CreateShader>();
261     if (c) {
262       c->Init(type, client_id);
263     }
264   }
265 
CullFace(GLenum mode)266   void CullFace(GLenum mode) {
267     gles2::cmds::CullFace* c = GetCmdSpace<gles2::cmds::CullFace>();
268     if (c) {
269       c->Init(mode);
270     }
271   }
272 
DeleteBuffers(GLsizei n,uint32 buffers_shm_id,uint32 buffers_shm_offset)273   void DeleteBuffers(
274       GLsizei n, uint32 buffers_shm_id, uint32 buffers_shm_offset) {
275     gles2::cmds::DeleteBuffers* c = GetCmdSpace<gles2::cmds::DeleteBuffers>();
276     if (c) {
277       c->Init(n, buffers_shm_id, buffers_shm_offset);
278     }
279   }
280 
DeleteBuffersImmediate(GLsizei n,const GLuint * buffers)281   void DeleteBuffersImmediate(GLsizei n, const GLuint* buffers) {
282     const uint32 size = gles2::cmds::DeleteBuffersImmediate::ComputeSize(n);
283     gles2::cmds::DeleteBuffersImmediate* c =
284         GetImmediateCmdSpaceTotalSize<gles2::cmds::DeleteBuffersImmediate>(
285             size);
286     if (c) {
287       c->Init(n, buffers);
288     }
289   }
290 
DeleteFramebuffers(GLsizei n,uint32 framebuffers_shm_id,uint32 framebuffers_shm_offset)291   void DeleteFramebuffers(
292       GLsizei n, uint32 framebuffers_shm_id, uint32 framebuffers_shm_offset) {
293     gles2::cmds::DeleteFramebuffers* c =
294         GetCmdSpace<gles2::cmds::DeleteFramebuffers>();
295     if (c) {
296       c->Init(n, framebuffers_shm_id, framebuffers_shm_offset);
297     }
298   }
299 
DeleteFramebuffersImmediate(GLsizei n,const GLuint * framebuffers)300   void DeleteFramebuffersImmediate(GLsizei n, const GLuint* framebuffers) {
301     const uint32 size =
302         gles2::cmds::DeleteFramebuffersImmediate::ComputeSize(n);
303     gles2::cmds::DeleteFramebuffersImmediate* c =
304         GetImmediateCmdSpaceTotalSize<gles2::cmds::DeleteFramebuffersImmediate>(
305             size);
306     if (c) {
307       c->Init(n, framebuffers);
308     }
309   }
310 
DeleteProgram(GLuint program)311   void DeleteProgram(GLuint program) {
312     gles2::cmds::DeleteProgram* c = GetCmdSpace<gles2::cmds::DeleteProgram>();
313     if (c) {
314       c->Init(program);
315     }
316   }
317 
DeleteRenderbuffers(GLsizei n,uint32 renderbuffers_shm_id,uint32 renderbuffers_shm_offset)318   void DeleteRenderbuffers(
319       GLsizei n, uint32 renderbuffers_shm_id,
320       uint32 renderbuffers_shm_offset) {
321     gles2::cmds::DeleteRenderbuffers* c =
322         GetCmdSpace<gles2::cmds::DeleteRenderbuffers>();
323     if (c) {
324       c->Init(n, renderbuffers_shm_id, renderbuffers_shm_offset);
325     }
326   }
327 
DeleteRenderbuffersImmediate(GLsizei n,const GLuint * renderbuffers)328   void DeleteRenderbuffersImmediate(GLsizei n, const GLuint* renderbuffers) {
329     const uint32 size =
330         gles2::cmds::DeleteRenderbuffersImmediate::ComputeSize(n);
331     gles2::cmds::DeleteRenderbuffersImmediate* c =
332         GetImmediateCmdSpaceTotalSize<gles2::cmds::DeleteRenderbuffersImmediate>(size);  // NOLINT
333     if (c) {
334       c->Init(n, renderbuffers);
335     }
336   }
337 
DeleteShader(GLuint shader)338   void DeleteShader(GLuint shader) {
339     gles2::cmds::DeleteShader* c = GetCmdSpace<gles2::cmds::DeleteShader>();
340     if (c) {
341       c->Init(shader);
342     }
343   }
344 
DeleteTextures(GLsizei n,uint32 textures_shm_id,uint32 textures_shm_offset)345   void DeleteTextures(
346       GLsizei n, uint32 textures_shm_id, uint32 textures_shm_offset) {
347     gles2::cmds::DeleteTextures* c =
348         GetCmdSpace<gles2::cmds::DeleteTextures>();
349     if (c) {
350       c->Init(n, textures_shm_id, textures_shm_offset);
351     }
352   }
353 
DeleteTexturesImmediate(GLsizei n,const GLuint * textures)354   void DeleteTexturesImmediate(GLsizei n, const GLuint* textures) {
355     const uint32 size = gles2::cmds::DeleteTexturesImmediate::ComputeSize(n);
356     gles2::cmds::DeleteTexturesImmediate* c =
357         GetImmediateCmdSpaceTotalSize<gles2::cmds::DeleteTexturesImmediate>(
358             size);
359     if (c) {
360       c->Init(n, textures);
361     }
362   }
363 
DepthFunc(GLenum func)364   void DepthFunc(GLenum func) {
365     gles2::cmds::DepthFunc* c = GetCmdSpace<gles2::cmds::DepthFunc>();
366     if (c) {
367       c->Init(func);
368     }
369   }
370 
DepthMask(GLboolean flag)371   void DepthMask(GLboolean flag) {
372     gles2::cmds::DepthMask* c = GetCmdSpace<gles2::cmds::DepthMask>();
373     if (c) {
374       c->Init(flag);
375     }
376   }
377 
DepthRangef(GLclampf zNear,GLclampf zFar)378   void DepthRangef(GLclampf zNear, GLclampf zFar) {
379     gles2::cmds::DepthRangef* c = GetCmdSpace<gles2::cmds::DepthRangef>();
380     if (c) {
381       c->Init(zNear, zFar);
382     }
383   }
384 
DetachShader(GLuint program,GLuint shader)385   void DetachShader(GLuint program, GLuint shader) {
386     gles2::cmds::DetachShader* c = GetCmdSpace<gles2::cmds::DetachShader>();
387     if (c) {
388       c->Init(program, shader);
389     }
390   }
391 
Disable(GLenum cap)392   void Disable(GLenum cap) {
393     gles2::cmds::Disable* c = GetCmdSpace<gles2::cmds::Disable>();
394     if (c) {
395       c->Init(cap);
396     }
397   }
398 
DisableVertexAttribArray(GLuint index)399   void DisableVertexAttribArray(GLuint index) {
400     gles2::cmds::DisableVertexAttribArray* c =
401         GetCmdSpace<gles2::cmds::DisableVertexAttribArray>();
402     if (c) {
403       c->Init(index);
404     }
405   }
406 
DrawArrays(GLenum mode,GLint first,GLsizei count)407   void DrawArrays(GLenum mode, GLint first, GLsizei count) {
408     gles2::cmds::DrawArrays* c = GetCmdSpace<gles2::cmds::DrawArrays>();
409     if (c) {
410       c->Init(mode, first, count);
411     }
412   }
413 
DrawElements(GLenum mode,GLsizei count,GLenum type,GLuint index_offset)414   void DrawElements(
415       GLenum mode, GLsizei count, GLenum type, GLuint index_offset) {
416     gles2::cmds::DrawElements* c = GetCmdSpace<gles2::cmds::DrawElements>();
417     if (c) {
418       c->Init(mode, count, type, index_offset);
419     }
420   }
421 
Enable(GLenum cap)422   void Enable(GLenum cap) {
423     gles2::cmds::Enable* c = GetCmdSpace<gles2::cmds::Enable>();
424     if (c) {
425       c->Init(cap);
426     }
427   }
428 
EnableVertexAttribArray(GLuint index)429   void EnableVertexAttribArray(GLuint index) {
430     gles2::cmds::EnableVertexAttribArray* c =
431         GetCmdSpace<gles2::cmds::EnableVertexAttribArray>();
432     if (c) {
433       c->Init(index);
434     }
435   }
436 
Finish()437   void Finish() {
438     gles2::cmds::Finish* c = GetCmdSpace<gles2::cmds::Finish>();
439     if (c) {
440       c->Init();
441     }
442   }
443 
Flush()444   void Flush() {
445     gles2::cmds::Flush* c = GetCmdSpace<gles2::cmds::Flush>();
446     if (c) {
447       c->Init();
448     }
449   }
450 
FramebufferRenderbuffer(GLenum target,GLenum attachment,GLenum renderbuffertarget,GLuint renderbuffer)451   void FramebufferRenderbuffer(
452       GLenum target, GLenum attachment, GLenum renderbuffertarget,
453       GLuint renderbuffer) {
454     gles2::cmds::FramebufferRenderbuffer* c =
455         GetCmdSpace<gles2::cmds::FramebufferRenderbuffer>();
456     if (c) {
457       c->Init(target, attachment, renderbuffertarget, renderbuffer);
458     }
459   }
460 
FramebufferTexture2D(GLenum target,GLenum attachment,GLenum textarget,GLuint texture,GLint level)461   void FramebufferTexture2D(
462       GLenum target, GLenum attachment, GLenum textarget, GLuint texture,
463       GLint level) {
464     gles2::cmds::FramebufferTexture2D* c =
465         GetCmdSpace<gles2::cmds::FramebufferTexture2D>();
466     if (c) {
467       c->Init(target, attachment, textarget, texture, level);
468     }
469   }
470 
FrontFace(GLenum mode)471   void FrontFace(GLenum mode) {
472     gles2::cmds::FrontFace* c = GetCmdSpace<gles2::cmds::FrontFace>();
473     if (c) {
474       c->Init(mode);
475     }
476   }
477 
GenBuffers(GLsizei n,uint32 buffers_shm_id,uint32 buffers_shm_offset)478   void GenBuffers(
479       GLsizei n, uint32 buffers_shm_id, uint32 buffers_shm_offset) {
480     gles2::cmds::GenBuffers* c = GetCmdSpace<gles2::cmds::GenBuffers>();
481     if (c) {
482       c->Init(n, buffers_shm_id, buffers_shm_offset);
483     }
484   }
485 
GenBuffersImmediate(GLsizei n,GLuint * buffers)486   void GenBuffersImmediate(GLsizei n, GLuint* buffers) {
487     const uint32 size = gles2::cmds::GenBuffersImmediate::ComputeSize(n);
488     gles2::cmds::GenBuffersImmediate* c =
489         GetImmediateCmdSpaceTotalSize<gles2::cmds::GenBuffersImmediate>(size);
490     if (c) {
491       c->Init(n, buffers);
492     }
493   }
494 
GenerateMipmap(GLenum target)495   void GenerateMipmap(GLenum target) {
496     gles2::cmds::GenerateMipmap* c =
497         GetCmdSpace<gles2::cmds::GenerateMipmap>();
498     if (c) {
499       c->Init(target);
500     }
501   }
502 
GenFramebuffers(GLsizei n,uint32 framebuffers_shm_id,uint32 framebuffers_shm_offset)503   void GenFramebuffers(
504       GLsizei n, uint32 framebuffers_shm_id, uint32 framebuffers_shm_offset) {
505     gles2::cmds::GenFramebuffers* c =
506         GetCmdSpace<gles2::cmds::GenFramebuffers>();
507     if (c) {
508       c->Init(n, framebuffers_shm_id, framebuffers_shm_offset);
509     }
510   }
511 
GenFramebuffersImmediate(GLsizei n,GLuint * framebuffers)512   void GenFramebuffersImmediate(GLsizei n, GLuint* framebuffers) {
513     const uint32 size = gles2::cmds::GenFramebuffersImmediate::ComputeSize(n);
514     gles2::cmds::GenFramebuffersImmediate* c =
515         GetImmediateCmdSpaceTotalSize<gles2::cmds::GenFramebuffersImmediate>(
516             size);
517     if (c) {
518       c->Init(n, framebuffers);
519     }
520   }
521 
GenRenderbuffers(GLsizei n,uint32 renderbuffers_shm_id,uint32 renderbuffers_shm_offset)522   void GenRenderbuffers(
523       GLsizei n, uint32 renderbuffers_shm_id,
524       uint32 renderbuffers_shm_offset) {
525     gles2::cmds::GenRenderbuffers* c =
526         GetCmdSpace<gles2::cmds::GenRenderbuffers>();
527     if (c) {
528       c->Init(n, renderbuffers_shm_id, renderbuffers_shm_offset);
529     }
530   }
531 
GenRenderbuffersImmediate(GLsizei n,GLuint * renderbuffers)532   void GenRenderbuffersImmediate(GLsizei n, GLuint* renderbuffers) {
533     const uint32 size = gles2::cmds::GenRenderbuffersImmediate::ComputeSize(n);
534     gles2::cmds::GenRenderbuffersImmediate* c =
535         GetImmediateCmdSpaceTotalSize<gles2::cmds::GenRenderbuffersImmediate>(
536             size);
537     if (c) {
538       c->Init(n, renderbuffers);
539     }
540   }
541 
GenTextures(GLsizei n,uint32 textures_shm_id,uint32 textures_shm_offset)542   void GenTextures(
543       GLsizei n, uint32 textures_shm_id, uint32 textures_shm_offset) {
544     gles2::cmds::GenTextures* c = GetCmdSpace<gles2::cmds::GenTextures>();
545     if (c) {
546       c->Init(n, textures_shm_id, textures_shm_offset);
547     }
548   }
549 
GenTexturesImmediate(GLsizei n,GLuint * textures)550   void GenTexturesImmediate(GLsizei n, GLuint* textures) {
551     const uint32 size = gles2::cmds::GenTexturesImmediate::ComputeSize(n);
552     gles2::cmds::GenTexturesImmediate* c =
553         GetImmediateCmdSpaceTotalSize<gles2::cmds::GenTexturesImmediate>(size);
554     if (c) {
555       c->Init(n, textures);
556     }
557   }
558 
GetActiveAttrib(GLuint program,GLuint index,uint32 name_bucket_id,uint32 result_shm_id,uint32 result_shm_offset)559   void GetActiveAttrib(
560       GLuint program, GLuint index, uint32 name_bucket_id, uint32 result_shm_id,
561       uint32 result_shm_offset) {
562     gles2::cmds::GetActiveAttrib* c =
563         GetCmdSpace<gles2::cmds::GetActiveAttrib>();
564     if (c) {
565       c->Init(
566           program, index, name_bucket_id, result_shm_id, result_shm_offset);
567     }
568   }
569 
GetActiveUniform(GLuint program,GLuint index,uint32 name_bucket_id,uint32 result_shm_id,uint32 result_shm_offset)570   void GetActiveUniform(
571       GLuint program, GLuint index, uint32 name_bucket_id, uint32 result_shm_id,
572       uint32 result_shm_offset) {
573     gles2::cmds::GetActiveUniform* c =
574         GetCmdSpace<gles2::cmds::GetActiveUniform>();
575     if (c) {
576       c->Init(
577           program, index, name_bucket_id, result_shm_id, result_shm_offset);
578     }
579   }
580 
GetAttachedShaders(GLuint program,uint32 result_shm_id,uint32 result_shm_offset,uint32 result_size)581   void GetAttachedShaders(
582       GLuint program, uint32 result_shm_id, uint32 result_shm_offset,
583       uint32 result_size) {
584     gles2::cmds::GetAttachedShaders* c =
585         GetCmdSpace<gles2::cmds::GetAttachedShaders>();
586     if (c) {
587       c->Init(program, result_shm_id, result_shm_offset, result_size);
588     }
589   }
590 
GetBooleanv(GLenum pname,uint32 params_shm_id,uint32 params_shm_offset)591   void GetBooleanv(
592       GLenum pname, uint32 params_shm_id, uint32 params_shm_offset) {
593     gles2::cmds::GetBooleanv* c = GetCmdSpace<gles2::cmds::GetBooleanv>();
594     if (c) {
595       c->Init(pname, params_shm_id, params_shm_offset);
596     }
597   }
598 
GetBufferParameteriv(GLenum target,GLenum pname,uint32 params_shm_id,uint32 params_shm_offset)599   void GetBufferParameteriv(
600       GLenum target, GLenum pname, uint32 params_shm_id,
601       uint32 params_shm_offset) {
602     gles2::cmds::GetBufferParameteriv* c =
603         GetCmdSpace<gles2::cmds::GetBufferParameteriv>();
604     if (c) {
605       c->Init(target, pname, params_shm_id, params_shm_offset);
606     }
607   }
608 
GetError(uint32 result_shm_id,uint32 result_shm_offset)609   void GetError(uint32 result_shm_id, uint32 result_shm_offset) {
610     gles2::cmds::GetError* c = GetCmdSpace<gles2::cmds::GetError>();
611     if (c) {
612       c->Init(result_shm_id, result_shm_offset);
613     }
614   }
615 
GetFloatv(GLenum pname,uint32 params_shm_id,uint32 params_shm_offset)616   void GetFloatv(
617       GLenum pname, uint32 params_shm_id, uint32 params_shm_offset) {
618     gles2::cmds::GetFloatv* c = GetCmdSpace<gles2::cmds::GetFloatv>();
619     if (c) {
620       c->Init(pname, params_shm_id, params_shm_offset);
621     }
622   }
623 
GetFramebufferAttachmentParameteriv(GLenum target,GLenum attachment,GLenum pname,uint32 params_shm_id,uint32 params_shm_offset)624   void GetFramebufferAttachmentParameteriv(
625       GLenum target, GLenum attachment, GLenum pname, uint32 params_shm_id,
626       uint32 params_shm_offset) {
627     gles2::cmds::GetFramebufferAttachmentParameteriv* c =
628         GetCmdSpace<gles2::cmds::GetFramebufferAttachmentParameteriv>();
629     if (c) {
630       c->Init(target, attachment, pname, params_shm_id, params_shm_offset);
631     }
632   }
633 
GetIntegerv(GLenum pname,uint32 params_shm_id,uint32 params_shm_offset)634   void GetIntegerv(
635       GLenum pname, uint32 params_shm_id, uint32 params_shm_offset) {
636     gles2::cmds::GetIntegerv* c = GetCmdSpace<gles2::cmds::GetIntegerv>();
637     if (c) {
638       c->Init(pname, params_shm_id, params_shm_offset);
639     }
640   }
641 
GetProgramiv(GLuint program,GLenum pname,uint32 params_shm_id,uint32 params_shm_offset)642   void GetProgramiv(
643       GLuint program, GLenum pname, uint32 params_shm_id,
644       uint32 params_shm_offset) {
645     gles2::cmds::GetProgramiv* c = GetCmdSpace<gles2::cmds::GetProgramiv>();
646     if (c) {
647       c->Init(program, pname, params_shm_id, params_shm_offset);
648     }
649   }
650 
GetProgramInfoLog(GLuint program,uint32 bucket_id)651   void GetProgramInfoLog(GLuint program, uint32 bucket_id) {
652     gles2::cmds::GetProgramInfoLog* c =
653         GetCmdSpace<gles2::cmds::GetProgramInfoLog>();
654     if (c) {
655       c->Init(program, bucket_id);
656     }
657   }
658 
GetRenderbufferParameteriv(GLenum target,GLenum pname,uint32 params_shm_id,uint32 params_shm_offset)659   void GetRenderbufferParameteriv(
660       GLenum target, GLenum pname, uint32 params_shm_id,
661       uint32 params_shm_offset) {
662     gles2::cmds::GetRenderbufferParameteriv* c =
663         GetCmdSpace<gles2::cmds::GetRenderbufferParameteriv>();
664     if (c) {
665       c->Init(target, pname, params_shm_id, params_shm_offset);
666     }
667   }
668 
GetShaderiv(GLuint shader,GLenum pname,uint32 params_shm_id,uint32 params_shm_offset)669   void GetShaderiv(
670       GLuint shader, GLenum pname, uint32 params_shm_id,
671       uint32 params_shm_offset) {
672     gles2::cmds::GetShaderiv* c = GetCmdSpace<gles2::cmds::GetShaderiv>();
673     if (c) {
674       c->Init(shader, pname, params_shm_id, params_shm_offset);
675     }
676   }
677 
GetShaderInfoLog(GLuint shader,uint32 bucket_id)678   void GetShaderInfoLog(GLuint shader, uint32 bucket_id) {
679     gles2::cmds::GetShaderInfoLog* c =
680         GetCmdSpace<gles2::cmds::GetShaderInfoLog>();
681     if (c) {
682       c->Init(shader, bucket_id);
683     }
684   }
685 
GetShaderPrecisionFormat(GLenum shadertype,GLenum precisiontype,uint32 result_shm_id,uint32 result_shm_offset)686   void GetShaderPrecisionFormat(
687       GLenum shadertype, GLenum precisiontype, uint32 result_shm_id,
688       uint32 result_shm_offset) {
689     gles2::cmds::GetShaderPrecisionFormat* c =
690         GetCmdSpace<gles2::cmds::GetShaderPrecisionFormat>();
691     if (c) {
692       c->Init(shadertype, precisiontype, result_shm_id, result_shm_offset);
693     }
694   }
695 
GetShaderSource(GLuint shader,uint32 bucket_id)696   void GetShaderSource(GLuint shader, uint32 bucket_id) {
697     gles2::cmds::GetShaderSource* c =
698         GetCmdSpace<gles2::cmds::GetShaderSource>();
699     if (c) {
700       c->Init(shader, bucket_id);
701     }
702   }
703 
GetString(GLenum name,uint32 bucket_id)704   void GetString(GLenum name, uint32 bucket_id) {
705     gles2::cmds::GetString* c = GetCmdSpace<gles2::cmds::GetString>();
706     if (c) {
707       c->Init(name, bucket_id);
708     }
709   }
710 
GetTexParameterfv(GLenum target,GLenum pname,uint32 params_shm_id,uint32 params_shm_offset)711   void GetTexParameterfv(
712       GLenum target, GLenum pname, uint32 params_shm_id,
713       uint32 params_shm_offset) {
714     gles2::cmds::GetTexParameterfv* c =
715         GetCmdSpace<gles2::cmds::GetTexParameterfv>();
716     if (c) {
717       c->Init(target, pname, params_shm_id, params_shm_offset);
718     }
719   }
720 
GetTexParameteriv(GLenum target,GLenum pname,uint32 params_shm_id,uint32 params_shm_offset)721   void GetTexParameteriv(
722       GLenum target, GLenum pname, uint32 params_shm_id,
723       uint32 params_shm_offset) {
724     gles2::cmds::GetTexParameteriv* c =
725         GetCmdSpace<gles2::cmds::GetTexParameteriv>();
726     if (c) {
727       c->Init(target, pname, params_shm_id, params_shm_offset);
728     }
729   }
730 
GetUniformfv(GLuint program,GLint location,uint32 params_shm_id,uint32 params_shm_offset)731   void GetUniformfv(
732       GLuint program, GLint location, uint32 params_shm_id,
733       uint32 params_shm_offset) {
734     gles2::cmds::GetUniformfv* c = GetCmdSpace<gles2::cmds::GetUniformfv>();
735     if (c) {
736       c->Init(program, location, params_shm_id, params_shm_offset);
737     }
738   }
739 
GetUniformiv(GLuint program,GLint location,uint32 params_shm_id,uint32 params_shm_offset)740   void GetUniformiv(
741       GLuint program, GLint location, uint32 params_shm_id,
742       uint32 params_shm_offset) {
743     gles2::cmds::GetUniformiv* c = GetCmdSpace<gles2::cmds::GetUniformiv>();
744     if (c) {
745       c->Init(program, location, params_shm_id, params_shm_offset);
746     }
747   }
748 
GetVertexAttribfv(GLuint index,GLenum pname,uint32 params_shm_id,uint32 params_shm_offset)749   void GetVertexAttribfv(
750       GLuint index, GLenum pname, uint32 params_shm_id,
751       uint32 params_shm_offset) {
752     gles2::cmds::GetVertexAttribfv* c =
753         GetCmdSpace<gles2::cmds::GetVertexAttribfv>();
754     if (c) {
755       c->Init(index, pname, params_shm_id, params_shm_offset);
756     }
757   }
758 
GetVertexAttribiv(GLuint index,GLenum pname,uint32 params_shm_id,uint32 params_shm_offset)759   void GetVertexAttribiv(
760       GLuint index, GLenum pname, uint32 params_shm_id,
761       uint32 params_shm_offset) {
762     gles2::cmds::GetVertexAttribiv* c =
763         GetCmdSpace<gles2::cmds::GetVertexAttribiv>();
764     if (c) {
765       c->Init(index, pname, params_shm_id, params_shm_offset);
766     }
767   }
768 
GetVertexAttribPointerv(GLuint index,GLenum pname,uint32 pointer_shm_id,uint32 pointer_shm_offset)769   void GetVertexAttribPointerv(
770       GLuint index, GLenum pname, uint32 pointer_shm_id,
771       uint32 pointer_shm_offset) {
772     gles2::cmds::GetVertexAttribPointerv* c =
773         GetCmdSpace<gles2::cmds::GetVertexAttribPointerv>();
774     if (c) {
775       c->Init(index, pname, pointer_shm_id, pointer_shm_offset);
776     }
777   }
778 
Hint(GLenum target,GLenum mode)779   void Hint(GLenum target, GLenum mode) {
780     gles2::cmds::Hint* c = GetCmdSpace<gles2::cmds::Hint>();
781     if (c) {
782       c->Init(target, mode);
783     }
784   }
785 
IsBuffer(GLuint buffer,uint32 result_shm_id,uint32 result_shm_offset)786   void IsBuffer(
787       GLuint buffer, uint32 result_shm_id, uint32 result_shm_offset) {
788     gles2::cmds::IsBuffer* c = GetCmdSpace<gles2::cmds::IsBuffer>();
789     if (c) {
790       c->Init(buffer, result_shm_id, result_shm_offset);
791     }
792   }
793 
IsEnabled(GLenum cap,uint32 result_shm_id,uint32 result_shm_offset)794   void IsEnabled(GLenum cap, uint32 result_shm_id, uint32 result_shm_offset) {
795     gles2::cmds::IsEnabled* c = GetCmdSpace<gles2::cmds::IsEnabled>();
796     if (c) {
797       c->Init(cap, result_shm_id, result_shm_offset);
798     }
799   }
800 
IsFramebuffer(GLuint framebuffer,uint32 result_shm_id,uint32 result_shm_offset)801   void IsFramebuffer(
802       GLuint framebuffer, uint32 result_shm_id, uint32 result_shm_offset) {
803     gles2::cmds::IsFramebuffer* c = GetCmdSpace<gles2::cmds::IsFramebuffer>();
804     if (c) {
805       c->Init(framebuffer, result_shm_id, result_shm_offset);
806     }
807   }
808 
IsProgram(GLuint program,uint32 result_shm_id,uint32 result_shm_offset)809   void IsProgram(
810       GLuint program, uint32 result_shm_id, uint32 result_shm_offset) {
811     gles2::cmds::IsProgram* c = GetCmdSpace<gles2::cmds::IsProgram>();
812     if (c) {
813       c->Init(program, result_shm_id, result_shm_offset);
814     }
815   }
816 
IsRenderbuffer(GLuint renderbuffer,uint32 result_shm_id,uint32 result_shm_offset)817   void IsRenderbuffer(
818       GLuint renderbuffer, uint32 result_shm_id, uint32 result_shm_offset) {
819     gles2::cmds::IsRenderbuffer* c =
820         GetCmdSpace<gles2::cmds::IsRenderbuffer>();
821     if (c) {
822       c->Init(renderbuffer, result_shm_id, result_shm_offset);
823     }
824   }
825 
IsShader(GLuint shader,uint32 result_shm_id,uint32 result_shm_offset)826   void IsShader(
827       GLuint shader, uint32 result_shm_id, uint32 result_shm_offset) {
828     gles2::cmds::IsShader* c = GetCmdSpace<gles2::cmds::IsShader>();
829     if (c) {
830       c->Init(shader, result_shm_id, result_shm_offset);
831     }
832   }
833 
IsTexture(GLuint texture,uint32 result_shm_id,uint32 result_shm_offset)834   void IsTexture(
835       GLuint texture, uint32 result_shm_id, uint32 result_shm_offset) {
836     gles2::cmds::IsTexture* c = GetCmdSpace<gles2::cmds::IsTexture>();
837     if (c) {
838       c->Init(texture, result_shm_id, result_shm_offset);
839     }
840   }
841 
LineWidth(GLfloat width)842   void LineWidth(GLfloat width) {
843     gles2::cmds::LineWidth* c = GetCmdSpace<gles2::cmds::LineWidth>();
844     if (c) {
845       c->Init(width);
846     }
847   }
848 
LinkProgram(GLuint program)849   void LinkProgram(GLuint program) {
850     gles2::cmds::LinkProgram* c = GetCmdSpace<gles2::cmds::LinkProgram>();
851     if (c) {
852       c->Init(program);
853     }
854   }
855 
PixelStorei(GLenum pname,GLint param)856   void PixelStorei(GLenum pname, GLint param) {
857     gles2::cmds::PixelStorei* c = GetCmdSpace<gles2::cmds::PixelStorei>();
858     if (c) {
859       c->Init(pname, param);
860     }
861   }
862 
PolygonOffset(GLfloat factor,GLfloat units)863   void PolygonOffset(GLfloat factor, GLfloat units) {
864     gles2::cmds::PolygonOffset* c = GetCmdSpace<gles2::cmds::PolygonOffset>();
865     if (c) {
866       c->Init(factor, units);
867     }
868   }
869 
ReadPixels(GLint x,GLint y,GLsizei width,GLsizei height,GLenum format,GLenum type,uint32 pixels_shm_id,uint32 pixels_shm_offset,uint32 result_shm_id,uint32 result_shm_offset,GLboolean async)870   void ReadPixels(
871       GLint x, GLint y, GLsizei width, GLsizei height, GLenum format,
872       GLenum type, uint32 pixels_shm_id, uint32 pixels_shm_offset,
873       uint32 result_shm_id, uint32 result_shm_offset, GLboolean async) {
874     gles2::cmds::ReadPixels* c = GetCmdSpace<gles2::cmds::ReadPixels>();
875     if (c) {
876       c->Init(
877           x, y, width, height, format, type, pixels_shm_id, pixels_shm_offset,
878           result_shm_id, result_shm_offset, async);
879     }
880   }
881 
ReleaseShaderCompiler()882   void ReleaseShaderCompiler() {
883     gles2::cmds::ReleaseShaderCompiler* c =
884         GetCmdSpace<gles2::cmds::ReleaseShaderCompiler>();
885     if (c) {
886       c->Init();
887     }
888   }
889 
RenderbufferStorage(GLenum target,GLenum internalformat,GLsizei width,GLsizei height)890   void RenderbufferStorage(
891       GLenum target, GLenum internalformat, GLsizei width, GLsizei height) {
892     gles2::cmds::RenderbufferStorage* c =
893         GetCmdSpace<gles2::cmds::RenderbufferStorage>();
894     if (c) {
895       c->Init(target, internalformat, width, height);
896     }
897   }
898 
SampleCoverage(GLclampf value,GLboolean invert)899   void SampleCoverage(GLclampf value, GLboolean invert) {
900     gles2::cmds::SampleCoverage* c =
901         GetCmdSpace<gles2::cmds::SampleCoverage>();
902     if (c) {
903       c->Init(value, invert);
904     }
905   }
906 
Scissor(GLint x,GLint y,GLsizei width,GLsizei height)907   void Scissor(GLint x, GLint y, GLsizei width, GLsizei height) {
908     gles2::cmds::Scissor* c = GetCmdSpace<gles2::cmds::Scissor>();
909     if (c) {
910       c->Init(x, y, width, height);
911     }
912   }
913 
ShaderBinary(GLsizei n,uint32 shaders_shm_id,uint32 shaders_shm_offset,GLenum binaryformat,uint32 binary_shm_id,uint32 binary_shm_offset,GLsizei length)914   void ShaderBinary(
915       GLsizei n, uint32 shaders_shm_id, uint32 shaders_shm_offset,
916       GLenum binaryformat, uint32 binary_shm_id, uint32 binary_shm_offset,
917       GLsizei length) {
918     gles2::cmds::ShaderBinary* c = GetCmdSpace<gles2::cmds::ShaderBinary>();
919     if (c) {
920       c->Init(
921           n, shaders_shm_id, shaders_shm_offset, binaryformat, binary_shm_id,
922           binary_shm_offset, length);
923     }
924   }
925 
ShaderSource(GLuint shader,uint32 data_shm_id,uint32 data_shm_offset,uint32 data_size)926   void ShaderSource(
927       GLuint shader, uint32 data_shm_id, uint32 data_shm_offset,
928       uint32 data_size) {
929     gles2::cmds::ShaderSource* c = GetCmdSpace<gles2::cmds::ShaderSource>();
930     if (c) {
931       c->Init(shader, data_shm_id, data_shm_offset, data_size);
932     }
933   }
934 
ShaderSourceBucket(GLuint shader,uint32 data_bucket_id)935   void ShaderSourceBucket(GLuint shader, uint32 data_bucket_id) {
936     gles2::cmds::ShaderSourceBucket* c =
937         GetCmdSpace<gles2::cmds::ShaderSourceBucket>();
938     if (c) {
939       c->Init(shader, data_bucket_id);
940     }
941   }
942 
StencilFunc(GLenum func,GLint ref,GLuint mask)943   void StencilFunc(GLenum func, GLint ref, GLuint mask) {
944     gles2::cmds::StencilFunc* c = GetCmdSpace<gles2::cmds::StencilFunc>();
945     if (c) {
946       c->Init(func, ref, mask);
947     }
948   }
949 
StencilFuncSeparate(GLenum face,GLenum func,GLint ref,GLuint mask)950   void StencilFuncSeparate(GLenum face, GLenum func, GLint ref, GLuint mask) {
951     gles2::cmds::StencilFuncSeparate* c =
952         GetCmdSpace<gles2::cmds::StencilFuncSeparate>();
953     if (c) {
954       c->Init(face, func, ref, mask);
955     }
956   }
957 
StencilMask(GLuint mask)958   void StencilMask(GLuint mask) {
959     gles2::cmds::StencilMask* c = GetCmdSpace<gles2::cmds::StencilMask>();
960     if (c) {
961       c->Init(mask);
962     }
963   }
964 
StencilMaskSeparate(GLenum face,GLuint mask)965   void StencilMaskSeparate(GLenum face, GLuint mask) {
966     gles2::cmds::StencilMaskSeparate* c =
967         GetCmdSpace<gles2::cmds::StencilMaskSeparate>();
968     if (c) {
969       c->Init(face, mask);
970     }
971   }
972 
StencilOp(GLenum fail,GLenum zfail,GLenum zpass)973   void StencilOp(GLenum fail, GLenum zfail, GLenum zpass) {
974     gles2::cmds::StencilOp* c = GetCmdSpace<gles2::cmds::StencilOp>();
975     if (c) {
976       c->Init(fail, zfail, zpass);
977     }
978   }
979 
StencilOpSeparate(GLenum face,GLenum fail,GLenum zfail,GLenum zpass)980   void StencilOpSeparate(
981       GLenum face, GLenum fail, GLenum zfail, GLenum zpass) {
982     gles2::cmds::StencilOpSeparate* c =
983         GetCmdSpace<gles2::cmds::StencilOpSeparate>();
984     if (c) {
985       c->Init(face, fail, zfail, zpass);
986     }
987   }
988 
TexImage2D(GLenum target,GLint level,GLint internalformat,GLsizei width,GLsizei height,GLint border,GLenum format,GLenum type,uint32 pixels_shm_id,uint32 pixels_shm_offset)989   void TexImage2D(
990       GLenum target, GLint level, GLint internalformat, GLsizei width,
991       GLsizei height, GLint border, GLenum format, GLenum type,
992       uint32 pixels_shm_id, uint32 pixels_shm_offset) {
993     gles2::cmds::TexImage2D* c = GetCmdSpace<gles2::cmds::TexImage2D>();
994     if (c) {
995       c->Init(
996           target, level, internalformat, width, height, border, format, type,
997           pixels_shm_id, pixels_shm_offset);
998     }
999   }
1000 
TexParameterf(GLenum target,GLenum pname,GLfloat param)1001   void TexParameterf(GLenum target, GLenum pname, GLfloat param) {
1002     gles2::cmds::TexParameterf* c = GetCmdSpace<gles2::cmds::TexParameterf>();
1003     if (c) {
1004       c->Init(target, pname, param);
1005     }
1006   }
1007 
TexParameterfv(GLenum target,GLenum pname,uint32 params_shm_id,uint32 params_shm_offset)1008   void TexParameterfv(
1009       GLenum target, GLenum pname, uint32 params_shm_id,
1010       uint32 params_shm_offset) {
1011     gles2::cmds::TexParameterfv* c =
1012         GetCmdSpace<gles2::cmds::TexParameterfv>();
1013     if (c) {
1014       c->Init(target, pname, params_shm_id, params_shm_offset);
1015     }
1016   }
1017 
TexParameterfvImmediate(GLenum target,GLenum pname,const GLfloat * params)1018   void TexParameterfvImmediate(
1019       GLenum target, GLenum pname, const GLfloat* params) {
1020     const uint32 size = gles2::cmds::TexParameterfvImmediate::ComputeSize();
1021     gles2::cmds::TexParameterfvImmediate* c =
1022         GetImmediateCmdSpaceTotalSize<gles2::cmds::TexParameterfvImmediate>(
1023             size);
1024     if (c) {
1025       c->Init(target, pname, params);
1026     }
1027   }
1028 
TexParameteri(GLenum target,GLenum pname,GLint param)1029   void TexParameteri(GLenum target, GLenum pname, GLint param) {
1030     gles2::cmds::TexParameteri* c = GetCmdSpace<gles2::cmds::TexParameteri>();
1031     if (c) {
1032       c->Init(target, pname, param);
1033     }
1034   }
1035 
TexParameteriv(GLenum target,GLenum pname,uint32 params_shm_id,uint32 params_shm_offset)1036   void TexParameteriv(
1037       GLenum target, GLenum pname, uint32 params_shm_id,
1038       uint32 params_shm_offset) {
1039     gles2::cmds::TexParameteriv* c =
1040         GetCmdSpace<gles2::cmds::TexParameteriv>();
1041     if (c) {
1042       c->Init(target, pname, params_shm_id, params_shm_offset);
1043     }
1044   }
1045 
TexParameterivImmediate(GLenum target,GLenum pname,const GLint * params)1046   void TexParameterivImmediate(
1047       GLenum target, GLenum pname, const GLint* params) {
1048     const uint32 size = gles2::cmds::TexParameterivImmediate::ComputeSize();
1049     gles2::cmds::TexParameterivImmediate* c =
1050         GetImmediateCmdSpaceTotalSize<gles2::cmds::TexParameterivImmediate>(
1051             size);
1052     if (c) {
1053       c->Init(target, pname, params);
1054     }
1055   }
1056 
TexSubImage2D(GLenum target,GLint level,GLint xoffset,GLint yoffset,GLsizei width,GLsizei height,GLenum format,GLenum type,uint32 pixels_shm_id,uint32 pixels_shm_offset,GLboolean internal)1057   void TexSubImage2D(
1058       GLenum target, GLint level, GLint xoffset, GLint yoffset, GLsizei width,
1059       GLsizei height, GLenum format, GLenum type, uint32 pixels_shm_id,
1060       uint32 pixels_shm_offset, GLboolean internal) {
1061     gles2::cmds::TexSubImage2D* c = GetCmdSpace<gles2::cmds::TexSubImage2D>();
1062     if (c) {
1063       c->Init(
1064           target, level, xoffset, yoffset, width, height, format, type,
1065           pixels_shm_id, pixels_shm_offset, internal);
1066     }
1067   }
1068 
Uniform1f(GLint location,GLfloat x)1069   void Uniform1f(GLint location, GLfloat x) {
1070     gles2::cmds::Uniform1f* c = GetCmdSpace<gles2::cmds::Uniform1f>();
1071     if (c) {
1072       c->Init(location, x);
1073     }
1074   }
1075 
Uniform1fv(GLint location,GLsizei count,uint32 v_shm_id,uint32 v_shm_offset)1076   void Uniform1fv(
1077       GLint location, GLsizei count, uint32 v_shm_id, uint32 v_shm_offset) {
1078     gles2::cmds::Uniform1fv* c = GetCmdSpace<gles2::cmds::Uniform1fv>();
1079     if (c) {
1080       c->Init(location, count, v_shm_id, v_shm_offset);
1081     }
1082   }
1083 
Uniform1fvImmediate(GLint location,GLsizei count,const GLfloat * v)1084   void Uniform1fvImmediate(GLint location, GLsizei count, const GLfloat* v) {
1085     const uint32 size = gles2::cmds::Uniform1fvImmediate::ComputeSize(count);
1086     gles2::cmds::Uniform1fvImmediate* c =
1087         GetImmediateCmdSpaceTotalSize<gles2::cmds::Uniform1fvImmediate>(size);
1088     if (c) {
1089       c->Init(location, count, v);
1090     }
1091   }
1092 
Uniform1i(GLint location,GLint x)1093   void Uniform1i(GLint location, GLint x) {
1094     gles2::cmds::Uniform1i* c = GetCmdSpace<gles2::cmds::Uniform1i>();
1095     if (c) {
1096       c->Init(location, x);
1097     }
1098   }
1099 
Uniform1iv(GLint location,GLsizei count,uint32 v_shm_id,uint32 v_shm_offset)1100   void Uniform1iv(
1101       GLint location, GLsizei count, uint32 v_shm_id, uint32 v_shm_offset) {
1102     gles2::cmds::Uniform1iv* c = GetCmdSpace<gles2::cmds::Uniform1iv>();
1103     if (c) {
1104       c->Init(location, count, v_shm_id, v_shm_offset);
1105     }
1106   }
1107 
Uniform1ivImmediate(GLint location,GLsizei count,const GLint * v)1108   void Uniform1ivImmediate(GLint location, GLsizei count, const GLint* v) {
1109     const uint32 size = gles2::cmds::Uniform1ivImmediate::ComputeSize(count);
1110     gles2::cmds::Uniform1ivImmediate* c =
1111         GetImmediateCmdSpaceTotalSize<gles2::cmds::Uniform1ivImmediate>(size);
1112     if (c) {
1113       c->Init(location, count, v);
1114     }
1115   }
1116 
Uniform2f(GLint location,GLfloat x,GLfloat y)1117   void Uniform2f(GLint location, GLfloat x, GLfloat y) {
1118     gles2::cmds::Uniform2f* c = GetCmdSpace<gles2::cmds::Uniform2f>();
1119     if (c) {
1120       c->Init(location, x, y);
1121     }
1122   }
1123 
Uniform2fv(GLint location,GLsizei count,uint32 v_shm_id,uint32 v_shm_offset)1124   void Uniform2fv(
1125       GLint location, GLsizei count, uint32 v_shm_id, uint32 v_shm_offset) {
1126     gles2::cmds::Uniform2fv* c = GetCmdSpace<gles2::cmds::Uniform2fv>();
1127     if (c) {
1128       c->Init(location, count, v_shm_id, v_shm_offset);
1129     }
1130   }
1131 
Uniform2fvImmediate(GLint location,GLsizei count,const GLfloat * v)1132   void Uniform2fvImmediate(GLint location, GLsizei count, const GLfloat* v) {
1133     const uint32 size = gles2::cmds::Uniform2fvImmediate::ComputeSize(count);
1134     gles2::cmds::Uniform2fvImmediate* c =
1135         GetImmediateCmdSpaceTotalSize<gles2::cmds::Uniform2fvImmediate>(size);
1136     if (c) {
1137       c->Init(location, count, v);
1138     }
1139   }
1140 
Uniform2i(GLint location,GLint x,GLint y)1141   void Uniform2i(GLint location, GLint x, GLint y) {
1142     gles2::cmds::Uniform2i* c = GetCmdSpace<gles2::cmds::Uniform2i>();
1143     if (c) {
1144       c->Init(location, x, y);
1145     }
1146   }
1147 
Uniform2iv(GLint location,GLsizei count,uint32 v_shm_id,uint32 v_shm_offset)1148   void Uniform2iv(
1149       GLint location, GLsizei count, uint32 v_shm_id, uint32 v_shm_offset) {
1150     gles2::cmds::Uniform2iv* c = GetCmdSpace<gles2::cmds::Uniform2iv>();
1151     if (c) {
1152       c->Init(location, count, v_shm_id, v_shm_offset);
1153     }
1154   }
1155 
Uniform2ivImmediate(GLint location,GLsizei count,const GLint * v)1156   void Uniform2ivImmediate(GLint location, GLsizei count, const GLint* v) {
1157     const uint32 size = gles2::cmds::Uniform2ivImmediate::ComputeSize(count);
1158     gles2::cmds::Uniform2ivImmediate* c =
1159         GetImmediateCmdSpaceTotalSize<gles2::cmds::Uniform2ivImmediate>(size);
1160     if (c) {
1161       c->Init(location, count, v);
1162     }
1163   }
1164 
Uniform3f(GLint location,GLfloat x,GLfloat y,GLfloat z)1165   void Uniform3f(GLint location, GLfloat x, GLfloat y, GLfloat z) {
1166     gles2::cmds::Uniform3f* c = GetCmdSpace<gles2::cmds::Uniform3f>();
1167     if (c) {
1168       c->Init(location, x, y, z);
1169     }
1170   }
1171 
Uniform3fv(GLint location,GLsizei count,uint32 v_shm_id,uint32 v_shm_offset)1172   void Uniform3fv(
1173       GLint location, GLsizei count, uint32 v_shm_id, uint32 v_shm_offset) {
1174     gles2::cmds::Uniform3fv* c = GetCmdSpace<gles2::cmds::Uniform3fv>();
1175     if (c) {
1176       c->Init(location, count, v_shm_id, v_shm_offset);
1177     }
1178   }
1179 
Uniform3fvImmediate(GLint location,GLsizei count,const GLfloat * v)1180   void Uniform3fvImmediate(GLint location, GLsizei count, const GLfloat* v) {
1181     const uint32 size = gles2::cmds::Uniform3fvImmediate::ComputeSize(count);
1182     gles2::cmds::Uniform3fvImmediate* c =
1183         GetImmediateCmdSpaceTotalSize<gles2::cmds::Uniform3fvImmediate>(size);
1184     if (c) {
1185       c->Init(location, count, v);
1186     }
1187   }
1188 
Uniform3i(GLint location,GLint x,GLint y,GLint z)1189   void Uniform3i(GLint location, GLint x, GLint y, GLint z) {
1190     gles2::cmds::Uniform3i* c = GetCmdSpace<gles2::cmds::Uniform3i>();
1191     if (c) {
1192       c->Init(location, x, y, z);
1193     }
1194   }
1195 
Uniform3iv(GLint location,GLsizei count,uint32 v_shm_id,uint32 v_shm_offset)1196   void Uniform3iv(
1197       GLint location, GLsizei count, uint32 v_shm_id, uint32 v_shm_offset) {
1198     gles2::cmds::Uniform3iv* c = GetCmdSpace<gles2::cmds::Uniform3iv>();
1199     if (c) {
1200       c->Init(location, count, v_shm_id, v_shm_offset);
1201     }
1202   }
1203 
Uniform3ivImmediate(GLint location,GLsizei count,const GLint * v)1204   void Uniform3ivImmediate(GLint location, GLsizei count, const GLint* v) {
1205     const uint32 size = gles2::cmds::Uniform3ivImmediate::ComputeSize(count);
1206     gles2::cmds::Uniform3ivImmediate* c =
1207         GetImmediateCmdSpaceTotalSize<gles2::cmds::Uniform3ivImmediate>(size);
1208     if (c) {
1209       c->Init(location, count, v);
1210     }
1211   }
1212 
Uniform4f(GLint location,GLfloat x,GLfloat y,GLfloat z,GLfloat w)1213   void Uniform4f(GLint location, GLfloat x, GLfloat y, GLfloat z, GLfloat w) {
1214     gles2::cmds::Uniform4f* c = GetCmdSpace<gles2::cmds::Uniform4f>();
1215     if (c) {
1216       c->Init(location, x, y, z, w);
1217     }
1218   }
1219 
Uniform4fv(GLint location,GLsizei count,uint32 v_shm_id,uint32 v_shm_offset)1220   void Uniform4fv(
1221       GLint location, GLsizei count, uint32 v_shm_id, uint32 v_shm_offset) {
1222     gles2::cmds::Uniform4fv* c = GetCmdSpace<gles2::cmds::Uniform4fv>();
1223     if (c) {
1224       c->Init(location, count, v_shm_id, v_shm_offset);
1225     }
1226   }
1227 
Uniform4fvImmediate(GLint location,GLsizei count,const GLfloat * v)1228   void Uniform4fvImmediate(GLint location, GLsizei count, const GLfloat* v) {
1229     const uint32 size = gles2::cmds::Uniform4fvImmediate::ComputeSize(count);
1230     gles2::cmds::Uniform4fvImmediate* c =
1231         GetImmediateCmdSpaceTotalSize<gles2::cmds::Uniform4fvImmediate>(size);
1232     if (c) {
1233       c->Init(location, count, v);
1234     }
1235   }
1236 
Uniform4i(GLint location,GLint x,GLint y,GLint z,GLint w)1237   void Uniform4i(GLint location, GLint x, GLint y, GLint z, GLint w) {
1238     gles2::cmds::Uniform4i* c = GetCmdSpace<gles2::cmds::Uniform4i>();
1239     if (c) {
1240       c->Init(location, x, y, z, w);
1241     }
1242   }
1243 
Uniform4iv(GLint location,GLsizei count,uint32 v_shm_id,uint32 v_shm_offset)1244   void Uniform4iv(
1245       GLint location, GLsizei count, uint32 v_shm_id, uint32 v_shm_offset) {
1246     gles2::cmds::Uniform4iv* c = GetCmdSpace<gles2::cmds::Uniform4iv>();
1247     if (c) {
1248       c->Init(location, count, v_shm_id, v_shm_offset);
1249     }
1250   }
1251 
Uniform4ivImmediate(GLint location,GLsizei count,const GLint * v)1252   void Uniform4ivImmediate(GLint location, GLsizei count, const GLint* v) {
1253     const uint32 size = gles2::cmds::Uniform4ivImmediate::ComputeSize(count);
1254     gles2::cmds::Uniform4ivImmediate* c =
1255         GetImmediateCmdSpaceTotalSize<gles2::cmds::Uniform4ivImmediate>(size);
1256     if (c) {
1257       c->Init(location, count, v);
1258     }
1259   }
1260 
UniformMatrix2fv(GLint location,GLsizei count,GLboolean transpose,uint32 value_shm_id,uint32 value_shm_offset)1261   void UniformMatrix2fv(
1262       GLint location, GLsizei count, GLboolean transpose, uint32 value_shm_id,
1263       uint32 value_shm_offset) {
1264     gles2::cmds::UniformMatrix2fv* c =
1265         GetCmdSpace<gles2::cmds::UniformMatrix2fv>();
1266     if (c) {
1267       c->Init(location, count, transpose, value_shm_id, value_shm_offset);
1268     }
1269   }
1270 
UniformMatrix2fvImmediate(GLint location,GLsizei count,GLboolean transpose,const GLfloat * value)1271   void UniformMatrix2fvImmediate(
1272       GLint location, GLsizei count, GLboolean transpose,
1273       const GLfloat* value) {
1274     const uint32 size =
1275         gles2::cmds::UniformMatrix2fvImmediate::ComputeSize(count);
1276     gles2::cmds::UniformMatrix2fvImmediate* c =
1277         GetImmediateCmdSpaceTotalSize<gles2::cmds::UniformMatrix2fvImmediate>(
1278             size);
1279     if (c) {
1280       c->Init(location, count, transpose, value);
1281     }
1282   }
1283 
UniformMatrix3fv(GLint location,GLsizei count,GLboolean transpose,uint32 value_shm_id,uint32 value_shm_offset)1284   void UniformMatrix3fv(
1285       GLint location, GLsizei count, GLboolean transpose, uint32 value_shm_id,
1286       uint32 value_shm_offset) {
1287     gles2::cmds::UniformMatrix3fv* c =
1288         GetCmdSpace<gles2::cmds::UniformMatrix3fv>();
1289     if (c) {
1290       c->Init(location, count, transpose, value_shm_id, value_shm_offset);
1291     }
1292   }
1293 
UniformMatrix3fvImmediate(GLint location,GLsizei count,GLboolean transpose,const GLfloat * value)1294   void UniformMatrix3fvImmediate(
1295       GLint location, GLsizei count, GLboolean transpose,
1296       const GLfloat* value) {
1297     const uint32 size =
1298         gles2::cmds::UniformMatrix3fvImmediate::ComputeSize(count);
1299     gles2::cmds::UniformMatrix3fvImmediate* c =
1300         GetImmediateCmdSpaceTotalSize<gles2::cmds::UniformMatrix3fvImmediate>(
1301             size);
1302     if (c) {
1303       c->Init(location, count, transpose, value);
1304     }
1305   }
1306 
UniformMatrix4fv(GLint location,GLsizei count,GLboolean transpose,uint32 value_shm_id,uint32 value_shm_offset)1307   void UniformMatrix4fv(
1308       GLint location, GLsizei count, GLboolean transpose, uint32 value_shm_id,
1309       uint32 value_shm_offset) {
1310     gles2::cmds::UniformMatrix4fv* c =
1311         GetCmdSpace<gles2::cmds::UniformMatrix4fv>();
1312     if (c) {
1313       c->Init(location, count, transpose, value_shm_id, value_shm_offset);
1314     }
1315   }
1316 
UniformMatrix4fvImmediate(GLint location,GLsizei count,GLboolean transpose,const GLfloat * value)1317   void UniformMatrix4fvImmediate(
1318       GLint location, GLsizei count, GLboolean transpose,
1319       const GLfloat* value) {
1320     const uint32 size =
1321         gles2::cmds::UniformMatrix4fvImmediate::ComputeSize(count);
1322     gles2::cmds::UniformMatrix4fvImmediate* c =
1323         GetImmediateCmdSpaceTotalSize<gles2::cmds::UniformMatrix4fvImmediate>(
1324             size);
1325     if (c) {
1326       c->Init(location, count, transpose, value);
1327     }
1328   }
1329 
UseProgram(GLuint program)1330   void UseProgram(GLuint program) {
1331     gles2::cmds::UseProgram* c = GetCmdSpace<gles2::cmds::UseProgram>();
1332     if (c) {
1333       c->Init(program);
1334     }
1335   }
1336 
ValidateProgram(GLuint program)1337   void ValidateProgram(GLuint program) {
1338     gles2::cmds::ValidateProgram* c =
1339         GetCmdSpace<gles2::cmds::ValidateProgram>();
1340     if (c) {
1341       c->Init(program);
1342     }
1343   }
1344 
VertexAttrib1f(GLuint indx,GLfloat x)1345   void VertexAttrib1f(GLuint indx, GLfloat x) {
1346     gles2::cmds::VertexAttrib1f* c =
1347         GetCmdSpace<gles2::cmds::VertexAttrib1f>();
1348     if (c) {
1349       c->Init(indx, x);
1350     }
1351   }
1352 
VertexAttrib1fv(GLuint indx,uint32 values_shm_id,uint32 values_shm_offset)1353   void VertexAttrib1fv(
1354       GLuint indx, uint32 values_shm_id, uint32 values_shm_offset) {
1355     gles2::cmds::VertexAttrib1fv* c =
1356         GetCmdSpace<gles2::cmds::VertexAttrib1fv>();
1357     if (c) {
1358       c->Init(indx, values_shm_id, values_shm_offset);
1359     }
1360   }
1361 
VertexAttrib1fvImmediate(GLuint indx,const GLfloat * values)1362   void VertexAttrib1fvImmediate(GLuint indx, const GLfloat* values) {
1363     const uint32 size = gles2::cmds::VertexAttrib1fvImmediate::ComputeSize();
1364     gles2::cmds::VertexAttrib1fvImmediate* c =
1365         GetImmediateCmdSpaceTotalSize<gles2::cmds::VertexAttrib1fvImmediate>(
1366             size);
1367     if (c) {
1368       c->Init(indx, values);
1369     }
1370   }
1371 
VertexAttrib2f(GLuint indx,GLfloat x,GLfloat y)1372   void VertexAttrib2f(GLuint indx, GLfloat x, GLfloat y) {
1373     gles2::cmds::VertexAttrib2f* c =
1374         GetCmdSpace<gles2::cmds::VertexAttrib2f>();
1375     if (c) {
1376       c->Init(indx, x, y);
1377     }
1378   }
1379 
VertexAttrib2fv(GLuint indx,uint32 values_shm_id,uint32 values_shm_offset)1380   void VertexAttrib2fv(
1381       GLuint indx, uint32 values_shm_id, uint32 values_shm_offset) {
1382     gles2::cmds::VertexAttrib2fv* c =
1383         GetCmdSpace<gles2::cmds::VertexAttrib2fv>();
1384     if (c) {
1385       c->Init(indx, values_shm_id, values_shm_offset);
1386     }
1387   }
1388 
VertexAttrib2fvImmediate(GLuint indx,const GLfloat * values)1389   void VertexAttrib2fvImmediate(GLuint indx, const GLfloat* values) {
1390     const uint32 size = gles2::cmds::VertexAttrib2fvImmediate::ComputeSize();
1391     gles2::cmds::VertexAttrib2fvImmediate* c =
1392         GetImmediateCmdSpaceTotalSize<gles2::cmds::VertexAttrib2fvImmediate>(
1393             size);
1394     if (c) {
1395       c->Init(indx, values);
1396     }
1397   }
1398 
VertexAttrib3f(GLuint indx,GLfloat x,GLfloat y,GLfloat z)1399   void VertexAttrib3f(GLuint indx, GLfloat x, GLfloat y, GLfloat z) {
1400     gles2::cmds::VertexAttrib3f* c =
1401         GetCmdSpace<gles2::cmds::VertexAttrib3f>();
1402     if (c) {
1403       c->Init(indx, x, y, z);
1404     }
1405   }
1406 
VertexAttrib3fv(GLuint indx,uint32 values_shm_id,uint32 values_shm_offset)1407   void VertexAttrib3fv(
1408       GLuint indx, uint32 values_shm_id, uint32 values_shm_offset) {
1409     gles2::cmds::VertexAttrib3fv* c =
1410         GetCmdSpace<gles2::cmds::VertexAttrib3fv>();
1411     if (c) {
1412       c->Init(indx, values_shm_id, values_shm_offset);
1413     }
1414   }
1415 
VertexAttrib3fvImmediate(GLuint indx,const GLfloat * values)1416   void VertexAttrib3fvImmediate(GLuint indx, const GLfloat* values) {
1417     const uint32 size = gles2::cmds::VertexAttrib3fvImmediate::ComputeSize();
1418     gles2::cmds::VertexAttrib3fvImmediate* c =
1419         GetImmediateCmdSpaceTotalSize<gles2::cmds::VertexAttrib3fvImmediate>(
1420             size);
1421     if (c) {
1422       c->Init(indx, values);
1423     }
1424   }
1425 
VertexAttrib4f(GLuint indx,GLfloat x,GLfloat y,GLfloat z,GLfloat w)1426   void VertexAttrib4f(
1427       GLuint indx, GLfloat x, GLfloat y, GLfloat z, GLfloat w) {
1428     gles2::cmds::VertexAttrib4f* c =
1429         GetCmdSpace<gles2::cmds::VertexAttrib4f>();
1430     if (c) {
1431       c->Init(indx, x, y, z, w);
1432     }
1433   }
1434 
VertexAttrib4fv(GLuint indx,uint32 values_shm_id,uint32 values_shm_offset)1435   void VertexAttrib4fv(
1436       GLuint indx, uint32 values_shm_id, uint32 values_shm_offset) {
1437     gles2::cmds::VertexAttrib4fv* c =
1438         GetCmdSpace<gles2::cmds::VertexAttrib4fv>();
1439     if (c) {
1440       c->Init(indx, values_shm_id, values_shm_offset);
1441     }
1442   }
1443 
VertexAttrib4fvImmediate(GLuint indx,const GLfloat * values)1444   void VertexAttrib4fvImmediate(GLuint indx, const GLfloat* values) {
1445     const uint32 size = gles2::cmds::VertexAttrib4fvImmediate::ComputeSize();
1446     gles2::cmds::VertexAttrib4fvImmediate* c =
1447         GetImmediateCmdSpaceTotalSize<gles2::cmds::VertexAttrib4fvImmediate>(
1448             size);
1449     if (c) {
1450       c->Init(indx, values);
1451     }
1452   }
1453 
VertexAttribPointer(GLuint indx,GLint size,GLenum type,GLboolean normalized,GLsizei stride,GLuint offset)1454   void VertexAttribPointer(
1455       GLuint indx, GLint size, GLenum type, GLboolean normalized,
1456       GLsizei stride, GLuint offset) {
1457     gles2::cmds::VertexAttribPointer* c =
1458         GetCmdSpace<gles2::cmds::VertexAttribPointer>();
1459     if (c) {
1460       c->Init(indx, size, type, normalized, stride, offset);
1461     }
1462   }
1463 
Viewport(GLint x,GLint y,GLsizei width,GLsizei height)1464   void Viewport(GLint x, GLint y, GLsizei width, GLsizei height) {
1465     gles2::cmds::Viewport* c = GetCmdSpace<gles2::cmds::Viewport>();
1466     if (c) {
1467       c->Init(x, y, width, height);
1468     }
1469   }
1470 
BlitFramebufferCHROMIUM(GLint srcX0,GLint srcY0,GLint srcX1,GLint srcY1,GLint dstX0,GLint dstY0,GLint dstX1,GLint dstY1,GLbitfield mask,GLenum filter)1471   void BlitFramebufferCHROMIUM(
1472       GLint srcX0, GLint srcY0, GLint srcX1, GLint srcY1, GLint dstX0,
1473       GLint dstY0, GLint dstX1, GLint dstY1, GLbitfield mask, GLenum filter) {
1474     gles2::cmds::BlitFramebufferCHROMIUM* c =
1475         GetCmdSpace<gles2::cmds::BlitFramebufferCHROMIUM>();
1476     if (c) {
1477       c->Init(
1478           srcX0, srcY0, srcX1, srcY1, dstX0, dstY0, dstX1, dstY1, mask,
1479           filter);
1480     }
1481   }
1482 
RenderbufferStorageMultisampleCHROMIUM(GLenum target,GLsizei samples,GLenum internalformat,GLsizei width,GLsizei height)1483   void RenderbufferStorageMultisampleCHROMIUM(
1484       GLenum target, GLsizei samples, GLenum internalformat, GLsizei width,
1485       GLsizei height) {
1486     gles2::cmds::RenderbufferStorageMultisampleCHROMIUM* c =
1487         GetCmdSpace<gles2::cmds::RenderbufferStorageMultisampleCHROMIUM>();
1488     if (c) {
1489       c->Init(target, samples, internalformat, width, height);
1490     }
1491   }
1492 
RenderbufferStorageMultisampleEXT(GLenum target,GLsizei samples,GLenum internalformat,GLsizei width,GLsizei height)1493   void RenderbufferStorageMultisampleEXT(
1494       GLenum target, GLsizei samples, GLenum internalformat, GLsizei width,
1495       GLsizei height) {
1496     gles2::cmds::RenderbufferStorageMultisampleEXT* c =
1497         GetCmdSpace<gles2::cmds::RenderbufferStorageMultisampleEXT>();
1498     if (c) {
1499       c->Init(target, samples, internalformat, width, height);
1500     }
1501   }
1502 
FramebufferTexture2DMultisampleEXT(GLenum target,GLenum attachment,GLenum textarget,GLuint texture,GLint level,GLsizei samples)1503   void FramebufferTexture2DMultisampleEXT(
1504       GLenum target, GLenum attachment, GLenum textarget, GLuint texture,
1505       GLint level, GLsizei samples) {
1506     gles2::cmds::FramebufferTexture2DMultisampleEXT* c =
1507         GetCmdSpace<gles2::cmds::FramebufferTexture2DMultisampleEXT>();
1508     if (c) {
1509       c->Init(target, attachment, textarget, texture, level, samples);
1510     }
1511   }
1512 
TexStorage2DEXT(GLenum target,GLsizei levels,GLenum internalFormat,GLsizei width,GLsizei height)1513   void TexStorage2DEXT(
1514       GLenum target, GLsizei levels, GLenum internalFormat, GLsizei width,
1515       GLsizei height) {
1516     gles2::cmds::TexStorage2DEXT* c =
1517         GetCmdSpace<gles2::cmds::TexStorage2DEXT>();
1518     if (c) {
1519       c->Init(target, levels, internalFormat, width, height);
1520     }
1521   }
1522 
GenQueriesEXT(GLsizei n,uint32 queries_shm_id,uint32 queries_shm_offset)1523   void GenQueriesEXT(
1524       GLsizei n, uint32 queries_shm_id, uint32 queries_shm_offset) {
1525     gles2::cmds::GenQueriesEXT* c = GetCmdSpace<gles2::cmds::GenQueriesEXT>();
1526     if (c) {
1527       c->Init(n, queries_shm_id, queries_shm_offset);
1528     }
1529   }
1530 
GenQueriesEXTImmediate(GLsizei n,GLuint * queries)1531   void GenQueriesEXTImmediate(GLsizei n, GLuint* queries) {
1532     const uint32 size = gles2::cmds::GenQueriesEXTImmediate::ComputeSize(n);
1533     gles2::cmds::GenQueriesEXTImmediate* c =
1534         GetImmediateCmdSpaceTotalSize<gles2::cmds::GenQueriesEXTImmediate>(
1535             size);
1536     if (c) {
1537       c->Init(n, queries);
1538     }
1539   }
1540 
DeleteQueriesEXT(GLsizei n,uint32 queries_shm_id,uint32 queries_shm_offset)1541   void DeleteQueriesEXT(
1542       GLsizei n, uint32 queries_shm_id, uint32 queries_shm_offset) {
1543     gles2::cmds::DeleteQueriesEXT* c =
1544         GetCmdSpace<gles2::cmds::DeleteQueriesEXT>();
1545     if (c) {
1546       c->Init(n, queries_shm_id, queries_shm_offset);
1547     }
1548   }
1549 
DeleteQueriesEXTImmediate(GLsizei n,const GLuint * queries)1550   void DeleteQueriesEXTImmediate(GLsizei n, const GLuint* queries) {
1551     const uint32 size = gles2::cmds::DeleteQueriesEXTImmediate::ComputeSize(n);
1552     gles2::cmds::DeleteQueriesEXTImmediate* c =
1553         GetImmediateCmdSpaceTotalSize<gles2::cmds::DeleteQueriesEXTImmediate>(
1554             size);
1555     if (c) {
1556       c->Init(n, queries);
1557     }
1558   }
1559 
BeginQueryEXT(GLenum target,GLuint id,uint32 sync_data_shm_id,uint32 sync_data_shm_offset)1560   void BeginQueryEXT(
1561       GLenum target, GLuint id, uint32 sync_data_shm_id,
1562       uint32 sync_data_shm_offset) {
1563     gles2::cmds::BeginQueryEXT* c = GetCmdSpace<gles2::cmds::BeginQueryEXT>();
1564     if (c) {
1565       c->Init(target, id, sync_data_shm_id, sync_data_shm_offset);
1566     }
1567   }
1568 
EndQueryEXT(GLenum target,GLuint submit_count)1569   void EndQueryEXT(GLenum target, GLuint submit_count) {
1570     gles2::cmds::EndQueryEXT* c = GetCmdSpace<gles2::cmds::EndQueryEXT>();
1571     if (c) {
1572       c->Init(target, submit_count);
1573     }
1574   }
1575 
InsertEventMarkerEXT(GLuint bucket_id)1576   void InsertEventMarkerEXT(GLuint bucket_id) {
1577     gles2::cmds::InsertEventMarkerEXT* c =
1578         GetCmdSpace<gles2::cmds::InsertEventMarkerEXT>();
1579     if (c) {
1580       c->Init(bucket_id);
1581     }
1582   }
1583 
PushGroupMarkerEXT(GLuint bucket_id)1584   void PushGroupMarkerEXT(GLuint bucket_id) {
1585     gles2::cmds::PushGroupMarkerEXT* c =
1586         GetCmdSpace<gles2::cmds::PushGroupMarkerEXT>();
1587     if (c) {
1588       c->Init(bucket_id);
1589     }
1590   }
1591 
PopGroupMarkerEXT()1592   void PopGroupMarkerEXT() {
1593     gles2::cmds::PopGroupMarkerEXT* c =
1594         GetCmdSpace<gles2::cmds::PopGroupMarkerEXT>();
1595     if (c) {
1596       c->Init();
1597     }
1598   }
1599 
GenVertexArraysOES(GLsizei n,uint32 arrays_shm_id,uint32 arrays_shm_offset)1600   void GenVertexArraysOES(
1601       GLsizei n, uint32 arrays_shm_id, uint32 arrays_shm_offset) {
1602     gles2::cmds::GenVertexArraysOES* c =
1603         GetCmdSpace<gles2::cmds::GenVertexArraysOES>();
1604     if (c) {
1605       c->Init(n, arrays_shm_id, arrays_shm_offset);
1606     }
1607   }
1608 
GenVertexArraysOESImmediate(GLsizei n,GLuint * arrays)1609   void GenVertexArraysOESImmediate(GLsizei n, GLuint* arrays) {
1610     const uint32 size =
1611         gles2::cmds::GenVertexArraysOESImmediate::ComputeSize(n);
1612     gles2::cmds::GenVertexArraysOESImmediate* c =
1613         GetImmediateCmdSpaceTotalSize<gles2::cmds::GenVertexArraysOESImmediate>(
1614             size);
1615     if (c) {
1616       c->Init(n, arrays);
1617     }
1618   }
1619 
DeleteVertexArraysOES(GLsizei n,uint32 arrays_shm_id,uint32 arrays_shm_offset)1620   void DeleteVertexArraysOES(
1621       GLsizei n, uint32 arrays_shm_id, uint32 arrays_shm_offset) {
1622     gles2::cmds::DeleteVertexArraysOES* c =
1623         GetCmdSpace<gles2::cmds::DeleteVertexArraysOES>();
1624     if (c) {
1625       c->Init(n, arrays_shm_id, arrays_shm_offset);
1626     }
1627   }
1628 
DeleteVertexArraysOESImmediate(GLsizei n,const GLuint * arrays)1629   void DeleteVertexArraysOESImmediate(GLsizei n, const GLuint* arrays) {
1630     const uint32 size =
1631         gles2::cmds::DeleteVertexArraysOESImmediate::ComputeSize(n);
1632     gles2::cmds::DeleteVertexArraysOESImmediate* c =
1633         GetImmediateCmdSpaceTotalSize<gles2::cmds::DeleteVertexArraysOESImmediate>(size);  // NOLINT
1634     if (c) {
1635       c->Init(n, arrays);
1636     }
1637   }
1638 
IsVertexArrayOES(GLuint array,uint32 result_shm_id,uint32 result_shm_offset)1639   void IsVertexArrayOES(
1640       GLuint array, uint32 result_shm_id, uint32 result_shm_offset) {
1641     gles2::cmds::IsVertexArrayOES* c =
1642         GetCmdSpace<gles2::cmds::IsVertexArrayOES>();
1643     if (c) {
1644       c->Init(array, result_shm_id, result_shm_offset);
1645     }
1646   }
1647 
BindVertexArrayOES(GLuint array)1648   void BindVertexArrayOES(GLuint array) {
1649     gles2::cmds::BindVertexArrayOES* c =
1650         GetCmdSpace<gles2::cmds::BindVertexArrayOES>();
1651     if (c) {
1652       c->Init(array);
1653     }
1654   }
1655 
SwapBuffers()1656   void SwapBuffers() {
1657     gles2::cmds::SwapBuffers* c = GetCmdSpace<gles2::cmds::SwapBuffers>();
1658     if (c) {
1659       c->Init();
1660     }
1661   }
1662 
GetMaxValueInBufferCHROMIUM(GLuint buffer_id,GLsizei count,GLenum type,GLuint offset,uint32 result_shm_id,uint32 result_shm_offset)1663   void GetMaxValueInBufferCHROMIUM(
1664       GLuint buffer_id, GLsizei count, GLenum type, GLuint offset,
1665       uint32 result_shm_id, uint32 result_shm_offset) {
1666     gles2::cmds::GetMaxValueInBufferCHROMIUM* c =
1667         GetCmdSpace<gles2::cmds::GetMaxValueInBufferCHROMIUM>();
1668     if (c) {
1669       c->Init(
1670           buffer_id, count, type, offset, result_shm_id, result_shm_offset);
1671     }
1672   }
1673 
GenSharedIdsCHROMIUM(GLuint namespace_id,GLuint id_offset,GLsizei n,uint32 ids_shm_id,uint32 ids_shm_offset)1674   void GenSharedIdsCHROMIUM(
1675       GLuint namespace_id, GLuint id_offset, GLsizei n, uint32 ids_shm_id,
1676       uint32 ids_shm_offset) {
1677     gles2::cmds::GenSharedIdsCHROMIUM* c =
1678         GetCmdSpace<gles2::cmds::GenSharedIdsCHROMIUM>();
1679     if (c) {
1680       c->Init(namespace_id, id_offset, n, ids_shm_id, ids_shm_offset);
1681     }
1682   }
1683 
DeleteSharedIdsCHROMIUM(GLuint namespace_id,GLsizei n,uint32 ids_shm_id,uint32 ids_shm_offset)1684   void DeleteSharedIdsCHROMIUM(
1685       GLuint namespace_id, GLsizei n, uint32 ids_shm_id,
1686       uint32 ids_shm_offset) {
1687     gles2::cmds::DeleteSharedIdsCHROMIUM* c =
1688         GetCmdSpace<gles2::cmds::DeleteSharedIdsCHROMIUM>();
1689     if (c) {
1690       c->Init(namespace_id, n, ids_shm_id, ids_shm_offset);
1691     }
1692   }
1693 
RegisterSharedIdsCHROMIUM(GLuint namespace_id,GLsizei n,uint32 ids_shm_id,uint32 ids_shm_offset)1694   void RegisterSharedIdsCHROMIUM(
1695       GLuint namespace_id, GLsizei n, uint32 ids_shm_id,
1696       uint32 ids_shm_offset) {
1697     gles2::cmds::RegisterSharedIdsCHROMIUM* c =
1698         GetCmdSpace<gles2::cmds::RegisterSharedIdsCHROMIUM>();
1699     if (c) {
1700       c->Init(namespace_id, n, ids_shm_id, ids_shm_offset);
1701     }
1702   }
1703 
EnableFeatureCHROMIUM(GLuint bucket_id,uint32 result_shm_id,uint32 result_shm_offset)1704   void EnableFeatureCHROMIUM(
1705       GLuint bucket_id, uint32 result_shm_id, uint32 result_shm_offset) {
1706     gles2::cmds::EnableFeatureCHROMIUM* c =
1707         GetCmdSpace<gles2::cmds::EnableFeatureCHROMIUM>();
1708     if (c) {
1709       c->Init(bucket_id, result_shm_id, result_shm_offset);
1710     }
1711   }
1712 
ResizeCHROMIUM(GLuint width,GLuint height,GLfloat scale_factor)1713   void ResizeCHROMIUM(GLuint width, GLuint height, GLfloat scale_factor) {
1714     gles2::cmds::ResizeCHROMIUM* c =
1715         GetCmdSpace<gles2::cmds::ResizeCHROMIUM>();
1716     if (c) {
1717       c->Init(width, height, scale_factor);
1718     }
1719   }
1720 
GetRequestableExtensionsCHROMIUM(uint32 bucket_id)1721   void GetRequestableExtensionsCHROMIUM(uint32 bucket_id) {
1722     gles2::cmds::GetRequestableExtensionsCHROMIUM* c =
1723         GetCmdSpace<gles2::cmds::GetRequestableExtensionsCHROMIUM>();
1724     if (c) {
1725       c->Init(bucket_id);
1726     }
1727   }
1728 
RequestExtensionCHROMIUM(uint32 bucket_id)1729   void RequestExtensionCHROMIUM(uint32 bucket_id) {
1730     gles2::cmds::RequestExtensionCHROMIUM* c =
1731         GetCmdSpace<gles2::cmds::RequestExtensionCHROMIUM>();
1732     if (c) {
1733       c->Init(bucket_id);
1734     }
1735   }
1736 
GetMultipleIntegervCHROMIUM(uint32 pnames_shm_id,uint32 pnames_shm_offset,GLuint count,uint32 results_shm_id,uint32 results_shm_offset,GLsizeiptr size)1737   void GetMultipleIntegervCHROMIUM(
1738       uint32 pnames_shm_id, uint32 pnames_shm_offset, GLuint count,
1739       uint32 results_shm_id, uint32 results_shm_offset, GLsizeiptr size) {
1740     gles2::cmds::GetMultipleIntegervCHROMIUM* c =
1741         GetCmdSpace<gles2::cmds::GetMultipleIntegervCHROMIUM>();
1742     if (c) {
1743       c->Init(
1744           pnames_shm_id, pnames_shm_offset, count, results_shm_id,
1745           results_shm_offset, size);
1746     }
1747   }
1748 
GetProgramInfoCHROMIUM(GLuint program,uint32 bucket_id)1749   void GetProgramInfoCHROMIUM(GLuint program, uint32 bucket_id) {
1750     gles2::cmds::GetProgramInfoCHROMIUM* c =
1751         GetCmdSpace<gles2::cmds::GetProgramInfoCHROMIUM>();
1752     if (c) {
1753       c->Init(program, bucket_id);
1754     }
1755   }
1756 
CreateStreamTextureCHROMIUM(GLuint client_id,uint32 result_shm_id,uint32 result_shm_offset)1757   void CreateStreamTextureCHROMIUM(
1758       GLuint client_id, uint32 result_shm_id, uint32 result_shm_offset) {
1759     gles2::cmds::CreateStreamTextureCHROMIUM* c =
1760         GetCmdSpace<gles2::cmds::CreateStreamTextureCHROMIUM>();
1761     if (c) {
1762       c->Init(client_id, result_shm_id, result_shm_offset);
1763     }
1764   }
1765 
DestroyStreamTextureCHROMIUM(GLuint texture)1766   void DestroyStreamTextureCHROMIUM(GLuint texture) {
1767     gles2::cmds::DestroyStreamTextureCHROMIUM* c =
1768         GetCmdSpace<gles2::cmds::DestroyStreamTextureCHROMIUM>();
1769     if (c) {
1770       c->Init(texture);
1771     }
1772   }
1773 
GetTranslatedShaderSourceANGLE(GLuint shader,uint32 bucket_id)1774   void GetTranslatedShaderSourceANGLE(GLuint shader, uint32 bucket_id) {
1775     gles2::cmds::GetTranslatedShaderSourceANGLE* c =
1776         GetCmdSpace<gles2::cmds::GetTranslatedShaderSourceANGLE>();
1777     if (c) {
1778       c->Init(shader, bucket_id);
1779     }
1780   }
1781 
PostSubBufferCHROMIUM(GLint x,GLint y,GLint width,GLint height)1782   void PostSubBufferCHROMIUM(GLint x, GLint y, GLint width, GLint height) {
1783     gles2::cmds::PostSubBufferCHROMIUM* c =
1784         GetCmdSpace<gles2::cmds::PostSubBufferCHROMIUM>();
1785     if (c) {
1786       c->Init(x, y, width, height);
1787     }
1788   }
1789 
TexImageIOSurface2DCHROMIUM(GLenum target,GLsizei width,GLsizei height,GLuint ioSurfaceId,GLuint plane)1790   void TexImageIOSurface2DCHROMIUM(
1791       GLenum target, GLsizei width, GLsizei height, GLuint ioSurfaceId,
1792       GLuint plane) {
1793     gles2::cmds::TexImageIOSurface2DCHROMIUM* c =
1794         GetCmdSpace<gles2::cmds::TexImageIOSurface2DCHROMIUM>();
1795     if (c) {
1796       c->Init(target, width, height, ioSurfaceId, plane);
1797     }
1798   }
1799 
CopyTextureCHROMIUM(GLenum target,GLenum source_id,GLenum dest_id,GLint level,GLint internalformat,GLenum dest_type)1800   void CopyTextureCHROMIUM(
1801       GLenum target, GLenum source_id, GLenum dest_id, GLint level,
1802       GLint internalformat, GLenum dest_type) {
1803     gles2::cmds::CopyTextureCHROMIUM* c =
1804         GetCmdSpace<gles2::cmds::CopyTextureCHROMIUM>();
1805     if (c) {
1806       c->Init(target, source_id, dest_id, level, internalformat, dest_type);
1807     }
1808   }
1809 
DrawArraysInstancedANGLE(GLenum mode,GLint first,GLsizei count,GLsizei primcount)1810   void DrawArraysInstancedANGLE(
1811       GLenum mode, GLint first, GLsizei count, GLsizei primcount) {
1812     gles2::cmds::DrawArraysInstancedANGLE* c =
1813         GetCmdSpace<gles2::cmds::DrawArraysInstancedANGLE>();
1814     if (c) {
1815       c->Init(mode, first, count, primcount);
1816     }
1817   }
1818 
DrawElementsInstancedANGLE(GLenum mode,GLsizei count,GLenum type,GLuint index_offset,GLsizei primcount)1819   void DrawElementsInstancedANGLE(
1820       GLenum mode, GLsizei count, GLenum type, GLuint index_offset,
1821       GLsizei primcount) {
1822     gles2::cmds::DrawElementsInstancedANGLE* c =
1823         GetCmdSpace<gles2::cmds::DrawElementsInstancedANGLE>();
1824     if (c) {
1825       c->Init(mode, count, type, index_offset, primcount);
1826     }
1827   }
1828 
VertexAttribDivisorANGLE(GLuint index,GLuint divisor)1829   void VertexAttribDivisorANGLE(GLuint index, GLuint divisor) {
1830     gles2::cmds::VertexAttribDivisorANGLE* c =
1831         GetCmdSpace<gles2::cmds::VertexAttribDivisorANGLE>();
1832     if (c) {
1833       c->Init(index, divisor);
1834     }
1835   }
1836 
ProduceTextureCHROMIUM(GLenum target,uint32 mailbox_shm_id,uint32 mailbox_shm_offset)1837   void ProduceTextureCHROMIUM(
1838       GLenum target, uint32 mailbox_shm_id, uint32 mailbox_shm_offset) {
1839     gles2::cmds::ProduceTextureCHROMIUM* c =
1840         GetCmdSpace<gles2::cmds::ProduceTextureCHROMIUM>();
1841     if (c) {
1842       c->Init(target, mailbox_shm_id, mailbox_shm_offset);
1843     }
1844   }
1845 
ProduceTextureCHROMIUMImmediate(GLenum target,const GLbyte * mailbox)1846   void ProduceTextureCHROMIUMImmediate(GLenum target, const GLbyte* mailbox) {
1847     const uint32 size =
1848         gles2::cmds::ProduceTextureCHROMIUMImmediate::ComputeSize();
1849     gles2::cmds::ProduceTextureCHROMIUMImmediate* c =
1850         GetImmediateCmdSpaceTotalSize<gles2::cmds::ProduceTextureCHROMIUMImmediate>(size);  // NOLINT
1851     if (c) {
1852       c->Init(target, mailbox);
1853     }
1854   }
1855 
ConsumeTextureCHROMIUM(GLenum target,uint32 mailbox_shm_id,uint32 mailbox_shm_offset)1856   void ConsumeTextureCHROMIUM(
1857       GLenum target, uint32 mailbox_shm_id, uint32 mailbox_shm_offset) {
1858     gles2::cmds::ConsumeTextureCHROMIUM* c =
1859         GetCmdSpace<gles2::cmds::ConsumeTextureCHROMIUM>();
1860     if (c) {
1861       c->Init(target, mailbox_shm_id, mailbox_shm_offset);
1862     }
1863   }
1864 
ConsumeTextureCHROMIUMImmediate(GLenum target,const GLbyte * mailbox)1865   void ConsumeTextureCHROMIUMImmediate(GLenum target, const GLbyte* mailbox) {
1866     const uint32 size =
1867         gles2::cmds::ConsumeTextureCHROMIUMImmediate::ComputeSize();
1868     gles2::cmds::ConsumeTextureCHROMIUMImmediate* c =
1869         GetImmediateCmdSpaceTotalSize<gles2::cmds::ConsumeTextureCHROMIUMImmediate>(size);  // NOLINT
1870     if (c) {
1871       c->Init(target, mailbox);
1872     }
1873   }
1874 
BindUniformLocationCHROMIUM(GLuint program,GLint location,uint32 name_shm_id,uint32 name_shm_offset,uint32 data_size)1875   void BindUniformLocationCHROMIUM(
1876       GLuint program, GLint location, uint32 name_shm_id,
1877       uint32 name_shm_offset, uint32 data_size) {
1878     gles2::cmds::BindUniformLocationCHROMIUM* c =
1879         GetCmdSpace<gles2::cmds::BindUniformLocationCHROMIUM>();
1880     if (c) {
1881       c->Init(program, location, name_shm_id, name_shm_offset, data_size);
1882     }
1883   }
1884 
BindUniformLocationCHROMIUMBucket(GLuint program,GLint location,uint32 name_bucket_id)1885   void BindUniformLocationCHROMIUMBucket(
1886       GLuint program, GLint location, uint32 name_bucket_id) {
1887     gles2::cmds::BindUniformLocationCHROMIUMBucket* c =
1888         GetCmdSpace<gles2::cmds::BindUniformLocationCHROMIUMBucket>();
1889     if (c) {
1890       c->Init(program, location, name_bucket_id);
1891     }
1892   }
1893 
BindTexImage2DCHROMIUM(GLenum target,GLint imageId)1894   void BindTexImage2DCHROMIUM(GLenum target, GLint imageId) {
1895     gles2::cmds::BindTexImage2DCHROMIUM* c =
1896         GetCmdSpace<gles2::cmds::BindTexImage2DCHROMIUM>();
1897     if (c) {
1898       c->Init(target, imageId);
1899     }
1900   }
1901 
ReleaseTexImage2DCHROMIUM(GLenum target,GLint imageId)1902   void ReleaseTexImage2DCHROMIUM(GLenum target, GLint imageId) {
1903     gles2::cmds::ReleaseTexImage2DCHROMIUM* c =
1904         GetCmdSpace<gles2::cmds::ReleaseTexImage2DCHROMIUM>();
1905     if (c) {
1906       c->Init(target, imageId);
1907     }
1908   }
1909 
TraceBeginCHROMIUM(GLuint bucket_id)1910   void TraceBeginCHROMIUM(GLuint bucket_id) {
1911     gles2::cmds::TraceBeginCHROMIUM* c =
1912         GetCmdSpace<gles2::cmds::TraceBeginCHROMIUM>();
1913     if (c) {
1914       c->Init(bucket_id);
1915     }
1916   }
1917 
TraceEndCHROMIUM()1918   void TraceEndCHROMIUM() {
1919     gles2::cmds::TraceEndCHROMIUM* c =
1920         GetCmdSpace<gles2::cmds::TraceEndCHROMIUM>();
1921     if (c) {
1922       c->Init();
1923     }
1924   }
1925 
AsyncTexSubImage2DCHROMIUM(GLenum target,GLint level,GLint xoffset,GLint yoffset,GLsizei width,GLsizei height,GLenum format,GLenum type,uint32 data_shm_id,uint32 data_shm_offset)1926   void AsyncTexSubImage2DCHROMIUM(
1927       GLenum target, GLint level, GLint xoffset, GLint yoffset, GLsizei width,
1928       GLsizei height, GLenum format, GLenum type, uint32 data_shm_id,
1929       uint32 data_shm_offset) {
1930     gles2::cmds::AsyncTexSubImage2DCHROMIUM* c =
1931         GetCmdSpace<gles2::cmds::AsyncTexSubImage2DCHROMIUM>();
1932     if (c) {
1933       c->Init(
1934           target, level, xoffset, yoffset, width, height, format, type,
1935           data_shm_id, data_shm_offset);
1936     }
1937   }
1938 
AsyncTexImage2DCHROMIUM(GLenum target,GLint level,GLint internalformat,GLsizei width,GLsizei height,GLint border,GLenum format,GLenum type,uint32 pixels_shm_id,uint32 pixels_shm_offset)1939   void AsyncTexImage2DCHROMIUM(
1940       GLenum target, GLint level, GLint internalformat, GLsizei width,
1941       GLsizei height, GLint border, GLenum format, GLenum type,
1942       uint32 pixels_shm_id, uint32 pixels_shm_offset) {
1943     gles2::cmds::AsyncTexImage2DCHROMIUM* c =
1944         GetCmdSpace<gles2::cmds::AsyncTexImage2DCHROMIUM>();
1945     if (c) {
1946       c->Init(
1947           target, level, internalformat, width, height, border, format, type,
1948           pixels_shm_id, pixels_shm_offset);
1949     }
1950   }
1951 
WaitAsyncTexImage2DCHROMIUM(GLenum target)1952   void WaitAsyncTexImage2DCHROMIUM(GLenum target) {
1953     gles2::cmds::WaitAsyncTexImage2DCHROMIUM* c =
1954         GetCmdSpace<gles2::cmds::WaitAsyncTexImage2DCHROMIUM>();
1955     if (c) {
1956       c->Init(target);
1957     }
1958   }
1959 
DiscardFramebufferEXT(GLenum target,GLsizei count,uint32 attachments_shm_id,uint32 attachments_shm_offset)1960   void DiscardFramebufferEXT(
1961       GLenum target, GLsizei count, uint32 attachments_shm_id,
1962       uint32 attachments_shm_offset) {
1963     gles2::cmds::DiscardFramebufferEXT* c =
1964         GetCmdSpace<gles2::cmds::DiscardFramebufferEXT>();
1965     if (c) {
1966       c->Init(target, count, attachments_shm_id, attachments_shm_offset);
1967     }
1968   }
1969 
DiscardFramebufferEXTImmediate(GLenum target,GLsizei count,const GLenum * attachments)1970   void DiscardFramebufferEXTImmediate(
1971       GLenum target, GLsizei count, const GLenum* attachments) {
1972     const uint32 size =
1973         gles2::cmds::DiscardFramebufferEXTImmediate::ComputeSize(count);
1974     gles2::cmds::DiscardFramebufferEXTImmediate* c =
1975         GetImmediateCmdSpaceTotalSize<gles2::cmds::DiscardFramebufferEXTImmediate>(size);  // NOLINT
1976     if (c) {
1977       c->Init(target, count, attachments);
1978     }
1979   }
1980 
LoseContextCHROMIUM(GLenum current,GLenum other)1981   void LoseContextCHROMIUM(GLenum current, GLenum other) {
1982     gles2::cmds::LoseContextCHROMIUM* c =
1983         GetCmdSpace<gles2::cmds::LoseContextCHROMIUM>();
1984     if (c) {
1985       c->Init(current, other);
1986     }
1987   }
1988 
WaitSyncPointCHROMIUM(GLuint sync_point)1989   void WaitSyncPointCHROMIUM(GLuint sync_point) {
1990     gles2::cmds::WaitSyncPointCHROMIUM* c =
1991         GetCmdSpace<gles2::cmds::WaitSyncPointCHROMIUM>();
1992     if (c) {
1993       c->Init(sync_point);
1994     }
1995   }
1996 
DrawBuffersEXT(GLsizei count,uint32 bufs_shm_id,uint32 bufs_shm_offset)1997   void DrawBuffersEXT(
1998       GLsizei count, uint32 bufs_shm_id, uint32 bufs_shm_offset) {
1999     gles2::cmds::DrawBuffersEXT* c =
2000         GetCmdSpace<gles2::cmds::DrawBuffersEXT>();
2001     if (c) {
2002       c->Init(count, bufs_shm_id, bufs_shm_offset);
2003     }
2004   }
2005 
DrawBuffersEXTImmediate(GLsizei count,const GLenum * bufs)2006   void DrawBuffersEXTImmediate(GLsizei count, const GLenum* bufs) {
2007     const uint32 size =
2008         gles2::cmds::DrawBuffersEXTImmediate::ComputeSize(count);
2009     gles2::cmds::DrawBuffersEXTImmediate* c =
2010         GetImmediateCmdSpaceTotalSize<gles2::cmds::DrawBuffersEXTImmediate>(
2011             size);
2012     if (c) {
2013       c->Init(count, bufs);
2014     }
2015   }
2016 
DiscardBackbufferCHROMIUM()2017   void DiscardBackbufferCHROMIUM() {
2018     gles2::cmds::DiscardBackbufferCHROMIUM* c =
2019         GetCmdSpace<gles2::cmds::DiscardBackbufferCHROMIUM>();
2020     if (c) {
2021       c->Init();
2022     }
2023   }
2024 
2025 #endif  // GPU_COMMAND_BUFFER_CLIENT_GLES2_CMD_HELPER_AUTOGEN_H_
2026 
2027