I'm trying to put an object in motion in an eliptical path on the VB screen. Any help would be greatly appreciated ASAP
Matt
Printable View
I'm trying to put an object in motion in an eliptical path on the VB screen. Any help would be greatly appreciated ASAP
Matt
x*x/(a*a) + y*y/(b*b) = 1
or, y = + and - sqr(b*b*(1-x*x/(a*a))
vary x from one end of the major diameter to the other end, and calculate the two values of y. And then do whatever you like with the points of the ellipse.
Note however that for serious applications, this method is not good for reasons of speed and uniformity. It gives you points that are densely located at one region than at the other.
For better methods of getting the points of an ellipse, refer to the Mid-Point algorithm, available in any fundamental graphics book.