diff --git a/docs/api/en/core/BufferGeometry.html b/docs/api/en/core/BufferGeometry.html index 43630ef3bf4acb..477af4a6c75762 100644 --- a/docs/api/en/core/BufferGeometry.html +++ b/docs/api/en/core/BufferGeometry.html @@ -231,18 +231,16 @@

[method:BufferGeometry clone]()

[method:undefined computeBoundingBox]()

- Computes bounding box of the geometry, updating [page:.boundingBox] - attribute.
- Bounding boxes aren't computed by default. They need to be explicitly - computed, otherwise they are `null`. + Computes the bounding box of the geometry, and updates the [page:.boundingBox] attribute. + The bounding box is not computed by the engine; it must be computed by your app. + You may need to recompute the bounding box if the geometry vertices are modified.

[method:undefined computeBoundingSphere]()

- Computes bounding sphere of the geometry, updating [page:.boundingSphere] - attribute.
- Bounding spheres aren't computed by default. They need to be explicitly - computed, otherwise they are `null`. + Computes the bounding sphere of the geometry, and updates the [page:.boundingSphere] attribute. + The engine automatically computes the bounding sphere when it is needed, e.g., for ray casting or view frustum culling. + You may need to recompute the bounding sphere if the geometry vertices are modified.

[method:undefined computeTangents]()

diff --git a/docs/api/en/objects/InstancedMesh.html b/docs/api/en/objects/InstancedMesh.html index c880c77a90b2a8..c3fb76db5faa5a 100644 --- a/docs/api/en/objects/InstancedMesh.html +++ b/docs/api/en/objects/InstancedMesh.html @@ -94,17 +94,16 @@

Methods

[method:undefined computeBoundingBox]()

- Computes the bounding box, updating [page:.boundingBox] attribute.
- Bounding boxes aren't computed by default. They need to be explicitly - computed, otherwise they are `null`. + Computes the bounding box of the instanced mesh, and updates the [page:.boundingBox] attribute. + The bounding box is not computed by the engine; it must be computed by your app. + You may need to recompute the bounding box if an instance is transformed via [page:.setMatrixAt]().

[method:undefined computeBoundingSphere]()

- Computes the bounding sphere, updating [page:.boundingSphere] - attribute.
- Bounding spheres aren't computed by default. They need to be explicitly - computed, otherwise they are `null`. + Computes the bounding sphere of the instanced mesh, and updates the [page:.boundingSphere] attribute. + The engine automatically computes the bounding sphere when it is needed, e.g., for ray casting or view frustum culling. + You may need to recompute the bounding sphere if an instance is transformed via [page:.setMatrixAt]().

[method:undefined dispose]()

diff --git a/docs/api/en/objects/SkinnedMesh.html b/docs/api/en/objects/SkinnedMesh.html index f9ed6d4c229230..02c5f2f9cec8f4 100644 --- a/docs/api/en/objects/SkinnedMesh.html +++ b/docs/api/en/objects/SkinnedMesh.html @@ -151,20 +151,16 @@

[method:SkinnedMesh clone]()

[method:undefined computeBoundingBox]()

- Computes the bounding box, updating [page:.boundingBox] attribute.
- Bounding boxes aren't computed by default. They need to be explicitly - computed, otherwise they are `null`. If an instance of [name] is animated, - this method should be called per frame to compute a correct bounding box. + Computes the bounding box of the skinned mesh, and updates the [page:.boundingBox] attribute. + The bounding box is not computed by the engine; it must be computed by your app. + If the skinned mesh is animated, the bounding box should be recomputed per frame.

[method:undefined computeBoundingSphere]()

- Computes the bounding sphere, updating [page:.boundingSphere] - attribute.
- Bounding spheres aren't computed by default. They need to be explicitly - computed, otherwise they are `null`. If an instance of [name] is animated, - this method should be called per frame to compute a correct bounding - sphere. + Computes the bounding sphere of the skinned mesh, and updates the [page:.boundingSphere] attribute. + The bounding sphere is automatically computed by the engine when it is needed, e.g., for ray casting and view frustum culling. + If the skinned mesh is animated, the bounding sphere should be recomputed per frame.

[method:undefined normalizeSkinWeights]()

diff --git a/docs/manual/en/introduction/How-to-update-things.html b/docs/manual/en/introduction/How-to-update-things.html index 69bbd04d999903..7a28ac5bcfd17f 100644 --- a/docs/manual/en/introduction/How-to-update-things.html +++ b/docs/manual/en/introduction/How-to-update-things.html @@ -190,7 +190,6 @@

Examples

-

Cameras

A camera's position and target is updated automatically. If you need to change

@@ -216,5 +215,35 @@

Cameras

camera.updateProjectionMatrix();
+ +

InstancedMesh

+
+

+ `InstancedMesh` is a class for conveniently access instanced rendering in `three.js`. Certain library features like view frustum culling or + ray casting rely on up-to-date bounding volumes (bounding sphere and bounding box). Because of the way how `InstancedMesh` works, the class + has its own [page:InstancedMesh.boundingBox boundingBox] and [page:InstancedMesh.boundingSphere boundingSphere] properties that supersede + the bounding volumes on geometry level. +

+

+ Similar to geometries you have to recompute the bounding box and sphere whenever you change the underlying data. In context of `InstancedMesh`, that + happens when you transform instances via [page:InstancedMesh.setMatrixAt setMatrixAt](). You can use the same pattern like with geometries. +

+ +instancedMesh.computeBoundingBox(); +instancedMesh.computeBoundingSphere(); + + +
+ +

SkinnedMesh

+
+

+ `SkinnedMesh` follows the same principles like `InstancedMesh` in context of bounding volumes. Meaning the class has its own version of + [page:SkinnedMesh.boundingBox boundingBox] and [page:SkinnedMesh.boundingSphere boundingSphere] to correctly enclose animated meshes. + When calling `computeBoundingBox()` and `computeBoundingSphere()`, the class computes the respective bounding volumes based on the current + bone tranformation (or in other words the current animation state). +

+
+