I don’t remember what sparked the idea, but for some time I have been thinking about having a desktop background that showed the changing view of Earth from space; a geostationary position showing the approaching sunrise/sunset. I have seen a ‘Desktop DreamScene‘? that was something akin to what I was after, but I wanted to do this myself and slightly differently. In the end I think I ended up using the same or very similar software to achieve my effect.
Google Earth was my first port of call to source these images, but this was limited by the limited ability to take clean screenshots and inability to position the view off-centre. After more stumbling around the web I came accross NASA’s World Wind Java application. This is fantastic, the Blue Marble Next Generation images look fantastic, it is open source and can be developed in a multitude of ways and it can be scripted. The drawback is that the applet is supplied as a demo, my Java skills are virtually non-existant and after some time playing around and looking at other peoples work I had made very little progress. Then whilst watching some of the BBC Wonders of the Solar System series I began wondering what software they used to create the models. The BBC site pointed me towards Celestia. Another free offering, it has its own scripting language and lets the user explore the solar system in its known entirety.
Celestia has its own scripting language and an active user base who have generated many higher resolution image maps and other objects. I downloaded a night view and higher res day views, then created my own cloud cover png.
I adapted the scattering effect after reading a discussion about adapting night time views, I don’t know about realism, but I prefer the look offered by the following:
Atmosphere
{
Height 60
Lower [ 0.43 0.52 0.65 ]
Upper [ 0.26 0.47 0.84 ]
Sky [ 0.40 0.6 1.0 ]
Sunset [ 1.0 0.6 0.2 ]
CloudHeight 7
CloudSpeed 65
CloudMap "earth-clouds.*"
# Mie 0.001
# MieAsymmetry -0.25
# Rayleigh [ 0.001 0.0025 0.006 ]
# MieScaleHeight 12
# my old values
## Mie 0.0005
## MieAsymmetry -0.15
## Rayleigh [ 0.00025 0.0009 0.0015 ]
## Absorption [ 0.00018 0.00005 0.0 ]
## MieScaleHeight 18
Mie 0.0050
MieAsymmetry -0.35
Rayleigh [ 0.0008121 0.0020775 0.00375 ]
Absorption [ 0.00057 0.0004 0.0 ]
MieScaleHeight 15
}
There is more work to do on the night lights, I can improve on what I currently have, but I have not had any luck using the Radiance Calibrated Lights: 1996-1997 from http://www.ngdc.noaa.gov/dmsp/download_rad_cal_96-97.html. This post and this one discuss creating texture maps, but I have not managed to do it. I will stick with what I have for now.
Version 1.6.1 of Celestia will allow the user to use a url directly in a script, but for now I set the view I would like to record then run a little script. The script increments the date and time and takes a series of screenshots. In this way I captured 288 images; images from midnight to midnight for the 15th Jan, 15th Feb etc. So I get a rougly accurate seasonal variation in sunlight. If I were really keen I would work out how to use the NASA Blue Marble monthly images so the snowline moves according to the season along with the sunlight, but then since all the snow seems to be melting anyway…
I use the images on my desktop background along with a little program wot I wrote to keep the images in sync with the local time. Below is the celx script i use in celestia.
To Use the Script: Read the rest of this entry »