Advertisement

interpolating between two points

Started by August 08, 2002 08:05 PM
0 comments, last by billybob 22 years, 6 months ago
i''m working on making suspension for a car, and i have the start point and end point of the spring relative to the car. i''ve already rotated these to the correct position, and i have a variable that says where the tire is between these two points. it goes from 0 to 1, 0 being the start point, 1 being the end. if the tire was at .5 on the spring, it would be halfway between the two points. how do i find out the location of the tire like this?
startValue + param * (endValue - startValue)

if param = 0, returns startValue
if param = 1, returns endValue

This topic is closed to new replies.

Advertisement