Debian Codegraph @

closure-library/closure/goog/webgl/webgl.js

raw
1 // Copyright 2011 The Closure Library Authors. All Rights Reserved.
2 //
3 // Licensed under the Apache License, Version 2.0 (the "License");
4 // you may not use this file except in compliance with the License.
5 // You may obtain a copy of the License at
6 //
7 // http://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
16 /**
17 * @fileoverview Constants used by the WebGL rendering, including all of the
18 * constants used from the WebGL context. For example, instead of using
19 * context.ARRAY_BUFFER, your code can use
20 * goog.webgl.ARRAY_BUFFER. The benefits for doing this include allowing
21 * the compiler to optimize your code so that the compiled code does not have to
22 * contain large strings to reference these properties, and reducing runtime
23 * property access.
24 *
25 * Values are taken from the WebGL Spec:
26 * https://www.khronos.org/registry/webgl/specs/1.0/#WEBGLRENDERINGCONTEXT
27 */
28
29 goog.provide('goog.webgl');
30
31
32 /**
33 * @const
34 * @type {number}
35 */
36 goog.webgl.DEPTH_BUFFER_BIT = 0x00000100;
37
38
39 /**
40 * @const
41 * @type {number}
42 */
43 goog.webgl.STENCIL_BUFFER_BIT = 0x00000400;
44
45
46 /**
47 * @const
48 * @type {number}
49 */
50 goog.webgl.COLOR_BUFFER_BIT = 0x00004000;
51
52
53 /**
54 * @const
55 * @type {number}
56 */
57 goog.webgl.POINTS = 0x0000;
58
59
60 /**
61 * @const
62 * @type {number}
63 */
64 goog.webgl.LINES = 0x0001;
65
66
67 /**
68 * @const
69 * @type {number}
70 */
71 goog.webgl.LINE_LOOP = 0x0002;
72
73
74 /**
75 * @const
76 * @type {number}
77 */
78 goog.webgl.LINE_STRIP = 0x0003;
79
80
81 /**
82 * @const
83 * @type {number}
84 */
85 goog.webgl.TRIANGLES = 0x0004;
86
87
88 /**
89 * @const
90 * @type {number}
91 */
92 goog.webgl.TRIANGLE_STRIP = 0x0005;
93
94
95 /**
96 * @const
97 * @type {number}
98 */
99 goog.webgl.TRIANGLE_FAN = 0x0006;
100
101
102 /**
103 * @const
104 * @type {number}
105 */
106 goog.webgl.ZERO = 0;
107
108
109 /**
110 * @const
111 * @type {number}
112 */
113 goog.webgl.ONE = 1;
114
115
116 /**
117 * @const
118 * @type {number}
119 */
120 goog.webgl.SRC_COLOR = 0x0300;
121
122
123 /**
124 * @const
125 * @type {number}
126 */
127 goog.webgl.ONE_MINUS_SRC_COLOR = 0x0301;
128
129
130 /**
131 * @const
132 * @type {number}
133 */
134 goog.webgl.SRC_ALPHA = 0x0302;
135
136
137 /**
138 * @const
139 * @type {number}
140 */
141 goog.webgl.ONE_MINUS_SRC_ALPHA = 0x0303;
142
143
144 /**
145 * @const
146 * @type {number}
147 */
148 goog.webgl.DST_ALPHA = 0x0304;
149
150
151 /**
152 * @const
153 * @type {number}
154 */
155 goog.webgl.ONE_MINUS_DST_ALPHA = 0x0305;
156
157
158 /**
159 * @const
160 * @type {number}
161 */
162 goog.webgl.DST_COLOR = 0x0306;
163
164
165 /**
166 * @const
167 * @type {number}
168 */
169 goog.webgl.ONE_MINUS_DST_COLOR = 0x0307;
170
171
172 /**
173 * @const
174 * @type {number}
175 */
176 goog.webgl.SRC_ALPHA_SATURATE = 0x0308;
177
178
179 /**
180 * @const
181 * @type {number}
182 */
183 goog.webgl.FUNC_ADD = 0x8006;
184
185
186 /**
187 * @const
188 * @type {number}
189 */
190 goog.webgl.BLEND_EQUATION = 0x8009;
191
192
193 /**
194 * Same as BLEND_EQUATION
195 * @const
196 * @type {number}
197 */
198 goog.webgl.BLEND_EQUATION_RGB = 0x8009;
199
200
201 /**
202 * @const
203 * @type {number}
204 */
205 goog.webgl.BLEND_EQUATION_ALPHA = 0x883D;
206
207
208 /**
209 * @const
210 * @type {number}
211 */
212 goog.webgl.FUNC_SUBTRACT = 0x800A;
213
214
215 /**
216 * @const
217 * @type {number}
218 */
219 goog.webgl.FUNC_REVERSE_SUBTRACT = 0x800B;
220
221
222 /**
223 * @const
224 * @type {number}
225 */
226 goog.webgl.BLEND_DST_RGB = 0x80C8;
227
228
229 /**
230 * @const
231 * @type {number}
232 */
233 goog.webgl.BLEND_SRC_RGB = 0x80C9;
234
235
236 /**
237 * @const
238 * @type {number}
239 */
240 goog.webgl.BLEND_DST_ALPHA = 0x80CA;
241
242
243 /**
244 * @const
245 * @type {number}
246 */
247 goog.webgl.BLEND_SRC_ALPHA = 0x80CB;
248
249
250 /**
251 * @const
252 * @type {number}
253 */
254 goog.webgl.CONSTANT_COLOR = 0x8001;
255
256
257 /**
258 * @const
259 * @type {number}
260 */
261 goog.webgl.ONE_MINUS_CONSTANT_COLOR = 0x8002;
262
263
264 /**
265 * @const
266 * @type {number}
267 */
268 goog.webgl.CONSTANT_ALPHA = 0x8003;
269
270
271 /**
272 * @const
273 * @type {number}
274 */
275 goog.webgl.ONE_MINUS_CONSTANT_ALPHA = 0x8004;
276
277
278 /**
279 * @const
280 * @type {number}
281 */
282 goog.webgl.BLEND_COLOR = 0x8005;
283
284
285 /**
286 * @const
287 * @type {number}
288 */
289 goog.webgl.ARRAY_BUFFER = 0x8892;
290
291
292 /**
293 * @const
294 * @type {number}
295 */
296 goog.webgl.ELEMENT_ARRAY_BUFFER = 0x8893;
297
298
299 /**
300 * @const
301 * @type {number}
302 */
303 goog.webgl.ARRAY_BUFFER_BINDING = 0x8894;
304
305
306 /**
307 * @const
308 * @type {number}
309 */
310 goog.webgl.ELEMENT_ARRAY_BUFFER_BINDING = 0x8895;
311
312
313 /**
314 * @const
315 * @type {number}
316 */
317 goog.webgl.STREAM_DRAW = 0x88E0;
318
319
320 /**
321 * @const
322 * @type {number}
323 */
324 goog.webgl.STATIC_DRAW = 0x88E4;
325
326
327 /**
328 * @const
329 * @type {number}
330 */
331 goog.webgl.DYNAMIC_DRAW = 0x88E8;
332
333
334 /**
335 * @const
336 * @type {number}
337 */
338 goog.webgl.BUFFER_SIZE = 0x8764;
339
340
341 /**
342 * @const
343 * @type {number}
344 */
345 goog.webgl.BUFFER_USAGE = 0x8765;
346
347
348 /**
349 * @const
350 * @type {number}
351 */
352 goog.webgl.CURRENT_VERTEX_ATTRIB = 0x8626;
353
354
355 /**
356 * @const
357 * @type {number}
358 */
359 goog.webgl.FRONT = 0x0404;
360
361
362 /**
363 * @const
364 * @type {number}
365 */
366 goog.webgl.BACK = 0x0405;
367
368
369 /**
370 * @const
371 * @type {number}
372 */
373 goog.webgl.FRONT_AND_BACK = 0x0408;
374
375
376 /**
377 * @const
378 * @type {number}
379 */
380 goog.webgl.CULL_FACE = 0x0B44;
381
382
383 /**
384 * @const
385 * @type {number}
386 */
387 goog.webgl.BLEND = 0x0BE2;
388
389
390 /**
391 * @const
392 * @type {number}
393 */
394 goog.webgl.DITHER = 0x0BD0;
395
396
397 /**
398 * @const
399 * @type {number}
400 */
401 goog.webgl.STENCIL_TEST = 0x0B90;
402
403
404 /**
405 * @const
406 * @type {number}
407 */
408 goog.webgl.DEPTH_TEST = 0x0B71;
409
410
411 /**
412 * @const
413 * @type {number}
414 */
415 goog.webgl.SCISSOR_TEST = 0x0C11;
416
417
418 /**
419 * @const
420 * @type {number}
421 */
422 goog.webgl.POLYGON_OFFSET_FILL = 0x8037;
423
424
425 /**
426 * @const
427 * @type {number}
428 */
429 goog.webgl.SAMPLE_ALPHA_TO_COVERAGE = 0x809E;
430
431
432 /**
433 * @const
434 * @type {number}
435 */
436 goog.webgl.SAMPLE_COVERAGE = 0x80A0;
437
438
439 /**
440 * @const
441 * @type {number}
442 */
443 goog.webgl.NO_ERROR = 0;
444
445
446 /**
447 * @const
448 * @type {number}
449 */
450 goog.webgl.INVALID_ENUM = 0x0500;
451
452
453 /**
454 * @const
455 * @type {number}
456 */
457 goog.webgl.INVALID_VALUE = 0x0501;
458
459
460 /**
461 * @const
462 * @type {number}
463 */
464 goog.webgl.INVALID_OPERATION = 0x0502;
465
466
467 /**
468 * @const
469 * @type {number}
470 */
471 goog.webgl.OUT_OF_MEMORY = 0x0505;
472
473
474 /**
475 * @const
476 * @type {number}
477 */
478 goog.webgl.CW = 0x0900;
479
480
481 /**
482 * @const
483 * @type {number}
484 */
485 goog.webgl.CCW = 0x0901;
486
487
488 /**
489 * @const
490 * @type {number}
491 */
492 goog.webgl.LINE_WIDTH = 0x0B21;
493
494
495 /**
496 * @const
497 * @type {number}
498 */
499 goog.webgl.ALIASED_POINT_SIZE_RANGE = 0x846D;
500
501
502 /**
503 * @const
504 * @type {number}
505 */
506 goog.webgl.ALIASED_LINE_WIDTH_RANGE = 0x846E;
507
508
509 /**
510 * @const
511 * @type {number}
512 */
513 goog.webgl.CULL_FACE_MODE = 0x0B45;
514
515
516 /**
517 * @const
518 * @type {number}
519 */
520 goog.webgl.FRONT_FACE = 0x0B46;
521
522
523 /**
524 * @const
525 * @type {number}
526 */
527 goog.webgl.DEPTH_RANGE = 0x0B70;
528
529
530 /**
531 * @const
532 * @type {number}
533 */
534 goog.webgl.DEPTH_WRITEMASK = 0x0B72;
535
536
537 /**
538 * @const
539 * @type {number}
540 */
541 goog.webgl.DEPTH_CLEAR_VALUE = 0x0B73;
542
543
544 /**
545 * @const
546 * @type {number}
547 */
548 goog.webgl.DEPTH_FUNC = 0x0B74;
549
550
551 /**
552 * @const
553 * @type {number}
554 */
555 goog.webgl.STENCIL_CLEAR_VALUE = 0x0B91;
556
557
558 /**
559 * @const
560 * @type {number}
561 */
562 goog.webgl.STENCIL_FUNC = 0x0B92;
563
564
565 /**
566 * @const
567 * @type {number}
568 */
569 goog.webgl.STENCIL_FAIL = 0x0B94;
570
571
572 /**
573 * @const
574 * @type {number}
575 */
576 goog.webgl.STENCIL_PASS_DEPTH_FAIL = 0x0B95;
577
578
579 /**
580 * @const
581 * @type {number}
582 */
583 goog.webgl.STENCIL_PASS_DEPTH_PASS = 0x0B96;
584
585
586 /**
587 * @const
588 * @type {number}
589 */
590 goog.webgl.STENCIL_REF = 0x0B97;
591
592
593 /**
594 * @const
595 * @type {number}
596 */
597 goog.webgl.STENCIL_VALUE_MASK = 0x0B93;
598
599
600 /**
601 * @const
602 * @type {number}
603 */
604 goog.webgl.STENCIL_WRITEMASK = 0x0B98;
605
606
607 /**
608 * @const
609 * @type {number}
610 */
611 goog.webgl.STENCIL_BACK_FUNC = 0x8800;
612
613
614 /**
615 * @const
616 * @type {number}
617 */
618 goog.webgl.STENCIL_BACK_FAIL = 0x8801;
619
620
621 /**
622 * @const
623 * @type {number}
624 */
625 goog.webgl.STENCIL_BACK_PASS_DEPTH_FAIL = 0x8802;
626
627
628 /**
629 * @const
630 * @type {number}
631 */
632 goog.webgl.STENCIL_BACK_PASS_DEPTH_PASS = 0x8803;
633
634
635 /**
636 * @const
637 * @type {number}
638 */
639 goog.webgl.STENCIL_BACK_REF = 0x8CA3;
640
641
642 /**
643 * @const
644 * @type {number}
645 */
646 goog.webgl.STENCIL_BACK_VALUE_MASK = 0x8CA4;
647
648
649 /**
650 * @const
651 * @type {number}
652 */
653 goog.webgl.STENCIL_BACK_WRITEMASK = 0x8CA5;
654
655
656 /**
657 * @const
658 * @type {number}
659 */
660 goog.webgl.VIEWPORT = 0x0BA2;
661
662
663 /**
664 * @const
665 * @type {number}
666 */
667 goog.webgl.SCISSOR_BOX = 0x0C10;
668
669
670 /**
671 * @const
672 * @type {number}
673 */
674 goog.webgl.COLOR_CLEAR_VALUE = 0x0C22;
675
676
677 /**
678 * @const
679 * @type {number}
680 */
681 goog.webgl.COLOR_WRITEMASK = 0x0C23;
682
683
684 /**
685 * @const
686 * @type {number}
687 */
688 goog.webgl.UNPACK_ALIGNMENT = 0x0CF5;
689
690
691 /**
692 * @const
693 * @type {number}
694 */
695 goog.webgl.PACK_ALIGNMENT = 0x0D05;
696
697
698 /**
699 * @const
700 * @type {number}
701 */
702 goog.webgl.MAX_TEXTURE_SIZE = 0x0D33;
703
704
705 /**
706 * @const
707 * @type {number}
708 */
709 goog.webgl.MAX_VIEWPORT_DIMS = 0x0D3A;
710
711
712 /**
713 * @const
714 * @type {number}
715 */
716 goog.webgl.SUBPIXEL_BITS = 0x0D50;
717
718
719 /**
720 * @const
721 * @type {number}
722 */
723 goog.webgl.RED_BITS = 0x0D52;
724
725
726 /**
727 * @const
728 * @type {number}
729 */
730 goog.webgl.GREEN_BITS = 0x0D53;
731
732
733 /**
734 * @const
735 * @type {number}
736 */
737 goog.webgl.BLUE_BITS = 0x0D54;
738
739
740 /**
741 * @const
742 * @type {number}
743 */
744 goog.webgl.ALPHA_BITS = 0x0D55;
745
746
747 /**
748 * @const
749 * @type {number}
750 */
751 goog.webgl.DEPTH_BITS = 0x0D56;
752
753
754 /**
755 * @const
756 * @type {number}
757 */
758 goog.webgl.STENCIL_BITS = 0x0D57;
759
760
761 /**
762 * @const
763 * @type {number}
764 */
765 goog.webgl.POLYGON_OFFSET_UNITS = 0x2A00;
766
767
768 /**
769 * @const
770 * @type {number}
771 */
772 goog.webgl.POLYGON_OFFSET_FACTOR = 0x8038;
773
774
775 /**
776 * @const
777 * @type {number}
778 */
779 goog.webgl.TEXTURE_BINDING_2D = 0x8069;
780
781
782 /**
783 * @const
784 * @type {number}
785 */
786 goog.webgl.SAMPLE_BUFFERS = 0x80A8;
787
788
789 /**
790 * @const
791 * @type {number}
792 */
793 goog.webgl.SAMPLES = 0x80A9;
794
795
796 /**
797 * @const
798 * @type {number}
799 */
800 goog.webgl.SAMPLE_COVERAGE_VALUE = 0x80AA;
801
802
803 /**
804 * @const
805 * @type {number}
806 */
807 goog.webgl.SAMPLE_COVERAGE_INVERT = 0x80AB;
808
809
810 /**
811 * @const
812 * @type {number}
813 */
814 goog.webgl.COMPRESSED_TEXTURE_FORMATS = 0x86A3;
815
816
817 /**
818 * @const
819 * @type {number}
820 */
821 goog.webgl.DONT_CARE = 0x1100;
822
823
824 /**
825 * @const
826 * @type {number}
827 */
828 goog.webgl.FASTEST = 0x1101;
829
830
831 /**
832 * @const
833 * @type {number}
834 */
835 goog.webgl.NICEST = 0x1102;
836
837
838 /**
839 * @const
840 * @type {number}
841 */
842 goog.webgl.GENERATE_MIPMAP_HINT = 0x8192;
843
844
845 /**
846 * @const
847 * @type {number}
848 */
849 goog.webgl.BYTE = 0x1400;
850
851
852 /**
853 * @const
854 * @type {number}
855 */
856 goog.webgl.UNSIGNED_BYTE = 0x1401;
857
858
859 /**
860 * @const
861 * @type {number}
862 */
863 goog.webgl.SHORT = 0x1402;
864
865
866 /**
867 * @const
868 * @type {number}
869 */
870 goog.webgl.UNSIGNED_SHORT = 0x1403;
871
872
873 /**
874 * @const
875 * @type {number}
876 */
877 goog.webgl.INT = 0x1404;
878
879
880 /**
881 * @const
882 * @type {number}
883 */
884 goog.webgl.UNSIGNED_INT = 0x1405;
885
886
887 /**
888 * @const
889 * @type {number}
890 */
891 goog.webgl.FLOAT = 0x1406;
892
893
894 /**
895 * @const
896 * @type {number}
897 */
898 goog.webgl.DEPTH_COMPONENT = 0x1902;
899
900
901 /**
902 * @const
903 * @type {number}
904 */
905 goog.webgl.ALPHA = 0x1906;
906
907
908 /**
909 * @const
910 * @type {number}
911 */
912 goog.webgl.RGB = 0x1907;
913
914
915 /**
916 * @const
917 * @type {number}
918 */
919 goog.webgl.RGBA = 0x1908;
920
921
922 /**
923 * @const
924 * @type {number}
925 */
926 goog.webgl.LUMINANCE = 0x1909;
927
928
929 /**
930 * @const
931 * @type {number}
932 */
933 goog.webgl.LUMINANCE_ALPHA = 0x190A;
934
935
936 /**
937 * @const
938 * @type {number}
939 */
940 goog.webgl.UNSIGNED_SHORT_4_4_4_4 = 0x8033;
941
942
943 /**
944 * @const
945 * @type {number}
946 */
947 goog.webgl.UNSIGNED_SHORT_5_5_5_1 = 0x8034;
948
949
950 /**
951 * @const
952 * @type {number}
953 */
954 goog.webgl.UNSIGNED_SHORT_5_6_5 = 0x8363;
955
956
957 /**
958 * @const
959 * @type {number}
960 */
961 goog.webgl.FRAGMENT_SHADER = 0x8B30;
962
963
964 /**
965 * @const
966 * @type {number}
967 */
968 goog.webgl.VERTEX_SHADER = 0x8B31;
969
970
971 /**
972 * @const
973 * @type {number}
974 */
975 goog.webgl.MAX_VERTEX_ATTRIBS = 0x8869;
976
977
978 /**
979 * @const
980 * @type {number}
981 */
982 goog.webgl.MAX_VERTEX_UNIFORM_VECTORS = 0x8DFB;
983
984
985 /**
986 * @const
987 * @type {number}
988 */
989 goog.webgl.MAX_VARYING_VECTORS = 0x8DFC;
990
991
992 /**
993 * @const
994 * @type {number}
995 */
996 goog.webgl.MAX_COMBINED_TEXTURE_IMAGE_UNITS = 0x8B4D;
997
998
999 /**
1000 * @const
1001 * @type {number}
1002 */
1003 goog.webgl.MAX_VERTEX_TEXTURE_IMAGE_UNITS = 0x8B4C;
1004
1005
1006 /**
1007 * @const
1008 * @type {number}
1009 */
1010 goog.webgl.MAX_TEXTURE_IMAGE_UNITS = 0x8872;
1011
1012
1013 /**
1014 * @const
1015 * @type {number}
1016 */
1017 goog.webgl.MAX_FRAGMENT_UNIFORM_VECTORS = 0x8DFD;
1018
1019
1020 /**
1021 * @const
1022 * @type {number}
1023 */
1024 goog.webgl.SHADER_TYPE = 0x8B4F;
1025
1026
1027 /**
1028 * @const
1029 * @type {number}
1030 */
1031 goog.webgl.DELETE_STATUS = 0x8B80;
1032
1033
1034 /**
1035 * @const
1036 * @type {number}
1037 */
1038 goog.webgl.LINK_STATUS = 0x8B82;
1039
1040
1041 /**
1042 * @const
1043 * @type {number}
1044 */
1045 goog.webgl.VALIDATE_STATUS = 0x8B83;
1046
1047
1048 /**
1049 * @const
1050 * @type {number}
1051 */
1052 goog.webgl.ATTACHED_SHADERS = 0x8B85;
1053
1054
1055 /**
1056 * @const
1057 * @type {number}
1058 */
1059 goog.webgl.ACTIVE_UNIFORMS = 0x8B86;
1060
1061
1062 /**
1063 * @const
1064 * @type {number}
1065 */
1066 goog.webgl.ACTIVE_ATTRIBUTES = 0x8B89;
1067
1068
1069 /**
1070 * @const
1071 * @type {number}
1072 */
1073 goog.webgl.SHADING_LANGUAGE_VERSION = 0x8B8C;
1074
1075
1076 /**
1077 * @const
1078 * @type {number}
1079 */
1080 goog.webgl.CURRENT_PROGRAM = 0x8B8D;
1081
1082
1083 /**
1084 * @const
1085 * @type {number}
1086 */
1087 goog.webgl.NEVER = 0x0200;
1088
1089
1090 /**
1091 * @const
1092 * @type {number}
1093 */
1094 goog.webgl.LESS = 0x0201;
1095
1096
1097 /**
1098 * @const
1099 * @type {number}
1100 */
1101 goog.webgl.EQUAL = 0x0202;
1102
1103
1104 /**
1105 * @const
1106 * @type {number}
1107 */
1108 goog.webgl.LEQUAL = 0x0203;
1109
1110
1111 /**
1112 * @const
1113 * @type {number}
1114 */
1115 goog.webgl.GREATER = 0x0204;
1116
1117
1118 /**
1119 * @const
1120 * @type {number}
1121 */
1122 goog.webgl.NOTEQUAL = 0x0205;
1123
1124
1125 /**
1126 * @const
1127 * @type {number}
1128 */
1129 goog.webgl.GEQUAL = 0x0206;
1130
1131
1132 /**
1133 * @const
1134 * @type {number}
1135 */
1136 goog.webgl.ALWAYS = 0x0207;
1137
1138
1139 /**
1140 * @const
1141 * @type {number}
1142 */
1143 goog.webgl.KEEP = 0x1E00;
1144
1145
1146 /**
1147 * @const
1148 * @type {number}
1149 */
1150 goog.webgl.REPLACE = 0x1E01;
1151
1152
1153 /**
1154 * @const
1155 * @type {number}
1156 */
1157 goog.webgl.INCR = 0x1E02;
1158
1159
1160 /**
1161 * @const
1162 * @type {number}
1163 */
1164 goog.webgl.DECR = 0x1E03;
1165
1166
1167 /**
1168 * @const
1169 * @type {number}
1170 */
1171 goog.webgl.INVERT = 0x150A;
1172
1173
1174 /**
1175 * @const
1176 * @type {number}
1177 */
1178 goog.webgl.INCR_WRAP = 0x8507;
1179
1180
1181 /**
1182 * @const
1183 * @type {number}
1184 */
1185 goog.webgl.DECR_WRAP = 0x8508;
1186
1187
1188 /**
1189 * @const
1190 * @type {number}
1191 */
1192 goog.webgl.VENDOR = 0x1F00;
1193
1194
1195 /**
1196 * @const
1197 * @type {number}
1198 */
1199 goog.webgl.RENDERER = 0x1F01;
1200
1201
1202 /**
1203 * @const
1204 * @type {number}
1205 */
1206 goog.webgl.VERSION = 0x1F02;
1207
1208
1209 /**
1210 * @const
1211 * @type {number}
1212 */
1213 goog.webgl.NEAREST = 0x2600;
1214
1215
1216 /**
1217 * @const
1218 * @type {number}
1219 */
1220 goog.webgl.LINEAR = 0x2601;
1221
1222
1223 /**
1224 * @const
1225 * @type {number}
1226 */
1227 goog.webgl.NEAREST_MIPMAP_NEAREST = 0x2700;
1228
1229
1230 /**
1231 * @const
1232 * @type {number}
1233 */
1234 goog.webgl.LINEAR_MIPMAP_NEAREST = 0x2701;
1235
1236
1237 /**
1238 * @const
1239 * @type {number}
1240 */
1241 goog.webgl.NEAREST_MIPMAP_LINEAR = 0x2702;
1242
1243
1244 /**
1245 * @const
1246 * @type {number}
1247 */
1248 goog.webgl.LINEAR_MIPMAP_LINEAR = 0x2703;
1249
1250
1251 /**
1252 * @const
1253 * @type {number}
1254 */
1255 goog.webgl.TEXTURE_MAG_FILTER = 0x2800;
1256
1257
1258 /**
1259 * @const
1260 * @type {number}
1261 */
1262 goog.webgl.TEXTURE_MIN_FILTER = 0x2801;
1263
1264
1265 /**
1266 * @const
1267 * @type {number}
1268 */
1269 goog.webgl.TEXTURE_WRAP_S = 0x2802;
1270
1271
1272 /**
1273 * @const
1274 * @type {number}
1275 */
1276 goog.webgl.TEXTURE_WRAP_T = 0x2803;
1277
1278
1279 /**
1280 * @const
1281 * @type {number}
1282 */
1283 goog.webgl.TEXTURE_2D = 0x0DE1;
1284
1285
1286 /**
1287 * @const
1288 * @type {number}
1289 */
1290 goog.webgl.TEXTURE = 0x1702;
1291
1292
1293 /**
1294 * @const
1295 * @type {number}
1296 */
1297 goog.webgl.TEXTURE_CUBE_MAP = 0x8513;
1298
1299
1300 /**
1301 * @const
1302 * @type {number}
1303 */
1304 goog.webgl.TEXTURE_BINDING_CUBE_MAP = 0x8514;
1305
1306
1307 /**
1308 * @const
1309 * @type {number}
1310 */
1311 goog.webgl.TEXTURE_CUBE_MAP_POSITIVE_X = 0x8515;
1312
1313
1314 /**
1315 * @const
1316 * @type {number}
1317 */
1318 goog.webgl.TEXTURE_CUBE_MAP_NEGATIVE_X = 0x8516;
1319
1320
1321 /**
1322 * @const
1323 * @type {number}
1324 */
1325 goog.webgl.TEXTURE_CUBE_MAP_POSITIVE_Y = 0x8517;
1326
1327
1328 /**
1329 * @const
1330 * @type {number}
1331 */
1332 goog.webgl.TEXTURE_CUBE_MAP_NEGATIVE_Y = 0x8518;
1333
1334
1335 /**
1336 * @const
1337 * @type {number}
1338 */
1339 goog.webgl.TEXTURE_CUBE_MAP_POSITIVE_Z = 0x8519;
1340
1341
1342 /**
1343 * @const
1344 * @type {number}
1345 */
1346 goog.webgl.TEXTURE_CUBE_MAP_NEGATIVE_Z = 0x851A;
1347
1348
1349 /**
1350 * @const
1351 * @type {number}
1352 */
1353 goog.webgl.MAX_CUBE_MAP_TEXTURE_SIZE = 0x851C;
1354
1355
1356 /**
1357 * @const
1358 * @type {number}
1359 */
1360 goog.webgl.TEXTURE0 = 0x84C0;
1361
1362
1363 /**
1364 * @const
1365 * @type {number}
1366 */
1367 goog.webgl.TEXTURE1 = 0x84C1;
1368
1369
1370 /**
1371 * @const
1372 * @type {number}
1373 */
1374 goog.webgl.TEXTURE2 = 0x84C2;
1375
1376
1377 /**
1378 * @const
1379 * @type {number}
1380 */
1381 goog.webgl.TEXTURE3 = 0x84C3;
1382
1383
1384 /**
1385 * @const
1386 * @type {number}
1387 */
1388 goog.webgl.TEXTURE4 = 0x84C4;
1389
1390
1391 /**
1392 * @const
1393 * @type {number}
1394 */
1395 goog.webgl.TEXTURE5 = 0x84C5;
1396
1397
1398 /**
1399 * @const
1400 * @type {number}
1401 */
1402 goog.webgl.TEXTURE6 = 0x84C6;
1403
1404
1405 /**
1406 * @const
1407 * @type {number}
1408 */
1409 goog.webgl.TEXTURE7 = 0x84C7;
1410
1411
1412 /**
1413 * @const
1414 * @type {number}
1415 */
1416 goog.webgl.TEXTURE8 = 0x84C8;
1417
1418
1419 /**
1420 * @const
1421 * @type {number}
1422 */
1423 goog.webgl.TEXTURE9 = 0x84C9;
1424
1425
1426 /**
1427 * @const
1428 * @type {number}
1429 */
1430 goog.webgl.TEXTURE10 = 0x84CA;
1431
1432
1433 /**
1434 * @const
1435 * @type {number}
1436 */
1437 goog.webgl.TEXTURE11 = 0x84CB;
1438
1439
1440 /**
1441 * @const
1442 * @type {number}
1443 */
1444 goog.webgl.TEXTURE12 = 0x84CC;
1445
1446
1447 /**
1448 * @const
1449 * @type {number}
1450 */
1451 goog.webgl.TEXTURE13 = 0x84CD;
1452
1453
1454 /**
1455 * @const
1456 * @type {number}
1457 */
1458 goog.webgl.TEXTURE14 = 0x84CE;
1459
1460
1461 /**
1462 * @const
1463 * @type {number}
1464 */
1465 goog.webgl.TEXTURE15 = 0x84CF;
1466
1467
1468 /**
1469 * @const
1470 * @type {number}
1471 */
1472 goog.webgl.TEXTURE16 = 0x84D0;
1473
1474
1475 /**
1476 * @const
1477 * @type {number}
1478 */
1479 goog.webgl.TEXTURE17 = 0x84D1;
1480
1481
1482 /**
1483 * @const
1484 * @type {number}
1485 */
1486 goog.webgl.TEXTURE18 = 0x84D2;
1487
1488
1489 /**
1490 * @const
1491 * @type {number}
1492 */
1493 goog.webgl.TEXTURE19 = 0x84D3;
1494
1495
1496 /**
1497 * @const
1498 * @type {number}
1499 */
1500 goog.webgl.TEXTURE20 = 0x84D4;
1501
1502
1503 /**
1504 * @const
1505 * @type {number}
1506 */
1507 goog.webgl.TEXTURE21 = 0x84D5;
1508
1509
1510 /**
1511 * @const
1512 * @type {number}
1513 */
1514 goog.webgl.TEXTURE22 = 0x84D6;
1515
1516
1517 /**
1518 * @const
1519 * @type {number}
1520 */
1521 goog.webgl.TEXTURE23 = 0x84D7;
1522
1523
1524 /**
1525 * @const
1526 * @type {number}
1527 */
1528 goog.webgl.TEXTURE24 = 0x84D8;
1529
1530
1531 /**
1532 * @const
1533 * @type {number}
1534 */
1535 goog.webgl.TEXTURE25 = 0x84D9;
1536
1537
1538 /**
1539 * @const
1540 * @type {number}
1541 */
1542 goog.webgl.TEXTURE26 = 0x84DA;
1543
1544
1545 /**
1546 * @const
1547 * @type {number}
1548 */
1549 goog.webgl.TEXTURE27 = 0x84DB;
1550
1551
1552 /**
1553 * @const
1554 * @type {number}
1555 */
1556 goog.webgl.TEXTURE28 = 0x84DC;
1557
1558
1559 /**
1560 * @const
1561 * @type {number}
1562 */
1563 goog.webgl.TEXTURE29 = 0x84DD;
1564
1565
1566 /**
1567 * @const
1568 * @type {number}
1569 */
1570 goog.webgl.TEXTURE30 = 0x84DE;
1571
1572
1573 /**
1574 * @const
1575 * @type {number}
1576 */
1577 goog.webgl.TEXTURE31 = 0x84DF;
1578
1579
1580 /**
1581 * @const
1582 * @type {number}
1583 */
1584 goog.webgl.ACTIVE_TEXTURE = 0x84E0;
1585
1586
1587 /**
1588 * @const
1589 * @type {number}
1590 */
1591 goog.webgl.REPEAT = 0x2901;
1592
1593
1594 /**
1595 * @const
1596 * @type {number}
1597 */
1598 goog.webgl.CLAMP_TO_EDGE = 0x812F;
1599
1600
1601 /**
1602 * @const
1603 * @type {number}
1604 */
1605 goog.webgl.MIRRORED_REPEAT = 0x8370;
1606
1607
1608 /**
1609 * @const
1610 * @type {number}
1611 */
1612 goog.webgl.FLOAT_VEC2 = 0x8B50;
1613
1614
1615 /**
1616 * @const
1617 * @type {number}
1618 */
1619 goog.webgl.FLOAT_VEC3 = 0x8B51;
1620
1621
1622 /**
1623 * @const
1624 * @type {number}
1625 */
1626 goog.webgl.FLOAT_VEC4 = 0x8B52;
1627
1628
1629 /**
1630 * @const
1631 * @type {number}
1632 */
1633 goog.webgl.INT_VEC2 = 0x8B53;
1634
1635
1636 /**
1637 * @const
1638 * @type {number}
1639 */
1640 goog.webgl.INT_VEC3 = 0x8B54;
1641
1642
1643 /**
1644 * @const
1645 * @type {number}
1646 */
1647 goog.webgl.INT_VEC4 = 0x8B55;
1648
1649
1650 /**
1651 * @const
1652 * @type {number}
1653 */
1654 goog.webgl.BOOL = 0x8B56;
1655
1656
1657 /**
1658 * @const
1659 * @type {number}
1660 */
1661 goog.webgl.BOOL_VEC2 = 0x8B57;
1662
1663
1664 /**
1665 * @const
1666 * @type {number}
1667 */
1668 goog.webgl.BOOL_VEC3 = 0x8B58;
1669
1670
1671 /**
1672 * @const
1673 * @type {number}
1674 */
1675 goog.webgl.BOOL_VEC4 = 0x8B59;
1676
1677
1678 /**
1679 * @const
1680 * @type {number}
1681 */
1682 goog.webgl.FLOAT_MAT2 = 0x8B5A;
1683
1684
1685 /**
1686 * @const
1687 * @type {number}
1688 */
1689 goog.webgl.FLOAT_MAT3 = 0x8B5B;
1690
1691
1692 /**
1693 * @const
1694 * @type {number}
1695 */
1696 goog.webgl.FLOAT_MAT4 = 0x8B5C;
1697
1698
1699 /**
1700 * @const
1701 * @type {number}
1702 */
1703 goog.webgl.SAMPLER_2D = 0x8B5E;
1704
1705
1706 /**
1707 * @const
1708 * @type {number}
1709 */
1710 goog.webgl.SAMPLER_CUBE = 0x8B60;
1711
1712
1713 /**
1714 * @const
1715 * @type {number}
1716 */
1717 goog.webgl.VERTEX_ATTRIB_ARRAY_ENABLED = 0x8622;
1718
1719
1720 /**
1721 * @const
1722 * @type {number}
1723 */
1724 goog.webgl.VERTEX_ATTRIB_ARRAY_SIZE = 0x8623;
1725
1726
1727 /**
1728 * @const
1729 * @type {number}
1730 */
1731 goog.webgl.VERTEX_ATTRIB_ARRAY_STRIDE = 0x8624;
1732
1733
1734 /**
1735 * @const
1736 * @type {number}
1737 */
1738 goog.webgl.VERTEX_ATTRIB_ARRAY_TYPE = 0x8625;
1739
1740
1741 /**
1742 * @const
1743 * @type {number}
1744 */
1745 goog.webgl.VERTEX_ATTRIB_ARRAY_NORMALIZED = 0x886A;
1746
1747
1748 /**
1749 * @const
1750 * @type {number}
1751 */
1752 goog.webgl.VERTEX_ATTRIB_ARRAY_POINTER = 0x8645;
1753
1754
1755 /**
1756 * @const
1757 * @type {number}
1758 */
1759 goog.webgl.VERTEX_ATTRIB_ARRAY_BUFFER_BINDING = 0x889F;
1760
1761
1762 /**
1763 * @const
1764 * @type {number}
1765 */
1766 goog.webgl.COMPILE_STATUS = 0x8B81;
1767
1768
1769 /**
1770 * @const
1771 * @type {number}
1772 */
1773 goog.webgl.LOW_FLOAT = 0x8DF0;
1774
1775
1776 /**
1777 * @const
1778 * @type {number}
1779 */
1780 goog.webgl.MEDIUM_FLOAT = 0x8DF1;
1781
1782
1783 /**
1784 * @const
1785 * @type {number}
1786 */
1787 goog.webgl.HIGH_FLOAT = 0x8DF2;
1788
1789
1790 /**
1791 * @const
1792 * @type {number}
1793 */
1794 goog.webgl.LOW_INT = 0x8DF3;
1795
1796
1797 /**
1798 * @const
1799 * @type {number}
1800 */
1801 goog.webgl.MEDIUM_INT = 0x8DF4;
1802
1803
1804 /**
1805 * @const
1806 * @type {number}
1807 */
1808 goog.webgl.HIGH_INT = 0x8DF5;
1809
1810
1811 /**
1812 * @const
1813 * @type {number}
1814 */
1815 goog.webgl.FRAMEBUFFER = 0x8D40;
1816
1817
1818 /**
1819 * @const
1820 * @type {number}
1821 */
1822 goog.webgl.RENDERBUFFER = 0x8D41;
1823
1824
1825 /**
1826 * @const
1827 * @type {number}
1828 */
1829 goog.webgl.RGBA4 = 0x8056;
1830
1831
1832 /**
1833 * @const
1834 * @type {number}
1835 */
1836 goog.webgl.RGB5_A1 = 0x8057;
1837
1838
1839 /**
1840 * @const
1841 * @type {number}
1842 */
1843 goog.webgl.RGB565 = 0x8D62;
1844
1845
1846 /**
1847 * @const
1848 * @type {number}
1849 */
1850 goog.webgl.DEPTH_COMPONENT16 = 0x81A5;
1851
1852
1853 /**
1854 * @const
1855 * @type {number}
1856 */
1857 goog.webgl.STENCIL_INDEX = 0x1901;
1858
1859
1860 /**
1861 * @const
1862 * @type {number}
1863 */
1864 goog.webgl.STENCIL_INDEX8 = 0x8D48;
1865
1866
1867 /**
1868 * @const
1869 * @type {number}
1870 */
1871 goog.webgl.DEPTH_STENCIL = 0x84F9;
1872
1873
1874 /**
1875 * @const
1876 * @type {number}
1877 */
1878 goog.webgl.RENDERBUFFER_WIDTH = 0x8D42;
1879
1880
1881 /**
1882 * @const
1883 * @type {number}
1884 */
1885 goog.webgl.RENDERBUFFER_HEIGHT = 0x8D43;
1886
1887
1888 /**
1889 * @const
1890 * @type {number}
1891 */
1892 goog.webgl.RENDERBUFFER_INTERNAL_FORMAT = 0x8D44;
1893
1894
1895 /**
1896 * @const
1897 * @type {number}
1898 */
1899 goog.webgl.RENDERBUFFER_RED_SIZE = 0x8D50;
1900
1901
1902 /**
1903 * @const
1904 * @type {number}
1905 */
1906 goog.webgl.RENDERBUFFER_GREEN_SIZE = 0x8D51;
1907
1908
1909 /**
1910 * @const
1911 * @type {number}
1912 */
1913 goog.webgl.RENDERBUFFER_BLUE_SIZE = 0x8D52;
1914
1915
1916 /**
1917 * @const
1918 * @type {number}
1919 */
1920 goog.webgl.RENDERBUFFER_ALPHA_SIZE = 0x8D53;
1921
1922
1923 /**
1924 * @const
1925 * @type {number}
1926 */
1927 goog.webgl.RENDERBUFFER_DEPTH_SIZE = 0x8D54;
1928
1929
1930 /**
1931 * @const
1932 * @type {number}
1933 */
1934 goog.webgl.RENDERBUFFER_STENCIL_SIZE = 0x8D55;
1935
1936
1937 /**
1938 * @const
1939 * @type {number}
1940 */
1941 goog.webgl.FRAMEBUFFER_ATTACHMENT_OBJECT_TYPE = 0x8CD0;
1942
1943
1944 /**
1945 * @const
1946 * @type {number}
1947 */
1948 goog.webgl.FRAMEBUFFER_ATTACHMENT_OBJECT_NAME = 0x8CD1;
1949
1950
1951 /**
1952 * @const
1953 * @type {number}
1954 */
1955 goog.webgl.FRAMEBUFFER_ATTACHMENT_TEXTURE_LEVEL = 0x8CD2;
1956
1957
1958 /**
1959 * @const
1960 * @type {number}
1961 */
1962 goog.webgl.FRAMEBUFFER_ATTACHMENT_TEXTURE_CUBE_MAP_FACE = 0x8CD3;
1963
1964
1965 /**
1966 * @const
1967 * @type {number}
1968 */
1969 goog.webgl.COLOR_ATTACHMENT0 = 0x8CE0;
1970
1971
1972 /**
1973 * @const
1974 * @type {number}
1975 */
1976 goog.webgl.DEPTH_ATTACHMENT = 0x8D00;
1977
1978
1979 /**
1980 * @const
1981 * @type {number}
1982 */
1983 goog.webgl.STENCIL_ATTACHMENT = 0x8D20;
1984
1985
1986 /**
1987 * @const
1988 * @type {number}
1989 */
1990 goog.webgl.DEPTH_STENCIL_ATTACHMENT = 0x821A;
1991
1992
1993 /**
1994 * @const
1995 * @type {number}
1996 */
1997 goog.webgl.NONE = 0;
1998
1999
2000 /**
2001 * @const
2002 * @type {number}
2003 */
2004 goog.webgl.FRAMEBUFFER_COMPLETE = 0x8CD5;
2005
2006
2007 /**
2008 * @const
2009 * @type {number}
2010 */
2011 goog.webgl.FRAMEBUFFER_INCOMPLETE_ATTACHMENT = 0x8CD6;
2012
2013
2014 /**
2015 * @const
2016 * @type {number}
2017 */
2018 goog.webgl.FRAMEBUFFER_INCOMPLETE_MISSING_ATTACHMENT = 0x8CD7;
2019
2020
2021 /**
2022 * @const
2023 * @type {number}
2024 */
2025 goog.webgl.FRAMEBUFFER_INCOMPLETE_DIMENSIONS = 0x8CD9;
2026
2027
2028 /**
2029 * @const
2030 * @type {number}
2031 */
2032 goog.webgl.FRAMEBUFFER_UNSUPPORTED = 0x8CDD;
2033
2034
2035 /**
2036 * @const
2037 * @type {number}
2038 */
2039 goog.webgl.FRAMEBUFFER_BINDING = 0x8CA6;
2040
2041
2042 /**
2043 * @const
2044 * @type {number}
2045 */
2046 goog.webgl.RENDERBUFFER_BINDING = 0x8CA7;
2047
2048
2049 /**
2050 * @const
2051 * @type {number}
2052 */
2053 goog.webgl.MAX_RENDERBUFFER_SIZE = 0x84E8;
2054
2055
2056 /**
2057 * @const
2058 * @type {number}
2059 */
2060 goog.webgl.INVALID_FRAMEBUFFER_OPERATION = 0x0506;
2061
2062
2063 /**
2064 * @const
2065 * @type {number}
2066 */
2067 goog.webgl.UNPACK_FLIP_Y_WEBGL = 0x9240;
2068
2069
2070 /**
2071 * @const
2072 * @type {number}
2073 */
2074 goog.webgl.UNPACK_PREMULTIPLY_ALPHA_WEBGL = 0x9241;
2075
2076
2077 /**
2078 * @const
2079 * @type {number}
2080 */
2081 goog.webgl.CONTEXT_LOST_WEBGL = 0x9242;
2082
2083
2084 /**
2085 * @const
2086 * @type {number}
2087 */
2088 goog.webgl.UNPACK_COLORSPACE_CONVERSION_WEBGL = 0x9243;
2089
2090
2091 /**
2092 * @const
2093 * @type {number}
2094 */
2095 goog.webgl.BROWSER_DEFAULT_WEBGL = 0x9244;
2096
2097
2098 /**
2099 * From the OES_texture_half_float extension.
2100 * http://www.khronos.org/registry/webgl/extensions/OES_texture_half_float/
2101 * @const
2102 * @type {number}
2103 */
2104 goog.webgl.HALF_FLOAT_OES = 0x8D61;
2105
2106
2107 /**
2108 * From the OES_standard_derivatives extension.
2109 * http://www.khronos.org/registry/webgl/extensions/OES_standard_derivatives/
2110 * @const
2111 * @type {number}
2112 */
2113 goog.webgl.FRAGMENT_SHADER_DERIVATIVE_HINT_OES = 0x8B8B;
2114
2115
2116 /**
2117 * From the OES_vertex_array_object extension.
2118 * http://www.khronos.org/registry/webgl/extensions/OES_vertex_array_object/
2119 * @const
2120 * @type {number}
2121 */
2122 goog.webgl.VERTEX_ARRAY_BINDING_OES = 0x85B5;
2123
2124
2125 /**
2126 * From the WEBGL_debug_renderer_info extension.
2127 * http://www.khronos.org/registry/webgl/extensions/WEBGL_debug_renderer_info/
2128 * @const
2129 * @type {number}
2130 */
2131 goog.webgl.UNMASKED_VENDOR_WEBGL = 0x9245;
2132
2133
2134 /**
2135 * From the WEBGL_debug_renderer_info extension.
2136 * http://www.khronos.org/registry/webgl/extensions/WEBGL_debug_renderer_info/
2137 * @const
2138 * @type {number}
2139 */
2140 goog.webgl.UNMASKED_RENDERER_WEBGL = 0x9246;
2141
2142
2143 /**
2144 * From the WEBGL_compressed_texture_s3tc extension.
2145 * http://www.khronos.org/registry/webgl/extensions/WEBGL_compressed_texture_s3tc/
2146 * @const
2147 * @type {number}
2148 */
2149 goog.webgl.COMPRESSED_RGB_S3TC_DXT1_EXT = 0x83F0;
2150
2151
2152 /**
2153 * From the WEBGL_compressed_texture_s3tc extension.
2154 * http://www.khronos.org/registry/webgl/extensions/WEBGL_compressed_texture_s3tc/
2155 * @const
2156 * @type {number}
2157 */
2158 goog.webgl.COMPRESSED_RGBA_S3TC_DXT1_EXT = 0x83F1;
2159
2160
2161 /**
2162 * From the WEBGL_compressed_texture_s3tc extension.
2163 * http://www.khronos.org/registry/webgl/extensions/WEBGL_compressed_texture_s3tc/
2164 * @const
2165 * @type {number}
2166 */
2167 goog.webgl.COMPRESSED_RGBA_S3TC_DXT3_EXT = 0x83F2;
2168
2169
2170 /**
2171 * From the WEBGL_compressed_texture_s3tc extension.
2172 * http://www.khronos.org/registry/webgl/extensions/WEBGL_compressed_texture_s3tc/
2173 * @const
2174 * @type {number}
2175 */
2176 goog.webgl.COMPRESSED_RGBA_S3TC_DXT5_EXT = 0x83F3;
2177
2178
2179 /**
2180 * From the EXT_texture_filter_anisotropic extension.
2181 * http://www.khronos.org/registry/webgl/extensions/EXT_texture_filter_anisotropic/
2182 * @const
2183 * @type {number}
2184 */
2185 goog.webgl.TEXTURE_MAX_ANISOTROPY_EXT = 0x84FE;
2186
2187
2188 /**
2189 * From the EXT_texture_filter_anisotropic extension.
2190 * http://www.khronos.org/registry/webgl/extensions/EXT_texture_filter_anisotropic/
2191 * @const
2192 * @type {number}
2193 */
2194 goog.webgl.MAX_TEXTURE_MAX_ANISOTROPY_EXT = 0x84FF;