Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(119)

Side by Side Diff: src/shared/ppapi_proxy/plugin_opengles.cc

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

Powered by Google App Engine
This is Rietveld 408576698