Hi,
I think you need to do Rectangular to Polar conversion after working
out your r value based on your angle.
Assuming c is calculated by
c = \varphi ^ \frac{2}{\pi} = 1.358456
Then here is some psuedocode.
for(angle = 0;angle < revolutions;angle += step) {
c = 1.358456;
r= a * Math.pow(c, angle);
x = r * Math.cos(angle);
y = r * Math.sin(angle);
lineTo(x, y)...
}
That should point you in the right direction.
HTH
Glen
Merrill, Jason wrote:
\I'm no math whiz, does anyone know how I can draw a golden spiral and position and move sprites/movieClips along a golden spiral path?
What is a golden spiral?
http://en.wikipedia.org/wiki/Golden_spiral
"In geometry, a golden spiral is a logarithmic spiral whose growth factor b is related to φ, the golden ratio. Specifically, a golden spiral gets wider (or further from its origin) by a factor of φ for every quarter-turn it makes."
Or a spiral shape in general? I want to position a point along the spiral
based on numerical data. Then as things change, animate the object along the
path of the spiral. I need this to be dynamic, not hand-drawn guide layers.
Anyone know how to translate this math to Actionscript?
Thanks,
Jason Merrill
Bank of America
GT&O Learning & Leadership Development
eTools & Multimedia Team
_______________________________________________
Flashcoders@chattyfig.figleaf.com
To change your subscription options or search the archive:
http://chattyfig.figleaf.com/mailman/listinfo/flashcoders
Brought to you by Fig Leaf Software
Premier Authorized Adobe Consulting and Training
http://www.figleaf.com
http://training.figleaf.com
_______________________________________________
Flashcoders@chattyfig.figleaf.com
To change your subscription options or search the archive:
http://chattyfig.figleaf.com/mailman/listinfo/flashcoders
Brought to you by Fig Leaf Software
Premier Authorized Adobe Consulting and Training
http://www.figleaf.com
http://training.figleaf.com