|
![](/i/fill.gif) |
In article <396F6E26.A9FFDE42@my-dejanews.com>,
gre### [at] my-dejanews com wrote:
>I've tried all kinds of tricks for 3D, and nothing looks right. The
>problem is with a surface with a y component (rolling hills). If it
>drops a great amount in y, it should roll more, if it drops less in y,
>it rolls less.
What you want is not how far it drops in y, but how far it rolls. That
is, if it is rolling on a straight line, what is the length of that
line? If it is rolling on a curve, what is the length of that curve?
If the curves aren't simple circular curves (for which I think there is
a function; perhaps the arcsin/arccos/arctan functions?), but you know
the points anywhere on the surface (which you must, since you're putting
the balls there?), you could approximate small triangles to get an
approximation of the distance rolled.
I wrote something about trig functions in POV
(http://www.hoboes.com/html/NetLife/POV/Trig/) but you can probably use
the vector functions to do what you want.
Jerry
Post a reply to this message
|
![](/i/fill.gif) |