I added Ray-Triangle intersection test to the engine. First I want to use PhysX for doing this but this library does not support dynamic triangle meshes it means I can’t change the mesh data very frequently with a reasonable speed so I decide to write my own Ray-Triangle intersection test.
I find an algorithm for do this issue on Collision Detection in Interactive 3D Environments Book it says Ray-Triangle test but when I test the algorithm it works as a line-triangle intersection test. The more interesting thing is that the next chapter is talking about line-triangle intersection test but it works good and the performance is very good.
The next thing I worked on this week was on getting the ray from screen coordinates and this part work good too.
2 comments:
Post a Comment