We closed this forum 18 June 2010. It has served us well since 2005 as the ALPHA forum did before it from 2002 to 2005. New discussions are ongoing at the new URL http://forum.processing.org. You'll need to sign up and get a new user account. We're sorry about that inconvenience, but we think it's better in the long run. The content on this forum will remain online.
IndexProgramming Questions & HelpPrograms › Motion on more complex curves
Page Index Toggle Pages: 1
Motion on more complex curves? (Read 448 times)
Motion on more complex curves?
Apr 7th, 2006, 8:03am
 
Hey guys,

Im not really an expert in either programming or mathematics, but I have a problem Id like to chip away at. Essentially, I would like to be able to create custom curves (bezier perhaps?) and have ellipses follow these curves.

The example ive been looking at is from the learning section of the website: http://www.processing.org/learning/examples/movingoncurves.html

This is nice, but I what I really want to do is to draw my own curves and have objects follow them rather than having them follow the path of a simple sine curve.

Also, im curious what kind of stress this would put on the framerate. Ideally I want a lot of objects on the screen following the curves (in the area of 200+).

Anyways, my question is pretty broad ... but If someone could give me a few tips or point me in the right direction it would be appreciated,

Thanks
Re: Motion on more complex curves?
Reply #1 - Apr 7th, 2006, 9:42am
 
You might want to take a look at craig reynold's steering algo:

http://www.red3d.com/cwr/steer/

Also, in processing it is very easy to obtain x/y data from a curve, simply by using built-in functions such as bezierPoint or curvePoint.
Page Index Toggle Pages: 1