In Ogre, there's a class Ogre::Box
that looks like it can support a three-dimensional box. However, this class is using a size_t
data type for storage of its coordinates. Since size_t
is essentially an unsigned integer, it cannot handle negative numbers, and so using it for any real geometry is not possible. I know I can just keep a few numbers or invent a homebrew box class by myself, but what is the usual Ogre way of doing this? Also, I don't care if the box is using integers or floats for storage, it just happens so that it doesn't matter for the task at hand.
You can have a look at Ogre::AxisAlignedBox. If you are looking for a class representing a cube as mesh, you won't find it. However, there is a convenience class which creates an Ogre::Mesh
for you: Ogre::PrefabFactory
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With