From 249e041f75dcf2b75356e1283fdb40b5385f631d Mon Sep 17 00:00:00 2001 From: WestLangley Date: Tue, 18 Jan 2022 03:43:24 -0500 Subject: [PATCH] AABB clarification (#23125) --- docs/api/en/math/Box3.html | 6 +++--- src/math/Box3.js | 4 +++- 2 files changed, 6 insertions(+), 4 deletions(-) diff --git a/docs/api/en/math/Box3.html b/docs/api/en/math/Box3.html index 800b1325b04a3d..91566c818ae307 100644 --- a/docs/api/en/math/Box3.html +++ b/docs/api/en/math/Box3.html @@ -268,9 +268,9 @@

[method:this setFromObject]( [param:Object3D object] )

[page:Object3D object] - [page:Object3D] to compute the bounding box of.

- Computes the world-axis-aligned bounding box of an [page:Object3D] (including its children), - accounting for the object's, and children's, world transforms. - The function may result in a larger box than strictly necessary. + Computes a world-axis-aligned bounding box of an [page:Object3D] (including its children), + accounting for the object's, and children's, world transforms.

+ For computational efficiency, the computed bounding box may be larger than the minimal world-axis-aligned bounding box.

diff --git a/src/math/Box3.js b/src/math/Box3.js index 1a5e4ffd7f1254..8691ec647358a7 100644 --- a/src/math/Box3.js +++ b/src/math/Box3.js @@ -191,7 +191,9 @@ class Box3 { expandByObject( object ) { // Computes the world-axis-aligned bounding box of an object (including its children), - // accounting for both the object's, and children's, world transforms + // accounting for both the object's, and children's, world transforms. + + // For computational efficiency, the computed bounding box may be larger than the minimal world-axis-aligned bounding box. object.updateWorldMatrix( false, false );