FBX mesh and polysoup collision woes
by Mark Lacay · in Torque X 3D · 01/15/2009 (7:16 am) · 4 replies
Now that there is a forum specifically for Torque X 3D questions...
How does one implement collision detection on an arbitrary mesh? I have tried a number of things without success on an .fbx model and have yet to get it to register collisions. What gives?
What is the right way to do interiors in TX3D if not through .fbx and .x models?
How does one implement collision detection on an arbitrary mesh? I have tried a number of things without success on an .fbx model and have yet to get it to register collisions. What gives?
What is the right way to do interiors in TX3D if not through .fbx and .x models?
#2
Anyway, thanks for the great book. It's a good start to having complete Torque X documentation and more should be written like it.
01/15/2009 (1:13 pm)
Thanks for the info John. I thought that there was polysoup detection available for XNA shapes and it was just thoughtfully left out of your book. I really wish some of this stuff were more thoroughly mentioned in the official documentation so finding an answer to this wouldn't take days.Anyway, thanks for the great book. It's a good start to having complete Torque X documentation and more should be written like it.
#3
are the 2 ways you mentioned above the only ways to setup collision? Can you not implement collision based on the collision boxes set up in a DTS?
If you can, how do I go about setting that up?
03/11/2009 (3:38 pm)
@John,are the 2 ways you mentioned above the only ways to setup collision? Can you not implement collision based on the collision boxes set up in a DTS?
If you can, how do I go about setting that up?
#4
John K.
www.envygames.com
03/23/2009 (10:13 am)
Alexander, I wish you could. Torque X currently does not process the built-in collision shapes that are embedded within the DTS shape. This is too bad, because that's one of the best parts of the DTS model format. I'm sure it will end up in a future release.John K.
www.envygames.com
Associate John Kanalakis
EnvyGames
For DTS Shapes
1. Use the T3DStaticTSComponent with its built-in polysoup collisions
2. Use primitive shapes (sphere/cube) as collision bodies
For XNA Shapes (.X/.FBX)
Since there is no polysoup collision code available for these shapes, refer to option 2 above.
Polysoup takes more CPU overhead, but is more accurate. I tend to use it where smooth curves are needed. Primitive shapes are more clunky, but are also more efficient. In the 3D FPS Demo, the player has 2 spheres used as collision shapes. The .txscene file for that demo should reveal how to setup the primitive collision shapes.
John K.