Beefy Boxes and Bandwidth Generously Provided by pair Networks
go ahead... be a heretic
 
PerlMonks  

Re: color problem

by sundialsvc4 (Abbot)
on Dec 31, 2013 at 14:35 UTC ( #1068800=note: print w/ replies, xml ) Need Help??


in reply to color problem

There will be three points-of-interest in the geometry:

  • The position in space (and orientation) of the camera, and the dimensions of its viewport.
  • The position-in-space of the sun, the center of orbit.
  • The distance and angle (polar coordinates) of each planet, which may be converted to absolute (x,y,z).
All of this math lets you determine, at any point in time, whether a given planet is visible to the camera, where it appears on the camera's film, and how far away from the camera it is. You then sort this display-list in descending order by z-order, and draw it.


Comment on Re: color problem

Log In?
Username:
Password:

What's my password?
Create A New User
Node Status?
node history
Node Type: note [id://1068800]
help
Chatterbox?
and the web crawler heard nothing...

How do I use this? | Other CB clients
Other Users?
Others perusing the Monastery: (3)
As of 2014-10-25 23:05 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    For retirement, I am banking on:










    Results (149 votes), past polls