Plan for Mike Kuklinski
by Mike Kuklinski · 07/16/2005 (12:45 am) · 0 comments
Well, after a lot of work, I have finally gotten preliminary ColDet support into Torque.
What is ColDet? ColDet is a L/GPL library designed for polygon accurate collisions.
http://photoneffect.com/coldet/
Now, I wrote a polygon parser that goes through the TSShape of an object, and returns a list of triangles from it. I have an optimized mesh in the model called 'ColDet', which is what it gets the triangles from. These are added into the ColDet Collision Mesh in C++, which is what is used in collision detection. So far, I have successfully gotten a raycast used against objects. I integrated a raycast into a GUI, which draws a small white rectangle in the center of the screen when a collision is detected.
It should be childs play to write a new raycast function, and then new mesh-mesh functions (For object on object collisions).
Here is an AVI (DivX format) of me testing the ColDet raycast on one of the Raptor models in Kuiper. You will notice a slight stuttering. That is not ColDet, it is because I had a background process open that was ungratefully using many CPU cycles. I noticed no slowdown from ColDet when using a release build, but there was some slowdown in a debug build; however, that could also be the Torque Raycast I was also running. I ran a Torque Raycast first, if it succeeded, I ran a ColDet one..
www.kuattech.com/ColDetTorque.avi
What is ColDet? ColDet is a L/GPL library designed for polygon accurate collisions.
http://photoneffect.com/coldet/
Now, I wrote a polygon parser that goes through the TSShape of an object, and returns a list of triangles from it. I have an optimized mesh in the model called 'ColDet', which is what it gets the triangles from. These are added into the ColDet Collision Mesh in C++, which is what is used in collision detection. So far, I have successfully gotten a raycast used against objects. I integrated a raycast into a GUI, which draws a small white rectangle in the center of the screen when a collision is detected.
It should be childs play to write a new raycast function, and then new mesh-mesh functions (For object on object collisions).
Here is an AVI (DivX format) of me testing the ColDet raycast on one of the Raptor models in Kuiper. You will notice a slight stuttering. That is not ColDet, it is because I had a background process open that was ungratefully using many CPU cycles. I noticed no slowdown from ColDet when using a release build, but there was some slowdown in a debug build; however, that could also be the Torque Raycast I was also running. I ran a Torque Raycast first, if it succeeded, I ran a ColDet one..
www.kuattech.com/ColDetTorque.avi
About the author