View Javadoc
1   /*
2    * Copyright (c) 2002-2025 Gargoyle Software Inc.
3    *
4    * Licensed under the Apache License, Version 2.0 (the "License");
5    * you may not use this file except in compliance with the License.
6    * You may obtain a copy of the License at
7    * https://www.apache.org/licenses/LICENSE-2.0
8    *
9    * Unless required by applicable law or agreed to in writing, software
10   * distributed under the License is distributed on an "AS IS" BASIS,
11   * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
12   * See the License for the specific language governing permissions and
13   * limitations under the License.
14   */
15  package org.htmlunit.javascript.host.canvas;
16  
17  import static org.htmlunit.javascript.configuration.SupportedBrowser.CHROME;
18  import static org.htmlunit.javascript.configuration.SupportedBrowser.EDGE;
19  
20  import org.htmlunit.javascript.HtmlUnitScriptable;
21  import org.htmlunit.javascript.JavaScriptEngine;
22  import org.htmlunit.javascript.configuration.JsxClass;
23  import org.htmlunit.javascript.configuration.JsxConstant;
24  import org.htmlunit.javascript.configuration.JsxConstructor;
25  
26  /**
27   * A JavaScript object for {@code WebGLRenderingContext}.
28   *
29   * @author Ahmed Ashour
30   * @author Ronald Brill
31   */
32  @JsxClass
33  public class WebGLRenderingContext extends HtmlUnitScriptable {
34  
35      /** The constant {@code DEPTH_BUFFER_BIT}. */
36      @JsxConstant
37      public static final int DEPTH_BUFFER_BIT = 0x0100;
38      /** The constant {@code STENCIL_BUFFER_BIT}. */
39      @JsxConstant
40      public static final int STENCIL_BUFFER_BIT = 0x0400;
41      /** The constant {@code COLOR_BUFFER_BIT}. */
42      @JsxConstant
43      public static final int COLOR_BUFFER_BIT = 0x4000;
44  
45      /** The constant {@code POINTS}. */
46      @JsxConstant
47      public static final int POINTS = 0x0;
48      /** The constant {@code LINES}. */
49      @JsxConstant
50      public static final int LINES = 0x0001;
51      /** The constant {@code LINE_LOOP}. */
52      @JsxConstant
53      public static final int LINE_LOOP = 0x0002;
54      /** The constant {@code LINE_STRIP}. */
55      @JsxConstant
56      public static final int LINE_STRIP = 0x0003;
57      /** The constant {@code TRIANGLES}. */
58      @JsxConstant
59      public static final int TRIANGLES = 0x0004;
60      /** The constant {@code TRIANGLE_STRIP}. */
61      @JsxConstant
62      public static final int TRIANGLE_STRIP = 0x0005;
63      /** The constant {@code TRIANGLE_FAN}. */
64      @JsxConstant
65      public static final int TRIANGLE_FAN = 0x0006;
66  
67      /** The constant {@code ZERO}. */
68      @JsxConstant
69      public static final int ZERO = 0x0;
70      /** The constant {@code ONE}. */
71      @JsxConstant
72      public static final int ONE = 0x0001;
73      /** The constant {@code SRC_COLOR}. */
74      @JsxConstant
75      public static final int SRC_COLOR = 0x0300;
76      /** The constant {@code ONE_MINUS_SRC_COLOR}. */
77      @JsxConstant
78      public static final int ONE_MINUS_SRC_COLOR = 0x0301;
79      /** The constant {@code SRC_ALPHA}. */
80      @JsxConstant
81      public static final int SRC_ALPHA = 0x0302;
82      /** The constant {@code ONE_MINUS_SRC_ALPHA}. */
83      @JsxConstant
84      public static final int ONE_MINUS_SRC_ALPHA = 0x0303;
85      /** The constant {@code DST_ALPHA}. */
86      @JsxConstant
87      public static final int DST_ALPHA = 0x0304;
88      /** The constant {@code ONE_MINUS_DST_ALPHA}. */
89      @JsxConstant
90      public static final int ONE_MINUS_DST_ALPHA = 0x0305;
91      /** The constant {@code DST_COLOR}. */
92      @JsxConstant
93      public static final int DST_COLOR = 0x0306;
94      /** The constant {@code ONE_MINUS_DST_COLOR}. */
95      @JsxConstant
96      public static final int ONE_MINUS_DST_COLOR = 0x0307;
97      /** The constant {@code SRC_ALPHA_SATURATE}. */
98      @JsxConstant
99      public static final int SRC_ALPHA_SATURATE = 0x0308;
100     /** The constant {@code CONSTANT_COLOR}. */
101     @JsxConstant
102     public static final int CONSTANT_COLOR = 0x8001;
103     /** The constant {@code ONE_MINUS_CONSTANT_COLOR}. */
104     @JsxConstant
105     public static final int ONE_MINUS_CONSTANT_COLOR = 0x8002;
106     /** The constant {@code CONSTANT_ALPHA}. */
107     @JsxConstant
108     public static final int CONSTANT_ALPHA = 0x8003;
109     /** The constant {@code ONE_MINUS_CONSTANT_ALPHA}. */
110     @JsxConstant
111     public static final int ONE_MINUS_CONSTANT_ALPHA = 0x8004;
112 
113     /** The constant {@code FUNC_ADD}. */
114     @JsxConstant
115     public static final int FUNC_ADD = 0x8006;
116     /** The constant {@code FUNC_REVERSE_SUBTRACT}. */
117     @JsxConstant
118     public static final int FUNC_REVERSE_SUBTRACT = 0x800B;
119 
120     /** The constant {@code BLEND_EQUATION}. */
121     @JsxConstant
122     public static final int BLEND_EQUATION = 0x8009;
123     /** The constant {@code BLEND_EQUATION_RGB}. */
124     @JsxConstant
125     public static final int BLEND_EQUATION_RGB = 0x8009;
126     /** The constant {@code BLEND_EQUATION_ALPHA}. */
127     @JsxConstant
128     public static final int BLEND_EQUATION_ALPHA = 0x883D;
129     /** The constant {@code BLEND_DST_RGB}. */
130     @JsxConstant
131     public static final int BLEND_DST_RGB = 0x80C8;
132 
133     /** The constant {@code NO_ERROR}. */
134     @JsxConstant
135     public static final int NO_ERROR = 0x0;
136     /** The constant {@code NONE}. */
137     @JsxConstant
138     public static final int NONE = 0x0;
139     /** The constant {@code NEVER}. */
140     @JsxConstant
141     public static final int NEVER = 0x0200;
142     /** The constant {@code LESS}. */
143     @JsxConstant
144     public static final int LESS = 0x0201;
145     /** The constant {@code EQUAL}. */
146     @JsxConstant
147     public static final int EQUAL = 0x0202;
148     /** The constant {@code LEQUAL}. */
149     @JsxConstant
150     public static final int LEQUAL = 0x0203;
151     /** The constant {@code GREATER}. */
152     @JsxConstant
153     public static final int GREATER = 0x0204;
154     /** The constant {@code NOTEQUAL}. */
155     @JsxConstant
156     public static final int NOTEQUAL = 0x0205;
157     /** The constant {@code GEQUAL}. */
158     @JsxConstant
159     public static final int GEQUAL = 0x0206;
160     /** The constant {@code ALWAYS}. */
161     @JsxConstant
162     public static final int ALWAYS = 0x0207;
163     /** The constant {@code FRONT}. */
164     @JsxConstant
165     public static final int FRONT = 0x0404;
166     /** The constant {@code BACK}. */
167     @JsxConstant
168     public static final int BACK = 0x0405;
169     /** The constant {@code FRONT_AND_BACK}. */
170     @JsxConstant
171     public static final int FRONT_AND_BACK = 0x0408;
172     /** The constant {@code INVALID_ENUM}. */
173     @JsxConstant
174     public static final int INVALID_ENUM = 0x0500;
175     /** The constant {@code INVALID_VALUE}. */
176     @JsxConstant
177     public static final int INVALID_VALUE = 0x0501;
178     /** The constant {@code INVALID_OPERATION}. */
179     @JsxConstant
180     public static final int INVALID_OPERATION = 0x0502;
181     /** The constant {@code OUT_OF_MEMORY}. */
182     @JsxConstant
183     public static final int OUT_OF_MEMORY = 0x0505;
184     /** The constant {@code INVALID_FRAMEBUFFER_OPERATION}. */
185     @JsxConstant
186     public static final int INVALID_FRAMEBUFFER_OPERATION = 0x0506;
187     /** The constant {@code CW}. */
188     @JsxConstant
189     public static final int CW = 0x0900;
190     /** The constant {@code CCW}. */
191     @JsxConstant
192     public static final int CCW = 0x0901;
193     /** The constant {@code LINE_WIDTH}. */
194     @JsxConstant
195     public static final int LINE_WIDTH = 0x0B21;
196     /** The constant {@code CULL_FACE}. */
197     @JsxConstant
198     public static final int CULL_FACE = 0x0B44;
199     /** The constant {@code CULL_FACE_MODE}. */
200     @JsxConstant
201     public static final int CULL_FACE_MODE = 0x0B45;
202     /** The constant {@code FRONT_FACE}. */
203     @JsxConstant
204     public static final int FRONT_FACE = 0x0B46;
205     /** The constant {@code DEPTH_RANGE}. */
206     @JsxConstant
207     public static final int DEPTH_RANGE = 0x0B70;
208     /** The constant {@code DEPTH_TEST}. */
209     @JsxConstant
210     public static final int DEPTH_TEST = 0x0B71;
211     /** The constant {@code DEPTH_WRITEMASK}. */
212     @JsxConstant
213     public static final int DEPTH_WRITEMASK = 0x0B72;
214     /** The constant {@code DEPTH_CLEAR_VALUE}. */
215     @JsxConstant
216     public static final int DEPTH_CLEAR_VALUE = 0x0B73;
217     /** The constant {@code DEPTH_FUNC}. */
218     @JsxConstant
219     public static final int DEPTH_FUNC = 0x0B74;
220     /** The constant {@code STENCIL_TEST}. */
221     @JsxConstant
222     public static final int STENCIL_TEST = 0x0B90;
223     /** The constant {@code STENCIL_CLEAR_VALUE}. */
224     @JsxConstant
225     public static final int STENCIL_CLEAR_VALUE = 0x0B91;
226     /** The constant {@code STENCIL_FUNC}. */
227     @JsxConstant
228     public static final int STENCIL_FUNC = 0x0B92;
229     /** The constant {@code STENCIL_VALUE_MASK}. */
230     @JsxConstant
231     public static final int STENCIL_VALUE_MASK = 0x0B93;
232     /** The constant {@code STENCIL_FAIL}. */
233     @JsxConstant
234     public static final int STENCIL_FAIL = 0x0B94;
235     /** The constant {@code STENCIL_PASS_DEPTH_FAIL}. */
236     @JsxConstant
237     public static final int STENCIL_PASS_DEPTH_FAIL = 0x0B95;
238     /** The constant {@code STENCIL_PASS_DEPTH_PASS}. */
239     @JsxConstant
240     public static final int STENCIL_PASS_DEPTH_PASS = 0x0B96;
241     /** The constant {@code STENCIL_REF}. */
242     @JsxConstant
243     public static final int STENCIL_REF = 0x0B97;
244     /** The constant {@code STENCIL_WRITEMASK}. */
245     @JsxConstant
246     public static final int STENCIL_WRITEMASK = 0x0B98;
247     /** The constant {@code VIEWPORT}. */
248     @JsxConstant
249     public static final int VIEWPORT = 0x0BA2;
250     /** The constant {@code DITHER}. */
251     @JsxConstant
252     public static final int DITHER = 0x0BD0;
253     /** The constant {@code BLEND}. */
254     @JsxConstant
255     public static final int BLEND = 0x0BE2;
256     /** The constant {@code SCISSOR_BOX}. */
257     @JsxConstant
258     public static final int SCISSOR_BOX = 0x0C10;
259     /** The constant {@code SCISSOR_TEST}. */
260     @JsxConstant
261     public static final int SCISSOR_TEST = 0x0C11;
262     /** The constant {@code COLOR_CLEAR_VALUE}. */
263     @JsxConstant
264     public static final int COLOR_CLEAR_VALUE = 0x0C22;
265     /** The constant {@code COLOR_WRITEMASK}. */
266     @JsxConstant
267     public static final int COLOR_WRITEMASK = 0x0C23;
268     /** The constant {@code UNPACK_ALIGNMENT}. */
269     @JsxConstant
270     public static final int UNPACK_ALIGNMENT = 0x0Cf5;
271     /** The constant {@code PACK_ALIGNMENT}. */
272     @JsxConstant
273     public static final int PACK_ALIGNMENT = 0x0D05;
274     /** The constant {@code MAX_TEXTURE_SIZE}. */
275     @JsxConstant
276     public static final int MAX_TEXTURE_SIZE = 0x0D33;
277     /** The constant {@code MAX_VIEWPORT_DIMS}. */
278     @JsxConstant
279     public static final int MAX_VIEWPORT_DIMS = 0x0D3A;
280     /** The constant {@code SUBPIXEL_BITS}. */
281     @JsxConstant
282     public static final int SUBPIXEL_BITS = 0x0D50;
283     /** The constant {@code RED_BITS}. */
284     @JsxConstant
285     public static final int RED_BITS = 0x0D52;
286     /** The constant {@code GREEN_BITS}. */
287     @JsxConstant
288     public static final int GREEN_BITS = 0x0D53;
289     /** The constant {@code BLUE_BITS}. */
290     @JsxConstant
291     public static final int BLUE_BITS = 0x0D54;
292     /** The constant {@code ALPHA_BITS}. */
293     @JsxConstant
294     public static final int ALPHA_BITS = 0x0D55;
295     /** The constant {@code DEPTH_BITS}. */
296     @JsxConstant
297     public static final int DEPTH_BITS = 0x0D56;
298     /** The constant {@code STENCIL_BITS}. */
299     @JsxConstant
300     public static final int STENCIL_BITS = 0x0D57;
301     /** The constant {@code TEXTURE_2D}. */
302     @JsxConstant
303     public static final int TEXTURE_2D = 0x0DE1;
304     /** The constant {@code DONT_CARE}. */
305     @JsxConstant
306     public static final int DONT_CARE = 0x1100;
307     /** The constant {@code FASTEST}. */
308     @JsxConstant
309     public static final int FASTEST = 0x1101;
310     /** The constant {@code NICEST}. */
311     @JsxConstant
312     public static final int NICEST = 0x1102;
313     /** The constant {@code BYTE}. */
314     @JsxConstant
315     public static final int BYTE = 0x1400;
316     /** The constant {@code UNSIGNED_BYTE}. */
317     @JsxConstant
318     public static final int UNSIGNED_BYTE = 0x1401;
319     /** The constant {@code SHORT}. */
320     @JsxConstant
321     public static final int SHORT = 0x1402;
322     /** The constant {@code UNSIGNED_SHORT}. */
323     @JsxConstant
324     public static final int UNSIGNED_SHORT = 0x1403;
325     /** The constant {@code INT}. */
326     @JsxConstant
327     public static final int INT = 0x1404;
328     /** The constant {@code UNSIGNED_INT}. */
329     @JsxConstant
330     public static final int UNSIGNED_INT = 0x1405;
331     /** The constant {@code FLOAT}. */
332     @JsxConstant
333     public static final int FLOAT = 0x1406;
334     /** The constant {@code INVERT}. */
335     @JsxConstant
336     public static final int INVERT = 0x150A;
337     /** The constant {@code TEXTURE}. */
338     @JsxConstant
339     public static final int TEXTURE = 0x1702;
340     /** The constant {@code DEPTH_COMPONENT}. */
341     @JsxConstant
342     public static final int DEPTH_COMPONENT = 0x1902;
343     /** The constant {@code ALPHA}. */
344     @JsxConstant
345     public static final int ALPHA = 0x1906;
346     /** The constant {@code RGB}. */
347     @JsxConstant
348     public static final int RGB = 0x1907;
349     /** The constant {@code RGBA}. */
350     @JsxConstant
351     public static final int RGBA = 0x1908;
352     /** The constant {@code LUMINANCE}. */
353     @JsxConstant
354     public static final int LUMINANCE = 0x1909;
355     /** The constant {@code LUMINANCE_ALPHA}. */
356     @JsxConstant
357     public static final int LUMINANCE_ALPHA = 0x190A;
358     /** The constant {@code KEEP}. */
359     @JsxConstant
360     public static final int KEEP = 0x1E00;
361     /** The constant {@code REPLACE}. */
362     @JsxConstant
363     public static final int REPLACE = 0x1E01;
364     /** The constant {@code INCR}. */
365     @JsxConstant
366     public static final int INCR = 0x1E02;
367     /** The constant {@code DECR}. */
368     @JsxConstant
369     public static final int DECR = 0x1E03;
370     /** The constant {@code VENDOR}. */
371     @JsxConstant
372     public static final int VENDOR = 0x1F00;
373     /** The constant {@code RENDERER}. */
374     @JsxConstant
375     public static final int RENDERER = 0x1F01;
376     /** The constant {@code VERSION}. */
377     @JsxConstant
378     public static final int VERSION = 0x1F02;
379     /** The constant {@code NEAREST}. */
380     @JsxConstant
381     public static final int NEAREST = 0x2600;
382     /** The constant {@code LINEAR}. */
383     @JsxConstant
384     public static final int LINEAR = 0x2601;
385     /** The constant {@code NEAREST_MIPMAP_NEAREST}. */
386     @JsxConstant
387     public static final int NEAREST_MIPMAP_NEAREST = 0x2700;
388     /** The constant {@code LINEAR_MIPMAP_NEAREST}. */
389     @JsxConstant
390     public static final int LINEAR_MIPMAP_NEAREST = 0x2701;
391     /** The constant {@code NEAREST_MIPMAP_LINEAR}. */
392     @JsxConstant
393     public static final int NEAREST_MIPMAP_LINEAR = 0x2702;
394     /** The constant {@code LINEAR_MIPMAP_LINEAR}. */
395     @JsxConstant
396     public static final int LINEAR_MIPMAP_LINEAR = 0x2703;
397     /** The constant {@code TEXTURE_MAG_FILTER}. */
398     @JsxConstant
399     public static final int TEXTURE_MAG_FILTER = 0x2800;
400     /** The constant {@code TEXTURE_MIN_FILTER}. */
401     @JsxConstant
402     public static final int TEXTURE_MIN_FILTER = 0x2801;
403     /** The constant {@code TEXTURE_WRAP_S}. */
404     @JsxConstant
405     public static final int TEXTURE_WRAP_S = 0x2802;
406     /** The constant {@code TEXTURE_WRAP_T}. */
407     @JsxConstant
408     public static final int TEXTURE_WRAP_T = 0x2803;
409     /** The constant {@code REPEAT}. */
410     @JsxConstant
411     public static final int REPEAT = 0x2901;
412     /** The constant {@code POLYGON_OFFSET_UNITS}. */
413     @JsxConstant
414     public static final int POLYGON_OFFSET_UNITS = 0x2A00;
415     /** The constant {@code BLEND_COLOR}. */
416     @JsxConstant
417     public static final int BLEND_COLOR = 0x8005;
418     /** The constant {@code FUNC_SUBTRACT}. */
419     @JsxConstant
420     public static final int FUNC_SUBTRACT = 0x800A;
421     /** The constant {@code UNSIGNED_SHORT_4_4_4_4}. */
422     @JsxConstant
423     public static final int UNSIGNED_SHORT_4_4_4_4 = 0x8033;
424     /** The constant {@code UNSIGNED_SHORT_5_5_5_1}. */
425     @JsxConstant
426     public static final int UNSIGNED_SHORT_5_5_5_1 = 0x8034;
427     /** The constant {@code POLYGON_OFFSET_FILL}. */
428     @JsxConstant
429     public static final int POLYGON_OFFSET_FILL = 0x8037;
430     /** The constant {@code POLYGON_OFFSET_FACTOR}. */
431     @JsxConstant
432     public static final int POLYGON_OFFSET_FACTOR = 0x8038;
433     /** The constant {@code RGBA4}. */
434     @JsxConstant
435     public static final int RGBA4 = 0x8056;
436     /** The constant {@code RGB8}. */
437     @JsxConstant({CHROME, EDGE})
438     public static final int RGB8 = 0x8051;
439     /** The constant {@code RGB5_A1}. */
440     @JsxConstant
441     public static final int RGB5_A1 = 0x8057;
442     /** The constant {@code RGBA8}. */
443     @JsxConstant({CHROME, EDGE})
444     public static final int RGBA8 = 0x8058;
445     /** The constant {@code TEXTURE_BINDING_2D}. */
446     @JsxConstant
447     public static final int TEXTURE_BINDING_2D = 0x8069;
448     /** The constant {@code SAMPLE_ALPHA_TO_COVERAGE}. */
449     @JsxConstant
450     public static final int SAMPLE_ALPHA_TO_COVERAGE = 0x809E;
451     /** The constant {@code SAMPLE_COVERAGE}. */
452     @JsxConstant
453     public static final int SAMPLE_COVERAGE = 0x80A0;
454     /** The constant {@code SAMPLE_BUFFERS}. */
455     @JsxConstant
456     public static final int SAMPLE_BUFFERS = 0x80A8;
457     /** The constant {@code SAMPLES}. */
458     @JsxConstant
459     public static final int SAMPLES = 0x80A9;
460     /** The constant {@code SAMPLE_COVERAGE_VALUE}. */
461     @JsxConstant
462     public static final int SAMPLE_COVERAGE_VALUE = 0x80AA;
463     /** The constant {@code SAMPLE_COVERAGE_INVERT}. */
464     @JsxConstant
465     public static final int SAMPLE_COVERAGE_INVERT = 0x80AB;
466     /** The constant {@code BLEND_SRC_RGB}. */
467     @JsxConstant
468     public static final int BLEND_SRC_RGB = 0x80C9;
469     /** The constant {@code BLEND_DST_ALPHA}. */
470     @JsxConstant
471     public static final int BLEND_DST_ALPHA = 0x80CA;
472     /** The constant {@code BLEND_SRC_ALPHA}. */
473     @JsxConstant
474     public static final int BLEND_SRC_ALPHA = 0x80CB;
475     /** The constant {@code CLAMP_TO_EDGE}. */
476     @JsxConstant
477     public static final int CLAMP_TO_EDGE = 0x812F;
478     /** The constant {@code GENERATE_MIPMAP_HINT}. */
479     @JsxConstant
480     public static final int GENERATE_MIPMAP_HINT = 0x8192;
481     /** The constant {@code DEPTH_COMPONENT16}. */
482     @JsxConstant
483     public static final int DEPTH_COMPONENT16 = 0x81A5;
484     /** The constant {@code DEPTH_STENCIL_ATTACHMENT}. */
485     @JsxConstant
486     public static final int DEPTH_STENCIL_ATTACHMENT = 0x821A;
487     /** The constant {@code UNSIGNED_SHORT_5_6_5}. */
488     @JsxConstant
489     public static final int UNSIGNED_SHORT_5_6_5 = 0x8363;
490     /** The constant {@code MIRRORED_REPEAT}. */
491     @JsxConstant
492     public static final int MIRRORED_REPEAT = 0x8370;
493     /** The constant {@code ALIASED_POINT_SIZE_RANGE}. */
494     @JsxConstant
495     public static final int ALIASED_POINT_SIZE_RANGE = 0x846D;
496     /** The constant {@code ALIASED_LINE_WIDTH_RANGE}. */
497     @JsxConstant
498     public static final int ALIASED_LINE_WIDTH_RANGE = 0x846E;
499     /** The constant {@code TEXTURE0}. */
500     @JsxConstant
501     public static final int TEXTURE0 = 0x84C0;
502     /** The constant {@code TEXTURE1}. */
503     @JsxConstant
504     public static final int TEXTURE1 = 0x84C1;
505     /** The constant {@code TEXTURE2}. */
506     @JsxConstant
507     public static final int TEXTURE2 = 0x84C2;
508     /** The constant {@code TEXTURE3}. */
509     @JsxConstant
510     public static final int TEXTURE3 = 0x84C3;
511     /** The constant {@code TEXTURE4}. */
512     @JsxConstant
513     public static final int TEXTURE4 = 0x84C4;
514     /** The constant {@code TEXTURE5}. */
515     @JsxConstant
516     public static final int TEXTURE5 = 0x84C5;
517     /** The constant {@code TEXTURE6}. */
518     @JsxConstant
519     public static final int TEXTURE6 = 0x84C6;
520     /** The constant {@code TEXTURE7}. */
521     @JsxConstant
522     public static final int TEXTURE7 = 0x84C7;
523     /** The constant {@code TEXTURE8}. */
524     @JsxConstant
525     public static final int TEXTURE8 = 0x84C8;
526     /** The constant {@code TEXTURE9}. */
527     @JsxConstant
528     public static final int TEXTURE9 = 0x84C9;
529     /** The constant {@code TEXTURE10}. */
530     @JsxConstant
531     public static final int TEXTURE10 = 0x84CA;
532     /** The constant {@code TEXTURE11}. */
533     @JsxConstant
534     public static final int TEXTURE11 = 0x84CB;
535     /** The constant {@code TEXTURE12}. */
536     @JsxConstant
537     public static final int TEXTURE12 = 0x84CC;
538     /** The constant {@code TEXTURE13}. */
539     @JsxConstant
540     public static final int TEXTURE13 = 0x84CD;
541     /** The constant {@code TEXTURE14}. */
542     @JsxConstant
543     public static final int TEXTURE14 = 0x84CE;
544     /** The constant {@code TEXTURE15}. */
545     @JsxConstant
546     public static final int TEXTURE15 = 0x84CF;
547     /** The constant {@code TEXTURE16}. */
548     @JsxConstant
549     public static final int TEXTURE16 = 0x84D0;
550     /** The constant {@code TEXTURE17}. */
551     @JsxConstant
552     public static final int TEXTURE17 = 0x84D1;
553     /** The constant {@code TEXTURE18}. */
554     @JsxConstant
555     public static final int TEXTURE18 = 0x84D2;
556     /** The constant {@code TEXTURE19}. */
557     @JsxConstant
558     public static final int TEXTURE19 = 0x84D3;
559     /** The constant {@code TEXTURE20}. */
560     @JsxConstant
561     public static final int TEXTURE20 = 0x84D4;
562     /** The constant {@code TEXTURE21}. */
563     @JsxConstant
564     public static final int TEXTURE21 = 0x84D5;
565     /** The constant {@code TEXTURE22}. */
566     @JsxConstant
567     public static final int TEXTURE22 = 0x84D6;
568     /** The constant {@code TEXTURE23}. */
569     @JsxConstant
570     public static final int TEXTURE23 = 0x84D7;
571     /** The constant {@code TEXTURE24}. */
572     @JsxConstant
573     public static final int TEXTURE24 = 0x84D8;
574     /** The constant {@code TEXTURE25}. */
575     @JsxConstant
576     public static final int TEXTURE25 = 0x84D9;
577     /** The constant {@code TEXTURE26}. */
578     @JsxConstant
579     public static final int TEXTURE26 = 0x84DA;
580     /** The constant {@code TEXTURE27}. */
581     @JsxConstant
582     public static final int TEXTURE27 = 0x84DB;
583     /** The constant {@code TEXTURE28}. */
584     @JsxConstant
585     public static final int TEXTURE28 = 0x84DC;
586     /** The constant {@code TEXTURE29}. */
587     @JsxConstant
588     public static final int TEXTURE29 = 0x84DD;
589     /** The constant {@code TEXTURE30}. */
590     @JsxConstant
591     public static final int TEXTURE30 = 0x84DE;
592     /** The constant {@code TEXTURE31}. */
593     @JsxConstant
594     public static final int TEXTURE31 = 0x84DF;
595     /** The constant {@code ACTIVE_TEXTURE}. */
596     @JsxConstant
597     public static final int ACTIVE_TEXTURE = 0x84E0;
598     /** The constant {@code MAX_RENDERBUFFER_SIZE}. */
599     @JsxConstant
600     public static final int MAX_RENDERBUFFER_SIZE = 0x84E8;
601     /** The constant {@code DEPTH_STENCIL}. */
602     @JsxConstant
603     public static final int DEPTH_STENCIL = 0x84F9;
604     /** The constant {@code INCR_WRAP}. */
605     @JsxConstant
606     public static final int INCR_WRAP = 0x8507;
607     /** The constant {@code DECR_WRAP}. */
608     @JsxConstant
609     public static final int DECR_WRAP = 0x8508;
610     /** The constant {@code TEXTURE_CUBE_MAP}. */
611     @JsxConstant
612     public static final int TEXTURE_CUBE_MAP = 0x8513;
613     /** The constant {@code TEXTURE_BINDING_CUBE_MAP}. */
614     @JsxConstant
615     public static final int TEXTURE_BINDING_CUBE_MAP = 0x8514;
616     /** The constant {@code TEXTURE_CUBE_MAP_POSITIVE_X}. */
617     @JsxConstant
618     public static final int TEXTURE_CUBE_MAP_POSITIVE_X = 0x8515;
619     /** The constant {@code TEXTURE_CUBE_MAP_NEGATIVE_X}. */
620     @JsxConstant
621     public static final int TEXTURE_CUBE_MAP_NEGATIVE_X = 0x8516;
622     /** The constant {@code TEXTURE_CUBE_MAP_POSITIVE_Y}. */
623     @JsxConstant
624     public static final int TEXTURE_CUBE_MAP_POSITIVE_Y = 0x8517;
625     /** The constant {@code TEXTURE_CUBE_MAP_NEGATIVE_Y}. */
626     @JsxConstant
627     public static final int TEXTURE_CUBE_MAP_NEGATIVE_Y = 0x8518;
628     /** The constant {@code TEXTURE_CUBE_MAP_POSITIVE_Z}. */
629     @JsxConstant
630     public static final int TEXTURE_CUBE_MAP_POSITIVE_Z = 0x8519;
631     /** The constant {@code TEXTURE_CUBE_MAP_NEGATIVE_Z}. */
632     @JsxConstant
633     public static final int TEXTURE_CUBE_MAP_NEGATIVE_Z = 0x851A;
634     /** The constant {@code MAX_CUBE_MAP_TEXTURE_SIZE}. */
635     @JsxConstant
636     public static final int MAX_CUBE_MAP_TEXTURE_SIZE = 0x851C;
637     /** The constant {@code VERTEX_ATTRIB_ARRAY_ENABLED}. */
638     @JsxConstant
639     public static final int VERTEX_ATTRIB_ARRAY_ENABLED = 0x8622;
640     /** The constant {@code VERTEX_ATTRIB_ARRAY_SIZE}. */
641     @JsxConstant
642     public static final int VERTEX_ATTRIB_ARRAY_SIZE = 0x8623;
643     /** The constant {@code VERTEX_ATTRIB_ARRAY_STRIDE}. */
644     @JsxConstant
645     public static final int VERTEX_ATTRIB_ARRAY_STRIDE = 0x8624;
646     /** The constant {@code VERTEX_ATTRIB_ARRAY_TYPE}. */
647     @JsxConstant
648     public static final int VERTEX_ATTRIB_ARRAY_TYPE = 0x8625;
649     /** The constant {@code CURRENT_VERTEX_ATTRIB}. */
650     @JsxConstant
651     public static final int CURRENT_VERTEX_ATTRIB = 0x8626;
652     /** The constant {@code VERTEX_ATTRIB_ARRAY_POINTER}. */
653     @JsxConstant
654     public static final int VERTEX_ATTRIB_ARRAY_POINTER = 0x8645;
655     /** The constant {@code COMPRESSED_TEXTURE_FORMATS}. */
656     @JsxConstant
657     public static final int COMPRESSED_TEXTURE_FORMATS = 0x86A3;
658     /** The constant {@code BUFFER_SIZE}. */
659     @JsxConstant
660     public static final int BUFFER_SIZE = 0x8764;
661     /** The constant {@code BUFFER_USAGE}. */
662     @JsxConstant
663     public static final int BUFFER_USAGE = 0x8765;
664     /** The constant {@code STENCIL_BACK_FUNC}. */
665     @JsxConstant
666     public static final int STENCIL_BACK_FUNC = 0x8800;
667     /** The constant {@code STENCIL_BACK_FAIL}. */
668     @JsxConstant
669     public static final int STENCIL_BACK_FAIL = 0x8801;
670     /** The constant {@code STENCIL_BACK_PASS_DEPTH_FAIL}. */
671     @JsxConstant
672     public static final int STENCIL_BACK_PASS_DEPTH_FAIL = 0x8802;
673     /** The constant {@code STENCIL_BACK_PASS_DEPTH_PASS}. */
674     @JsxConstant
675     public static final int STENCIL_BACK_PASS_DEPTH_PASS = 0x8803;
676     /** The constant {@code MAX_VERTEX_ATTRIBS}. */
677     @JsxConstant
678     public static final int MAX_VERTEX_ATTRIBS = 0x8869;
679     /** The constant {@code VERTEX_ATTRIB_ARRAY_NORMALIZED}. */
680     @JsxConstant
681     public static final int VERTEX_ATTRIB_ARRAY_NORMALIZED = 0x886A;
682     /** The constant {@code MAX_TEXTURE_IMAGE_UNITS}. */
683     @JsxConstant
684     public static final int MAX_TEXTURE_IMAGE_UNITS = 0x8872;
685     /** The constant {@code ARRAY_BUFFER}. */
686     @JsxConstant
687     public static final int ARRAY_BUFFER = 0x8892;
688     /** The constant {@code ELEMENT_ARRAY_BUFFER}. */
689     @JsxConstant
690     public static final int ELEMENT_ARRAY_BUFFER = 0x8893;
691     /** The constant {@code ARRAY_BUFFER_BINDING}. */
692     @JsxConstant
693     public static final int ARRAY_BUFFER_BINDING = 0x8894;
694     /** The constant {@code ELEMENT_ARRAY_BUFFER_BINDING}. */
695     @JsxConstant
696     public static final int ELEMENT_ARRAY_BUFFER_BINDING = 0x8895;
697     /** The constant {@code VERTEX_ATTRIB_ARRAY_BUFFER_BINDING}. */
698     @JsxConstant
699     public static final int VERTEX_ATTRIB_ARRAY_BUFFER_BINDING = 0x889F;
700     /** The constant {@code STREAM_DRAW}. */
701     @JsxConstant
702     public static final int STREAM_DRAW = 0x88E0;
703     /** The constant {@code STATIC_DRAW}. */
704     @JsxConstant
705     public static final int STATIC_DRAW = 0x88E4;
706     /** The constant {@code DYNAMIC_DRAW}. */
707     @JsxConstant
708     public static final int DYNAMIC_DRAW = 0x88E8;
709     /** The constant {@code FRAGMENT_SHADER}. */
710     @JsxConstant
711     public static final int FRAGMENT_SHADER = 0x8B30;
712     /** The constant {@code VERTEX_SHADER}. */
713     @JsxConstant
714     public static final int VERTEX_SHADER = 0x8B31;
715     /** The constant {@code MAX_VERTEX_TEXTURE_IMAGE_UNITS}. */
716     @JsxConstant
717     public static final int MAX_VERTEX_TEXTURE_IMAGE_UNITS = 0x8B4C;
718     /** The constant {@code MAX_COMBINED_TEXTURE_IMAGE_UNITS}. */
719     @JsxConstant
720     public static final int MAX_COMBINED_TEXTURE_IMAGE_UNITS = 0x8B4D;
721     /** The constant {@code SHADER_TYPE}. */
722     @JsxConstant
723     public static final int SHADER_TYPE = 0x8B4F;
724     /** The constant {@code FLOAT_VEC2}. */
725     @JsxConstant
726     public static final int FLOAT_VEC2 = 0x8B50;
727     /** The constant {@code FLOAT_VEC3}. */
728     @JsxConstant
729     public static final int FLOAT_VEC3 = 0x8B51;
730     /** The constant {@code FLOAT_VEC4}. */
731     @JsxConstant
732     public static final int FLOAT_VEC4 = 0x8B52;
733     /** The constant {@code INT_VEC2}. */
734     @JsxConstant
735     public static final int INT_VEC2 = 0x8B53;
736     /** The constant {@code INT_VEC3}. */
737     @JsxConstant
738     public static final int INT_VEC3 = 0x8B54;
739     /** The constant {@code INT_VEC4}. */
740     @JsxConstant
741     public static final int INT_VEC4 = 0x8B55;
742     /** The constant {@code BOOL}. */
743     @JsxConstant
744     public static final int BOOL = 0x8B56;
745     /** The constant {@code BOOL_VEC2}. */
746     @JsxConstant
747     public static final int BOOL_VEC2 = 0x8B57;
748     /** The constant {@code BOOL_VEC3}. */
749     @JsxConstant
750     public static final int BOOL_VEC3 = 0x8B58;
751     /** The constant {@code BOOL_VEC4}. */
752     @JsxConstant
753     public static final int BOOL_VEC4 = 0x8B59;
754     /** The constant {@code FLOAT_MAT2}. */
755     @JsxConstant
756     public static final int FLOAT_MAT2 = 0x8B5A;
757     /** The constant {@code FLOAT_MAT3}. */
758     @JsxConstant
759     public static final int FLOAT_MAT3 = 0x8B5B;
760     /** The constant {@code FLOAT_MAT4}. */
761     @JsxConstant
762     public static final int FLOAT_MAT4 = 0x8B5C;
763     /** The constant {@code SAMPLER_2D}. */
764     @JsxConstant
765     public static final int SAMPLER_2D = 0x8B5E;
766     /** The constant {@code SAMPLER_CUBE}. */
767     @JsxConstant
768     public static final int SAMPLER_CUBE = 0x8B60;
769     /** The constant {@code DELETE_STATUS}. */
770     @JsxConstant
771     public static final int DELETE_STATUS = 0x8B80;
772     /** The constant {@code COMPILE_STATUS}. */
773     @JsxConstant
774     public static final int COMPILE_STATUS = 0x8B81;
775     /** The constant {@code LINK_STATUS}. */
776     @JsxConstant
777     public static final int LINK_STATUS = 0x8B82;
778     /** The constant {@code VALIDATE_STATUS}. */
779     @JsxConstant
780     public static final int VALIDATE_STATUS = 0x8B83;
781     /** The constant {@code ATTACHED_SHADERS}. */
782     @JsxConstant
783     public static final int ATTACHED_SHADERS = 0x8B85;
784     /** The constant {@code ACTIVE_UNIFORMS}. */
785     @JsxConstant
786     public static final int ACTIVE_UNIFORMS = 0x8B86;
787     /** The constant {@code ACTIVE_ATTRIBUTES}. */
788     @JsxConstant
789     public static final int ACTIVE_ATTRIBUTES = 0x8B89;
790     /** The constant {@code SHADING_LANGUAGE_VERSION}. */
791     @JsxConstant
792     public static final int SHADING_LANGUAGE_VERSION = 0x8B8C;
793     /** The constant {@code CURRENT_PROGRAM}. */
794     @JsxConstant
795     public static final int CURRENT_PROGRAM = 0x8B8D;
796     /** The constant {@code IMPLEMENTATION_COLOR_READ_TYPE}. */
797     @JsxConstant
798     public static final int IMPLEMENTATION_COLOR_READ_TYPE = 0x8B9A;
799     /** The constant {@code IMPLEMENTATION_COLOR_READ_FORMAT}. */
800     @JsxConstant
801     public static final int IMPLEMENTATION_COLOR_READ_FORMAT = 0x8B9B;
802     /** The constant {@code STENCIL_BACK_REF}. */
803     @JsxConstant
804     public static final int STENCIL_BACK_REF = 0x8CA3;
805     /** The constant {@code STENCIL_BACK_VALUE_MASK}. */
806     @JsxConstant
807     public static final int STENCIL_BACK_VALUE_MASK = 0x8CA4;
808     /** The constant {@code STENCIL_BACK_WRITEMASK}. */
809     @JsxConstant
810     public static final int STENCIL_BACK_WRITEMASK = 0x8CA5;
811     /** The constant {@code FRAMEBUFFER_BINDING}. */
812     @JsxConstant
813     public static final int FRAMEBUFFER_BINDING = 0x8CA6;
814     /** The constant {@code RENDERBUFFER_BINDING}. */
815     @JsxConstant
816     public static final int RENDERBUFFER_BINDING = 0x8CA7;
817     /** The constant {@code FRAMEBUFFER_ATTACHMENT_OBJECT_TYPE}. */
818     @JsxConstant
819     public static final int FRAMEBUFFER_ATTACHMENT_OBJECT_TYPE = 0x8CD0;
820     /** The constant {@code FRAMEBUFFER_ATTACHMENT_OBJECT_NAME}. */
821     @JsxConstant
822     public static final int FRAMEBUFFER_ATTACHMENT_OBJECT_NAME = 0x8CD1;
823     /** The constant {@code FRAMEBUFFER_ATTACHMENT_TEXTURE_LEVEL}. */
824     @JsxConstant
825     public static final int FRAMEBUFFER_ATTACHMENT_TEXTURE_LEVEL = 0x8CD2;
826     /** The constant {@code FRAMEBUFFER_ATTACHMENT_TEXTURE_CUBE_MAP_FACE}. */
827     @JsxConstant
828     public static final int FRAMEBUFFER_ATTACHMENT_TEXTURE_CUBE_MAP_FACE = 0x8CD3;
829     /** The constant {@code FRAMEBUFFER_COMPLETE}. */
830     @JsxConstant
831     public static final int FRAMEBUFFER_COMPLETE = 0x8CD5;
832     /** The constant {@code FRAMEBUFFER_INCOMPLETE_ATTACHMENT}. */
833     @JsxConstant
834     public static final int FRAMEBUFFER_INCOMPLETE_ATTACHMENT = 0x8CD6;
835     /** The constant {@code FRAMEBUFFER_INCOMPLETE_MISSING_ATTACHMENT}. */
836     @JsxConstant
837     public static final int FRAMEBUFFER_INCOMPLETE_MISSING_ATTACHMENT = 0x8CD7;
838     /** The constant {@code FRAMEBUFFER_INCOMPLETE_DIMENSIONS}. */
839     @JsxConstant
840     public static final int FRAMEBUFFER_INCOMPLETE_DIMENSIONS = 0x8CD9;
841     /** The constant {@code FRAMEBUFFER_UNSUPPORTED}. */
842     @JsxConstant
843     public static final int FRAMEBUFFER_UNSUPPORTED = 0x8CDD;
844     /** The constant {@code COLOR_ATTACHMENT0}. */
845     @JsxConstant
846     public static final int COLOR_ATTACHMENT0 = 0x8ce0;
847     /** The constant {@code DEPTH_ATTACHMENT}. */
848     @JsxConstant
849     public static final int DEPTH_ATTACHMENT = 0x8D00;
850     /** The constant {@code STENCIL_ATTACHMENT}. */
851     @JsxConstant
852     public static final int STENCIL_ATTACHMENT = 0x8D20;
853     /** The constant {@code FRAMEBUFFER}. */
854     @JsxConstant
855     public static final int FRAMEBUFFER = 0x8D40;
856     /** The constant {@code RENDERBUFFER}. */
857     @JsxConstant
858     public static final int RENDERBUFFER = 0x8D41;
859     /** The constant {@code RENDERBUFFER_WIDTH}. */
860     @JsxConstant
861     public static final int RENDERBUFFER_WIDTH = 0x8D42;
862     /** The constant {@code RENDERBUFFER_HEIGHT}. */
863     @JsxConstant
864     public static final int RENDERBUFFER_HEIGHT = 0x8D43;
865     /** The constant {@code RENDERBUFFER_INTERNAL_FORMAT}. */
866     @JsxConstant
867     public static final int RENDERBUFFER_INTERNAL_FORMAT = 0x8D44;
868     /** The constant {@code STENCIL_INDEX8}. */
869     @JsxConstant
870     public static final int STENCIL_INDEX8 = 0x8D48;
871     /** The constant {@code RENDERBUFFER_RED_SIZE}. */
872     @JsxConstant
873     public static final int RENDERBUFFER_RED_SIZE = 0x8D50;
874     /** The constant {@code RENDERBUFFER_GREEN_SIZE}. */
875     @JsxConstant
876     public static final int RENDERBUFFER_GREEN_SIZE = 0x8D51;
877     /** The constant {@code RENDERBUFFER_BLUE_SIZE}. */
878     @JsxConstant
879     public static final int RENDERBUFFER_BLUE_SIZE = 0x8D52;
880     /** The constant {@code RENDERBUFFER_ALPHA_SIZE}. */
881     @JsxConstant
882     public static final int RENDERBUFFER_ALPHA_SIZE = 0x8D53;
883     /** The constant {@code RENDERBUFFER_DEPTH_SIZE}. */
884     @JsxConstant
885     public static final int RENDERBUFFER_DEPTH_SIZE = 0x8D54;
886     /** The constant {@code RENDERBUFFER_STENCIL_SIZE}. */
887     @JsxConstant
888     public static final int RENDERBUFFER_STENCIL_SIZE = 0x8D55;
889     /** The constant {@code RGB565}. */
890     @JsxConstant
891     public static final int RGB565 = 0x8D62;
892     /** The constant {@code LOW_FLOAT}. */
893     @JsxConstant
894     public static final int LOW_FLOAT = 0x8DF0;
895     /** The constant {@code MEDIUM_FLOAT}. */
896     @JsxConstant
897     public static final int MEDIUM_FLOAT = 0x8DF1;
898     /** The constant {@code HIGH_FLOAT}. */
899     @JsxConstant
900     public static final int HIGH_FLOAT = 0x8DF2;
901     /** The constant {@code LOW_INT}. */
902     @JsxConstant
903     public static final int LOW_INT = 0x8DF3;
904     /** The constant {@code MEDIUM_INT}. */
905     @JsxConstant
906     public static final int MEDIUM_INT = 0x8DF4;
907     /** The constant {@code HIGH_INT}. */
908     @JsxConstant
909     public static final int HIGH_INT = 0x8DF5;
910     /** The constant {@code MAX_VERTEX_UNIFORM_VECTORS}. */
911     @JsxConstant
912     public static final int MAX_VERTEX_UNIFORM_VECTORS = 0x8DFB;
913     /** The constant {@code MAX_VARYING_VECTORS}. */
914     @JsxConstant
915     public static final int MAX_VARYING_VECTORS = 0x8DFC;
916     /** The constant {@code MAX_FRAGMENT_UNIFORM_VECTORS}. */
917     @JsxConstant
918     public static final int MAX_FRAGMENT_UNIFORM_VECTORS = 0x8DFD;
919     /** The constant {@code UNPACK_FLIP_Y_WEBGL}. */
920     @JsxConstant
921     public static final int UNPACK_FLIP_Y_WEBGL = 0x9240;
922     /** The constant {@code UNPACK_PREMULTIPLY_ALPHA_WEBGL}. */
923     @JsxConstant
924     public static final int UNPACK_PREMULTIPLY_ALPHA_WEBGL = 0x9241;
925     /** The constant {@code CONTEXT_LOST_WEBGL}. */
926     @JsxConstant
927     public static final int CONTEXT_LOST_WEBGL = 0x9242;
928     /** The constant {@code UNPACK_COLORSPACE_CONVERSION_WEBGL}. */
929     @JsxConstant
930     public static final int UNPACK_COLORSPACE_CONVERSION_WEBGL = 0x9243;
931     /** The constant {@code BROWSER_DEFAULT_WEBGL}. */
932     @JsxConstant
933     public static final int BROWSER_DEFAULT_WEBGL = 0x9244;
934 
935     /**
936      * Creates an instance.
937      */
938     @JsxConstructor
939     public void jsConstructor() {
940         throw JavaScriptEngine.typeErrorIllegalConstructor();
941     }
942 }