澳 Charlie Lobo <charlie.lobo@xxxxxxxxx>编写: >Hmm, well if you want the position of the sun in the sky (in radians) you'd >do something like: >time(in miliseconds) * 2*PI / 86400000 >Of course this doesn't matter when the sun is hidden >If you want more elaborate sun movement, you have to consider that the sun's >path "wobbles" from north to south as the year goes by due to the >inclination of the planet's rotatoinal axis. It's also shifted north or >southwards depending on the latitude. > >On Fri, Jul 15, 2011 at 10:22 AM, Roger Durañona Vargas ><luo_hei@xxxxxxxx>wrote: > >> Im trying to implement a day/night cycle in my game with some sort of sun >> movement affecting shadows, but I have faced a few problems. First I tried >> to use Caelum, which is a plugin for Ogre which manages sky, sun, >> precipitation, fog, etc, but the lack of help made me desist two times from >> using it. >> so, Im trying the basic approach, doing it myself. The problem is that I >> dont know how to determine the position for the light source according to >> the time to simulate the sun trajectory on the sky. Also, I havent found any >> reference about the right parameters to simulate the light intensity and >> color for different day times: morning, midday, dusk... Can somebody give me >> a help? >> >> -- >> Roger D. Vargas >> Using Gentoo Linux 2010 >> La unica forma de encontrar los limites de lo posible es yendo mas >> alla de ellos, hacia lo imposible >> >> >> --------------------- >> To unsubscribe go to >> http://gameprogrammer.com/**mailinglist.html<http://gameprogrammer.com/mailinglist.html> >> >> >>