simply transform your 2 points in a parametric line. A parametric line is simply a point + a vector that gives the direction of the line. Any point on the line can be found using

point + t*vector

where t is a number. So, for your line, if you have point a and point b :

a + t(b-a)

b-a is the direction vector. To find any point you give a value to t.

Now, since your line is finite, you’ll need an interval in which t is valid. For you case, since your line is between a and b, the t interval is [0,1].

Conclusion, if you input any t between 0 and 1, you’ll get a point between your 2 end points

in the case where your line is infinite(ex : a ray), then the t interval would be

(-infinity,infinity) or ]-infinity,infinity[ depending on which math symbols you use

[This message has been edited by Gorg (edited 02-05-2001).]