@nativescript/canvas 2.0.0-alpha.23 → 2.0.0-alpha.25
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/Canvas/common.d.ts +199 -25
- package/Canvas/common.js +624 -489
- package/Canvas/common.js.map +1 -1
- package/Canvas/index.android.js +19 -9
- package/Canvas/index.android.js.map +1 -1
- package/Canvas/index.ios.js +13 -12
- package/Canvas/index.ios.js.map +1 -1
- package/Canvas2D/CanvasRenderingContext2D/index.d.ts +0 -1
- package/Canvas2D/CanvasRenderingContext2D/index.js +9 -121
- package/Canvas2D/CanvasRenderingContext2D/index.js.map +1 -1
- package/WebGL/WebGLExtensions/index.d.ts +4 -3
- package/WebGL/WebGLExtensions/index.js +10 -3
- package/WebGL/WebGLExtensions/index.js.map +1 -1
- package/WebGL/WebGLRenderingContext/index.d.ts +15 -15
- package/WebGL/WebGLRenderingContext/index.js +15 -277
- package/WebGL/WebGLRenderingContext/index.js.map +1 -1
- package/WebGL2/WebGL2RenderingContext/index.js +0 -86
- package/WebGL2/WebGL2RenderingContext/index.js.map +1 -1
- package/package.json +1 -1
- package/platforms/android/canvas-release.aar +0 -0
- package/platforms/ios/CanvasNative.xcframework/ios-arm64/CanvasNative.framework/CanvasNative +0 -0
- package/platforms/ios/CanvasNative.xcframework/ios-arm64/CanvasNative.framework/Headers/CanvasNative-Swift.h +2 -0
- package/platforms/ios/CanvasNative.xcframework/ios-arm64/CanvasNative.framework/Headers/canvas_native.h +19 -0
- package/platforms/ios/CanvasNative.xcframework/ios-arm64/CanvasNative.framework/Modules/CanvasNative.swiftmodule/Project/arm64-apple-ios.swiftsourceinfo +0 -0
- package/platforms/ios/CanvasNative.xcframework/ios-arm64/CanvasNative.framework/Modules/CanvasNative.swiftmodule/arm64-apple-ios.abi.json +1035 -83
- package/platforms/ios/CanvasNative.xcframework/ios-arm64/CanvasNative.framework/Modules/CanvasNative.swiftmodule/arm64-apple-ios.private.swiftinterface +2 -0
- package/platforms/ios/CanvasNative.xcframework/ios-arm64/CanvasNative.framework/Modules/CanvasNative.swiftmodule/arm64-apple-ios.swiftinterface +2 -0
- package/platforms/ios/CanvasNative.xcframework/ios-arm64/dSYMs/CanvasNative.framework.dSYM/Contents/Resources/DWARF/CanvasNative +0 -0
- package/platforms/ios/CanvasNative.xcframework/ios-arm64_x86_64-simulator/CanvasNative.framework/CanvasNative +0 -0
- package/platforms/ios/CanvasNative.xcframework/ios-arm64_x86_64-simulator/CanvasNative.framework/Headers/CanvasNative-Swift.h +4 -0
- package/platforms/ios/CanvasNative.xcframework/ios-arm64_x86_64-simulator/CanvasNative.framework/Headers/canvas_native.h +19 -0
- package/platforms/ios/CanvasNative.xcframework/ios-arm64_x86_64-simulator/CanvasNative.framework/Modules/CanvasNative.swiftmodule/Project/arm64-apple-ios-simulator.swiftsourceinfo +0 -0
- package/platforms/ios/CanvasNative.xcframework/ios-arm64_x86_64-simulator/CanvasNative.framework/Modules/CanvasNative.swiftmodule/Project/x86_64-apple-ios-simulator.swiftsourceinfo +0 -0
- package/platforms/ios/CanvasNative.xcframework/ios-arm64_x86_64-simulator/CanvasNative.framework/Modules/CanvasNative.swiftmodule/arm64-apple-ios-simulator.abi.json +1035 -83
- package/platforms/ios/CanvasNative.xcframework/ios-arm64_x86_64-simulator/CanvasNative.framework/Modules/CanvasNative.swiftmodule/arm64-apple-ios-simulator.private.swiftinterface +2 -0
- package/platforms/ios/CanvasNative.xcframework/ios-arm64_x86_64-simulator/CanvasNative.framework/Modules/CanvasNative.swiftmodule/arm64-apple-ios-simulator.swiftinterface +2 -0
- package/platforms/ios/CanvasNative.xcframework/ios-arm64_x86_64-simulator/CanvasNative.framework/Modules/CanvasNative.swiftmodule/x86_64-apple-ios-simulator.abi.json +1035 -83
- package/platforms/ios/CanvasNative.xcframework/ios-arm64_x86_64-simulator/CanvasNative.framework/Modules/CanvasNative.swiftmodule/x86_64-apple-ios-simulator.private.swiftinterface +2 -0
- package/platforms/ios/CanvasNative.xcframework/ios-arm64_x86_64-simulator/CanvasNative.framework/Modules/CanvasNative.swiftmodule/x86_64-apple-ios-simulator.swiftinterface +2 -0
- package/platforms/ios/CanvasNative.xcframework/ios-arm64_x86_64-simulator/CanvasNative.framework/_CodeSignature/CodeResources +24 -24
- package/platforms/ios/CanvasNative.xcframework/ios-arm64_x86_64-simulator/dSYMs/CanvasNative.framework.dSYM/Contents/Resources/DWARF/CanvasNative +0 -0
- package/platforms/ios/src/cpp/CanvasJSIModule.cpp +13 -62
- package/platforms/ios/src/cpp/ImageBitmapImpl.h +15 -3
- package/platforms/ios/src/cpp/OneByteStringResource.cpp +26 -2
- package/platforms/ios/src/cpp/OneByteStringResource.h +14 -3
- package/platforms/ios/src/cpp/TextDecoderImpl.cpp +8 -9
- package/platforms/ios/src/cpp/canvas2d/CanvasRenderingContext2DImpl.cpp +257 -268
- package/platforms/ios/src/cpp/canvas2d/MatrixImpl.cpp +8 -2
- package/platforms/ios/src/cpp/canvas2d/Path2D.cpp +1 -1
- package/platforms/ios/src/cpp/webgl/WebGLRenderingContext.cpp +72 -94
- package/platforms/ios/src/cpp/webgl/extensions/ANGLE_instanced_arraysImpl.cpp +2 -2
- package/platforms/ios/src/cpp/webgl/extensions/ANGLE_instanced_arraysImpl.h +4 -3
- package/platforms/ios/src/cpp/webgl/extensions/EXT_disjoint_timer_queryImpl.cpp +1 -5
- package/platforms/ios/src/cpp/webgl/extensions/EXT_disjoint_timer_queryImpl.h +5 -5
- package/platforms/ios/src/cpp/webgl2/WebGL2RenderingContext.cpp +103 -113
|
@@ -72,110 +72,70 @@ export class WebGLRenderingContext extends WebGLRenderingContextBase {
|
|
|
72
72
|
return this.native.__toDataURL(arguments[0], arguments[1]);
|
|
73
73
|
}
|
|
74
74
|
activeTexture(texture) {
|
|
75
|
-
this._glCheckError('activeTexture');
|
|
76
|
-
this._checkArgs('activeTexture', arguments);
|
|
77
75
|
this.native.activeTexture(texture);
|
|
78
76
|
}
|
|
79
77
|
attachShader(program, shader) {
|
|
80
|
-
this._glCheckError('attachShader');
|
|
81
|
-
this._checkArgs('attachShader', arguments);
|
|
82
78
|
const value = program.native;
|
|
83
79
|
const value2 = shader.native;
|
|
84
80
|
this.native.attachShader(value, value2);
|
|
85
81
|
}
|
|
86
82
|
bindAttribLocation(program, index, name) {
|
|
87
|
-
this._glCheckError('bindAttribLocation');
|
|
88
|
-
this._checkArgs('bindAttribLocation', arguments);
|
|
89
83
|
const value = program.native;
|
|
90
84
|
this.native.bindAttribLocation(value, index, name);
|
|
91
85
|
}
|
|
92
86
|
bindBuffer(target, buffer) {
|
|
93
|
-
this._glCheckError('bindBuffer');
|
|
94
|
-
this._checkArgs('bindBuffer', arguments);
|
|
95
87
|
const value = buffer ? buffer.native : null;
|
|
96
88
|
this.native.bindBuffer(target, value);
|
|
97
89
|
}
|
|
98
90
|
bindFramebuffer(target, framebuffer) {
|
|
99
|
-
this._glCheckError('bindFramebuffer');
|
|
100
|
-
this._checkArgs('bindFramebuffer', arguments);
|
|
101
91
|
const value = framebuffer ? framebuffer.native : null;
|
|
102
92
|
this.native.bindFramebuffer(target, value);
|
|
103
93
|
}
|
|
104
94
|
bindRenderbuffer(target, renderbuffer) {
|
|
105
|
-
this._glCheckError('bindRenderbuffer');
|
|
106
|
-
this._checkArgs('bindRenderbuffer', arguments);
|
|
107
95
|
const value = renderbuffer ? renderbuffer.native : null;
|
|
108
96
|
this.native.bindRenderbuffer(target, value);
|
|
109
97
|
}
|
|
110
98
|
bindTexture(target, texture) {
|
|
111
|
-
this._glCheckError('bindTexture');
|
|
112
|
-
this._checkArgs('bindTexture', arguments);
|
|
113
99
|
const value = texture ? texture.native : null;
|
|
114
100
|
this.native.bindTexture(target, value);
|
|
115
101
|
}
|
|
116
102
|
blendColor(red, green, blue, alpha) {
|
|
117
|
-
this._glCheckError('blendColor');
|
|
118
|
-
this._checkArgs('blendColor', arguments);
|
|
119
103
|
this.native.blendColor(red, green, blue, alpha);
|
|
120
104
|
}
|
|
121
105
|
blendEquationSeparate(modeRGB, modeAlpha) {
|
|
122
|
-
this._glCheckError('blendEquationSeparate');
|
|
123
|
-
this._checkArgs('blendEquationSeparate', arguments);
|
|
124
106
|
this.native.blendEquationSeparate(modeRGB, modeAlpha);
|
|
125
107
|
}
|
|
126
108
|
blendEquation(mode) {
|
|
127
|
-
this._glCheckError('blendEquation');
|
|
128
|
-
this._checkArgs('blendEquation', arguments);
|
|
129
109
|
this.native.blendEquation(mode);
|
|
130
110
|
}
|
|
131
111
|
blendFuncSeparate(srcRGB = this.ONE, dstRGB = this.ZERO, srcAlpha = this.ONE, dstAlpha = this.ZERO) {
|
|
132
|
-
this._glCheckError('blendFuncSeparate');
|
|
133
|
-
this._checkArgs('blendFuncSeparate', arguments);
|
|
134
112
|
this.native.blendFuncSeparate(srcRGB, dstRGB, srcAlpha, dstAlpha);
|
|
135
113
|
}
|
|
136
114
|
blendFunc(sfactor = this.ONE, dfactor = this.ZERO) {
|
|
137
|
-
this._glCheckError('blendFunc');
|
|
138
|
-
this._checkArgs('blendFunc', arguments);
|
|
139
115
|
this.native.blendFunc(sfactor, dfactor);
|
|
140
116
|
}
|
|
141
117
|
bufferData(target, srcData, usage) {
|
|
142
|
-
this._glCheckError('bufferData');
|
|
143
|
-
this._checkArgs('bufferData', arguments);
|
|
144
118
|
this.native.bufferData(target, srcData, usage);
|
|
145
119
|
}
|
|
146
120
|
bufferSubData(target, offset, srcData) {
|
|
147
|
-
this._glCheckError('bufferSubData');
|
|
148
|
-
this._checkArgs('bufferSubData', arguments);
|
|
149
121
|
this.native.bufferSubData(target, offset, srcData);
|
|
150
122
|
}
|
|
151
123
|
checkFramebufferStatus(target) {
|
|
152
|
-
this._glCheckError('checkFramebufferStatus');
|
|
153
|
-
this._checkArgs('checkFramebufferStatus', arguments);
|
|
154
124
|
return this.native.checkFramebufferStatus(target);
|
|
155
125
|
}
|
|
156
126
|
clearColor(red, green, blue, alpha) {
|
|
157
|
-
this._glCheckError('clearColor');
|
|
158
|
-
this._checkArgs('clearColor', arguments);
|
|
159
127
|
this.native.clearColor(red, green, blue, alpha);
|
|
160
128
|
}
|
|
161
129
|
clearDepth(depth) {
|
|
162
|
-
this._glCheckError('clearDepth');
|
|
163
|
-
this._checkArgs('clearDepth', arguments);
|
|
164
130
|
this.native.clearDepth(depth);
|
|
165
131
|
}
|
|
166
132
|
clearStencil(stencil) {
|
|
167
|
-
this._glCheckError('clearStencil');
|
|
168
|
-
this._checkArgs('clearStencil', arguments);
|
|
169
133
|
this.native.clearStencil(stencil);
|
|
170
134
|
}
|
|
171
135
|
clear(mask) {
|
|
172
|
-
this._glCheckError('clear');
|
|
173
|
-
this._checkArgs('clear', arguments);
|
|
174
136
|
this.native.clear(mask);
|
|
175
137
|
}
|
|
176
138
|
colorMask(red, green, blue, alpha) {
|
|
177
|
-
this._glCheckError('colorMask');
|
|
178
|
-
this._checkArgs('colorMask', arguments);
|
|
179
139
|
this.native.colorMask(red, green, blue, alpha);
|
|
180
140
|
}
|
|
181
141
|
commit() {
|
|
@@ -183,115 +143,73 @@ export class WebGLRenderingContext extends WebGLRenderingContextBase {
|
|
|
183
143
|
this.native.commit();
|
|
184
144
|
}
|
|
185
145
|
compileShader(shader) {
|
|
186
|
-
this._glCheckError('compileShader');
|
|
187
|
-
this._checkArgs('compileShader', arguments);
|
|
188
146
|
const value = shader.native;
|
|
189
147
|
this.native.compileShader(value);
|
|
190
148
|
}
|
|
191
149
|
compressedTexImage2D(target, level, internalformat, width, height, border, pixels) {
|
|
192
|
-
this._glCheckError('compressedTexImage2D');
|
|
193
|
-
this._checkArgs('compressedTexImage2D', arguments);
|
|
194
150
|
this.native.compressedTexImage2D(target, level, internalformat, width, height, border, pixels);
|
|
195
151
|
}
|
|
196
152
|
compressedTexSubImage2D(target, level, xoffset, yoffset, width, height, format, pixels) {
|
|
197
|
-
this._glCheckError('compressedTexSubImage2D');
|
|
198
|
-
this._checkArgs('compressedTexSubImage2D', arguments);
|
|
199
153
|
this.native.compressedTexSubImage2D(target, level, xoffset, yoffset, width, height, format, pixels);
|
|
200
154
|
}
|
|
201
155
|
copyTexImage2D(target, level, internalformat, x, y, width, height, border) {
|
|
202
|
-
this._glCheckError('copyTexImage2D');
|
|
203
|
-
this._checkArgs('copyTexImage2D', arguments);
|
|
204
156
|
this.native.copyTexImage2D(target, level, internalformat, x, y, width, height, border);
|
|
205
157
|
}
|
|
206
158
|
copyTexSubImage2D(target, level, xoffset, yoffset, x, y, width, height) {
|
|
207
|
-
this._glCheckError('copyTexSubImage2D');
|
|
208
|
-
this._checkArgs('copyTexSubImage2D', arguments);
|
|
209
159
|
this.native.copyTexSubImage2D(target, level, xoffset, yoffset, x, y, width, height);
|
|
210
160
|
}
|
|
211
161
|
createBuffer() {
|
|
212
|
-
this._glCheckError('createBuffer');
|
|
213
|
-
this._checkArgs('createBuffer', arguments);
|
|
214
162
|
const id = this.native.createBuffer();
|
|
215
163
|
return new WebGLBuffer(id);
|
|
216
164
|
}
|
|
217
165
|
createFramebuffer() {
|
|
218
|
-
this._glCheckError('createFramebuffer');
|
|
219
|
-
this._checkArgs('createFramebuffer', arguments);
|
|
220
166
|
return new WebGLFramebuffer(this.native.createFramebuffer());
|
|
221
167
|
}
|
|
222
168
|
createProgram() {
|
|
223
|
-
this._glCheckError('createProgram');
|
|
224
|
-
this._checkArgs('createProgram', arguments);
|
|
225
169
|
return new WebGLProgram(this.native.createProgram());
|
|
226
170
|
}
|
|
227
171
|
createRenderbuffer() {
|
|
228
|
-
this._glCheckError('createRenderbuffer');
|
|
229
|
-
this._checkArgs('createRenderbuffer', arguments);
|
|
230
172
|
return new WebGLRenderbuffer(this.native.createRenderbuffer());
|
|
231
173
|
}
|
|
232
174
|
createShader(type) {
|
|
233
|
-
this._glCheckError('createShader');
|
|
234
|
-
this._checkArgs('createShader', arguments);
|
|
235
175
|
return new WebGLShader(this.native.createShader(type));
|
|
236
176
|
}
|
|
237
177
|
createTexture() {
|
|
238
|
-
this._glCheckError('createTexture');
|
|
239
|
-
this._checkArgs('createTexture', arguments);
|
|
240
178
|
return new WebGLTexture(this.native.createTexture());
|
|
241
179
|
}
|
|
242
180
|
cullFace(mode) {
|
|
243
|
-
this._glCheckError('cullFace');
|
|
244
|
-
this._checkArgs('cullFace', arguments);
|
|
245
181
|
this.native.cullFace(mode);
|
|
246
182
|
}
|
|
247
183
|
deleteBuffer(buffer) {
|
|
248
|
-
this._glCheckError('deleteBuffer');
|
|
249
|
-
this._checkArgs('deleteBuffer', arguments);
|
|
250
184
|
const value = buffer.native;
|
|
251
185
|
this.native.deleteBuffer(value);
|
|
252
186
|
}
|
|
253
187
|
deleteFramebuffer(frameBuffer) {
|
|
254
|
-
this._glCheckError('deleteFramebuffer');
|
|
255
|
-
this._checkArgs('deleteFramebuffer', arguments);
|
|
256
188
|
const value = frameBuffer.native;
|
|
257
189
|
this.native.deleteFramebuffer(value);
|
|
258
190
|
}
|
|
259
191
|
deleteProgram(program) {
|
|
260
|
-
this._glCheckError('deleteProgram');
|
|
261
|
-
this._checkArgs('deleteProgram', arguments);
|
|
262
192
|
const value = program.native;
|
|
263
193
|
this.native.deleteProgram(value);
|
|
264
194
|
}
|
|
265
195
|
deleteRenderbuffer(renderBuffer) {
|
|
266
|
-
this._glCheckError('deleteRenderbuffer');
|
|
267
|
-
this._checkArgs('deleteRenderbuffer', arguments);
|
|
268
196
|
const value = renderBuffer.native;
|
|
269
197
|
this.native.deleteRenderbuffer(value);
|
|
270
198
|
}
|
|
271
199
|
deleteShader(shader) {
|
|
272
|
-
this._glCheckError('deleteShader');
|
|
273
|
-
this._checkArgs('deleteShader', arguments);
|
|
274
200
|
this.native.deleteShader(shader.native);
|
|
275
201
|
}
|
|
276
202
|
deleteTexture(texture) {
|
|
277
|
-
this._glCheckError('deleteTexture');
|
|
278
|
-
this._checkArgs('deleteTexture', arguments);
|
|
279
203
|
const value = texture.native;
|
|
280
204
|
this.native.deleteTexture(value);
|
|
281
205
|
}
|
|
282
206
|
depthFunc(func) {
|
|
283
|
-
this._glCheckError('depthFunc');
|
|
284
|
-
this._checkArgs('depthFunc', arguments);
|
|
285
207
|
this.native.depthFunc(func);
|
|
286
208
|
}
|
|
287
209
|
depthMask(flag) {
|
|
288
|
-
this._glCheckError('depthMask');
|
|
289
|
-
this._checkArgs('depthMask', arguments);
|
|
290
210
|
this.native.depthMask(flag);
|
|
291
211
|
}
|
|
292
212
|
depthRange(zNear, zFar) {
|
|
293
|
-
this._glCheckError('depthRange');
|
|
294
|
-
this._checkArgs('depthRange', arguments);
|
|
295
213
|
this.native.depthRange(zNear, zFar);
|
|
296
214
|
}
|
|
297
215
|
detachShader(program, shader) {
|
|
@@ -302,94 +220,62 @@ export class WebGLRenderingContext extends WebGLRenderingContextBase {
|
|
|
302
220
|
this.native.detachShader(value, value2);
|
|
303
221
|
}
|
|
304
222
|
disableVertexAttribArray(index) {
|
|
305
|
-
this._glCheckError('disableVertexAttribArray');
|
|
306
|
-
this._checkArgs('disableVertexAttribArray', arguments);
|
|
307
223
|
this.native.disableVertexAttribArray(index);
|
|
308
224
|
}
|
|
309
225
|
disable(cap) {
|
|
310
|
-
this._glCheckError('disable');
|
|
311
|
-
this._checkArgs('disable', arguments);
|
|
312
226
|
this.native.disable(cap);
|
|
313
227
|
}
|
|
314
228
|
drawArrays(mode, first, count) {
|
|
315
|
-
this._glCheckError('drawArrays');
|
|
316
|
-
this._checkArgs('drawArrays', arguments);
|
|
317
229
|
this.native.drawArrays(mode, first, count);
|
|
318
230
|
}
|
|
319
231
|
drawElements(mode, count, type, offset) {
|
|
320
|
-
this._glCheckError('drawElements');
|
|
321
|
-
this._checkArgs('drawElements', arguments);
|
|
322
232
|
this.native.drawElements(mode, count, type, offset);
|
|
323
233
|
}
|
|
324
234
|
enableVertexAttribArray(index) {
|
|
325
|
-
this._glCheckError('enableVertexAttribArray');
|
|
326
|
-
this._checkArgs('enableVertexAttribArray', arguments);
|
|
327
235
|
this.native.enableVertexAttribArray(index);
|
|
328
236
|
}
|
|
329
237
|
enable(cap) {
|
|
330
|
-
this._glCheckError('enable');
|
|
331
|
-
this._checkArgs('enable', arguments);
|
|
332
238
|
this.native.enable(cap);
|
|
333
239
|
}
|
|
334
240
|
finish() {
|
|
335
|
-
this._glCheckError('finish');
|
|
336
241
|
this.native.finish();
|
|
337
242
|
}
|
|
338
243
|
flush() {
|
|
339
|
-
this._glCheckError('flush');
|
|
340
244
|
this.native.flush();
|
|
341
245
|
}
|
|
342
246
|
framebufferRenderbuffer(target, attachment, renderbuffertarget, renderbuffer) {
|
|
343
|
-
this._glCheckError('framebufferRenderbuffer');
|
|
344
|
-
this._checkArgs('framebufferRenderbuffer', arguments);
|
|
345
247
|
const value = renderbuffer.native;
|
|
346
248
|
this.native.framebufferRenderbuffer(target, attachment, renderbuffertarget, value);
|
|
347
249
|
}
|
|
348
250
|
framebufferTexture2D(target, attachment, textarget, texture, level) {
|
|
349
|
-
this._glCheckError('framebufferTexture2D');
|
|
350
|
-
this._checkArgs('framebufferTexture2D', arguments);
|
|
351
251
|
const value = texture.native;
|
|
352
252
|
this.native.framebufferTexture2D(target, attachment, textarget, value, level);
|
|
353
253
|
}
|
|
354
254
|
frontFace(mode) {
|
|
355
|
-
this._checkArgs('frontFace', arguments);
|
|
356
|
-
this._glCheckError('frontFace');
|
|
357
255
|
this.native.frontFace(mode);
|
|
358
256
|
}
|
|
359
257
|
generateMipmap(target) {
|
|
360
|
-
this._checkArgs('generateMipmap', arguments);
|
|
361
|
-
this._glCheckError('generateMipmap');
|
|
362
258
|
this.native.generateMipmap(target);
|
|
363
259
|
}
|
|
364
260
|
getActiveAttrib(program, index) {
|
|
365
|
-
this._glCheckError('getActiveAttrib');
|
|
366
|
-
this._checkArgs('getActiveAttrib', arguments);
|
|
367
261
|
const value = program.native;
|
|
368
262
|
const attrib = this.native.getActiveAttrib(value, index);
|
|
369
263
|
return new WebGLActiveInfo(attrib);
|
|
370
264
|
}
|
|
371
265
|
getActiveUniform(program, index) {
|
|
372
|
-
this._glCheckError('getActiveUniform');
|
|
373
|
-
this._checkArgs('getActiveUniform', arguments);
|
|
374
266
|
const value = program.native;
|
|
375
267
|
const uniform = this.native.getActiveUniform(value, index);
|
|
376
268
|
return new WebGLActiveInfo(uniform);
|
|
377
269
|
}
|
|
378
270
|
getAttachedShaders(program) {
|
|
379
|
-
this._glCheckError('getAttachedShaders');
|
|
380
|
-
this._checkArgs('getAttachedShaders', arguments);
|
|
381
271
|
const value = program.native;
|
|
382
272
|
return this.native.getAttachedShaders(value).map((shader) => new WebGLShader(shader));
|
|
383
273
|
}
|
|
384
274
|
getAttribLocation(program, name) {
|
|
385
|
-
this._glCheckError('getAttribLocation');
|
|
386
|
-
this._checkArgs('getAttribLocation', arguments);
|
|
387
275
|
const value = program.native;
|
|
388
276
|
return this.native.getAttribLocation(value, name);
|
|
389
277
|
}
|
|
390
278
|
getBufferParameter(target, pname) {
|
|
391
|
-
this._glCheckError('getBufferParameter');
|
|
392
|
-
this._checkArgs('getBufferParameter', arguments);
|
|
393
279
|
return this.native.getBufferParameter(target, pname);
|
|
394
280
|
}
|
|
395
281
|
getContextAttributes() {
|
|
@@ -399,8 +285,6 @@ export class WebGLRenderingContext extends WebGLRenderingContextBase {
|
|
|
399
285
|
return this.native.getError();
|
|
400
286
|
}
|
|
401
287
|
getExtension(name) {
|
|
402
|
-
this._glCheckError('getExtension');
|
|
403
|
-
this._checkArgs('getExtension', arguments);
|
|
404
288
|
if (name === 'EXT_disjoint_timer_query_webgl2') {
|
|
405
289
|
return null;
|
|
406
290
|
}
|
|
@@ -459,8 +343,6 @@ export class WebGLRenderingContext extends WebGLRenderingContextBase {
|
|
|
459
343
|
return null;
|
|
460
344
|
}
|
|
461
345
|
getFramebufferAttachmentParameter(target, attachment, pname) {
|
|
462
|
-
this._glCheckError('getFramebufferAttachmentParameter');
|
|
463
|
-
this._checkArgs('getFramebufferAttachmentParameter', arguments);
|
|
464
346
|
const param = this.native.getFramebufferAttachmentParameter(target, attachment, pname);
|
|
465
347
|
if (typeof param === 'object') {
|
|
466
348
|
if (param.isRenderbuffer) {
|
|
@@ -526,66 +408,45 @@ export class WebGLRenderingContext extends WebGLRenderingContextBase {
|
|
|
526
408
|
}
|
|
527
409
|
}
|
|
528
410
|
getParameter(pname) {
|
|
529
|
-
this._glCheckError('getParameter');
|
|
530
|
-
this._checkArgs('getParameter', arguments);
|
|
531
411
|
const value = this.native.getParameter(pname);
|
|
532
412
|
return this._handleGetParameter(pname, value);
|
|
533
413
|
}
|
|
534
414
|
getProgramInfoLog(program) {
|
|
535
|
-
this._glCheckError('getProgramInfoLog');
|
|
536
|
-
this._checkArgs('getProgramInfoLog', arguments);
|
|
537
415
|
const value = program.native;
|
|
538
416
|
return this.native.getProgramInfoLog(value);
|
|
539
417
|
}
|
|
540
418
|
getProgramParameter(program, pname) {
|
|
541
|
-
this._glCheckError('getProgramParameter');
|
|
542
|
-
this._checkArgs('getProgramParameter', arguments);
|
|
543
419
|
const value = program.native;
|
|
544
420
|
const result = this.native.getProgramParameter(value, pname);
|
|
545
421
|
return result;
|
|
546
422
|
}
|
|
547
423
|
getRenderbufferParameter(target, pname) {
|
|
548
|
-
this._glCheckError('getRenderbufferParameter');
|
|
549
|
-
this._checkArgs('getRenderbufferParameter', arguments);
|
|
550
424
|
return this.native.getRenderbufferParameter(target, pname);
|
|
551
425
|
}
|
|
552
426
|
getShaderInfoLog(shader) {
|
|
553
|
-
this._glCheckError('getShaderInfoLog');
|
|
554
|
-
this._checkArgs('getShaderInfoLog', arguments);
|
|
555
427
|
const value = shader.native;
|
|
556
428
|
return this.native.getShaderInfoLog(value);
|
|
557
429
|
}
|
|
558
430
|
getShaderParameter(shader, pname) {
|
|
559
|
-
this._glCheckError('getShaderParameter');
|
|
560
|
-
this._checkArgs('getShaderParameter', arguments);
|
|
561
431
|
const value = shader.native;
|
|
562
432
|
const result = this.native.getShaderParameter(value, pname);
|
|
563
433
|
return result;
|
|
564
434
|
}
|
|
565
435
|
getShaderPrecisionFormat(shaderType, precisionType) {
|
|
566
|
-
this._glCheckError('getShaderPrecisionFormat');
|
|
567
|
-
this._checkArgs('getShaderPrecisionFormat', arguments);
|
|
568
436
|
const precision = this.native.getShaderPrecisionFormat(shaderType, precisionType);
|
|
569
437
|
return new WebGLShaderPrecisionFormat(precision);
|
|
570
438
|
}
|
|
571
439
|
getShaderSource(shader) {
|
|
572
|
-
this._glCheckError('getShaderSource');
|
|
573
|
-
this._checkArgs('getShaderSource', arguments);
|
|
574
440
|
const value = shader ? shader.native : 0;
|
|
575
441
|
return this.native.getShaderSource(value);
|
|
576
442
|
}
|
|
577
443
|
getSupportedExtensions() {
|
|
578
|
-
this._glCheckError('getSupportedExtensions');
|
|
579
444
|
return this.native.getSupportedExtensions();
|
|
580
445
|
}
|
|
581
446
|
getTexParameter(target, pname) {
|
|
582
|
-
this._glCheckError('getTexParameter');
|
|
583
|
-
this._checkArgs('getTexParameter', arguments);
|
|
584
447
|
return this.native.getTexParameter(target, pname);
|
|
585
448
|
}
|
|
586
449
|
getUniformLocation(program, name) {
|
|
587
|
-
this._glCheckError('getUniformLocation');
|
|
588
|
-
this._checkArgs('getUniformLocation', arguments);
|
|
589
450
|
const value = program.native;
|
|
590
451
|
const id = this.native.getUniformLocation(value, name);
|
|
591
452
|
if (id === -1) {
|
|
@@ -594,8 +455,6 @@ export class WebGLRenderingContext extends WebGLRenderingContextBase {
|
|
|
594
455
|
return new WebGLUniformLocation(id);
|
|
595
456
|
}
|
|
596
457
|
getUniform(program, location) {
|
|
597
|
-
this._glCheckError('getUniform');
|
|
598
|
-
this._checkArgs('getUniform', arguments);
|
|
599
458
|
const value = program.native;
|
|
600
459
|
const value2 = location.native;
|
|
601
460
|
const uniform = this.native.getUniform(value, value2);
|
|
@@ -605,13 +464,9 @@ export class WebGLRenderingContext extends WebGLRenderingContextBase {
|
|
|
605
464
|
return uniform;
|
|
606
465
|
}
|
|
607
466
|
getVertexAttribOffset(index, pname) {
|
|
608
|
-
this._glCheckError('getVertexAttribOffset');
|
|
609
|
-
this._checkArgs('getVertexAttribOffset', arguments);
|
|
610
467
|
return this.native.getVertexAttribOffset(index, pname);
|
|
611
468
|
}
|
|
612
469
|
getVertexAttrib(index, pname) {
|
|
613
|
-
this._glCheckError('getVertexAttrib');
|
|
614
|
-
this._checkArgs('getVertexAttrib', arguments);
|
|
615
470
|
const value = this.native.getVertexAttrib(index, pname);
|
|
616
471
|
if (pname === this.CURRENT_VERTEX_ATTRIB) {
|
|
617
472
|
return value;
|
|
@@ -619,69 +474,46 @@ export class WebGLRenderingContext extends WebGLRenderingContextBase {
|
|
|
619
474
|
return value;
|
|
620
475
|
}
|
|
621
476
|
hint(target, mode) {
|
|
622
|
-
this._glCheckError('hint');
|
|
623
|
-
this._checkArgs('hint', arguments);
|
|
624
477
|
this.native.hint(target, mode);
|
|
625
478
|
}
|
|
626
479
|
isBuffer(buffer) {
|
|
627
|
-
this._glCheckError('isBuffer');
|
|
628
|
-
this._checkArgs('isBuffer', arguments);
|
|
629
480
|
const value = buffer.native;
|
|
630
481
|
return this.native.isBuffer(value);
|
|
631
482
|
}
|
|
632
483
|
isContextLost() {
|
|
633
|
-
this._glCheckError('isContextLost');
|
|
634
484
|
return this.native.isContextLost();
|
|
635
485
|
}
|
|
636
486
|
isEnabled(cap) {
|
|
637
|
-
this._glCheckError('isEnabled');
|
|
638
|
-
this._checkArgs('isEnabled', arguments);
|
|
639
487
|
return this.native.isEnabled(cap);
|
|
640
488
|
}
|
|
641
489
|
isFramebuffer(framebuffer) {
|
|
642
|
-
this._glCheckError('isFramebuffer');
|
|
643
|
-
this._checkArgs('isFramebuffer', arguments);
|
|
644
490
|
const value = framebuffer ? framebuffer.native : 0;
|
|
645
491
|
return this.native.isFramebuffer(value);
|
|
646
492
|
}
|
|
647
493
|
isProgram(program) {
|
|
648
|
-
this._glCheckError('isProgram');
|
|
649
|
-
this._checkArgs('isProgram', arguments);
|
|
650
494
|
const value = program.native;
|
|
651
495
|
return this.native.isProgram(value);
|
|
652
496
|
}
|
|
653
497
|
isRenderbuffer(renderbuffer) {
|
|
654
|
-
this._glCheckError('isRenderbuffer');
|
|
655
|
-
this._checkArgs('isRenderbuffer', arguments);
|
|
656
498
|
const value = renderbuffer.native;
|
|
657
499
|
return this.native.isRenderbuffer(value);
|
|
658
500
|
}
|
|
659
501
|
isShader(shader) {
|
|
660
|
-
this._glCheckError('isShader');
|
|
661
|
-
this._checkArgs('isShader', arguments);
|
|
662
502
|
const value = shader.native;
|
|
663
503
|
return this.native.isShader(value);
|
|
664
504
|
}
|
|
665
505
|
isTexture(texture) {
|
|
666
|
-
this._glCheckError('isTexture');
|
|
667
|
-
this._checkArgs('isTexture', arguments);
|
|
668
506
|
const value = texture.native;
|
|
669
507
|
return this.native.isTexture(value);
|
|
670
508
|
}
|
|
671
509
|
lineWidth(width) {
|
|
672
|
-
this._glCheckError('lineWidth');
|
|
673
|
-
this._checkArgs('lineWidth', arguments);
|
|
674
510
|
this.native.lineWidth(width);
|
|
675
511
|
}
|
|
676
512
|
linkProgram(program) {
|
|
677
|
-
this._glCheckError('linkProgram');
|
|
678
|
-
this._checkArgs('linkProgram', arguments);
|
|
679
513
|
const value = program ? program.native : 0;
|
|
680
514
|
this.native.linkProgram(value);
|
|
681
515
|
}
|
|
682
516
|
pixelStorei(pname, param) {
|
|
683
|
-
this._glCheckError('pixelStorei');
|
|
684
|
-
this._checkArgs('pixelStorei', arguments);
|
|
685
517
|
if (pname === this.UNPACK_FLIP_Y_WEBGL || pname === this.UNPACK_PREMULTIPLY_ALPHA_WEBGL) {
|
|
686
518
|
if (pname === this.UNPACK_FLIP_Y_WEBGL) {
|
|
687
519
|
this._flipY = param;
|
|
@@ -702,18 +534,12 @@ export class WebGLRenderingContext extends WebGLRenderingContextBase {
|
|
|
702
534
|
}
|
|
703
535
|
}
|
|
704
536
|
polygonOffset(factor, units) {
|
|
705
|
-
this._glCheckError('polygonOffset');
|
|
706
|
-
this._checkArgs('polygonOffset', arguments);
|
|
707
537
|
this.native.polygonOffset(factor, units);
|
|
708
538
|
}
|
|
709
539
|
readPixels(x, y, width, height, format, type, pixels) {
|
|
710
|
-
this._glCheckError('readPixels');
|
|
711
|
-
this._checkArgs('readPixels', arguments);
|
|
712
540
|
this.native.readPixels(x, y, width, height, format, type, pixels);
|
|
713
541
|
}
|
|
714
542
|
renderbufferStorage(target, internalFormat, width, height) {
|
|
715
|
-
this._glCheckError('renderbufferStorage');
|
|
716
|
-
this._checkArgs('renderbufferStorage', arguments);
|
|
717
543
|
if (internalFormat === this.DEPTH_STENCIL) {
|
|
718
544
|
// DEPTH24_STENCIL8 = 35056
|
|
719
545
|
// DEPTH24_STENCIL8_OES = 0x88F0
|
|
@@ -722,54 +548,34 @@ export class WebGLRenderingContext extends WebGLRenderingContextBase {
|
|
|
722
548
|
this.native.renderbufferStorage(target, internalFormat, width, height);
|
|
723
549
|
}
|
|
724
550
|
sampleCoverage(value, invert) {
|
|
725
|
-
this._glCheckError('sampleCoverage');
|
|
726
|
-
this._checkArgs('sampleCoverage', arguments);
|
|
727
551
|
this.native.sampleCoverage(value, invert);
|
|
728
552
|
}
|
|
729
553
|
scissor(x, y, width, height) {
|
|
730
|
-
this._glCheckError('scissor');
|
|
731
|
-
this._checkArgs('scissor', arguments);
|
|
732
554
|
this.native.scissor(x, y, width, height);
|
|
733
555
|
}
|
|
734
556
|
shaderSource(shader, source) {
|
|
735
|
-
this._glCheckError('shaderSource');
|
|
736
|
-
this._checkArgs('shaderSource', arguments);
|
|
737
557
|
const value = shader ? shader.native : 0;
|
|
738
558
|
this.native.shaderSource(value, source);
|
|
739
559
|
}
|
|
740
560
|
stencilFuncSeparate(face, func, ref, mask) {
|
|
741
|
-
this._glCheckError('stencilFuncSeparate');
|
|
742
|
-
this._checkArgs('stencilFuncSeparate', arguments);
|
|
743
561
|
this.native.stencilFuncSeparate(face, func, ref, mask);
|
|
744
562
|
}
|
|
745
563
|
stencilFunc(func, ref, mask) {
|
|
746
|
-
this._glCheckError('stencilFunc');
|
|
747
|
-
this._checkArgs('stencilFunc', arguments);
|
|
748
564
|
this.native.stencilFunc(func, ref, mask);
|
|
749
565
|
}
|
|
750
566
|
stencilMaskSeparate(face, mask) {
|
|
751
|
-
this._glCheckError('stencilMaskSeparate');
|
|
752
|
-
this._checkArgs('stencilMaskSeparate', arguments);
|
|
753
567
|
this.native.stencilMaskSeparate(face, mask);
|
|
754
568
|
}
|
|
755
569
|
stencilMask(mask) {
|
|
756
|
-
this._glCheckError('stencilMask');
|
|
757
|
-
this._checkArgs('stencilMask', arguments);
|
|
758
570
|
this.native.stencilMask(mask);
|
|
759
571
|
}
|
|
760
572
|
stencilOpSeparate(face, fail, zfail, zpass) {
|
|
761
|
-
this._glCheckError('stencilOpSeparate');
|
|
762
|
-
this._checkArgs('stencilOpSeparate', arguments);
|
|
763
573
|
this.native.stencilOpSeparate(face, fail, zfail, zpass);
|
|
764
574
|
}
|
|
765
575
|
stencilOp(fail, zfail, zpass) {
|
|
766
|
-
this._glCheckError('stencilOp');
|
|
767
|
-
this._checkArgs('stencilOp', arguments);
|
|
768
576
|
this.native.stencilOp(fail, zfail, zpass);
|
|
769
577
|
}
|
|
770
578
|
texImage2D(target, level, internalformat, width, height, border, format, type, pixels) {
|
|
771
|
-
this._glCheckError('texImage2D');
|
|
772
|
-
this._checkArgs('texImage2D', arguments);
|
|
773
579
|
if (arguments.length === 9) {
|
|
774
580
|
this.native.texImage2D(target, level, internalformat, width, height, border, format, type ?? internalformat, pixels);
|
|
775
581
|
}
|
|
@@ -814,18 +620,12 @@ export class WebGLRenderingContext extends WebGLRenderingContextBase {
|
|
|
814
620
|
}
|
|
815
621
|
}
|
|
816
622
|
texParameterf(target, pname, param) {
|
|
817
|
-
this._glCheckError('texParameterf');
|
|
818
|
-
this._checkArgs('texParameterf', arguments);
|
|
819
623
|
this.native.texParameterf(target, pname, param);
|
|
820
624
|
}
|
|
821
625
|
texParameteri(target, pname, param) {
|
|
822
|
-
this._glCheckError('texParameteri');
|
|
823
|
-
this._checkArgs('texParameteri', arguments);
|
|
824
626
|
this.native.texParameteri(target, pname, param);
|
|
825
627
|
}
|
|
826
628
|
texSubImage2D(target, level, xoffset, yoffset, width, height, format, type, pixels) {
|
|
827
|
-
this._glCheckError('texSubImage2D');
|
|
828
|
-
this._checkArgs('texSubImage2D', arguments);
|
|
829
629
|
if (arguments.length === 9) {
|
|
830
630
|
this.native.texSubImage2D(target, level, xoffset, yoffset, width, height, format, type, pixels);
|
|
831
631
|
}
|
|
@@ -865,179 +665,117 @@ export class WebGLRenderingContext extends WebGLRenderingContextBase {
|
|
|
865
665
|
}
|
|
866
666
|
}
|
|
867
667
|
uniform1f(location, v0) {
|
|
868
|
-
this._glCheckError('uniform1f');
|
|
869
|
-
this._checkArgs('uniform1f', arguments);
|
|
870
668
|
const loc = location.native;
|
|
871
669
|
this.native.uniform1f(loc, v0);
|
|
872
670
|
}
|
|
873
671
|
uniform1iv(location, value) {
|
|
874
|
-
this._glCheckError('uniform1iv');
|
|
875
|
-
this._checkArgs('uniform1iv', arguments);
|
|
876
672
|
const loc = location.native;
|
|
877
673
|
this.native.uniform1iv(loc, value);
|
|
878
674
|
}
|
|
879
675
|
uniform1fv(location, value) {
|
|
880
|
-
this._glCheckError('uniform1fv');
|
|
881
|
-
this._checkArgs('uniform1fv', arguments);
|
|
882
676
|
const loc = location.native;
|
|
883
677
|
this.native.uniform1fv(loc, value);
|
|
884
678
|
}
|
|
885
679
|
uniform1i(location, v0) {
|
|
886
|
-
this._glCheckError('uniform1i');
|
|
887
|
-
this._checkArgs('uniform1i', arguments);
|
|
888
680
|
const loc = location.native;
|
|
889
681
|
this.native.uniform1i(loc, Number(v0));
|
|
890
682
|
}
|
|
891
683
|
uniform2f(location, v0, v1) {
|
|
892
|
-
this._glCheckError('uniform2f');
|
|
893
|
-
this._checkArgs('uniform2f', arguments);
|
|
894
684
|
const loc = location.native;
|
|
895
685
|
this.native.uniform2f(loc, v0, v1);
|
|
896
686
|
}
|
|
897
687
|
uniform2iv(location, value) {
|
|
898
|
-
this._glCheckError('uniform2iv');
|
|
899
|
-
this._checkArgs('uniform2iv', arguments);
|
|
900
688
|
const loc = location.native;
|
|
901
689
|
this.native.uniform2iv(loc, value);
|
|
902
690
|
}
|
|
903
691
|
uniform2fv(location, value) {
|
|
904
|
-
this._glCheckError('uniform2fv');
|
|
905
|
-
this._checkArgs('uniform2fv', arguments);
|
|
906
692
|
const loc = location.native;
|
|
907
693
|
this.native.uniform2fv(loc, value);
|
|
908
694
|
}
|
|
909
695
|
uniform2i(location, v0, v1) {
|
|
910
|
-
this._glCheckError('uniform2i');
|
|
911
|
-
this._checkArgs('uniform2i', arguments);
|
|
912
696
|
const loc = location.native;
|
|
913
697
|
this.native.uniform2i(loc, v0, v1);
|
|
914
698
|
}
|
|
915
699
|
uniform3f(location, v0, v1, v2) {
|
|
916
|
-
this._glCheckError('uniform3f');
|
|
917
|
-
this._checkArgs('uniform3f', arguments);
|
|
918
700
|
const loc = location.native;
|
|
919
701
|
this.native.uniform3f(loc, v0, v1, v2);
|
|
920
702
|
}
|
|
921
703
|
uniform3iv(location, value) {
|
|
922
|
-
this._glCheckError('uniform3iv');
|
|
923
|
-
this._checkArgs('uniform3iv', arguments);
|
|
924
704
|
const loc = location.native;
|
|
925
705
|
this.native.uniform3iv(loc, value);
|
|
926
706
|
}
|
|
927
707
|
uniform3fv(location, value) {
|
|
928
|
-
this._glCheckError('uniform3fv');
|
|
929
|
-
this._checkArgs('uniform3fv', arguments);
|
|
930
708
|
const loc = location.native;
|
|
931
709
|
this.native.uniform3fv(loc, value);
|
|
932
710
|
}
|
|
933
711
|
uniform3i(location, v0, v1, v2) {
|
|
934
|
-
this._glCheckError('uniform3i');
|
|
935
|
-
this._checkArgs('uniform3i', arguments);
|
|
936
712
|
const loc = location.native;
|
|
937
713
|
this.native.uniform3i(loc, v0, v1, v2);
|
|
938
714
|
}
|
|
939
715
|
uniform4f(location, v0, v1, v2, v3) {
|
|
940
|
-
this._glCheckError('uniform4f');
|
|
941
|
-
this._checkArgs('uniform4f', arguments);
|
|
942
716
|
const loc = location.native;
|
|
943
717
|
this.native.uniform4f(loc, v0, v1, v2, v3);
|
|
944
718
|
}
|
|
945
719
|
uniform4iv(location, value) {
|
|
946
|
-
this._glCheckError('uniform4iv');
|
|
947
|
-
this._checkArgs('uniform4iv', arguments);
|
|
948
720
|
const loc = location.native;
|
|
949
721
|
this.native.uniform4iv(loc, value);
|
|
950
722
|
}
|
|
951
723
|
uniform4fv(location, value) {
|
|
952
|
-
this._glCheckError('uniform4fv');
|
|
953
|
-
this._checkArgs('uniform4fv', arguments);
|
|
954
724
|
const loc = location.native;
|
|
955
725
|
this.native.uniform4fv(loc, value);
|
|
956
726
|
}
|
|
957
727
|
uniform4i(location, v0, v1, v2, v3) {
|
|
958
|
-
this._glCheckError('uniform4i');
|
|
959
|
-
this._checkArgs('uniform4i', arguments);
|
|
960
728
|
const loc = location.native;
|
|
961
729
|
this.native.uniform4i(loc, v0, v1, v2, v3);
|
|
962
730
|
}
|
|
963
731
|
uniformMatrix2fv(location, transpose, value) {
|
|
964
|
-
this._glCheckError('uniformMatrix2fv');
|
|
965
|
-
this._checkArgs('uniformMatrix2fv', arguments);
|
|
966
732
|
const loc = location.native;
|
|
967
733
|
this.native.uniformMatrix2fv(loc, transpose, value);
|
|
968
734
|
}
|
|
969
735
|
uniformMatrix3fv(location, transpose, value) {
|
|
970
|
-
this._glCheckError('uniformMatrix3fv');
|
|
971
|
-
this._checkArgs('uniformMatrix3fv', arguments);
|
|
972
736
|
const loc = location.native;
|
|
973
737
|
this.native.uniformMatrix3fv(loc, transpose, value);
|
|
974
738
|
}
|
|
975
739
|
uniformMatrix4fv(location, transpose, value) {
|
|
976
|
-
this._glCheckError('uniformMatrix4fv');
|
|
977
|
-
this._checkArgs('uniformMatrix4fv', arguments);
|
|
978
740
|
const loc = location.native;
|
|
979
741
|
this.native.uniformMatrix4fv(loc, transpose, value);
|
|
980
742
|
}
|
|
981
743
|
useProgram(program) {
|
|
982
|
-
this._glCheckError('useProgram');
|
|
983
|
-
this._checkArgs('useProgram', arguments);
|
|
984
744
|
const value = program ? program.native : null;
|
|
985
745
|
this.native.useProgram(value);
|
|
986
746
|
}
|
|
987
747
|
validateProgram(program) {
|
|
988
|
-
this._glCheckError('validateProgram');
|
|
989
|
-
this._checkArgs('validateProgram', arguments);
|
|
990
748
|
const value = program.native;
|
|
991
749
|
this.native.validateProgram(value);
|
|
992
750
|
}
|
|
993
751
|
vertexAttrib1f(index, v0) {
|
|
994
|
-
this._glCheckError('vertexAttrib1f');
|
|
995
|
-
this._checkArgs('vertexAttrib1f', arguments);
|
|
996
752
|
this.native.vertexAttrib1f(index, v0);
|
|
997
753
|
}
|
|
998
754
|
vertexAttrib1fv(index, value) {
|
|
999
|
-
this._glCheckError('vertexAttrib1fv');
|
|
1000
|
-
this._checkArgs('vertexAttrib1fv', arguments);
|
|
1001
755
|
this.native.vertexAttrib1fv(index, value);
|
|
1002
756
|
}
|
|
1003
757
|
vertexAttrib2f(index, v0, v1) {
|
|
1004
|
-
this._glCheckError('vertexAttrib2f');
|
|
1005
|
-
this._checkArgs('vertexAttrib2f', arguments);
|
|
1006
758
|
this.native.vertexAttrib2f(index, v0, v1);
|
|
1007
759
|
}
|
|
1008
760
|
vertexAttrib2fv(index, value) {
|
|
1009
|
-
this._glCheckError('vertexAttrib2fv');
|
|
1010
|
-
this._checkArgs('vertexAttrib2fv', arguments);
|
|
1011
761
|
this.native.vertexAttrib2fv(index, value);
|
|
1012
762
|
}
|
|
1013
763
|
vertexAttrib3f(index, v0, v1, v2) {
|
|
1014
|
-
this._glCheckError('vertexAttrib3f');
|
|
1015
|
-
this._checkArgs('vertexAttrib3f', arguments);
|
|
1016
764
|
this.native.vertexAttrib3f(index, v0, v1, v2);
|
|
1017
765
|
}
|
|
1018
766
|
vertexAttrib3fv(index, value) {
|
|
1019
|
-
this._glCheckError('vertexAttrib3fv');
|
|
1020
|
-
this._checkArgs('vertexAttrib3fv', arguments);
|
|
1021
767
|
this.native.vertexAttrib3fv(index, value);
|
|
1022
768
|
}
|
|
1023
769
|
vertexAttrib4f(index, v0, v1, v2, v3) {
|
|
1024
|
-
this._glCheckError('vertexAttrib4f');
|
|
1025
|
-
this._checkArgs('vertexAttrib4f', arguments);
|
|
1026
770
|
this.native.vertexAttrib4f(index, v0, v1, v2, v3);
|
|
1027
771
|
}
|
|
1028
772
|
vertexAttrib4fv(index, value) {
|
|
1029
|
-
this._glCheckError('vertexAttrib4fv');
|
|
1030
|
-
this._checkArgs('vertexAttrib4fv', arguments);
|
|
1031
773
|
this.native.vertexAttrib4fv(index, value);
|
|
1032
774
|
}
|
|
1033
775
|
vertexAttribPointer(index, size, type, normalized, stride, offset) {
|
|
1034
|
-
this._glCheckError('vertexAttribPointer');
|
|
1035
|
-
this._checkArgs('vertexAttribPointer', arguments);
|
|
1036
776
|
this.native.vertexAttribPointer(index, size, type, !!normalized, stride, offset);
|
|
1037
777
|
}
|
|
1038
778
|
viewport(x, y, width, height) {
|
|
1039
|
-
this._glCheckError('viewport');
|
|
1040
|
-
this._checkArgs('viewport', arguments);
|
|
1041
779
|
this.native.viewport(x, y, width, height);
|
|
1042
780
|
}
|
|
1043
781
|
_glCheckError(message) {
|
|
@@ -1709,13 +1447,13 @@ __decorate([
|
|
|
1709
1447
|
__decorate([
|
|
1710
1448
|
profile,
|
|
1711
1449
|
__metadata("design:type", Function),
|
|
1712
|
-
__metadata("design:paramtypes", [WebGLUniformLocation,
|
|
1450
|
+
__metadata("design:paramtypes", [WebGLUniformLocation, Object]),
|
|
1713
1451
|
__metadata("design:returntype", void 0)
|
|
1714
1452
|
], WebGLRenderingContext.prototype, "uniform1iv", null);
|
|
1715
1453
|
__decorate([
|
|
1716
1454
|
profile,
|
|
1717
1455
|
__metadata("design:type", Function),
|
|
1718
|
-
__metadata("design:paramtypes", [WebGLUniformLocation,
|
|
1456
|
+
__metadata("design:paramtypes", [WebGLUniformLocation, Object]),
|
|
1719
1457
|
__metadata("design:returntype", void 0)
|
|
1720
1458
|
], WebGLRenderingContext.prototype, "uniform1fv", null);
|
|
1721
1459
|
__decorate([
|
|
@@ -1733,13 +1471,13 @@ __decorate([
|
|
|
1733
1471
|
__decorate([
|
|
1734
1472
|
profile,
|
|
1735
1473
|
__metadata("design:type", Function),
|
|
1736
|
-
__metadata("design:paramtypes", [WebGLUniformLocation,
|
|
1474
|
+
__metadata("design:paramtypes", [WebGLUniformLocation, Object]),
|
|
1737
1475
|
__metadata("design:returntype", void 0)
|
|
1738
1476
|
], WebGLRenderingContext.prototype, "uniform2iv", null);
|
|
1739
1477
|
__decorate([
|
|
1740
1478
|
profile,
|
|
1741
1479
|
__metadata("design:type", Function),
|
|
1742
|
-
__metadata("design:paramtypes", [WebGLUniformLocation,
|
|
1480
|
+
__metadata("design:paramtypes", [WebGLUniformLocation, Object]),
|
|
1743
1481
|
__metadata("design:returntype", void 0)
|
|
1744
1482
|
], WebGLRenderingContext.prototype, "uniform2fv", null);
|
|
1745
1483
|
__decorate([
|
|
@@ -1757,13 +1495,13 @@ __decorate([
|
|
|
1757
1495
|
__decorate([
|
|
1758
1496
|
profile,
|
|
1759
1497
|
__metadata("design:type", Function),
|
|
1760
|
-
__metadata("design:paramtypes", [WebGLUniformLocation,
|
|
1498
|
+
__metadata("design:paramtypes", [WebGLUniformLocation, Object]),
|
|
1761
1499
|
__metadata("design:returntype", void 0)
|
|
1762
1500
|
], WebGLRenderingContext.prototype, "uniform3iv", null);
|
|
1763
1501
|
__decorate([
|
|
1764
1502
|
profile,
|
|
1765
1503
|
__metadata("design:type", Function),
|
|
1766
|
-
__metadata("design:paramtypes", [WebGLUniformLocation,
|
|
1504
|
+
__metadata("design:paramtypes", [WebGLUniformLocation, Object]),
|
|
1767
1505
|
__metadata("design:returntype", void 0)
|
|
1768
1506
|
], WebGLRenderingContext.prototype, "uniform3fv", null);
|
|
1769
1507
|
__decorate([
|
|
@@ -1781,13 +1519,13 @@ __decorate([
|
|
|
1781
1519
|
__decorate([
|
|
1782
1520
|
profile,
|
|
1783
1521
|
__metadata("design:type", Function),
|
|
1784
|
-
__metadata("design:paramtypes", [WebGLUniformLocation,
|
|
1522
|
+
__metadata("design:paramtypes", [WebGLUniformLocation, Object]),
|
|
1785
1523
|
__metadata("design:returntype", void 0)
|
|
1786
1524
|
], WebGLRenderingContext.prototype, "uniform4iv", null);
|
|
1787
1525
|
__decorate([
|
|
1788
1526
|
profile,
|
|
1789
1527
|
__metadata("design:type", Function),
|
|
1790
|
-
__metadata("design:paramtypes", [WebGLUniformLocation,
|
|
1528
|
+
__metadata("design:paramtypes", [WebGLUniformLocation, Object]),
|
|
1791
1529
|
__metadata("design:returntype", void 0)
|
|
1792
1530
|
], WebGLRenderingContext.prototype, "uniform4fv", null);
|
|
1793
1531
|
__decorate([
|
|
@@ -1799,19 +1537,19 @@ __decorate([
|
|
|
1799
1537
|
__decorate([
|
|
1800
1538
|
profile,
|
|
1801
1539
|
__metadata("design:type", Function),
|
|
1802
|
-
__metadata("design:paramtypes", [WebGLUniformLocation, Boolean,
|
|
1540
|
+
__metadata("design:paramtypes", [WebGLUniformLocation, Boolean, Object]),
|
|
1803
1541
|
__metadata("design:returntype", void 0)
|
|
1804
1542
|
], WebGLRenderingContext.prototype, "uniformMatrix2fv", null);
|
|
1805
1543
|
__decorate([
|
|
1806
1544
|
profile,
|
|
1807
1545
|
__metadata("design:type", Function),
|
|
1808
|
-
__metadata("design:paramtypes", [WebGLUniformLocation, Boolean,
|
|
1546
|
+
__metadata("design:paramtypes", [WebGLUniformLocation, Boolean, Object]),
|
|
1809
1547
|
__metadata("design:returntype", void 0)
|
|
1810
1548
|
], WebGLRenderingContext.prototype, "uniformMatrix3fv", null);
|
|
1811
1549
|
__decorate([
|
|
1812
1550
|
profile,
|
|
1813
1551
|
__metadata("design:type", Function),
|
|
1814
|
-
__metadata("design:paramtypes", [WebGLUniformLocation, Boolean,
|
|
1552
|
+
__metadata("design:paramtypes", [WebGLUniformLocation, Boolean, Object]),
|
|
1815
1553
|
__metadata("design:returntype", void 0)
|
|
1816
1554
|
], WebGLRenderingContext.prototype, "uniformMatrix4fv", null);
|
|
1817
1555
|
__decorate([
|
|
@@ -1835,7 +1573,7 @@ __decorate([
|
|
|
1835
1573
|
__decorate([
|
|
1836
1574
|
profile,
|
|
1837
1575
|
__metadata("design:type", Function),
|
|
1838
|
-
__metadata("design:paramtypes", [Number,
|
|
1576
|
+
__metadata("design:paramtypes", [Number, Object]),
|
|
1839
1577
|
__metadata("design:returntype", void 0)
|
|
1840
1578
|
], WebGLRenderingContext.prototype, "vertexAttrib1fv", null);
|
|
1841
1579
|
__decorate([
|
|
@@ -1847,7 +1585,7 @@ __decorate([
|
|
|
1847
1585
|
__decorate([
|
|
1848
1586
|
profile,
|
|
1849
1587
|
__metadata("design:type", Function),
|
|
1850
|
-
__metadata("design:paramtypes", [Number,
|
|
1588
|
+
__metadata("design:paramtypes", [Number, Object]),
|
|
1851
1589
|
__metadata("design:returntype", void 0)
|
|
1852
1590
|
], WebGLRenderingContext.prototype, "vertexAttrib2fv", null);
|
|
1853
1591
|
__decorate([
|
|
@@ -1859,7 +1597,7 @@ __decorate([
|
|
|
1859
1597
|
__decorate([
|
|
1860
1598
|
profile,
|
|
1861
1599
|
__metadata("design:type", Function),
|
|
1862
|
-
__metadata("design:paramtypes", [Number,
|
|
1600
|
+
__metadata("design:paramtypes", [Number, Object]),
|
|
1863
1601
|
__metadata("design:returntype", void 0)
|
|
1864
1602
|
], WebGLRenderingContext.prototype, "vertexAttrib3fv", null);
|
|
1865
1603
|
__decorate([
|
|
@@ -1871,7 +1609,7 @@ __decorate([
|
|
|
1871
1609
|
__decorate([
|
|
1872
1610
|
profile,
|
|
1873
1611
|
__metadata("design:type", Function),
|
|
1874
|
-
__metadata("design:paramtypes", [Number,
|
|
1612
|
+
__metadata("design:paramtypes", [Number, Object]),
|
|
1875
1613
|
__metadata("design:returntype", void 0)
|
|
1876
1614
|
], WebGLRenderingContext.prototype, "vertexAttrib4fv", null);
|
|
1877
1615
|
__decorate([
|