Accurate OBB for GLTF (Oriented Bounding Box)

Try it like so: UZI demo - JSFiddle - Code Playground

The following line was wrong:

bbox.applyMatrix4(child.matrix);

If you setup the box for visualizing the OBB like in your app, it’s sufficient to just copy the OBB’s center to the box’s position property.

2 Likes