| OLD | NEW |
| (Empty) |
| 1 // Copyright (c) 2010 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. DO NOT EDIT! | |
| 6 | |
| 7 #include "webkit/plugins/ppapi/ppb_graphics_3d_impl.h" | |
| 8 | |
| 9 #include "gpu/command_buffer/client/gles2_implementation.h" | |
| 10 #include "ppapi/c/dev/ppb_opengles_dev.h" | |
| 11 | |
| 12 namespace webkit { | |
| 13 namespace ppapi { | |
| 14 | |
| 15 namespace { | |
| 16 | |
| 17 void ActiveTexture(GLenum texture) { | |
| 18 PPB_Graphics3D_Impl::GetCurrent()->impl()->ActiveTexture(texture); | |
| 19 } | |
| 20 void AttachShader(GLuint program, GLuint shader) { | |
| 21 PPB_Graphics3D_Impl::GetCurrent()->impl()->AttachShader(program, shader); | |
| 22 } | |
| 23 void BindAttribLocation(GLuint program, GLuint index, const char* name) { | |
| 24 PPB_Graphics3D_Impl::GetCurrent()->impl()->BindAttribLocation(program, index,
name); | |
| 25 } | |
| 26 void BindBuffer(GLenum target, GLuint buffer) { | |
| 27 PPB_Graphics3D_Impl::GetCurrent()->impl()->BindBuffer(target, buffer); | |
| 28 } | |
| 29 void BindFramebuffer(GLenum target, GLuint framebuffer) { | |
| 30 PPB_Graphics3D_Impl::GetCurrent()->impl()->BindFramebuffer(target, framebuffer
); | |
| 31 } | |
| 32 void BindRenderbuffer(GLenum target, GLuint renderbuffer) { | |
| 33 PPB_Graphics3D_Impl::GetCurrent()->impl()->BindRenderbuffer(target, renderbuff
er); | |
| 34 } | |
| 35 void BindTexture(GLenum target, GLuint texture) { | |
| 36 PPB_Graphics3D_Impl::GetCurrent()->impl()->BindTexture(target, texture); | |
| 37 } | |
| 38 void BlendColor(GLclampf red, GLclampf green, GLclampf blue, GLclampf alpha) { | |
| 39 PPB_Graphics3D_Impl::GetCurrent()->impl()->BlendColor(red, green, blue, alpha)
; | |
| 40 } | |
| 41 void BlendEquation(GLenum mode) { | |
| 42 PPB_Graphics3D_Impl::GetCurrent()->impl()->BlendEquation(mode); | |
| 43 } | |
| 44 void BlendEquationSeparate(GLenum modeRGB, GLenum modeAlpha) { | |
| 45 PPB_Graphics3D_Impl::GetCurrent()->impl()->BlendEquationSeparate(modeRGB, mode
Alpha); | |
| 46 } | |
| 47 void BlendFunc(GLenum sfactor, GLenum dfactor) { | |
| 48 PPB_Graphics3D_Impl::GetCurrent()->impl()->BlendFunc(sfactor, dfactor); | |
| 49 } | |
| 50 void BlendFuncSeparate( | |
| 51 GLenum srcRGB, GLenum dstRGB, GLenum srcAlpha, GLenum dstAlpha) { | |
| 52 PPB_Graphics3D_Impl::GetCurrent()->impl()->BlendFuncSeparate( | |
| 53 srcRGB, dstRGB, srcAlpha, dstAlpha); | |
| 54 } | |
| 55 void BufferData( | |
| 56 GLenum target, GLsizeiptr size, const void* data, GLenum usage) { | |
| 57 PPB_Graphics3D_Impl::GetCurrent()->impl()->BufferData(target, size, data, usag
e); | |
| 58 } | |
| 59 void BufferSubData( | |
| 60 GLenum target, GLintptr offset, GLsizeiptr size, const void* data) { | |
| 61 PPB_Graphics3D_Impl::GetCurrent()->impl()->BufferSubData(target, offset, size,
data); | |
| 62 } | |
| 63 GLenum CheckFramebufferStatus(GLenum target) { | |
| 64 return PPB_Graphics3D_Impl::GetCurrent()->impl()->CheckFramebufferStatus(targe
t); | |
| 65 } | |
| 66 void Clear(GLbitfield mask) { | |
| 67 PPB_Graphics3D_Impl::GetCurrent()->impl()->Clear(mask); | |
| 68 } | |
| 69 void ClearColor(GLclampf red, GLclampf green, GLclampf blue, GLclampf alpha) { | |
| 70 PPB_Graphics3D_Impl::GetCurrent()->impl()->ClearColor(red, green, blue, alpha)
; | |
| 71 } | |
| 72 void ClearDepthf(GLclampf depth) { | |
| 73 PPB_Graphics3D_Impl::GetCurrent()->impl()->ClearDepthf(depth); | |
| 74 } | |
| 75 void ClearStencil(GLint s) { | |
| 76 PPB_Graphics3D_Impl::GetCurrent()->impl()->ClearStencil(s); | |
| 77 } | |
| 78 void ColorMask( | |
| 79 GLboolean red, GLboolean green, GLboolean blue, GLboolean alpha) { | |
| 80 PPB_Graphics3D_Impl::GetCurrent()->impl()->ColorMask(red, green, blue, alpha); | |
| 81 } | |
| 82 void CompileShader(GLuint shader) { | |
| 83 PPB_Graphics3D_Impl::GetCurrent()->impl()->CompileShader(shader); | |
| 84 } | |
| 85 void CompressedTexImage2D( | |
| 86 GLenum target, GLint level, GLenum internalformat, GLsizei width, | |
| 87 GLsizei height, GLint border, GLsizei imageSize, const void* data) { | |
| 88 PPB_Graphics3D_Impl::GetCurrent()->impl()->CompressedTexImage2D( | |
| 89 target, level, internalformat, width, height, border, imageSize, data); | |
| 90 } | |
| 91 void CompressedTexSubImage2D( | |
| 92 GLenum target, GLint level, GLint xoffset, GLint yoffset, GLsizei width, | |
| 93 GLsizei height, GLenum format, GLsizei imageSize, const void* data) { | |
| 94 PPB_Graphics3D_Impl::GetCurrent()->impl()->CompressedTexSubImage2D( | |
| 95 target, level, xoffset, yoffset, width, height, format, imageSize, data); | |
| 96 } | |
| 97 void CopyTexImage2D( | |
| 98 GLenum target, GLint level, GLenum internalformat, GLint x, GLint y, | |
| 99 GLsizei width, GLsizei height, GLint border) { | |
| 100 PPB_Graphics3D_Impl::GetCurrent()->impl()->CopyTexImage2D( | |
| 101 target, level, internalformat, x, y, width, height, border); | |
| 102 } | |
| 103 void CopyTexSubImage2D( | |
| 104 GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint x, GLint y, | |
| 105 GLsizei width, GLsizei height) { | |
| 106 PPB_Graphics3D_Impl::GetCurrent()->impl()->CopyTexSubImage2D( | |
| 107 target, level, xoffset, yoffset, x, y, width, height); | |
| 108 } | |
| 109 GLuint CreateProgram() { | |
| 110 return PPB_Graphics3D_Impl::GetCurrent()->impl()->CreateProgram(); | |
| 111 } | |
| 112 GLuint CreateShader(GLenum type) { | |
| 113 return PPB_Graphics3D_Impl::GetCurrent()->impl()->CreateShader(type); | |
| 114 } | |
| 115 void CullFace(GLenum mode) { | |
| 116 PPB_Graphics3D_Impl::GetCurrent()->impl()->CullFace(mode); | |
| 117 } | |
| 118 void DeleteBuffers(GLsizei n, const GLuint* buffers) { | |
| 119 PPB_Graphics3D_Impl::GetCurrent()->impl()->DeleteBuffers(n, buffers); | |
| 120 } | |
| 121 void DeleteFramebuffers(GLsizei n, const GLuint* framebuffers) { | |
| 122 PPB_Graphics3D_Impl::GetCurrent()->impl()->DeleteFramebuffers(n, framebuffers)
; | |
| 123 } | |
| 124 void DeleteProgram(GLuint program) { | |
| 125 PPB_Graphics3D_Impl::GetCurrent()->impl()->DeleteProgram(program); | |
| 126 } | |
| 127 void DeleteRenderbuffers(GLsizei n, const GLuint* renderbuffers) { | |
| 128 PPB_Graphics3D_Impl::GetCurrent()->impl()->DeleteRenderbuffers(n, renderbuffer
s); | |
| 129 } | |
| 130 void DeleteShader(GLuint shader) { | |
| 131 PPB_Graphics3D_Impl::GetCurrent()->impl()->DeleteShader(shader); | |
| 132 } | |
| 133 void DeleteTextures(GLsizei n, const GLuint* textures) { | |
| 134 PPB_Graphics3D_Impl::GetCurrent()->impl()->DeleteTextures(n, textures); | |
| 135 } | |
| 136 void DepthFunc(GLenum func) { | |
| 137 PPB_Graphics3D_Impl::GetCurrent()->impl()->DepthFunc(func); | |
| 138 } | |
| 139 void DepthMask(GLboolean flag) { | |
| 140 PPB_Graphics3D_Impl::GetCurrent()->impl()->DepthMask(flag); | |
| 141 } | |
| 142 void DepthRangef(GLclampf zNear, GLclampf zFar) { | |
| 143 PPB_Graphics3D_Impl::GetCurrent()->impl()->DepthRangef(zNear, zFar); | |
| 144 } | |
| 145 void DetachShader(GLuint program, GLuint shader) { | |
| 146 PPB_Graphics3D_Impl::GetCurrent()->impl()->DetachShader(program, shader); | |
| 147 } | |
| 148 void Disable(GLenum cap) { | |
| 149 PPB_Graphics3D_Impl::GetCurrent()->impl()->Disable(cap); | |
| 150 } | |
| 151 void DisableVertexAttribArray(GLuint index) { | |
| 152 PPB_Graphics3D_Impl::GetCurrent()->impl()->DisableVertexAttribArray(index); | |
| 153 } | |
| 154 void DrawArrays(GLenum mode, GLint first, GLsizei count) { | |
| 155 PPB_Graphics3D_Impl::GetCurrent()->impl()->DrawArrays(mode, first, count); | |
| 156 } | |
| 157 void DrawElements( | |
| 158 GLenum mode, GLsizei count, GLenum type, const void* indices) { | |
| 159 PPB_Graphics3D_Impl::GetCurrent()->impl()->DrawElements(mode, count, type, ind
ices); | |
| 160 } | |
| 161 void Enable(GLenum cap) { | |
| 162 PPB_Graphics3D_Impl::GetCurrent()->impl()->Enable(cap); | |
| 163 } | |
| 164 void EnableVertexAttribArray(GLuint index) { | |
| 165 PPB_Graphics3D_Impl::GetCurrent()->impl()->EnableVertexAttribArray(index); | |
| 166 } | |
| 167 void Finish() { | |
| 168 PPB_Graphics3D_Impl::GetCurrent()->impl()->Finish(); | |
| 169 } | |
| 170 void Flush() { | |
| 171 PPB_Graphics3D_Impl::GetCurrent()->impl()->Flush(); | |
| 172 } | |
| 173 void FramebufferRenderbuffer( | |
| 174 GLenum target, GLenum attachment, GLenum renderbuffertarget, | |
| 175 GLuint renderbuffer) { | |
| 176 PPB_Graphics3D_Impl::GetCurrent()->impl()->FramebufferRenderbuffer( | |
| 177 target, attachment, renderbuffertarget, renderbuffer); | |
| 178 } | |
| 179 void FramebufferTexture2D( | |
| 180 GLenum target, GLenum attachment, GLenum textarget, GLuint texture, | |
| 181 GLint level) { | |
| 182 PPB_Graphics3D_Impl::GetCurrent()->impl()->FramebufferTexture2D( | |
| 183 target, attachment, textarget, texture, level); | |
| 184 } | |
| 185 void FrontFace(GLenum mode) { | |
| 186 PPB_Graphics3D_Impl::GetCurrent()->impl()->FrontFace(mode); | |
| 187 } | |
| 188 void GenBuffers(GLsizei n, GLuint* buffers) { | |
| 189 PPB_Graphics3D_Impl::GetCurrent()->impl()->GenBuffers(n, buffers); | |
| 190 } | |
| 191 void GenerateMipmap(GLenum target) { | |
| 192 PPB_Graphics3D_Impl::GetCurrent()->impl()->GenerateMipmap(target); | |
| 193 } | |
| 194 void GenFramebuffers(GLsizei n, GLuint* framebuffers) { | |
| 195 PPB_Graphics3D_Impl::GetCurrent()->impl()->GenFramebuffers(n, framebuffers); | |
| 196 } | |
| 197 void GenRenderbuffers(GLsizei n, GLuint* renderbuffers) { | |
| 198 PPB_Graphics3D_Impl::GetCurrent()->impl()->GenRenderbuffers(n, renderbuffers); | |
| 199 } | |
| 200 void GenTextures(GLsizei n, GLuint* textures) { | |
| 201 PPB_Graphics3D_Impl::GetCurrent()->impl()->GenTextures(n, textures); | |
| 202 } | |
| 203 void GetActiveAttrib( | |
| 204 GLuint program, GLuint index, GLsizei bufsize, GLsizei* length, GLint* size, | |
| 205 GLenum* type, char* name) { | |
| 206 PPB_Graphics3D_Impl::GetCurrent()->impl()->GetActiveAttrib( | |
| 207 program, index, bufsize, length, size, type, name); | |
| 208 } | |
| 209 void GetActiveUniform( | |
| 210 GLuint program, GLuint index, GLsizei bufsize, GLsizei* length, GLint* size, | |
| 211 GLenum* type, char* name) { | |
| 212 PPB_Graphics3D_Impl::GetCurrent()->impl()->GetActiveUniform( | |
| 213 program, index, bufsize, length, size, type, name); | |
| 214 } | |
| 215 void GetAttachedShaders( | |
| 216 GLuint program, GLsizei maxcount, GLsizei* count, GLuint* shaders) { | |
| 217 PPB_Graphics3D_Impl::GetCurrent()->impl()->GetAttachedShaders( | |
| 218 program, maxcount, count, shaders); | |
| 219 } | |
| 220 GLint GetAttribLocation(GLuint program, const char* name) { | |
| 221 return PPB_Graphics3D_Impl::GetCurrent()->impl()->GetAttribLocation(program, n
ame); | |
| 222 } | |
| 223 void GetBooleanv(GLenum pname, GLboolean* params) { | |
| 224 PPB_Graphics3D_Impl::GetCurrent()->impl()->GetBooleanv(pname, params); | |
| 225 } | |
| 226 void GetBufferParameteriv(GLenum target, GLenum pname, GLint* params) { | |
| 227 PPB_Graphics3D_Impl::GetCurrent()->impl()->GetBufferParameteriv( | |
| 228 target, pname, params); | |
| 229 } | |
| 230 GLenum GetError() { | |
| 231 return PPB_Graphics3D_Impl::GetCurrent()->impl()->GetError(); | |
| 232 } | |
| 233 void GetFloatv(GLenum pname, GLfloat* params) { | |
| 234 PPB_Graphics3D_Impl::GetCurrent()->impl()->GetFloatv(pname, params); | |
| 235 } | |
| 236 void GetFramebufferAttachmentParameteriv( | |
| 237 GLenum target, GLenum attachment, GLenum pname, GLint* params) { | |
| 238 PPB_Graphics3D_Impl::GetCurrent()->impl()->GetFramebufferAttachmentParameteriv
( | |
| 239 target, attachment, pname, params); | |
| 240 } | |
| 241 void GetIntegerv(GLenum pname, GLint* params) { | |
| 242 PPB_Graphics3D_Impl::GetCurrent()->impl()->GetIntegerv(pname, params); | |
| 243 } | |
| 244 void GetProgramiv(GLuint program, GLenum pname, GLint* params) { | |
| 245 PPB_Graphics3D_Impl::GetCurrent()->impl()->GetProgramiv(program, pname, params
); | |
| 246 } | |
| 247 void GetProgramInfoLog( | |
| 248 GLuint program, GLsizei bufsize, GLsizei* length, char* infolog) { | |
| 249 PPB_Graphics3D_Impl::GetCurrent()->impl()->GetProgramInfoLog( | |
| 250 program, bufsize, length, infolog); | |
| 251 } | |
| 252 void GetRenderbufferParameteriv(GLenum target, GLenum pname, GLint* params) { | |
| 253 PPB_Graphics3D_Impl::GetCurrent()->impl()->GetRenderbufferParameteriv( | |
| 254 target, pname, params); | |
| 255 } | |
| 256 void GetShaderiv(GLuint shader, GLenum pname, GLint* params) { | |
| 257 PPB_Graphics3D_Impl::GetCurrent()->impl()->GetShaderiv(shader, pname, params); | |
| 258 } | |
| 259 void GetShaderInfoLog( | |
| 260 GLuint shader, GLsizei bufsize, GLsizei* length, char* infolog) { | |
| 261 PPB_Graphics3D_Impl::GetCurrent()->impl()->GetShaderInfoLog( | |
| 262 shader, bufsize, length, infolog); | |
| 263 } | |
| 264 void GetShaderPrecisionFormat( | |
| 265 GLenum shadertype, GLenum precisiontype, GLint* range, GLint* precision) { | |
| 266 PPB_Graphics3D_Impl::GetCurrent()->impl()->GetShaderPrecisionFormat( | |
| 267 shadertype, precisiontype, range, precision); | |
| 268 } | |
| 269 void GetShaderSource( | |
| 270 GLuint shader, GLsizei bufsize, GLsizei* length, char* source) { | |
| 271 PPB_Graphics3D_Impl::GetCurrent()->impl()->GetShaderSource( | |
| 272 shader, bufsize, length, source); | |
| 273 } | |
| 274 const GLubyte* GetString(GLenum name) { | |
| 275 return PPB_Graphics3D_Impl::GetCurrent()->impl()->GetString(name); | |
| 276 } | |
| 277 void GetTexParameterfv(GLenum target, GLenum pname, GLfloat* params) { | |
| 278 PPB_Graphics3D_Impl::GetCurrent()->impl()->GetTexParameterfv(target, pname, pa
rams); | |
| 279 } | |
| 280 void GetTexParameteriv(GLenum target, GLenum pname, GLint* params) { | |
| 281 PPB_Graphics3D_Impl::GetCurrent()->impl()->GetTexParameteriv(target, pname, pa
rams); | |
| 282 } | |
| 283 void GetUniformfv(GLuint program, GLint location, GLfloat* params) { | |
| 284 PPB_Graphics3D_Impl::GetCurrent()->impl()->GetUniformfv(program, location, par
ams); | |
| 285 } | |
| 286 void GetUniformiv(GLuint program, GLint location, GLint* params) { | |
| 287 PPB_Graphics3D_Impl::GetCurrent()->impl()->GetUniformiv(program, location, par
ams); | |
| 288 } | |
| 289 GLint GetUniformLocation(GLuint program, const char* name) { | |
| 290 return PPB_Graphics3D_Impl::GetCurrent()->impl()->GetUniformLocation(program,
name); | |
| 291 } | |
| 292 void GetVertexAttribfv(GLuint index, GLenum pname, GLfloat* params) { | |
| 293 PPB_Graphics3D_Impl::GetCurrent()->impl()->GetVertexAttribfv(index, pname, par
ams); | |
| 294 } | |
| 295 void GetVertexAttribiv(GLuint index, GLenum pname, GLint* params) { | |
| 296 PPB_Graphics3D_Impl::GetCurrent()->impl()->GetVertexAttribiv(index, pname, par
ams); | |
| 297 } | |
| 298 void GetVertexAttribPointerv(GLuint index, GLenum pname, void** pointer) { | |
| 299 PPB_Graphics3D_Impl::GetCurrent()->impl()->GetVertexAttribPointerv( | |
| 300 index, pname, pointer); | |
| 301 } | |
| 302 void Hint(GLenum target, GLenum mode) { | |
| 303 PPB_Graphics3D_Impl::GetCurrent()->impl()->Hint(target, mode); | |
| 304 } | |
| 305 GLboolean IsBuffer(GLuint buffer) { | |
| 306 return PPB_Graphics3D_Impl::GetCurrent()->impl()->IsBuffer(buffer); | |
| 307 } | |
| 308 GLboolean IsEnabled(GLenum cap) { | |
| 309 return PPB_Graphics3D_Impl::GetCurrent()->impl()->IsEnabled(cap); | |
| 310 } | |
| 311 GLboolean IsFramebuffer(GLuint framebuffer) { | |
| 312 return PPB_Graphics3D_Impl::GetCurrent()->impl()->IsFramebuffer(framebuffer); | |
| 313 } | |
| 314 GLboolean IsProgram(GLuint program) { | |
| 315 return PPB_Graphics3D_Impl::GetCurrent()->impl()->IsProgram(program); | |
| 316 } | |
| 317 GLboolean IsRenderbuffer(GLuint renderbuffer) { | |
| 318 return PPB_Graphics3D_Impl::GetCurrent()->impl()->IsRenderbuffer(renderbuffer)
; | |
| 319 } | |
| 320 GLboolean IsShader(GLuint shader) { | |
| 321 return PPB_Graphics3D_Impl::GetCurrent()->impl()->IsShader(shader); | |
| 322 } | |
| 323 GLboolean IsTexture(GLuint texture) { | |
| 324 return PPB_Graphics3D_Impl::GetCurrent()->impl()->IsTexture(texture); | |
| 325 } | |
| 326 void LineWidth(GLfloat width) { | |
| 327 PPB_Graphics3D_Impl::GetCurrent()->impl()->LineWidth(width); | |
| 328 } | |
| 329 void LinkProgram(GLuint program) { | |
| 330 PPB_Graphics3D_Impl::GetCurrent()->impl()->LinkProgram(program); | |
| 331 } | |
| 332 void PixelStorei(GLenum pname, GLint param) { | |
| 333 PPB_Graphics3D_Impl::GetCurrent()->impl()->PixelStorei(pname, param); | |
| 334 } | |
| 335 void PolygonOffset(GLfloat factor, GLfloat units) { | |
| 336 PPB_Graphics3D_Impl::GetCurrent()->impl()->PolygonOffset(factor, units); | |
| 337 } | |
| 338 void ReadPixels( | |
| 339 GLint x, GLint y, GLsizei width, GLsizei height, GLenum format, GLenum type, | |
| 340 void* pixels) { | |
| 341 PPB_Graphics3D_Impl::GetCurrent()->impl()->ReadPixels( | |
| 342 x, y, width, height, format, type, pixels); | |
| 343 } | |
| 344 void ReleaseShaderCompiler() { | |
| 345 PPB_Graphics3D_Impl::GetCurrent()->impl()->ReleaseShaderCompiler(); | |
| 346 } | |
| 347 void RenderbufferStorage( | |
| 348 GLenum target, GLenum internalformat, GLsizei width, GLsizei height) { | |
| 349 PPB_Graphics3D_Impl::GetCurrent()->impl()->RenderbufferStorage( | |
| 350 target, internalformat, width, height); | |
| 351 } | |
| 352 void SampleCoverage(GLclampf value, GLboolean invert) { | |
| 353 PPB_Graphics3D_Impl::GetCurrent()->impl()->SampleCoverage(value, invert); | |
| 354 } | |
| 355 void Scissor(GLint x, GLint y, GLsizei width, GLsizei height) { | |
| 356 PPB_Graphics3D_Impl::GetCurrent()->impl()->Scissor(x, y, width, height); | |
| 357 } | |
| 358 void ShaderBinary( | |
| 359 GLsizei n, const GLuint* shaders, GLenum binaryformat, const void* binary, | |
| 360 GLsizei length) { | |
| 361 PPB_Graphics3D_Impl::GetCurrent()->impl()->ShaderBinary( | |
| 362 n, shaders, binaryformat, binary, length); | |
| 363 } | |
| 364 void ShaderSource( | |
| 365 GLuint shader, GLsizei count, const char** str, const GLint* length) { | |
| 366 PPB_Graphics3D_Impl::GetCurrent()->impl()->ShaderSource(shader, count, str, le
ngth); | |
| 367 } | |
| 368 void StencilFunc(GLenum func, GLint ref, GLuint mask) { | |
| 369 PPB_Graphics3D_Impl::GetCurrent()->impl()->StencilFunc(func, ref, mask); | |
| 370 } | |
| 371 void StencilFuncSeparate(GLenum face, GLenum func, GLint ref, GLuint mask) { | |
| 372 PPB_Graphics3D_Impl::GetCurrent()->impl()->StencilFuncSeparate(face, func, ref
, mask); | |
| 373 } | |
| 374 void StencilMask(GLuint mask) { | |
| 375 PPB_Graphics3D_Impl::GetCurrent()->impl()->StencilMask(mask); | |
| 376 } | |
| 377 void StencilMaskSeparate(GLenum face, GLuint mask) { | |
| 378 PPB_Graphics3D_Impl::GetCurrent()->impl()->StencilMaskSeparate(face, mask); | |
| 379 } | |
| 380 void StencilOp(GLenum fail, GLenum zfail, GLenum zpass) { | |
| 381 PPB_Graphics3D_Impl::GetCurrent()->impl()->StencilOp(fail, zfail, zpass); | |
| 382 } | |
| 383 void StencilOpSeparate(GLenum face, GLenum fail, GLenum zfail, GLenum zpass) { | |
| 384 PPB_Graphics3D_Impl::GetCurrent()->impl()->StencilOpSeparate( | |
| 385 face, fail, zfail, zpass); | |
| 386 } | |
| 387 void TexImage2D( | |
| 388 GLenum target, GLint level, GLint internalformat, GLsizei width, | |
| 389 GLsizei height, GLint border, GLenum format, GLenum type, | |
| 390 const void* pixels) { | |
| 391 PPB_Graphics3D_Impl::GetCurrent()->impl()->TexImage2D( | |
| 392 target, level, internalformat, width, height, border, format, type, | |
| 393 pixels); | |
| 394 } | |
| 395 void TexParameterf(GLenum target, GLenum pname, GLfloat param) { | |
| 396 PPB_Graphics3D_Impl::GetCurrent()->impl()->TexParameterf(target, pname, param)
; | |
| 397 } | |
| 398 void TexParameterfv(GLenum target, GLenum pname, const GLfloat* params) { | |
| 399 PPB_Graphics3D_Impl::GetCurrent()->impl()->TexParameterfv(target, pname, param
s); | |
| 400 } | |
| 401 void TexParameteri(GLenum target, GLenum pname, GLint param) { | |
| 402 PPB_Graphics3D_Impl::GetCurrent()->impl()->TexParameteri(target, pname, param)
; | |
| 403 } | |
| 404 void TexParameteriv(GLenum target, GLenum pname, const GLint* params) { | |
| 405 PPB_Graphics3D_Impl::GetCurrent()->impl()->TexParameteriv(target, pname, param
s); | |
| 406 } | |
| 407 void TexSubImage2D( | |
| 408 GLenum target, GLint level, GLint xoffset, GLint yoffset, GLsizei width, | |
| 409 GLsizei height, GLenum format, GLenum type, const void* pixels) { | |
| 410 PPB_Graphics3D_Impl::GetCurrent()->impl()->TexSubImage2D( | |
| 411 target, level, xoffset, yoffset, width, height, format, type, pixels); | |
| 412 } | |
| 413 void Uniform1f(GLint location, GLfloat x) { | |
| 414 PPB_Graphics3D_Impl::GetCurrent()->impl()->Uniform1f(location, x); | |
| 415 } | |
| 416 void Uniform1fv(GLint location, GLsizei count, const GLfloat* v) { | |
| 417 PPB_Graphics3D_Impl::GetCurrent()->impl()->Uniform1fv(location, count, v); | |
| 418 } | |
| 419 void Uniform1i(GLint location, GLint x) { | |
| 420 PPB_Graphics3D_Impl::GetCurrent()->impl()->Uniform1i(location, x); | |
| 421 } | |
| 422 void Uniform1iv(GLint location, GLsizei count, const GLint* v) { | |
| 423 PPB_Graphics3D_Impl::GetCurrent()->impl()->Uniform1iv(location, count, v); | |
| 424 } | |
| 425 void Uniform2f(GLint location, GLfloat x, GLfloat y) { | |
| 426 PPB_Graphics3D_Impl::GetCurrent()->impl()->Uniform2f(location, x, y); | |
| 427 } | |
| 428 void Uniform2fv(GLint location, GLsizei count, const GLfloat* v) { | |
| 429 PPB_Graphics3D_Impl::GetCurrent()->impl()->Uniform2fv(location, count, v); | |
| 430 } | |
| 431 void Uniform2i(GLint location, GLint x, GLint y) { | |
| 432 PPB_Graphics3D_Impl::GetCurrent()->impl()->Uniform2i(location, x, y); | |
| 433 } | |
| 434 void Uniform2iv(GLint location, GLsizei count, const GLint* v) { | |
| 435 PPB_Graphics3D_Impl::GetCurrent()->impl()->Uniform2iv(location, count, v); | |
| 436 } | |
| 437 void Uniform3f(GLint location, GLfloat x, GLfloat y, GLfloat z) { | |
| 438 PPB_Graphics3D_Impl::GetCurrent()->impl()->Uniform3f(location, x, y, z); | |
| 439 } | |
| 440 void Uniform3fv(GLint location, GLsizei count, const GLfloat* v) { | |
| 441 PPB_Graphics3D_Impl::GetCurrent()->impl()->Uniform3fv(location, count, v); | |
| 442 } | |
| 443 void Uniform3i(GLint location, GLint x, GLint y, GLint z) { | |
| 444 PPB_Graphics3D_Impl::GetCurrent()->impl()->Uniform3i(location, x, y, z); | |
| 445 } | |
| 446 void Uniform3iv(GLint location, GLsizei count, const GLint* v) { | |
| 447 PPB_Graphics3D_Impl::GetCurrent()->impl()->Uniform3iv(location, count, v); | |
| 448 } | |
| 449 void Uniform4f(GLint location, GLfloat x, GLfloat y, GLfloat z, GLfloat w) { | |
| 450 PPB_Graphics3D_Impl::GetCurrent()->impl()->Uniform4f(location, x, y, z, w); | |
| 451 } | |
| 452 void Uniform4fv(GLint location, GLsizei count, const GLfloat* v) { | |
| 453 PPB_Graphics3D_Impl::GetCurrent()->impl()->Uniform4fv(location, count, v); | |
| 454 } | |
| 455 void Uniform4i(GLint location, GLint x, GLint y, GLint z, GLint w) { | |
| 456 PPB_Graphics3D_Impl::GetCurrent()->impl()->Uniform4i(location, x, y, z, w); | |
| 457 } | |
| 458 void Uniform4iv(GLint location, GLsizei count, const GLint* v) { | |
| 459 PPB_Graphics3D_Impl::GetCurrent()->impl()->Uniform4iv(location, count, v); | |
| 460 } | |
| 461 void UniformMatrix2fv( | |
| 462 GLint location, GLsizei count, GLboolean transpose, const GLfloat* value) { | |
| 463 PPB_Graphics3D_Impl::GetCurrent()->impl()->UniformMatrix2fv( | |
| 464 location, count, transpose, value); | |
| 465 } | |
| 466 void UniformMatrix3fv( | |
| 467 GLint location, GLsizei count, GLboolean transpose, const GLfloat* value) { | |
| 468 PPB_Graphics3D_Impl::GetCurrent()->impl()->UniformMatrix3fv( | |
| 469 location, count, transpose, value); | |
| 470 } | |
| 471 void UniformMatrix4fv( | |
| 472 GLint location, GLsizei count, GLboolean transpose, const GLfloat* value) { | |
| 473 PPB_Graphics3D_Impl::GetCurrent()->impl()->UniformMatrix4fv( | |
| 474 location, count, transpose, value); | |
| 475 } | |
| 476 void UseProgram(GLuint program) { | |
| 477 PPB_Graphics3D_Impl::GetCurrent()->impl()->UseProgram(program); | |
| 478 } | |
| 479 void ValidateProgram(GLuint program) { | |
| 480 PPB_Graphics3D_Impl::GetCurrent()->impl()->ValidateProgram(program); | |
| 481 } | |
| 482 void VertexAttrib1f(GLuint indx, GLfloat x) { | |
| 483 PPB_Graphics3D_Impl::GetCurrent()->impl()->VertexAttrib1f(indx, x); | |
| 484 } | |
| 485 void VertexAttrib1fv(GLuint indx, const GLfloat* values) { | |
| 486 PPB_Graphics3D_Impl::GetCurrent()->impl()->VertexAttrib1fv(indx, values); | |
| 487 } | |
| 488 void VertexAttrib2f(GLuint indx, GLfloat x, GLfloat y) { | |
| 489 PPB_Graphics3D_Impl::GetCurrent()->impl()->VertexAttrib2f(indx, x, y); | |
| 490 } | |
| 491 void VertexAttrib2fv(GLuint indx, const GLfloat* values) { | |
| 492 PPB_Graphics3D_Impl::GetCurrent()->impl()->VertexAttrib2fv(indx, values); | |
| 493 } | |
| 494 void VertexAttrib3f(GLuint indx, GLfloat x, GLfloat y, GLfloat z) { | |
| 495 PPB_Graphics3D_Impl::GetCurrent()->impl()->VertexAttrib3f(indx, x, y, z); | |
| 496 } | |
| 497 void VertexAttrib3fv(GLuint indx, const GLfloat* values) { | |
| 498 PPB_Graphics3D_Impl::GetCurrent()->impl()->VertexAttrib3fv(indx, values); | |
| 499 } | |
| 500 void VertexAttrib4f(GLuint indx, GLfloat x, GLfloat y, GLfloat z, GLfloat w) { | |
| 501 PPB_Graphics3D_Impl::GetCurrent()->impl()->VertexAttrib4f(indx, x, y, z, w); | |
| 502 } | |
| 503 void VertexAttrib4fv(GLuint indx, const GLfloat* values) { | |
| 504 PPB_Graphics3D_Impl::GetCurrent()->impl()->VertexAttrib4fv(indx, values); | |
| 505 } | |
| 506 void VertexAttribPointer( | |
| 507 GLuint indx, GLint size, GLenum type, GLboolean normalized, GLsizei stride, | |
| 508 const void* ptr) { | |
| 509 PPB_Graphics3D_Impl::GetCurrent()->impl()->VertexAttribPointer( | |
| 510 indx, size, type, normalized, stride, ptr); | |
| 511 } | |
| 512 void Viewport(GLint x, GLint y, GLsizei width, GLsizei height) { | |
| 513 PPB_Graphics3D_Impl::GetCurrent()->impl()->Viewport(x, y, width, height); | |
| 514 } | |
| 515 void SwapBuffers() { | |
| 516 PPB_Graphics3D_Impl::GetCurrent()->impl()->SwapBuffers(); | |
| 517 } | |
| 518 | |
| 519 const struct PPB_OpenGLES_Dev ppb_opengles = { | |
| 520 &ActiveTexture, | |
| 521 &AttachShader, | |
| 522 &BindAttribLocation, | |
| 523 &BindBuffer, | |
| 524 &BindFramebuffer, | |
| 525 &BindRenderbuffer, | |
| 526 &BindTexture, | |
| 527 &BlendColor, | |
| 528 &BlendEquation, | |
| 529 &BlendEquationSeparate, | |
| 530 &BlendFunc, | |
| 531 &BlendFuncSeparate, | |
| 532 &BufferData, | |
| 533 &BufferSubData, | |
| 534 &CheckFramebufferStatus, | |
| 535 &Clear, | |
| 536 &ClearColor, | |
| 537 &ClearDepthf, | |
| 538 &ClearStencil, | |
| 539 &ColorMask, | |
| 540 &CompileShader, | |
| 541 &CompressedTexImage2D, | |
| 542 &CompressedTexSubImage2D, | |
| 543 &CopyTexImage2D, | |
| 544 &CopyTexSubImage2D, | |
| 545 &CreateProgram, | |
| 546 &CreateShader, | |
| 547 &CullFace, | |
| 548 &DeleteBuffers, | |
| 549 &DeleteFramebuffers, | |
| 550 &DeleteProgram, | |
| 551 &DeleteRenderbuffers, | |
| 552 &DeleteShader, | |
| 553 &DeleteTextures, | |
| 554 &DepthFunc, | |
| 555 &DepthMask, | |
| 556 &DepthRangef, | |
| 557 &DetachShader, | |
| 558 &Disable, | |
| 559 &DisableVertexAttribArray, | |
| 560 &DrawArrays, | |
| 561 &DrawElements, | |
| 562 &Enable, | |
| 563 &EnableVertexAttribArray, | |
| 564 &Finish, | |
| 565 &Flush, | |
| 566 &FramebufferRenderbuffer, | |
| 567 &FramebufferTexture2D, | |
| 568 &FrontFace, | |
| 569 &GenBuffers, | |
| 570 &GenerateMipmap, | |
| 571 &GenFramebuffers, | |
| 572 &GenRenderbuffers, | |
| 573 &GenTextures, | |
| 574 &GetActiveAttrib, | |
| 575 &GetActiveUniform, | |
| 576 &GetAttachedShaders, | |
| 577 &GetAttribLocation, | |
| 578 &GetBooleanv, | |
| 579 &GetBufferParameteriv, | |
| 580 &GetError, | |
| 581 &GetFloatv, | |
| 582 &GetFramebufferAttachmentParameteriv, | |
| 583 &GetIntegerv, | |
| 584 &GetProgramiv, | |
| 585 &GetProgramInfoLog, | |
| 586 &GetRenderbufferParameteriv, | |
| 587 &GetShaderiv, | |
| 588 &GetShaderInfoLog, | |
| 589 &GetShaderPrecisionFormat, | |
| 590 &GetShaderSource, | |
| 591 &GetString, | |
| 592 &GetTexParameterfv, | |
| 593 &GetTexParameteriv, | |
| 594 &GetUniformfv, | |
| 595 &GetUniformiv, | |
| 596 &GetUniformLocation, | |
| 597 &GetVertexAttribfv, | |
| 598 &GetVertexAttribiv, | |
| 599 &GetVertexAttribPointerv, | |
| 600 &Hint, | |
| 601 &IsBuffer, | |
| 602 &IsEnabled, | |
| 603 &IsFramebuffer, | |
| 604 &IsProgram, | |
| 605 &IsRenderbuffer, | |
| 606 &IsShader, | |
| 607 &IsTexture, | |
| 608 &LineWidth, | |
| 609 &LinkProgram, | |
| 610 &PixelStorei, | |
| 611 &PolygonOffset, | |
| 612 &ReadPixels, | |
| 613 &ReleaseShaderCompiler, | |
| 614 &RenderbufferStorage, | |
| 615 &SampleCoverage, | |
| 616 &Scissor, | |
| 617 &ShaderBinary, | |
| 618 &ShaderSource, | |
| 619 &StencilFunc, | |
| 620 &StencilFuncSeparate, | |
| 621 &StencilMask, | |
| 622 &StencilMaskSeparate, | |
| 623 &StencilOp, | |
| 624 &StencilOpSeparate, | |
| 625 &TexImage2D, | |
| 626 &TexParameterf, | |
| 627 &TexParameterfv, | |
| 628 &TexParameteri, | |
| 629 &TexParameteriv, | |
| 630 &TexSubImage2D, | |
| 631 &Uniform1f, | |
| 632 &Uniform1fv, | |
| 633 &Uniform1i, | |
| 634 &Uniform1iv, | |
| 635 &Uniform2f, | |
| 636 &Uniform2fv, | |
| 637 &Uniform2i, | |
| 638 &Uniform2iv, | |
| 639 &Uniform3f, | |
| 640 &Uniform3fv, | |
| 641 &Uniform3i, | |
| 642 &Uniform3iv, | |
| 643 &Uniform4f, | |
| 644 &Uniform4fv, | |
| 645 &Uniform4i, | |
| 646 &Uniform4iv, | |
| 647 &UniformMatrix2fv, | |
| 648 &UniformMatrix3fv, | |
| 649 &UniformMatrix4fv, | |
| 650 &UseProgram, | |
| 651 &ValidateProgram, | |
| 652 &VertexAttrib1f, | |
| 653 &VertexAttrib1fv, | |
| 654 &VertexAttrib2f, | |
| 655 &VertexAttrib2fv, | |
| 656 &VertexAttrib3f, | |
| 657 &VertexAttrib3fv, | |
| 658 &VertexAttrib4f, | |
| 659 &VertexAttrib4fv, | |
| 660 &VertexAttribPointer, | |
| 661 &Viewport, | |
| 662 &SwapBuffers | |
| 663 }; | |
| 664 | |
| 665 } // namespace | |
| 666 | |
| 667 const PPB_OpenGLES_Dev* PPB_Graphics3D_Impl::GetOpenGLESInterface() { | |
| 668 return &ppb_opengles; | |
| 669 } | |
| 670 | |
| 671 } // namespace ppapi | |
| 672 } // namespace webkit | |
| 673 | |
| OLD | NEW |