@types/three 0.149.0 → 0.150.0
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.
- three/README.md +2 -2
- three/build/three.d.cts +2 -0
- three/build/three.d.ts +2 -0
- three/build/three.module.d.ts +2 -0
- three/examples/jsm/controls/OrbitControls.d.ts +8 -3
- three/examples/jsm/controls/TrackballControls.d.ts +2 -2
- three/examples/jsm/controls/TransformControls.d.ts +4 -4
- three/examples/jsm/helpers/OctreeHelper.d.ts +1 -1
- three/examples/jsm/libs/fflate.module.d.ts +1 -0
- three/examples/jsm/libs/lil-gui.module.min.d.ts +1 -0
- three/examples/jsm/libs/stats.module.d.ts +2 -23
- three/examples/jsm/nodes/shadernode/ShaderNode.d.ts +3 -4
- three/examples/jsm/objects/MarchingCubes.d.ts +1 -0
- three/examples/jsm/shaders/VelocityShader.d.ts +2 -2
- three/index.d.ts +1 -1
- three/package.json +19 -4
- three/src/Three.d.ts +0 -1
- three/src/constants.d.ts +394 -254
- three/src/core/BufferAttribute.d.ts +456 -85
- three/src/core/BufferGeometry.d.ts +235 -67
- three/src/core/Clock.d.ts +28 -20
- three/src/core/EventDispatcher.d.ts +20 -4
- three/src/core/GLBufferAttribute.d.ts +102 -8
- three/src/core/InstancedBufferAttribute.d.ts +13 -24
- three/src/core/InstancedBufferGeometry.d.ts +22 -4
- three/src/core/InstancedInterleavedBuffer.d.ts +10 -2
- three/src/core/InterleavedBuffer.d.ts +98 -14
- three/src/core/InterleavedBufferAttribute.d.ts +146 -7
- three/src/core/Layers.d.ts +61 -6
- three/src/core/Object3D.d.ts +236 -119
- three/src/core/Raycaster.d.ts +103 -27
- three/src/core/Uniform.d.ts +28 -11
- three/src/core/UniformsGroup.d.ts +10 -4
- three/src/extras/Earcut.d.ts +3 -4
- three/src/materials/MeshPhysicalMaterial.d.ts +13 -1
- three/src/math/Color.d.ts +157 -3
- three/src/math/ColorManagement.d.ts +13 -7
- three/src/renderers/WebGLRenderer.d.ts +2 -2
- three/src/utils.d.ts +5 -2
- three/examples/jsm/libs/fflate.module.min.d.ts +0 -1185
three/src/constants.d.ts
CHANGED
|
@@ -1,168 +1,439 @@
|
|
|
1
1
|
export const REVISION: string;
|
|
2
2
|
|
|
3
3
|
// https://developer.mozilla.org/en-US/docs/Web/API/MouseEvent.button
|
|
4
|
-
export
|
|
5
|
-
LEFT
|
|
6
|
-
MIDDLE
|
|
7
|
-
RIGHT
|
|
8
|
-
ROTATE
|
|
9
|
-
DOLLY
|
|
10
|
-
PAN
|
|
11
|
-
}
|
|
12
|
-
|
|
13
|
-
export
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
4
|
+
export const MOUSE: {
|
|
5
|
+
LEFT: 0;
|
|
6
|
+
MIDDLE: 1;
|
|
7
|
+
RIGHT: 2;
|
|
8
|
+
ROTATE: 0;
|
|
9
|
+
DOLLY: 1;
|
|
10
|
+
PAN: 2;
|
|
11
|
+
};
|
|
12
|
+
|
|
13
|
+
export type MouseButton = 0 | 1 | 2;
|
|
14
|
+
|
|
15
|
+
export const TOUCH: {
|
|
16
|
+
ROTATE: 0;
|
|
17
|
+
PAN: 1;
|
|
18
|
+
DOLLY_PAN: 2;
|
|
19
|
+
DOLLY_ROTATE: 3;
|
|
20
|
+
};
|
|
21
|
+
|
|
22
|
+
export type TouchCount = 0 | 1 | 2 | 3;
|
|
19
23
|
|
|
20
24
|
// GL STATE CONSTANTS
|
|
21
|
-
export
|
|
22
|
-
export const
|
|
23
|
-
export const
|
|
24
|
-
export const
|
|
25
|
-
export
|
|
25
|
+
export const CullFaceNone: 0;
|
|
26
|
+
export const CullFaceBack: 1;
|
|
27
|
+
export const CullFaceFront: 2;
|
|
28
|
+
export const CullFaceFrontBack: 3;
|
|
29
|
+
export type CullFace = typeof CullFaceNone | typeof CullFaceBack | typeof CullFaceFront | typeof CullFaceFrontBack;
|
|
26
30
|
|
|
27
31
|
// Shadowing Type
|
|
28
|
-
export
|
|
29
|
-
export const
|
|
30
|
-
export const
|
|
31
|
-
export const
|
|
32
|
-
export
|
|
32
|
+
export const BasicShadowMap: 0;
|
|
33
|
+
export const PCFShadowMap: 1;
|
|
34
|
+
export const PCFSoftShadowMap: 2;
|
|
35
|
+
export const VSMShadowMap: 3;
|
|
36
|
+
export type ShadowMapType = typeof BasicShadowMap | typeof PCFShadowMap | typeof PCFSoftShadowMap | typeof VSMShadowMap;
|
|
33
37
|
|
|
34
38
|
// MATERIAL CONSTANTS
|
|
35
39
|
|
|
36
40
|
// side
|
|
41
|
+
export const FrontSide: 0;
|
|
42
|
+
export const BackSide: 1;
|
|
43
|
+
export const DoubleSide: 2;
|
|
44
|
+
export const TwoPassDoubleSide: 2;
|
|
37
45
|
/**
|
|
38
46
|
* Defines which side of faces will be rendered - front, back or both.
|
|
39
47
|
* Default is {@link FrontSide}.
|
|
40
48
|
*/
|
|
41
|
-
export
|
|
42
|
-
export const FrontSide: Side;
|
|
43
|
-
export const BackSide: Side;
|
|
44
|
-
export const DoubleSide: Side;
|
|
49
|
+
export type Side = typeof FrontSide | typeof BackSide | typeof DoubleSide | typeof TwoPassDoubleSide;
|
|
45
50
|
|
|
46
51
|
// blending modes
|
|
47
|
-
export
|
|
48
|
-
export const
|
|
49
|
-
export const
|
|
50
|
-
export const
|
|
51
|
-
export const
|
|
52
|
-
export const
|
|
53
|
-
export
|
|
52
|
+
export const NoBlending: 0;
|
|
53
|
+
export const NormalBlending: 1;
|
|
54
|
+
export const AdditiveBlending: 2;
|
|
55
|
+
export const SubtractiveBlending: 3;
|
|
56
|
+
export const MultiplyBlending: 4;
|
|
57
|
+
export const CustomBlending: 5;
|
|
58
|
+
export type Blending =
|
|
59
|
+
| typeof NoBlending
|
|
60
|
+
| typeof NormalBlending
|
|
61
|
+
| typeof AdditiveBlending
|
|
62
|
+
| typeof SubtractiveBlending
|
|
63
|
+
| typeof MultiplyBlending
|
|
64
|
+
| typeof CustomBlending;
|
|
54
65
|
|
|
55
66
|
// custom blending equations
|
|
56
67
|
// (numbers start from 100 not to clash with other
|
|
57
68
|
// mappings to OpenGL constants defined in Texture.js)
|
|
58
|
-
export
|
|
59
|
-
export const
|
|
60
|
-
export const
|
|
61
|
-
export const
|
|
62
|
-
export const
|
|
63
|
-
export
|
|
69
|
+
export const AddEquation: 100;
|
|
70
|
+
export const SubtractEquation: 101;
|
|
71
|
+
export const ReverseSubtractEquation: 102;
|
|
72
|
+
export const MinEquation: 103;
|
|
73
|
+
export const MaxEquation: 104;
|
|
74
|
+
export type BlendingEquation =
|
|
75
|
+
| typeof AddEquation
|
|
76
|
+
| typeof SubtractEquation
|
|
77
|
+
| typeof ReverseSubtractEquation
|
|
78
|
+
| typeof MinEquation
|
|
79
|
+
| typeof MaxEquation;
|
|
64
80
|
|
|
65
81
|
// custom blending destination factors
|
|
66
|
-
export
|
|
67
|
-
export const
|
|
68
|
-
export const
|
|
69
|
-
export const
|
|
70
|
-
export const
|
|
71
|
-
export const
|
|
72
|
-
export const
|
|
73
|
-
export const
|
|
74
|
-
export const
|
|
75
|
-
export const
|
|
76
|
-
export
|
|
82
|
+
export const ZeroFactor: 200;
|
|
83
|
+
export const OneFactor: 201;
|
|
84
|
+
export const SrcColorFactor: 202;
|
|
85
|
+
export const OneMinusSrcColorFactor: 203;
|
|
86
|
+
export const SrcAlphaFactor: 204;
|
|
87
|
+
export const OneMinusSrcAlphaFactor: 205;
|
|
88
|
+
export const DstAlphaFactor: 206;
|
|
89
|
+
export const OneMinusDstAlphaFactor: 207;
|
|
90
|
+
export const DstColorFactor: 208;
|
|
91
|
+
export const OneMinusDstColorFactor: 209;
|
|
92
|
+
export type BlendingDstFactor =
|
|
93
|
+
| typeof ZeroFactor
|
|
94
|
+
| typeof OneFactor
|
|
95
|
+
| typeof SrcColorFactor
|
|
96
|
+
| typeof OneMinusSrcColorFactor
|
|
97
|
+
| typeof SrcAlphaFactor
|
|
98
|
+
| typeof OneMinusSrcAlphaFactor
|
|
99
|
+
| typeof DstAlphaFactor
|
|
100
|
+
| typeof OneMinusDstAlphaFactor
|
|
101
|
+
| typeof DstColorFactor
|
|
102
|
+
| typeof OneMinusDstColorFactor;
|
|
77
103
|
|
|
78
104
|
// custom blending src factors
|
|
79
|
-
export
|
|
80
|
-
export
|
|
105
|
+
export const SrcAlphaSaturateFactor: 210;
|
|
106
|
+
export type BlendingSrcFactor = typeof SrcAlphaSaturateFactor;
|
|
81
107
|
|
|
82
108
|
// depth modes
|
|
83
|
-
export
|
|
84
|
-
export const
|
|
85
|
-
export const
|
|
86
|
-
export const
|
|
87
|
-
export const
|
|
88
|
-
export const
|
|
89
|
-
export const
|
|
90
|
-
export const
|
|
91
|
-
export
|
|
109
|
+
export const NeverDepth: 0;
|
|
110
|
+
export const AlwaysDepth: 1;
|
|
111
|
+
export const LessDepth: 2;
|
|
112
|
+
export const LessEqualDepth: 3;
|
|
113
|
+
export const EqualDepth: 4;
|
|
114
|
+
export const GreaterEqualDepth: 5;
|
|
115
|
+
export const GreaterDepth: 6;
|
|
116
|
+
export const NotEqualDepth: 7;
|
|
117
|
+
export type DepthModes =
|
|
118
|
+
| typeof NeverDepth
|
|
119
|
+
| typeof AlwaysDepth
|
|
120
|
+
| typeof LessDepth
|
|
121
|
+
| typeof LessEqualDepth
|
|
122
|
+
| typeof EqualDepth
|
|
123
|
+
| typeof GreaterEqualDepth
|
|
124
|
+
| typeof GreaterDepth
|
|
125
|
+
| typeof NotEqualDepth;
|
|
92
126
|
|
|
93
127
|
// TEXTURE CONSTANTS
|
|
94
128
|
// Operations
|
|
95
|
-
export
|
|
96
|
-
export const
|
|
97
|
-
export const
|
|
98
|
-
export
|
|
129
|
+
export const MultiplyOperation: 0;
|
|
130
|
+
export const MixOperation: 1;
|
|
131
|
+
export const AddOperation: 2;
|
|
132
|
+
export type Combine = typeof MultiplyOperation | typeof MixOperation | typeof AddOperation;
|
|
99
133
|
|
|
100
134
|
// Tone Mapping modes
|
|
101
|
-
export
|
|
102
|
-
export const
|
|
103
|
-
export const
|
|
104
|
-
export const
|
|
105
|
-
export const
|
|
106
|
-
export const
|
|
107
|
-
export
|
|
135
|
+
export const NoToneMapping: 0;
|
|
136
|
+
export const LinearToneMapping: 1;
|
|
137
|
+
export const ReinhardToneMapping: 2;
|
|
138
|
+
export const CineonToneMapping: 3;
|
|
139
|
+
export const ACESFilmicToneMapping: 4;
|
|
140
|
+
export const CustomToneMapping: 5;
|
|
141
|
+
export type ToneMapping =
|
|
142
|
+
| typeof NoToneMapping
|
|
143
|
+
| typeof LinearToneMapping
|
|
144
|
+
| typeof ReinhardToneMapping
|
|
145
|
+
| typeof CineonToneMapping
|
|
146
|
+
| typeof ACESFilmicToneMapping
|
|
147
|
+
| typeof CustomToneMapping;
|
|
108
148
|
|
|
109
149
|
// Mapping modes
|
|
110
|
-
export
|
|
111
|
-
export const
|
|
112
|
-
export const
|
|
113
|
-
export const
|
|
114
|
-
export const
|
|
115
|
-
export const
|
|
116
|
-
export
|
|
150
|
+
export const UVMapping: 300;
|
|
151
|
+
export const CubeReflectionMapping: 301;
|
|
152
|
+
export const CubeRefractionMapping: 302;
|
|
153
|
+
export const EquirectangularReflectionMapping: 303;
|
|
154
|
+
export const EquirectangularRefractionMapping: 304;
|
|
155
|
+
export const CubeUVReflectionMapping: 306;
|
|
156
|
+
export type Mapping =
|
|
157
|
+
| typeof UVMapping
|
|
158
|
+
| typeof CubeReflectionMapping
|
|
159
|
+
| typeof CubeRefractionMapping
|
|
160
|
+
| typeof EquirectangularReflectionMapping
|
|
161
|
+
| typeof EquirectangularRefractionMapping
|
|
162
|
+
| typeof CubeUVReflectionMapping;
|
|
117
163
|
|
|
118
164
|
// Wrapping modes
|
|
119
|
-
export
|
|
120
|
-
export const
|
|
121
|
-
export const
|
|
122
|
-
export
|
|
165
|
+
export const RepeatWrapping: 1000;
|
|
166
|
+
export const ClampToEdgeWrapping: 1001;
|
|
167
|
+
export const MirroredRepeatWrapping: 1002;
|
|
168
|
+
export type Wrapping = typeof RepeatWrapping | typeof ClampToEdgeWrapping | typeof MirroredRepeatWrapping;
|
|
123
169
|
|
|
124
170
|
// Filters
|
|
125
|
-
export
|
|
126
|
-
export const
|
|
127
|
-
export const
|
|
128
|
-
export const
|
|
129
|
-
export const
|
|
130
|
-
export const
|
|
131
|
-
export const
|
|
132
|
-
export const
|
|
133
|
-
export const
|
|
134
|
-
export const
|
|
135
|
-
export
|
|
171
|
+
export const NearestFilter: 1003;
|
|
172
|
+
export const NearestMipmapNearestFilter: 1004;
|
|
173
|
+
export const NearestMipMapNearestFilter: 1004;
|
|
174
|
+
export const NearestMipmapLinearFilter: 1005;
|
|
175
|
+
export const NearestMipMapLinearFilter: 1005;
|
|
176
|
+
export const LinearFilter: 1006;
|
|
177
|
+
export const LinearMipmapNearestFilter: 1007;
|
|
178
|
+
export const LinearMipMapNearestFilter: 1007;
|
|
179
|
+
export const LinearMipmapLinearFilter: 1008;
|
|
180
|
+
export const LinearMipMapLinearFilter: 1008;
|
|
181
|
+
export type TextureFilter =
|
|
182
|
+
| typeof NearestFilter
|
|
183
|
+
| typeof NearestMipmapNearestFilter
|
|
184
|
+
| typeof NearestMipMapNearestFilter
|
|
185
|
+
| typeof NearestMipmapLinearFilter
|
|
186
|
+
| typeof NearestMipMapLinearFilter
|
|
187
|
+
| typeof LinearFilter
|
|
188
|
+
| typeof LinearMipmapNearestFilter
|
|
189
|
+
| typeof LinearMipMapNearestFilter
|
|
190
|
+
| typeof LinearMipmapLinearFilter
|
|
191
|
+
| typeof LinearMipMapLinearFilter;
|
|
136
192
|
|
|
137
193
|
// Data types
|
|
138
|
-
export
|
|
139
|
-
export const
|
|
140
|
-
export const
|
|
141
|
-
export const
|
|
142
|
-
export const
|
|
143
|
-
export const
|
|
144
|
-
export const
|
|
145
|
-
export const
|
|
146
|
-
export const
|
|
147
|
-
export const
|
|
148
|
-
export const
|
|
149
|
-
export
|
|
194
|
+
export const UnsignedByteType: 1009;
|
|
195
|
+
export const ByteType: 1010;
|
|
196
|
+
export const ShortType: 1011;
|
|
197
|
+
export const UnsignedShortType: 1012;
|
|
198
|
+
export const IntType: 1013;
|
|
199
|
+
export const UnsignedIntType: 1014;
|
|
200
|
+
export const FloatType: 1015;
|
|
201
|
+
export const HalfFloatType: 1016;
|
|
202
|
+
export const UnsignedShort4444Type: 1017;
|
|
203
|
+
export const UnsignedShort5551Type: 1018;
|
|
204
|
+
export const UnsignedInt248Type: 1020;
|
|
205
|
+
export type TextureDataType =
|
|
206
|
+
| typeof UnsignedByteType
|
|
207
|
+
| typeof ByteType
|
|
208
|
+
| typeof ShortType
|
|
209
|
+
| typeof UnsignedShortType
|
|
210
|
+
| typeof IntType
|
|
211
|
+
| typeof UnsignedIntType
|
|
212
|
+
| typeof FloatType
|
|
213
|
+
| typeof HalfFloatType
|
|
214
|
+
| typeof UnsignedShort4444Type
|
|
215
|
+
| typeof UnsignedShort5551Type
|
|
216
|
+
| typeof UnsignedInt248Type;
|
|
150
217
|
|
|
151
218
|
// Pixel formats
|
|
152
|
-
export
|
|
153
|
-
export const
|
|
154
|
-
export const
|
|
155
|
-
export const
|
|
156
|
-
export const
|
|
157
|
-
export const
|
|
158
|
-
export const
|
|
159
|
-
export const
|
|
160
|
-
export const
|
|
161
|
-
export const
|
|
162
|
-
export const
|
|
163
|
-
export
|
|
164
|
-
|
|
165
|
-
|
|
219
|
+
export const AlphaFormat: 1021;
|
|
220
|
+
export const RGBAFormat: 1023;
|
|
221
|
+
export const LuminanceFormat: 1024;
|
|
222
|
+
export const LuminanceAlphaFormat: 1025;
|
|
223
|
+
export const DepthFormat: 1026;
|
|
224
|
+
export const DepthStencilFormat: 1027;
|
|
225
|
+
export const RedFormat: 1028;
|
|
226
|
+
export const RedIntegerFormat: 1029;
|
|
227
|
+
export const RGFormat: 1030;
|
|
228
|
+
export const RGIntegerFormat: 1031;
|
|
229
|
+
export const RGBAIntegerFormat: 1033;
|
|
230
|
+
export type PixelFormat =
|
|
231
|
+
| typeof AlphaFormat
|
|
232
|
+
| typeof RGBAFormat
|
|
233
|
+
| typeof LuminanceFormat
|
|
234
|
+
| typeof LuminanceAlphaFormat
|
|
235
|
+
| typeof DepthFormat
|
|
236
|
+
| typeof DepthStencilFormat
|
|
237
|
+
| typeof RedFormat
|
|
238
|
+
| typeof RedIntegerFormat
|
|
239
|
+
| typeof RGFormat
|
|
240
|
+
| typeof RGIntegerFormat
|
|
241
|
+
| typeof RGBAIntegerFormat
|
|
242
|
+
| typeof _SRGBAFormat;
|
|
243
|
+
|
|
244
|
+
// Compressed texture formats
|
|
245
|
+
// DDS / ST3C Compressed texture formats
|
|
246
|
+
export const RGB_S3TC_DXT1_Format: 33776;
|
|
247
|
+
export const RGBA_S3TC_DXT1_Format: 33777;
|
|
248
|
+
export const RGBA_S3TC_DXT3_Format: 33778;
|
|
249
|
+
export const RGBA_S3TC_DXT5_Format: 33779;
|
|
250
|
+
|
|
251
|
+
// PVRTC compressed './texture formats
|
|
252
|
+
export const RGB_PVRTC_4BPPV1_Format: 35840;
|
|
253
|
+
export const RGB_PVRTC_2BPPV1_Format: 35841;
|
|
254
|
+
export const RGBA_PVRTC_4BPPV1_Format: 35842;
|
|
255
|
+
export const RGBA_PVRTC_2BPPV1_Format: 35843;
|
|
256
|
+
|
|
257
|
+
// ETC compressed texture formats
|
|
258
|
+
export const RGB_ETC1_Format: 36196;
|
|
259
|
+
export const RGB_ETC2_Format: 37492;
|
|
260
|
+
export const RGBA_ETC2_EAC_Format: 37496;
|
|
261
|
+
|
|
262
|
+
// ASTC compressed texture formats
|
|
263
|
+
export const RGBA_ASTC_4x4_Format: 37808;
|
|
264
|
+
export const RGBA_ASTC_5x4_Format: 37809;
|
|
265
|
+
export const RGBA_ASTC_5x5_Format: 37810;
|
|
266
|
+
export const RGBA_ASTC_6x5_Format: 37811;
|
|
267
|
+
export const RGBA_ASTC_6x6_Format: 37812;
|
|
268
|
+
export const RGBA_ASTC_8x5_Format: 37813;
|
|
269
|
+
export const RGBA_ASTC_8x6_Format: 37814;
|
|
270
|
+
export const RGBA_ASTC_8x8_Format: 37815;
|
|
271
|
+
export const RGBA_ASTC_10x5_Format: 37816;
|
|
272
|
+
export const RGBA_ASTC_10x6_Format: 37817;
|
|
273
|
+
export const RGBA_ASTC_10x8_Format: 37818;
|
|
274
|
+
export const RGBA_ASTC_10x10_Format: 37819;
|
|
275
|
+
export const RGBA_ASTC_12x10_Format: 37820;
|
|
276
|
+
export const RGBA_ASTC_12x12_Format: 37821;
|
|
277
|
+
|
|
278
|
+
// BPTC compressed texture formats
|
|
279
|
+
export const RGBA_BPTC_Format: 36492;
|
|
280
|
+
|
|
281
|
+
// RGTC compressed texture formats
|
|
282
|
+
export const RED_RGTC1_Format: 36283;
|
|
283
|
+
export const SIGNED_RED_RGTC1_Format: 36284;
|
|
284
|
+
export const RED_GREEN_RGTC2_Format: 36285;
|
|
285
|
+
export const SIGNED_RED_GREEN_RGTC2_Format: 36286;
|
|
286
|
+
|
|
287
|
+
export type CompressedPixelFormat =
|
|
288
|
+
| typeof RGB_S3TC_DXT1_Format
|
|
289
|
+
| typeof RGBA_S3TC_DXT1_Format
|
|
290
|
+
| typeof RGBA_S3TC_DXT3_Format
|
|
291
|
+
| typeof RGBA_S3TC_DXT5_Format
|
|
292
|
+
| typeof RGB_PVRTC_4BPPV1_Format
|
|
293
|
+
| typeof RGB_PVRTC_2BPPV1_Format
|
|
294
|
+
| typeof RGBA_PVRTC_4BPPV1_Format
|
|
295
|
+
| typeof RGBA_PVRTC_2BPPV1_Format
|
|
296
|
+
| typeof RGB_ETC1_Format
|
|
297
|
+
| typeof RGB_ETC2_Format
|
|
298
|
+
| typeof RGBA_ETC2_EAC_Format
|
|
299
|
+
| typeof RGBA_ASTC_4x4_Format
|
|
300
|
+
| typeof RGBA_ASTC_5x4_Format
|
|
301
|
+
| typeof RGBA_ASTC_5x5_Format
|
|
302
|
+
| typeof RGBA_ASTC_6x5_Format
|
|
303
|
+
| typeof RGBA_ASTC_6x6_Format
|
|
304
|
+
| typeof RGBA_ASTC_8x5_Format
|
|
305
|
+
| typeof RGBA_ASTC_8x6_Format
|
|
306
|
+
| typeof RGBA_ASTC_8x8_Format
|
|
307
|
+
| typeof RGBA_ASTC_10x5_Format
|
|
308
|
+
| typeof RGBA_ASTC_10x6_Format
|
|
309
|
+
| typeof RGBA_ASTC_10x8_Format
|
|
310
|
+
| typeof RGBA_ASTC_10x10_Format
|
|
311
|
+
| typeof RGBA_ASTC_12x10_Format
|
|
312
|
+
| typeof RGBA_ASTC_12x12_Format
|
|
313
|
+
| typeof RGBA_BPTC_Format
|
|
314
|
+
| typeof RED_RGTC1_Format
|
|
315
|
+
| typeof SIGNED_RED_RGTC1_Format
|
|
316
|
+
| typeof RED_GREEN_RGTC2_Format
|
|
317
|
+
| typeof SIGNED_RED_GREEN_RGTC2_Format;
|
|
318
|
+
|
|
319
|
+
// Loop styles for AnimationAction
|
|
320
|
+
export const LoopOnce: 2200;
|
|
321
|
+
export const LoopRepeat: 2201;
|
|
322
|
+
export const LoopPingPong: 2202;
|
|
323
|
+
export type AnimationActionLoopStyles = typeof LoopOnce | typeof LoopRepeat | typeof LoopPingPong;
|
|
324
|
+
|
|
325
|
+
// Interpolation
|
|
326
|
+
export const InterpolateDiscrete: 2300;
|
|
327
|
+
export const InterpolateLinear: 2301;
|
|
328
|
+
export const InterpolateSmooth: 2302;
|
|
329
|
+
export type InterpolationModes = typeof InterpolateDiscrete | typeof InterpolateLinear | typeof InterpolateSmooth;
|
|
330
|
+
|
|
331
|
+
// Interpolant ending modes
|
|
332
|
+
export const ZeroCurvatureEnding: 2400;
|
|
333
|
+
export const ZeroSlopeEnding: 2401;
|
|
334
|
+
export const WrapAroundEnding: 2402;
|
|
335
|
+
export type InterpolationEndingModes = typeof ZeroCurvatureEnding | typeof ZeroSlopeEnding | typeof WrapAroundEnding;
|
|
336
|
+
|
|
337
|
+
// Animation blending modes
|
|
338
|
+
export const NormalAnimationBlendMode: 2500;
|
|
339
|
+
export const AdditiveAnimationBlendMode: 2501;
|
|
340
|
+
export type AnimationBlendMode = typeof NormalAnimationBlendMode | typeof AdditiveAnimationBlendMode;
|
|
341
|
+
|
|
342
|
+
// Triangle Draw modes
|
|
343
|
+
export const TrianglesDrawMode: 0;
|
|
344
|
+
export const TriangleStripDrawMode: 1;
|
|
345
|
+
export const TriangleFanDrawMode: 2;
|
|
346
|
+
export type TrianglesDrawModes = typeof TrianglesDrawMode | typeof TriangleStripDrawMode | typeof TriangleFanDrawMode;
|
|
347
|
+
|
|
348
|
+
// Texture Encodings
|
|
349
|
+
export const LinearEncoding: 3000;
|
|
350
|
+
export const sRGBEncoding: 3001;
|
|
351
|
+
export type TextureEncoding = typeof LinearEncoding | typeof sRGBEncoding;
|
|
352
|
+
|
|
353
|
+
// Depth packing strategies
|
|
354
|
+
export const BasicDepthPacking: 3200;
|
|
355
|
+
export const RGBADepthPacking: 3201;
|
|
356
|
+
export type DepthPackingStrategies = typeof BasicDepthPacking | typeof RGBADepthPacking;
|
|
357
|
+
|
|
358
|
+
// Normal Map types
|
|
359
|
+
export const TangentSpaceNormalMap: 0;
|
|
360
|
+
export const ObjectSpaceNormalMap: 1;
|
|
361
|
+
export type NormalMapTypes = typeof TangentSpaceNormalMap | typeof ObjectSpaceNormalMap;
|
|
362
|
+
|
|
363
|
+
export const NoColorSpace: '';
|
|
364
|
+
export const SRGBColorSpace: 'srgb';
|
|
365
|
+
export const LinearSRGBColorSpace: 'srgb-linear';
|
|
366
|
+
export const DisplayP3ColorSpace = 'display-p3';
|
|
367
|
+
export type ColorSpace =
|
|
368
|
+
| typeof NoColorSpace
|
|
369
|
+
| typeof SRGBColorSpace
|
|
370
|
+
| typeof LinearSRGBColorSpace
|
|
371
|
+
| typeof DisplayP3ColorSpace;
|
|
372
|
+
|
|
373
|
+
// Stencil Op types
|
|
374
|
+
export const ZeroStencilOp: 0;
|
|
375
|
+
export const KeepStencilOp: 7680;
|
|
376
|
+
export const ReplaceStencilOp: 7681;
|
|
377
|
+
export const IncrementStencilOp: 7682;
|
|
378
|
+
export const DecrementStencilOp: 7283;
|
|
379
|
+
export const IncrementWrapStencilOp: 34055;
|
|
380
|
+
export const DecrementWrapStencilOp: 34056;
|
|
381
|
+
export const InvertStencilOp: 5386;
|
|
382
|
+
export type StencilOp =
|
|
383
|
+
| typeof ZeroStencilOp
|
|
384
|
+
| typeof KeepStencilOp
|
|
385
|
+
| typeof ReplaceStencilOp
|
|
386
|
+
| typeof IncrementStencilOp
|
|
387
|
+
| typeof DecrementStencilOp
|
|
388
|
+
| typeof IncrementWrapStencilOp
|
|
389
|
+
| typeof DecrementWrapStencilOp
|
|
390
|
+
| typeof InvertStencilOp;
|
|
391
|
+
|
|
392
|
+
// Stencil Func types
|
|
393
|
+
export const NeverStencilFunc: 512;
|
|
394
|
+
export const LessStencilFunc: 513;
|
|
395
|
+
export const EqualStencilFunc: 514;
|
|
396
|
+
export const LessEqualStencilFunc: 515;
|
|
397
|
+
export const GreaterStencilFunc: 516;
|
|
398
|
+
export const NotEqualStencilFunc: 517;
|
|
399
|
+
export const GreaterEqualStencilFunc: 518;
|
|
400
|
+
export const AlwaysStencilFunc: 519;
|
|
401
|
+
export type StencilFunc =
|
|
402
|
+
| typeof NeverStencilFunc
|
|
403
|
+
| typeof LessStencilFunc
|
|
404
|
+
| typeof EqualStencilFunc
|
|
405
|
+
| typeof LessEqualStencilFunc
|
|
406
|
+
| typeof GreaterStencilFunc
|
|
407
|
+
| typeof NotEqualStencilFunc
|
|
408
|
+
| typeof GreaterEqualStencilFunc
|
|
409
|
+
| typeof AlwaysStencilFunc;
|
|
410
|
+
|
|
411
|
+
// usage types
|
|
412
|
+
export const StaticDrawUsage: 35044;
|
|
413
|
+
export const DynamicDrawUsage: 35048;
|
|
414
|
+
export const StreamDrawUsage: 35040;
|
|
415
|
+
export const StaticReadUsage: 35045;
|
|
416
|
+
export const DynamicReadUsage: 35049;
|
|
417
|
+
export const StreamReadUsage: 35041;
|
|
418
|
+
export const StaticCopyUsage: 35046;
|
|
419
|
+
export const DynamicCopyUsage: 35050;
|
|
420
|
+
export const StreamCopyUsage: 35042;
|
|
421
|
+
export type Usage =
|
|
422
|
+
| typeof StaticDrawUsage
|
|
423
|
+
| typeof DynamicDrawUsage
|
|
424
|
+
| typeof StreamDrawUsage
|
|
425
|
+
| typeof StaticReadUsage
|
|
426
|
+
| typeof DynamicReadUsage
|
|
427
|
+
| typeof StreamReadUsage
|
|
428
|
+
| typeof StaticCopyUsage
|
|
429
|
+
| typeof DynamicCopyUsage
|
|
430
|
+
| typeof StreamCopyUsage;
|
|
431
|
+
|
|
432
|
+
export const GLSL1: '100';
|
|
433
|
+
export const GLSL3: '300 es';
|
|
434
|
+
export type GLSLVersion = typeof GLSL1 | typeof GLSL3;
|
|
435
|
+
|
|
436
|
+
export const _SRGBAFormat = 1035; // fallback for WebGL 1
|
|
166
437
|
|
|
167
438
|
// Internal Pixel Formats
|
|
168
439
|
export type PixelFormatGPU =
|
|
@@ -228,137 +499,6 @@ export type PixelFormatGPU =
|
|
|
228
499
|
| 'DEPTH24_STENCIL8'
|
|
229
500
|
| 'DEPTH32F_STENCIL8';
|
|
230
501
|
|
|
231
|
-
// Compressed texture formats
|
|
232
|
-
// DDS / ST3C Compressed texture formats
|
|
233
|
-
export enum CompressedPixelFormat {}
|
|
234
|
-
export const RGB_S3TC_DXT1_Format: CompressedPixelFormat;
|
|
235
|
-
export const RGBA_S3TC_DXT1_Format: CompressedPixelFormat;
|
|
236
|
-
export const RGBA_S3TC_DXT3_Format: CompressedPixelFormat;
|
|
237
|
-
export const RGBA_S3TC_DXT5_Format: CompressedPixelFormat;
|
|
238
|
-
|
|
239
|
-
// PVRTC compressed './texture formats
|
|
240
|
-
export const RGB_PVRTC_4BPPV1_Format: CompressedPixelFormat;
|
|
241
|
-
export const RGB_PVRTC_2BPPV1_Format: CompressedPixelFormat;
|
|
242
|
-
export const RGBA_PVRTC_4BPPV1_Format: CompressedPixelFormat;
|
|
243
|
-
export const RGBA_PVRTC_2BPPV1_Format: CompressedPixelFormat;
|
|
244
|
-
|
|
245
|
-
// ETC compressed texture formats
|
|
246
|
-
export const RGB_ETC1_Format: CompressedPixelFormat;
|
|
247
|
-
export const RGB_ETC2_Format: CompressedPixelFormat;
|
|
248
|
-
export const RGBA_ETC2_EAC_Format: CompressedPixelFormat;
|
|
249
|
-
|
|
250
|
-
// ASTC compressed texture formats
|
|
251
|
-
export const RGBA_ASTC_4x4_Format: CompressedPixelFormat;
|
|
252
|
-
export const RGBA_ASTC_5x4_Format: CompressedPixelFormat;
|
|
253
|
-
export const RGBA_ASTC_5x5_Format: CompressedPixelFormat;
|
|
254
|
-
export const RGBA_ASTC_6x5_Format: CompressedPixelFormat;
|
|
255
|
-
export const RGBA_ASTC_6x6_Format: CompressedPixelFormat;
|
|
256
|
-
export const RGBA_ASTC_8x5_Format: CompressedPixelFormat;
|
|
257
|
-
export const RGBA_ASTC_8x6_Format: CompressedPixelFormat;
|
|
258
|
-
export const RGBA_ASTC_8x8_Format: CompressedPixelFormat;
|
|
259
|
-
export const RGBA_ASTC_10x5_Format: CompressedPixelFormat;
|
|
260
|
-
export const RGBA_ASTC_10x6_Format: CompressedPixelFormat;
|
|
261
|
-
export const RGBA_ASTC_10x8_Format: CompressedPixelFormat;
|
|
262
|
-
export const RGBA_ASTC_10x10_Format: CompressedPixelFormat;
|
|
263
|
-
export const RGBA_ASTC_12x10_Format: CompressedPixelFormat;
|
|
264
|
-
export const RGBA_ASTC_12x12_Format: CompressedPixelFormat;
|
|
265
|
-
|
|
266
|
-
// BPTC compressed texture formats
|
|
267
|
-
export const RGBA_BPTC_Format: CompressedPixelFormat;
|
|
268
|
-
|
|
269
|
-
// RGTC compressed texture formats
|
|
270
|
-
export const RED_RGTC1_Format: CompressedPixelFormat;
|
|
271
|
-
export const SIGNED_RED_RGTC1_Format: CompressedPixelFormat;
|
|
272
|
-
export const RED_GREEN_RGTC2_Format: CompressedPixelFormat;
|
|
273
|
-
export const SIGNED_RED_GREEN_RGTC2_Format: CompressedPixelFormat;
|
|
274
|
-
|
|
275
|
-
// Loop styles for AnimationAction
|
|
276
|
-
export enum AnimationActionLoopStyles {}
|
|
277
|
-
export const LoopOnce: AnimationActionLoopStyles;
|
|
278
|
-
export const LoopRepeat: AnimationActionLoopStyles;
|
|
279
|
-
export const LoopPingPong: AnimationActionLoopStyles;
|
|
280
|
-
|
|
281
|
-
// Interpolation
|
|
282
|
-
export enum InterpolationModes {}
|
|
283
|
-
export const InterpolateDiscrete: InterpolationModes;
|
|
284
|
-
export const InterpolateLinear: InterpolationModes;
|
|
285
|
-
export const InterpolateSmooth: InterpolationModes;
|
|
286
|
-
|
|
287
|
-
// Interpolant ending modes
|
|
288
|
-
export enum InterpolationEndingModes {}
|
|
289
|
-
export const ZeroCurvatureEnding: InterpolationEndingModes;
|
|
290
|
-
export const ZeroSlopeEnding: InterpolationEndingModes;
|
|
291
|
-
export const WrapAroundEnding: InterpolationEndingModes;
|
|
292
|
-
|
|
293
|
-
// Animation blending modes
|
|
294
|
-
export enum AnimationBlendMode {}
|
|
295
|
-
export const NormalAnimationBlendMode: AnimationBlendMode;
|
|
296
|
-
export const AdditiveAnimationBlendMode: AnimationBlendMode;
|
|
297
|
-
|
|
298
|
-
// Triangle Draw modes
|
|
299
|
-
export enum TrianglesDrawModes {}
|
|
300
|
-
export const TrianglesDrawMode: TrianglesDrawModes;
|
|
301
|
-
export const TriangleStripDrawMode: TrianglesDrawModes;
|
|
302
|
-
export const TriangleFanDrawMode: TrianglesDrawModes;
|
|
303
|
-
|
|
304
|
-
// Texture Encodings
|
|
305
|
-
export enum TextureEncoding {}
|
|
306
|
-
export const LinearEncoding: TextureEncoding;
|
|
307
|
-
export const sRGBEncoding: TextureEncoding;
|
|
308
|
-
|
|
309
|
-
// Depth packing strategies
|
|
310
|
-
export enum DepthPackingStrategies {}
|
|
311
|
-
export const BasicDepthPacking: DepthPackingStrategies;
|
|
312
|
-
export const RGBADepthPacking: DepthPackingStrategies;
|
|
313
|
-
|
|
314
|
-
// Normal Map types
|
|
315
|
-
export enum NormalMapTypes {}
|
|
316
|
-
export const TangentSpaceNormalMap: NormalMapTypes;
|
|
317
|
-
export const ObjectSpaceNormalMap: NormalMapTypes;
|
|
318
|
-
|
|
319
|
-
export type ColorSpace = NoColorSpace | SRGBColorSpace | LinearSRGBColorSpace;
|
|
320
|
-
export type NoColorSpace = '';
|
|
321
|
-
export type SRGBColorSpace = 'srgb';
|
|
322
|
-
export type LinearSRGBColorSpace = 'srgb-linear';
|
|
323
|
-
|
|
324
|
-
// Stencil Op types
|
|
325
|
-
export enum StencilOp {}
|
|
326
|
-
export const ZeroStencilOp: StencilOp;
|
|
327
|
-
export const KeepStencilOp: StencilOp;
|
|
328
|
-
export const ReplaceStencilOp: StencilOp;
|
|
329
|
-
export const IncrementStencilOp: StencilOp;
|
|
330
|
-
export const DecrementStencilOp: StencilOp;
|
|
331
|
-
export const IncrementWrapStencilOp: StencilOp;
|
|
332
|
-
export const DecrementWrapStencilOp: StencilOp;
|
|
333
|
-
export const InvertStencilOp: StencilOp;
|
|
334
|
-
|
|
335
|
-
// Stencil Func types
|
|
336
|
-
export enum StencilFunc {}
|
|
337
|
-
export const NeverStencilFunc: StencilFunc;
|
|
338
|
-
export const LessStencilFunc: StencilFunc;
|
|
339
|
-
export const EqualStencilFunc: StencilFunc;
|
|
340
|
-
export const LessEqualStencilFunc: StencilFunc;
|
|
341
|
-
export const GreaterStencilFunc: StencilFunc;
|
|
342
|
-
export const NotEqualStencilFunc: StencilFunc;
|
|
343
|
-
export const GreaterEqualStencilFunc: StencilFunc;
|
|
344
|
-
export const AlwaysStencilFunc: StencilFunc;
|
|
345
|
-
|
|
346
|
-
// usage types
|
|
347
|
-
export enum Usage {}
|
|
348
|
-
export const StaticDrawUsage: Usage;
|
|
349
|
-
export const DynamicDrawUsage: Usage;
|
|
350
|
-
export const StreamDrawUsage: Usage;
|
|
351
|
-
export const StaticReadUsage: Usage;
|
|
352
|
-
export const DynamicReadUsage: Usage;
|
|
353
|
-
export const StreamReadUsage: Usage;
|
|
354
|
-
export const StaticCopyUsage: Usage;
|
|
355
|
-
export const DynamicCopyUsage: Usage;
|
|
356
|
-
export const StreamCopyUsage: Usage;
|
|
357
|
-
|
|
358
|
-
export enum GLSLVersion {}
|
|
359
|
-
export const GLSL1: GLSLVersion;
|
|
360
|
-
export const GLSL3: GLSLVersion;
|
|
361
|
-
|
|
362
502
|
export type BuiltinShaderAttributeName =
|
|
363
503
|
| 'position'
|
|
364
504
|
| 'normal'
|