Skip to main content
gamedev.net
🔒 Locked

distance

Started by prgrmmr Dec 12, 2002 at 12:05 PM 1 replies 250+ views
Original Post
prgrmmr
prgrmmr
hi! i wrote a prog, that needs to calculate the distance between a point and a triangle ( 3D ). My algorithm works fine but runs very slowly. It uses a function that calculates if a ray intersects a triangle: ray origin is the point and the direction is the inverse of the tri normal ), if not intersects than calculates three edge-point distance. This is really very slow. Do you know a much faster solution? Thanks
cgoat
cgoat
Check out magic-software.com

I can''t say how good the algorithms are, but under the 3D source for distance, you''ll see code and a document for distance between point and triangle.
prgrmmr
prgrmmr
thanks for the link! that site is great!

Topic Locked

This topic has been locked by a moderator. New replies are not allowed.

Sign in to reply to this topic.