Skip to main content

LinePointDistance

Simple implementation of a Point to Line distance algorithm. The algorithm also calculates the location of the closest point on the line.


John Eriksson
(wmjoers)
Simple implementation of a Point to Line distance algorithm. The algorithm also calculates the location of the closest point on the line.

I needed an algorithm like this for one of my projects and coded a small proof of concept that might be helpful for others. The code is not 100% optimized and not documented at all. But I'll think it will be fairly easy to understand.

If you have any improvements of this code please send it to me!!!

Changes

Links

Home Page
http://arainyday.se/projects/python/LinePointDistance/

Releases

LinePointDistance 1.0 — 4 Jan, 2007

Pygame.org account Comments