Possibility to load Ogre meshes as collision shapes?

katzenjoghurt

04-08-2007 13:21:35

Hi! :D

Topic says it. :)
Is there a built-in function to load Ogre meshes as collision shapes or are only primitives implemented?

I looked through the tutorials, the feature list and the forum ... but didn't find anything regarding this topic.

The only thing I found was the NxGenerateConvexMeshFromOgreMesh function... is there also one for that doesn't built a convex hull and simulates the model as is?

Is used ODE before, where I could load a complete building ... collision worked inside and... fps were still okay.
Is this possible with NXOgre too?

betajaen

04-08-2007 18:19:10

Your probably after the TriangleMesh shape, which converts an Ogre mesh into a triangle mesh into the scene. TriangleMeshs can only be in "static" actors/bodies though.

new TriangleMeshShape("NameOfOgre.mesh")

Anything dynamic should be put through a convex shape for an approximation of the model, or a compound of shapes.

katzenjoghurt

05-08-2007 01:37:38

Ahhh... thx, betajean!

That's exactly what I was missing when overlooking the wrappers capabilities... so... wow... great! I'll have a closer look at it tomorrow. :)