Get sides of mesh's OBB bounding box

Hello,
there is some method to get the sides of a mesh’s OBB bounding box?
I know that mesh.getBoundingBoxInfo has the property vectors, but what I don’t know is which sides each of this vectors are representing and there isn’t any method of get an array that is a side of the bounding box (OBB in my case).

So, how can I get the sides?

Not directly but with minWorld and maxWorld you can easily rebuild the face you want right?

1 Like

Finding the optimal OBB in 3D is not an easy task. See for eg:

You could take all 8 points of the an AABB then translate them by the meshes rotation matrix. Which then will give you all 8 points in an approximate OBB.

1 Like

Indeed, but to me the aim of an OBB is to be “better” than the AABB in that it provides a smaller enclosing volume for your mesh.

If you take the AABB and simply rotates it for your OBB you’re better sticking with the AABB in the first place as it is easier to deal with.

1 Like

I answered with AABB in mind honestly but this may not have been the initial intent of @cpusam

Wow, so is it a hard problem? So, I will try rotate the AABB of mesh, because I don’t need so many precision.

1 Like

Then you would want to check out my post cpusam. Just make sure when you capture the boundingbox that your mesh is not rotated or anything prior so that your accuracy will be a little closer. Then just follow my steps above. There is a vectors parameter in the boundingData.boundingBox you can use, and then I assume you know how to apply a rotation matrix to a vector.

Ok man, I will follow your suggestion.
Thanks for you all people!