@types/three 0.164.1 → 0.166.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 +1 -1
- three/examples/jsm/controls/TransformControls.d.ts +8 -6
- three/examples/jsm/exporters/GLTFExporter.d.ts +6 -0
- three/examples/jsm/exporters/USDZExporter.d.ts +4 -2
- three/examples/jsm/geometries/TeapotGeometry.d.ts +24 -0
- three/examples/jsm/helpers/ViewHelper.d.ts +8 -6
- three/examples/jsm/lines/LineMaterial.d.ts +2 -4
- three/examples/jsm/loaders/DDSLoader.d.ts +8 -2
- three/examples/jsm/loaders/FontLoader.d.ts +1 -1
- three/examples/jsm/loaders/GLTFLoader.d.ts +12 -7
- three/examples/jsm/loaders/KTXLoader.d.ts +8 -2
- three/examples/jsm/loaders/LDrawLoader.d.ts +1 -1
- three/examples/jsm/loaders/PVRLoader.d.ts +2 -2
- three/examples/jsm/modifiers/EdgeSplitModifier.d.ts +17 -10
- three/examples/jsm/nodes/Nodes.d.ts +21 -57
- three/examples/jsm/nodes/accessors/BitangentNode.d.ts +4 -22
- three/examples/jsm/nodes/accessors/BufferAttributeNode.d.ts +50 -0
- three/examples/jsm/nodes/accessors/BufferNode.d.ts +3 -4
- three/examples/jsm/nodes/accessors/CameraNode.d.ts +11 -20
- three/examples/jsm/nodes/accessors/CubeTextureNode.d.ts +1 -1
- three/examples/jsm/nodes/accessors/MaterialNode.d.ts +4 -1
- three/examples/jsm/nodes/accessors/ModelNode.d.ts +3 -0
- three/examples/jsm/nodes/accessors/ModelViewProjectionNode.d.ts +1 -2
- three/examples/jsm/nodes/accessors/NormalNode.d.ts +9 -17
- three/examples/jsm/nodes/accessors/PositionNode.d.ts +6 -26
- three/examples/jsm/nodes/accessors/ReferenceNode.d.ts +3 -4
- three/examples/jsm/nodes/accessors/ReflectVectorNode.d.ts +3 -8
- three/examples/jsm/nodes/accessors/RendererReferenceNode.d.ts +2 -3
- three/examples/jsm/nodes/accessors/StorageBufferNode.d.ts +16 -4
- three/examples/jsm/nodes/accessors/StorageTextureNode.d.ts +40 -0
- three/examples/jsm/nodes/accessors/TangentNode.d.ts +8 -23
- three/examples/jsm/nodes/accessors/Texture3DNode.d.ts +16 -0
- three/examples/jsm/nodes/accessors/TextureNode.d.ts +1 -1
- three/examples/jsm/nodes/accessors/UVNode.d.ts +1 -8
- three/examples/jsm/nodes/accessors/UniformsNode.d.ts +0 -2
- three/examples/jsm/nodes/accessors/UserDataNode.d.ts +4 -3
- three/examples/jsm/nodes/code/CodeNode.d.ts +0 -1
- three/examples/jsm/nodes/code/ExpressionNode.d.ts +2 -3
- three/examples/jsm/nodes/core/AttributeNode.d.ts +11 -4
- three/examples/jsm/nodes/core/CacheNode.d.ts +4 -5
- three/examples/jsm/nodes/core/ConstNode.d.ts +1 -2
- three/examples/jsm/nodes/core/InputNode.d.ts +1 -2
- three/examples/jsm/nodes/core/LightingModel.d.ts +11 -0
- three/examples/jsm/nodes/core/Node.d.ts +102 -42
- three/examples/jsm/nodes/core/NodeAttribute.d.ts +7 -4
- three/examples/jsm/nodes/core/NodeBuilder.d.ts +30 -26
- three/examples/jsm/nodes/core/NodeCache.d.ts +48 -6
- three/examples/jsm/nodes/core/NodeFunction.d.ts +2 -2
- three/examples/jsm/nodes/core/NodeKeywords.d.ts +10 -7
- three/examples/jsm/nodes/core/NodeParser.d.ts +4 -4
- three/examples/jsm/nodes/core/NodeUniform.d.ts +8 -11
- three/examples/jsm/nodes/core/NodeVar.d.ts +5 -4
- three/examples/jsm/nodes/core/NodeVarying.d.ts +5 -6
- three/examples/jsm/nodes/core/PropertyNode.d.ts +4 -4
- three/examples/jsm/nodes/core/StackNode.d.ts +7 -1
- three/examples/jsm/nodes/core/StructTypeNode.d.ts +8 -0
- three/examples/jsm/nodes/core/TempNode.d.ts +1 -2
- three/examples/jsm/nodes/core/UniformGroup.d.ts +7 -0
- three/examples/jsm/nodes/core/UniformGroupNode.d.ts +21 -0
- three/examples/jsm/nodes/core/UniformNode.d.ts +16 -11
- three/examples/jsm/nodes/core/VarNode.d.ts +2 -0
- three/examples/jsm/nodes/core/VaryingNode.d.ts +4 -0
- three/examples/jsm/nodes/core/constants.d.ts +27 -79
- three/examples/jsm/nodes/display/DepthOfFieldNode.d.ts +30 -0
- three/examples/jsm/nodes/display/DotScreenNode.d.ts +32 -0
- three/examples/jsm/nodes/display/PassNode.d.ts +1 -1
- three/examples/jsm/nodes/display/RGBShiftNode.d.ts +24 -0
- three/examples/jsm/nodes/display/SobelOperatorNode.d.ts +17 -0
- three/examples/jsm/nodes/display/ViewportDepthNode.d.ts +4 -6
- three/examples/jsm/nodes/functions/BSDF/LTC.d.ts +9 -0
- three/examples/jsm/nodes/functions/PhysicalLightingModel.d.ts +2 -0
- three/examples/jsm/nodes/functions/ToonLightingModel.d.ts +4 -0
- three/examples/jsm/nodes/lighting/RectAreaLightNode.d.ts +10 -0
- three/examples/jsm/nodes/loaders/NodeLoader.d.ts +3 -3
- three/examples/jsm/nodes/loaders/NodeObjectLoader.d.ts +2 -3
- three/examples/jsm/nodes/materials/LineBasicNodeMaterial.d.ts +2 -0
- three/examples/jsm/nodes/materials/Materials.d.ts +3 -0
- three/examples/jsm/nodes/materials/MeshBasicNodeMaterial.d.ts +5 -1
- three/examples/jsm/nodes/materials/MeshMatcapNodeMaterial.d.ts +28 -0
- three/examples/jsm/nodes/materials/MeshNormalNodeMaterial.d.ts +2 -0
- three/examples/jsm/nodes/materials/MeshPhongNodeMaterial.d.ts +7 -4
- three/examples/jsm/nodes/materials/MeshPhysicalNodeMaterial.d.ts +24 -17
- three/examples/jsm/nodes/materials/MeshSSSNodeMaterial.d.ts +6 -7
- three/examples/jsm/nodes/materials/MeshStandardNodeMaterial.d.ts +8 -5
- three/examples/jsm/nodes/materials/MeshToonNodeMaterial.d.ts +38 -0
- three/examples/jsm/nodes/materials/NodeMaterial.d.ts +41 -37
- three/examples/jsm/nodes/materials/PointsNodeMaterial.d.ts +1 -0
- three/examples/jsm/nodes/materials/ShadowNodeMaterial.d.ts +1 -0
- three/examples/jsm/nodes/materials/SpriteNodeMaterial.d.ts +3 -3
- three/examples/jsm/nodes/materials/VolumeNodeMaterial.d.ts +10 -0
- three/examples/jsm/nodes/materialx/lib/mx_hsv.d.ts +1 -0
- three/examples/jsm/nodes/materialx/lib/mx_noise.d.ts +230 -0
- three/examples/jsm/nodes/math/MathNode.d.ts +5 -1
- three/examples/jsm/nodes/shadernode/ShaderNode.d.ts +58 -36
- three/examples/jsm/nodes/utils/ConvertNode.d.ts +2 -3
- three/examples/jsm/nodes/utils/DiscardNode.d.ts +1 -0
- three/examples/jsm/nodes/utils/EquirectUVNode.d.ts +2 -2
- three/examples/jsm/nodes/utils/SplitNode.d.ts +1 -1
- three/examples/jsm/nodes/utils/TriplanarTexturesNode.d.ts +4 -5
- three/examples/jsm/objects/Sky.d.ts +18 -0
- three/examples/jsm/renderers/common/Animation.d.ts +14 -0
- three/examples/jsm/renderers/common/Attributes.d.ts +20 -0
- three/examples/jsm/renderers/common/Background.d.ts +22 -0
- three/examples/jsm/renderers/common/BindGroup.d.ts +9 -0
- three/examples/jsm/renderers/common/Binding.d.ts +8 -0
- three/examples/jsm/renderers/common/Bindings.d.ts +42 -0
- three/examples/jsm/renderers/common/Buffer.d.ts +11 -0
- three/examples/jsm/renderers/common/BufferUtils.d.ts +4 -0
- three/examples/jsm/renderers/common/ChainMap.d.ts +9 -0
- three/examples/jsm/renderers/common/ClippingContext.d.ts +18 -0
- three/examples/jsm/renderers/common/Color4.d.ts +6 -5
- three/examples/jsm/renderers/common/ComputePipeline.d.ts +8 -0
- three/examples/jsm/renderers/common/Constants.d.ts +9 -0
- three/examples/jsm/renderers/common/CubeRenderTarget.d.ts +7 -0
- three/examples/jsm/renderers/common/DataMap.d.ts +20 -0
- three/examples/jsm/renderers/common/Geometries.d.ts +28 -0
- three/examples/jsm/renderers/common/Info.d.ts +25 -13
- three/examples/jsm/renderers/common/Pipeline.d.ts +6 -0
- three/examples/jsm/renderers/common/Pipelines.d.ts +68 -0
- three/examples/jsm/renderers/common/PostProcessing.d.ts +2 -0
- three/examples/jsm/renderers/common/ProgrammableStage.d.ts +15 -0
- three/examples/jsm/renderers/common/RenderBundle.d.ts +8 -0
- three/examples/jsm/renderers/common/RenderBundles.d.ts +10 -0
- three/examples/jsm/renderers/common/RenderContext.d.ts +38 -0
- three/examples/jsm/renderers/common/RenderContexts.d.ts +13 -0
- three/examples/jsm/renderers/common/RenderList.d.ts +62 -0
- three/examples/jsm/renderers/common/RenderLists.d.ts +10 -0
- three/examples/jsm/renderers/common/RenderObject.d.ts +73 -0
- three/examples/jsm/renderers/common/RenderObjects.d.ts +59 -0
- three/examples/jsm/renderers/common/RenderPipeline.d.ts +8 -0
- three/examples/jsm/renderers/common/Renderer.d.ts +186 -208
- three/examples/jsm/renderers/common/SampledTexture.d.ts +27 -0
- three/examples/jsm/renderers/common/Sampler.d.ts +11 -0
- three/examples/jsm/renderers/common/StorageBufferAttribute.d.ts +7 -0
- three/examples/jsm/renderers/common/StorageInstancedBufferAttribute.d.ts +7 -0
- three/examples/jsm/renderers/common/Textures.d.ts +64 -0
- three/examples/jsm/renderers/common/Uniform.d.ts +40 -0
- three/examples/jsm/renderers/common/UniformBuffer.d.ts +6 -0
- three/examples/jsm/renderers/common/UniformsGroup.d.ts +32 -0
- three/examples/jsm/renderers/common/nodes/NodeBuilderState.d.ts +30 -0
- three/examples/jsm/renderers/common/nodes/NodeSampledTexture.d.ts +29 -0
- three/examples/jsm/renderers/common/nodes/NodeSampler.d.ts +12 -0
- three/examples/jsm/renderers/common/nodes/NodeUniform.d.ts +63 -0
- three/examples/jsm/renderers/common/nodes/NodeUniformsGroup.d.ts +11 -0
- three/examples/jsm/renderers/common/nodes/Nodes.d.ts +95 -0
- three/examples/jsm/renderers/webgpu/nodes/WGSLNodeBuilder.d.ts +123 -0
- three/examples/jsm/renderers/webgpu/nodes/WGSLNodeFunction.d.ts +6 -0
- three/examples/jsm/renderers/webgpu/nodes/WGSLNodeParser.d.ts +6 -0
- three/examples/jsm/renderers/webgpu/utils/WebGPUConstants.d.ts +328 -0
- three/examples/jsm/utils/SceneUtils.d.ts +9 -3
- three/package.json +4 -4
- three/src/Three.d.ts +1 -0
- three/src/animation/tracks/StringKeyframeTrack.d.ts +1 -2
- three/src/constants.d.ts +6 -0
- three/src/core/BufferGeometry.d.ts +19 -17
- three/src/core/InterleavedBuffer.d.ts +2 -0
- three/src/extras/ShapeUtils.d.ts +5 -8
- three/src/extras/TextureUtils.d.ts +42 -0
- three/src/lights/LightShadow.d.ts +5 -0
- three/src/loaders/LoaderUtils.d.ts +9 -6
- three/src/materials/Material.d.ts +21 -12
- three/src/math/Color.d.ts +1 -1
- three/src/math/Matrix3.d.ts +2 -0
- three/src/math/Matrix4.d.ts +2 -0
- three/src/math/Vector4.d.ts +6 -0
- three/src/objects/BatchedMesh.d.ts +66 -47
- three/src/objects/InstancedMesh.d.ts +3 -3
- three/src/renderers/WebGLRenderer.d.ts +41 -19
- three/src/renderers/shaders/UniformsLib.d.ts +3 -0
- three/src/renderers/webgl/WebGLPrograms.d.ts +1 -1
- three/src/renderers/webxr/WebXRDepthSensing.d.ts +3 -1
- three/src/renderers/webxr/WebXRManager.d.ts +33 -23
- three/src/textures/CompressedArrayTexture.d.ts +36 -19
- three/src/textures/CompressedTexture.d.ts +16 -8
- three/src/textures/DataArrayTexture.d.ts +37 -20
- three/src/textures/FramebufferTexture.d.ts +1 -1
- three/src/textures/Texture.d.ts +3 -1
- three/src/utils.d.ts +2 -0
- three/examples/jsm/renderers/webgl/nodes/SlotNode.d.ts +0 -17
- three/examples/jsm/renderers/webgl/nodes/WebGLNodeBuilder.d.ts +0 -37
- three/examples/jsm/renderers/webgl/nodes/WebGLNodes.d.ts +0 -3
|
@@ -2,32 +2,43 @@ import { Camera } from "../cameras/Camera.js";
|
|
|
2
2
|
import { BufferGeometry } from "../core/BufferGeometry.js";
|
|
3
3
|
import { Material } from "../materials/Material.js";
|
|
4
4
|
import { Box3 } from "../math/Box3.js";
|
|
5
|
+
import { Color } from "../math/Color.js";
|
|
5
6
|
import { Matrix4 } from "../math/Matrix4.js";
|
|
6
7
|
import { Sphere } from "../math/Sphere.js";
|
|
7
8
|
import { Mesh } from "./Mesh.js";
|
|
8
9
|
|
|
9
10
|
/**
|
|
10
11
|
* A special version of {@link Mesh} with multi draw batch rendering support. Use {@link BatchedMesh} if you have to
|
|
11
|
-
* render a large number of objects with the same material but with different world transformations
|
|
12
|
-
*
|
|
12
|
+
* render a large number of objects with the same material but with different world transformations. The usage of
|
|
13
|
+
* {@link BatchedMesh} will help you to reduce the number of draw calls and thus improve the overall rendering
|
|
13
14
|
* performance in your application.
|
|
14
15
|
*
|
|
15
16
|
* If the {@link https://developer.mozilla.org/en-US/docs/Web/API/WEBGL_multi_draw WEBGL_multi_draw extension} is not
|
|
16
|
-
* supported then a less performant
|
|
17
|
+
* supported then a less performant fallback is used.
|
|
17
18
|
*
|
|
18
19
|
* @example
|
|
19
20
|
* const box = new THREE.BoxGeometry( 1, 1, 1 );
|
|
20
|
-
* const sphere = new THREE.
|
|
21
|
+
* const sphere = new THREE.SphereGeometry( 1, 12, 12 );
|
|
21
22
|
* const material = new THREE.MeshBasicMaterial( { color: 0x00ff00 } );
|
|
22
23
|
*
|
|
23
24
|
* // initialize and add geometries into the batched mesh
|
|
24
25
|
* const batchedMesh = new BatchedMesh( 10, 5000, 10000, material );
|
|
25
|
-
* const
|
|
26
|
-
* const
|
|
26
|
+
* const boxGeometryId = batchedMesh.addGeometry( box );
|
|
27
|
+
* const sphereGeometryId = batchedMesh.addGeometry( sphere );
|
|
28
|
+
*
|
|
29
|
+
* // create instances of those geometries
|
|
30
|
+
* const boxInstancedId1 = batchedMesh.addInstance( boxGeometryId );
|
|
31
|
+
* const boxInstancedId2 = batchedMesh.addInstance( boxGeometryId );
|
|
32
|
+
*
|
|
33
|
+
* const sphereInstancedId1 = batchedMesh.addInstance( sphereGeometryId );
|
|
34
|
+
* const sphereInstancedId2 = batchedMesh.addInstance( sphereGeometryId );
|
|
27
35
|
*
|
|
28
36
|
* // position the geometries
|
|
29
|
-
* batchedMesh.setMatrixAt(
|
|
30
|
-
* batchedMesh.setMatrixAt(
|
|
37
|
+
* batchedMesh.setMatrixAt( boxInstancedId1, boxMatrix1 );
|
|
38
|
+
* batchedMesh.setMatrixAt( boxInstancedId2, boxMatrix2 );
|
|
39
|
+
*
|
|
40
|
+
* batchedMesh.setMatrixAt( sphereInstancedId1, sphereMatrix1 );
|
|
41
|
+
* batchedMesh.setMatrixAt( sphereInstancedId2, sphereMatrix2 );
|
|
31
42
|
*
|
|
32
43
|
* scene.add( batchedMesh );
|
|
33
44
|
*
|
|
@@ -67,20 +78,20 @@ declare class BatchedMesh extends Mesh<BufferGeometry, Material> {
|
|
|
67
78
|
/**
|
|
68
79
|
* The maximum number of individual geometries that can be stored in the {@link BatchedMesh}. Read only.
|
|
69
80
|
*/
|
|
70
|
-
get
|
|
81
|
+
get maxInstanceCount(): number;
|
|
71
82
|
|
|
72
83
|
/**
|
|
73
84
|
* Read-only flag to check if a given object is of type {@link BatchedMesh}.
|
|
74
85
|
*/
|
|
75
|
-
isBatchedMesh: true;
|
|
86
|
+
readonly isBatchedMesh: true;
|
|
76
87
|
|
|
77
88
|
/**
|
|
78
|
-
* @param
|
|
89
|
+
* @param maxInstanceCount the max number of individual geometries planned to be added.
|
|
79
90
|
* @param maxVertexCount the max number of vertices to be used by all geometries.
|
|
80
91
|
* @param maxIndexCount the max number of indices to be used by all geometries.
|
|
81
|
-
* @param material an instance of
|
|
92
|
+
* @param material an instance of {@link Material}. Default is a new {@link MeshBasicMaterial}.
|
|
82
93
|
*/
|
|
83
|
-
constructor(
|
|
94
|
+
constructor(maxInstanceCount: number, maxVertexCount: number, maxIndexCount?: number, material?: Material);
|
|
84
95
|
|
|
85
96
|
/**
|
|
86
97
|
* Computes the bounding box, updating {@link .boundingBox} attribute.
|
|
@@ -101,40 +112,55 @@ declare class BatchedMesh extends Mesh<BufferGeometry, Material> {
|
|
|
101
112
|
dispose(): this;
|
|
102
113
|
|
|
103
114
|
/**
|
|
104
|
-
* Takes a sort a function that is run before render. The function takes a list of
|
|
105
|
-
* objects in the list include a "z" field to perform a depth-ordered sort with.
|
|
115
|
+
* Takes a sort a function that is run before render. The function takes a list of instances to sort and a camera.
|
|
116
|
+
* The objects in the list include a "z" field to perform a depth-ordered sort with.
|
|
106
117
|
*/
|
|
107
118
|
setCustomSort(
|
|
108
|
-
|
|
119
|
+
sortFunction:
|
|
120
|
+
| ((this: this, list: Array<{ start: number; count: number; z: number }>, camera: Camera) => void)
|
|
121
|
+
| null,
|
|
109
122
|
): this;
|
|
110
123
|
|
|
124
|
+
/**
|
|
125
|
+
* Get the color of the defined geometry.
|
|
126
|
+
* @param instanceId The id of an instance to get the color of.
|
|
127
|
+
* @param target The target object to copy the color in to.
|
|
128
|
+
*/
|
|
129
|
+
getColorAt(instanceId: number, target: Color): void;
|
|
130
|
+
|
|
111
131
|
/**
|
|
112
132
|
* Get the local transformation matrix of the defined instance.
|
|
113
|
-
* @param
|
|
114
|
-
* @param
|
|
133
|
+
* @param instanceId The id of an instance to get the matrix of.
|
|
134
|
+
* @param target This 4x4 matrix will be set to the local transformation matrix of the defined instance.
|
|
115
135
|
*/
|
|
116
|
-
getMatrixAt(
|
|
136
|
+
getMatrixAt(instanceId: number, target: Matrix4): Matrix4;
|
|
117
137
|
|
|
118
138
|
/**
|
|
119
139
|
* Get whether the given instance is marked as "visible" or not.
|
|
120
|
-
* @param
|
|
140
|
+
* @param instanceId The id of an instance to get the visibility state of.
|
|
121
141
|
*/
|
|
122
|
-
getVisibleAt(
|
|
142
|
+
getVisibleAt(instanceId: number): boolean;
|
|
123
143
|
|
|
124
144
|
/**
|
|
125
|
-
* Sets the given
|
|
126
|
-
*
|
|
127
|
-
* @param
|
|
145
|
+
* Sets the given color to the defined geometry instance.
|
|
146
|
+
* @param instanceId The id of the instance to set the color of.
|
|
147
|
+
* @param color The color to set the instance to.
|
|
148
|
+
*/
|
|
149
|
+
setColorAt(instanceId: number, color: Color): void;
|
|
150
|
+
|
|
151
|
+
/**
|
|
152
|
+
* Sets the given local transformation matrix to the defined instance.
|
|
153
|
+
* @param instanceId The id of an instance to set the matrix of.
|
|
128
154
|
* @param matrix A 4x4 matrix representing the local transformation of a single instance.
|
|
129
155
|
*/
|
|
130
|
-
setMatrixAt(
|
|
156
|
+
setMatrixAt(instanceId: number, matrix: Matrix4): this;
|
|
131
157
|
|
|
132
158
|
/**
|
|
133
|
-
* Sets the visibility of the
|
|
134
|
-
* @param
|
|
159
|
+
* Sets the visibility of the instance at the given index.
|
|
160
|
+
* @param instanceId The id of the instance to set the visibility of.
|
|
135
161
|
* @param visible A boolean value indicating the visibility state.
|
|
136
162
|
*/
|
|
137
|
-
setVisibleAt(
|
|
163
|
+
setVisibleAt(instanceId: number, visible: boolean): this;
|
|
138
164
|
|
|
139
165
|
/**
|
|
140
166
|
* Adds the given geometry to the {@link BatchedMesh} and returns the associated index referring to it.
|
|
@@ -149,30 +175,23 @@ declare class BatchedMesh extends Mesh<BufferGeometry, Material> {
|
|
|
149
175
|
addGeometry(geometry: BufferGeometry, reservedVertexRange?: number, reservedIndexRange?: number): number;
|
|
150
176
|
|
|
151
177
|
/**
|
|
152
|
-
*
|
|
153
|
-
*
|
|
154
|
-
* @param
|
|
155
|
-
*
|
|
156
|
-
*/
|
|
157
|
-
setGeometryAt(index: number, geometry: BufferGeometry): number;
|
|
158
|
-
|
|
159
|
-
/**
|
|
160
|
-
* Gets the instance count of the geometry at `index`. Returns `null` if instance counts are not configured.
|
|
161
|
-
* @param index The index of an instance. Values have to be in the range [0, count].
|
|
178
|
+
* Adds a new instance to the {@link BatchedMesh} using the geometry of the given geometryId and returns a new id
|
|
179
|
+
* referring to the new instance to be used by other functions.
|
|
180
|
+
* @param geometryId The id of a previously added geometry via "addGeometry" to add into the {@link BatchedMesh} to
|
|
181
|
+
* render.
|
|
162
182
|
*/
|
|
163
|
-
|
|
183
|
+
addInstance(geometryId: number): number;
|
|
164
184
|
|
|
165
185
|
/**
|
|
166
|
-
*
|
|
167
|
-
*
|
|
168
|
-
* @param
|
|
186
|
+
* Replaces the geometry at `geometryId` with the provided geometry. Throws an error if there is not enough space
|
|
187
|
+
* reserved for geometry. Calling this will change all instances that are rendering that geometry.
|
|
188
|
+
* @param geometryId Which geometry id to replace with this geometry.
|
|
189
|
+
* @param geometry The geometry to substitute at the given geometry id.
|
|
169
190
|
*/
|
|
170
|
-
|
|
171
|
-
|
|
172
|
-
deleteGeometry(index: number): this;
|
|
191
|
+
setGeometryAt(geometryId: number, geometry: BufferGeometry): number;
|
|
173
192
|
|
|
174
|
-
getBoundingBoxAt(
|
|
175
|
-
getBoundingSphereAt(
|
|
193
|
+
getBoundingBoxAt(geometryId: number, target: Box3): Box3 | null;
|
|
194
|
+
getBoundingSphereAt(geometryId: number, target: Sphere): Sphere | null;
|
|
176
195
|
}
|
|
177
196
|
|
|
178
197
|
export { BatchedMesh };
|
|
@@ -16,7 +16,7 @@ export interface InstancedMeshEventMap extends Object3DEventMap {
|
|
|
16
16
|
/**
|
|
17
17
|
* A special version of {@link THREE.Mesh | Mesh} with instanced rendering support
|
|
18
18
|
* @remarks
|
|
19
|
-
* Use {@link InstancedMesh} if you have to render a large number of objects with the same geometry and material but with different world transformations
|
|
19
|
+
* Use {@link InstancedMesh} if you have to render a large number of objects with the same geometry and material(s) but with different world transformations
|
|
20
20
|
* @remarks
|
|
21
21
|
* The usage of {@link InstancedMesh} will help you to reduce the number of draw calls and thus improve the overall rendering performance in your application.
|
|
22
22
|
* @see Example: {@link https://threejs.org/examples/#webgl_instancing_dynamic | WebGL / instancing / dynamic}
|
|
@@ -33,8 +33,8 @@ export class InstancedMesh<
|
|
|
33
33
|
> extends Mesh<TGeometry, TMaterial, TEventMap> {
|
|
34
34
|
/**
|
|
35
35
|
* Create a new instance of {@link InstancedMesh}
|
|
36
|
-
* @param geometry An instance of {@link
|
|
37
|
-
* @param material A single or an array of {@link
|
|
36
|
+
* @param geometry An instance of {@link BufferGeometry}.
|
|
37
|
+
* @param material A single or an array of {@link Material}. Default is a new {@link MeshBasicMaterial}.
|
|
38
38
|
* @param count The **maximum** number of instances of this Mesh. Expects a `Integer`
|
|
39
39
|
*/
|
|
40
40
|
constructor(geometry: TGeometry | undefined, material: TMaterial | undefined, count: number);
|
|
@@ -1,8 +1,10 @@
|
|
|
1
1
|
import { Camera } from "../cameras/Camera.js";
|
|
2
2
|
import { ColorSpace, CullFace, ShadowMapType, ToneMapping, WebGLCoordinateSystem } from "../constants.js";
|
|
3
|
+
import { TypedArray } from "../core/BufferAttribute.js";
|
|
3
4
|
import { BufferGeometry } from "../core/BufferGeometry.js";
|
|
4
5
|
import { Object3D } from "../core/Object3D.js";
|
|
5
6
|
import { Material } from "../materials/Material.js";
|
|
7
|
+
import { Box2 } from "../math/Box2.js";
|
|
6
8
|
import { Box3 } from "../math/Box3.js";
|
|
7
9
|
import { Color, ColorRepresentation } from "../math/Color.js";
|
|
8
10
|
import { Plane } from "../math/Plane.js";
|
|
@@ -125,7 +127,7 @@ export interface WebGLDebug {
|
|
|
125
127
|
*/
|
|
126
128
|
export class WebGLRenderer implements Renderer {
|
|
127
129
|
/**
|
|
128
|
-
* parameters is an optional object with properties defining the renderer's
|
|
130
|
+
* parameters is an optional object with properties defining the renderer's behavior.
|
|
129
131
|
* The constructor also accepts no parameters at all.
|
|
130
132
|
* In all cases, it will assume sane defaults when parameters are missing.
|
|
131
133
|
*/
|
|
@@ -196,13 +198,6 @@ export class WebGLRenderer implements Renderer {
|
|
|
196
198
|
|
|
197
199
|
get coordinateSystem(): typeof WebGLCoordinateSystem;
|
|
198
200
|
|
|
199
|
-
/**
|
|
200
|
-
* @deprecated Migrate your lighting according to the following guide:
|
|
201
|
-
* https://discourse.threejs.org/t/updates-to-lighting-in-three-js-r155/53733.
|
|
202
|
-
* @default true
|
|
203
|
-
*/
|
|
204
|
-
useLegacyLights: boolean;
|
|
205
|
-
|
|
206
201
|
/**
|
|
207
202
|
* @default THREE.NoToneMapping
|
|
208
203
|
*/
|
|
@@ -421,46 +416,73 @@ export class WebGLRenderer implements Renderer {
|
|
|
421
416
|
y: number,
|
|
422
417
|
width: number,
|
|
423
418
|
height: number,
|
|
424
|
-
buffer:
|
|
419
|
+
buffer: TypedArray,
|
|
425
420
|
activeCubeFaceIndex?: number,
|
|
426
421
|
): void;
|
|
427
422
|
|
|
423
|
+
readRenderTargetPixelsAsync(
|
|
424
|
+
renderTarget: WebGLRenderTarget | WebGLRenderTarget<Texture[]>,
|
|
425
|
+
x: number,
|
|
426
|
+
y: number,
|
|
427
|
+
width: number,
|
|
428
|
+
height: number,
|
|
429
|
+
buffer: TypedArray,
|
|
430
|
+
activeCubeFaceIndex?: number,
|
|
431
|
+
): Promise<TypedArray>;
|
|
432
|
+
|
|
428
433
|
/**
|
|
429
434
|
* Copies a region of the currently bound framebuffer into the selected mipmap level of the selected texture.
|
|
430
435
|
* This region is defined by the size of the destination texture's mip level, offset by the input position.
|
|
431
436
|
*
|
|
432
|
-
* @param position Specifies the pixel offset from which to copy out of the framebuffer.
|
|
433
437
|
* @param texture Specifies the destination texture.
|
|
438
|
+
* @param position Specifies the pixel offset from which to copy out of the framebuffer.
|
|
434
439
|
* @param level Specifies the destination mipmap level of the texture.
|
|
435
440
|
*/
|
|
436
|
-
copyFramebufferToTexture(
|
|
441
|
+
copyFramebufferToTexture(texture: Texture, position?: Vector2 | null, level?: number): void;
|
|
437
442
|
|
|
438
443
|
/**
|
|
439
|
-
* Copies
|
|
444
|
+
* Copies the pixels of a texture in the bounds `srcRegion` in the destination texture starting from the given
|
|
445
|
+
* position.
|
|
440
446
|
*
|
|
441
|
-
* @param position Specifies the pixel offset into the dstTexture where the copy will occur.
|
|
442
447
|
* @param srcTexture Specifies the source texture.
|
|
443
448
|
* @param dstTexture Specifies the destination texture.
|
|
449
|
+
* @param srcRegion Specifies the bounds
|
|
450
|
+
* @param dstPosition Specifies the pixel offset into the dstTexture where the copy will occur.
|
|
444
451
|
* @param level Specifies the destination mipmap level of the texture.
|
|
445
452
|
*/
|
|
446
|
-
copyTextureToTexture(
|
|
453
|
+
copyTextureToTexture(
|
|
454
|
+
srcTexture: Texture,
|
|
455
|
+
dstTexture: Texture,
|
|
456
|
+
srcRegion?: Box2 | null,
|
|
457
|
+
dstPosition?: Vector2 | null,
|
|
458
|
+
level?: number,
|
|
459
|
+
): void;
|
|
447
460
|
|
|
448
461
|
/**
|
|
449
|
-
* Copies the pixels of a texture in the bounds
|
|
450
|
-
*
|
|
451
|
-
*
|
|
462
|
+
* Copies the pixels of a texture in the bounds `srcRegion` in the destination texture starting from the given
|
|
463
|
+
* position.
|
|
464
|
+
*
|
|
452
465
|
* @param srcTexture Specifies the source texture.
|
|
453
466
|
* @param dstTexture Specifies the destination texture.
|
|
467
|
+
* @param srcRegion Specifies the bounds
|
|
468
|
+
* @param dstPosition Specifies the pixel offset into the dstTexture where the copy will occur.
|
|
454
469
|
* @param level Specifies the destination mipmap level of the texture.
|
|
455
470
|
*/
|
|
456
471
|
copyTextureToTexture3D(
|
|
457
|
-
sourceBox: Box3,
|
|
458
|
-
position: Vector3,
|
|
459
472
|
srcTexture: Texture,
|
|
460
473
|
dstTexture: Data3DTexture | DataArrayTexture,
|
|
474
|
+
srcRegion?: Box3 | null,
|
|
475
|
+
dstPosition?: Vector3 | null,
|
|
461
476
|
level?: number,
|
|
462
477
|
): void;
|
|
463
478
|
|
|
479
|
+
/**
|
|
480
|
+
* Initializes the given WebGLRenderTarget memory. Useful for initializing a render target so data can be copied
|
|
481
|
+
* into it using {@link WebGLRenderer.copyTextureToTexture} before it has been rendered to.
|
|
482
|
+
* @param target
|
|
483
|
+
*/
|
|
484
|
+
initRenderTarget(target: WebGLRenderTarget): void;
|
|
485
|
+
|
|
464
486
|
/**
|
|
465
487
|
* Initializes the given texture. Can be used to preload a texture rather than waiting until first render (which can cause noticeable lags due to decode and GPU upload overhead).
|
|
466
488
|
*
|
|
@@ -89,6 +89,7 @@ export const UniformsLib: {
|
|
|
89
89
|
directionalLightShadows: {
|
|
90
90
|
value: unknown[];
|
|
91
91
|
properties: {
|
|
92
|
+
shadowIntensity: number;
|
|
92
93
|
shadowBias: {};
|
|
93
94
|
shadowNormalBias: {};
|
|
94
95
|
shadowRadius: {};
|
|
@@ -112,6 +113,7 @@ export const UniformsLib: {
|
|
|
112
113
|
spotLightShadows: {
|
|
113
114
|
value: unknown[];
|
|
114
115
|
properties: {
|
|
116
|
+
shadowIntensity: number;
|
|
115
117
|
shadowBias: {};
|
|
116
118
|
shadowNormalBias: {};
|
|
117
119
|
shadowRadius: {};
|
|
@@ -133,6 +135,7 @@ export const UniformsLib: {
|
|
|
133
135
|
pointLightShadows: {
|
|
134
136
|
value: unknown[];
|
|
135
137
|
properties: {
|
|
138
|
+
shadowIntensity: number;
|
|
136
139
|
shadowBias: {};
|
|
137
140
|
shadowNormalBias: {};
|
|
138
141
|
shadowRadius: {};
|
|
@@ -39,6 +39,7 @@ export interface WebGLProgramParameters {
|
|
|
39
39
|
precision: "lowp" | "mediump" | "highp";
|
|
40
40
|
|
|
41
41
|
batching: boolean;
|
|
42
|
+
batchingColor: boolean;
|
|
42
43
|
instancing: boolean;
|
|
43
44
|
instancingColor: boolean;
|
|
44
45
|
instancingMorph: boolean;
|
|
@@ -186,7 +187,6 @@ export interface WebGLProgramParameters {
|
|
|
186
187
|
shadowMapType: ShadowMapType;
|
|
187
188
|
|
|
188
189
|
toneMapping: ToneMapping;
|
|
189
|
-
useLegacyLights: boolean;
|
|
190
190
|
|
|
191
191
|
decodeVideoTexture: boolean;
|
|
192
192
|
|
|
@@ -21,7 +21,9 @@ export class WebXRDepthSensing {
|
|
|
21
21
|
|
|
22
22
|
init(renderer: WebGLRenderer, depthData: XRWebGLDepthInformation, renderState: XRRenderState): void;
|
|
23
23
|
|
|
24
|
-
|
|
24
|
+
getMesh(cameraXR: WebXRArrayCamera): Mesh | null;
|
|
25
25
|
|
|
26
26
|
reset(): void;
|
|
27
|
+
|
|
28
|
+
getDepthTexture(): Texture | null;
|
|
27
29
|
}
|
|
@@ -6,6 +6,8 @@ import { ArrayCamera } from "../../cameras/ArrayCamera.js";
|
|
|
6
6
|
import { PerspectiveCamera } from "../../cameras/PerspectiveCamera.js";
|
|
7
7
|
import { EventDispatcher } from "../../core/EventDispatcher.js";
|
|
8
8
|
import { Vector4 } from "../../math/Vector4.js";
|
|
9
|
+
import { Mesh } from "../../objects/Mesh.js";
|
|
10
|
+
import { Texture } from "../../textures/Texture.js";
|
|
9
11
|
import { WebGLRenderer } from "../WebGLRenderer.js";
|
|
10
12
|
import { XRGripSpace, XRHandSpace, XRTargetRaySpace } from "./WebXRController.js";
|
|
11
13
|
|
|
@@ -22,7 +24,10 @@ export interface WebXRManagerEventMap {
|
|
|
22
24
|
}
|
|
23
25
|
|
|
24
26
|
export class WebXRManager extends EventDispatcher<WebXRManagerEventMap> {
|
|
25
|
-
|
|
27
|
+
/**
|
|
28
|
+
* @default true
|
|
29
|
+
*/
|
|
30
|
+
cameraAutoUpdate: boolean;
|
|
26
31
|
|
|
27
32
|
/**
|
|
28
33
|
* @default false
|
|
@@ -34,44 +39,49 @@ export class WebXRManager extends EventDispatcher<WebXRManagerEventMap> {
|
|
|
34
39
|
*/
|
|
35
40
|
isPresenting: boolean;
|
|
36
41
|
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
42
|
+
constructor(renderer: WebGLRenderer, gl: WebGLRenderingContext);
|
|
43
|
+
|
|
44
|
+
getController: (index: number) => XRTargetRaySpace;
|
|
45
|
+
|
|
46
|
+
getControllerGrip: (index: number) => XRGripSpace;
|
|
47
|
+
|
|
48
|
+
getHand: (index: number) => XRHandSpace;
|
|
49
|
+
|
|
50
|
+
setFramebufferScaleFactor: (value: number) => void;
|
|
41
51
|
|
|
42
|
-
|
|
52
|
+
setReferenceSpaceType: (value: XRReferenceSpaceType) => void;
|
|
43
53
|
|
|
44
|
-
|
|
54
|
+
getReferenceSpace: () => XRReferenceSpace | null;
|
|
45
55
|
|
|
46
|
-
|
|
56
|
+
setReferenceSpace: (value: XRReferenceSpace) => void;
|
|
47
57
|
|
|
48
|
-
|
|
58
|
+
getBaseLayer: () => XRWebGLLayer | XRProjectionLayer;
|
|
49
59
|
|
|
50
|
-
|
|
60
|
+
getBinding: () => XRWebGLBinding;
|
|
51
61
|
|
|
52
|
-
|
|
62
|
+
getFrame: () => XRFrame;
|
|
53
63
|
|
|
54
|
-
|
|
64
|
+
getSession: () => XRSession | null;
|
|
55
65
|
|
|
56
|
-
|
|
66
|
+
setSession: (value: XRSession | null) => Promise<void>;
|
|
57
67
|
|
|
58
|
-
|
|
68
|
+
getEnvironmentBlendMode: () => XREnvironmentBlendMode | undefined;
|
|
59
69
|
|
|
60
|
-
|
|
70
|
+
getDepthTexture: () => Texture | null;
|
|
61
71
|
|
|
62
|
-
|
|
72
|
+
updateCamera: (camera: PerspectiveCamera) => void;
|
|
63
73
|
|
|
64
|
-
|
|
74
|
+
getCamera: () => WebXRArrayCamera;
|
|
65
75
|
|
|
66
|
-
|
|
76
|
+
getFoveation: () => number | undefined;
|
|
67
77
|
|
|
68
|
-
|
|
78
|
+
setFoveation: (value: number) => void;
|
|
69
79
|
|
|
70
|
-
|
|
80
|
+
hasDepthSensing: () => boolean;
|
|
71
81
|
|
|
72
|
-
|
|
82
|
+
getDepthSensingMesh: () => Mesh | null;
|
|
73
83
|
|
|
74
|
-
|
|
84
|
+
setAnimationLoop: (callback: XRFrameRequestCallback | null) => void;
|
|
75
85
|
|
|
76
|
-
dispose()
|
|
86
|
+
dispose: () => void;
|
|
77
87
|
}
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { CompressedPixelFormat, TextureDataType, Wrapping } from "../constants.js";
|
|
2
|
-
import { CompressedTexture } from "./CompressedTexture.js";
|
|
2
|
+
import { CompressedTexture, CompressedTextureMipmap } from "./CompressedTexture.js";
|
|
3
3
|
|
|
4
4
|
/**
|
|
5
5
|
* Creates an texture 2D array based on data in compressed form, for example from a
|
|
@@ -9,10 +9,36 @@ import { CompressedTexture } from "./CompressedTexture.js";
|
|
|
9
9
|
* @see {@link https://github.com/mrdoob/three.js/blob/master/src/textures/CompressedArrayTexture.js | Source}
|
|
10
10
|
*/
|
|
11
11
|
export class CompressedArrayTexture extends CompressedTexture {
|
|
12
|
+
/**
|
|
13
|
+
* Read-only flag to check if a given object is of type {@link CompressedArrayTexture}.
|
|
14
|
+
* @remarks This is a _constant_ value
|
|
15
|
+
* @defaultValue `true`
|
|
16
|
+
*/
|
|
17
|
+
readonly isCompressedArrayTexture: true;
|
|
18
|
+
|
|
19
|
+
/**
|
|
20
|
+
* Overridden with a object containing width and height.
|
|
21
|
+
* @override
|
|
22
|
+
*/
|
|
23
|
+
get image(): { width: number; height: number; depth: number };
|
|
24
|
+
set image(value: { width: number; height: number; depth: number });
|
|
25
|
+
|
|
26
|
+
/**
|
|
27
|
+
* This defines how the texture is wrapped in the depth direction.
|
|
28
|
+
* @see {@link https://threejs.org/docs/index.html#api/en/constants/Textures | Texture Constants}
|
|
29
|
+
* @defaultValue {@link THREE.ClampToEdgeWrapping}
|
|
30
|
+
*/
|
|
31
|
+
wrapR: Wrapping;
|
|
32
|
+
|
|
33
|
+
/**
|
|
34
|
+
* A set of all layers which need to be updated in the texture. See {@link CompressedArrayTexture.addLayerUpdate}.
|
|
35
|
+
*/
|
|
36
|
+
layerUpdates: Set<number>;
|
|
37
|
+
|
|
12
38
|
/**
|
|
13
39
|
* Create a new instance of {@link CompressedArrayTexture}
|
|
14
|
-
* @param mipmaps The mipmaps array should contain objects with data, width and height.
|
|
15
|
-
*
|
|
40
|
+
* @param mipmaps The mipmaps array should contain objects with data, width and height. The mipmaps should be of the
|
|
41
|
+
* correct format and type.
|
|
16
42
|
* @param width The width of the biggest mipmap.
|
|
17
43
|
* @param height The height of the biggest mipmap.
|
|
18
44
|
* @param depth The number of layers of the 2D array texture
|
|
@@ -20,7 +46,7 @@ export class CompressedArrayTexture extends CompressedTexture {
|
|
|
20
46
|
* @param type See {@link Texture.type | .type}. Default {@link THREE.UnsignedByteType}
|
|
21
47
|
*/
|
|
22
48
|
constructor(
|
|
23
|
-
mipmaps:
|
|
49
|
+
mipmaps: CompressedTextureMipmap[],
|
|
24
50
|
width: number,
|
|
25
51
|
height: number,
|
|
26
52
|
depth: number,
|
|
@@ -29,23 +55,14 @@ export class CompressedArrayTexture extends CompressedTexture {
|
|
|
29
55
|
);
|
|
30
56
|
|
|
31
57
|
/**
|
|
32
|
-
*
|
|
33
|
-
*
|
|
34
|
-
*
|
|
58
|
+
* Describes that a specific layer of the texture needs to be updated. Normally when {@link Texture.needsUpdate} is
|
|
59
|
+
* set to true, the entire compressed texture array is sent to the GPU. Marking specific layers will only transmit
|
|
60
|
+
* subsets of all mipmaps associated with a specific depth in the array which is often much more performant.
|
|
35
61
|
*/
|
|
36
|
-
|
|
62
|
+
addLayerUpdate(layerIndex: number): void;
|
|
37
63
|
|
|
38
64
|
/**
|
|
39
|
-
*
|
|
40
|
-
* @override
|
|
65
|
+
* Resets the layer updates registry. See {@link CompressedArrayTexture.addLayerUpdate}.
|
|
41
66
|
*/
|
|
42
|
-
|
|
43
|
-
set image(value: { width: number; height: number; depth: number });
|
|
44
|
-
|
|
45
|
-
/**
|
|
46
|
-
* This defines how the texture is wrapped in the depth direction.
|
|
47
|
-
* @see {@link https://threejs.org/docs/index.html#api/en/constants/Textures | Texture Constants}
|
|
48
|
-
* @defaultValue {@link THREE.ClampToEdgeWrapping}
|
|
49
|
-
*/
|
|
50
|
-
wrapR: Wrapping;
|
|
67
|
+
clearLayoutUpdates(): void;
|
|
51
68
|
}
|
|
@@ -7,8 +7,15 @@ import {
|
|
|
7
7
|
TextureDataType,
|
|
8
8
|
Wrapping,
|
|
9
9
|
} from "../constants.js";
|
|
10
|
+
import { TypedArray } from "../core/BufferAttribute.js";
|
|
10
11
|
import { Texture } from "./Texture.js";
|
|
11
12
|
|
|
13
|
+
export interface CompressedTextureMipmap {
|
|
14
|
+
data: TypedArray;
|
|
15
|
+
width: number;
|
|
16
|
+
height: number;
|
|
17
|
+
}
|
|
18
|
+
|
|
12
19
|
/**
|
|
13
20
|
* Creates a texture based on data in compressed form, for example from a {@link https://en.wikipedia.org/wiki/DirectDraw_Surface | DDS} file.
|
|
14
21
|
* @remarks For use with the {@link THREE.CompressedTextureLoader | CompressedTextureLoader}.
|
|
@@ -18,8 +25,8 @@ import { Texture } from "./Texture.js";
|
|
|
18
25
|
export class CompressedTexture extends Texture {
|
|
19
26
|
/**
|
|
20
27
|
* This creates a new {@link THREE.CompressedTexture | CompressedTexture} object.
|
|
21
|
-
* @param mipmaps The mipmaps array should contain objects with data, width and height.
|
|
22
|
-
*
|
|
28
|
+
* @param mipmaps The mipmaps array should contain objects with data, width and height. The mipmaps should be of the
|
|
29
|
+
* correct format and type.
|
|
23
30
|
* @param width The width of the biggest mipmap.
|
|
24
31
|
* @param height The height of the biggest mipmap.
|
|
25
32
|
* @param format The format used in the mipmaps. See {@link THREE.CompressedPixelFormat}.
|
|
@@ -33,10 +40,10 @@ export class CompressedTexture extends Texture {
|
|
|
33
40
|
* @param colorSpace See {@link Texture.colorSpace .colorSpace}. Default {@link NoColorSpace}
|
|
34
41
|
*/
|
|
35
42
|
constructor(
|
|
36
|
-
mipmaps
|
|
37
|
-
width
|
|
38
|
-
height
|
|
39
|
-
format
|
|
43
|
+
mipmaps?: CompressedTextureMipmap[],
|
|
44
|
+
width?: number,
|
|
45
|
+
height?: number,
|
|
46
|
+
format?: CompressedPixelFormat,
|
|
40
47
|
type?: TextureDataType,
|
|
41
48
|
mapping?: Mapping,
|
|
42
49
|
wrapS?: Wrapping,
|
|
@@ -62,9 +69,10 @@ export class CompressedTexture extends Texture {
|
|
|
62
69
|
set image(value: { width: number; height: number });
|
|
63
70
|
|
|
64
71
|
/**
|
|
65
|
-
* The mipmaps array should contain objects with data, width and height. The mipmaps should be of the correct
|
|
72
|
+
* The mipmaps array should contain objects with data, width and height. The mipmaps should be of the correct
|
|
73
|
+
* format and type.
|
|
66
74
|
*/
|
|
67
|
-
mipmaps:
|
|
75
|
+
mipmaps: CompressedTextureMipmap[] | undefined;
|
|
68
76
|
|
|
69
77
|
/**
|
|
70
78
|
* @override
|