Jump to content
  • Advertisement

Archived

This topic is now archived and is closed to further replies.

eng3d

From polar coordinates to cartesians

This topic is 6141 days old which is more than the 365 day threshold we allow for new replies. Please post a new topic.

If you intended to correct an error in the post then please contact us.

Recommended Posts

Hi: i have some math problems. (really im very struck about it -->working a saturday). i have a spaceship flying to a 100milles (radius), then you can control the ship using only alpha a beta angles. How i can convert this in cartesian coordinates?. in 2d is easy : x=radius*cos(alpha); y=radius*sin(alpha); but in 3d? tnk for the help. ----------------------------------------------- "Cuando se es peon, la unica salida es la revolución"

Share this post


Link to post
Share on other sites
Advertisement
x=radius*cos(alpha)*cos(beta);
y=radius*sin(alpha)*cos(beta);
z=radius*sin(beta);

Beware: Valid only if no roll angle.



Laurent - http://www.lafaqmfc.com/
My little game: http://www.lafaqmfc.com/starshooter.htm

Share this post


Link to post
Share on other sites
tnk this work.


-----------------------------------------------

"Cuando se es peon, la unica salida es la revolución"

Share this post


Link to post
Share on other sites

  • Advertisement
×

Important Information

By using GameDev.net, you agree to our community Guidelines, Terms of Use, and Privacy Policy.

GameDev.net is your game development community. Create an account for your GameDev Portfolio and participate in the largest developer community in the games industry.

Sign me up!