Page 1 of 4

Atmospheres

Posted: 03.08.2006, 17:01
by chris
I'm hard at work on the new atmosphere code. The atmospheres in 1.4.1 are basically a hack, tuned to look OK but not based on a physical model. The new code actually simulates how light interacts with a scattering medium.

It's taking a lot of effort to get it right, and I'm still not there yet. Here's a preview anyway:

Image

--Chris

Posted: 03.08.2006, 17:49
by ElChristou
if you continue like this we will soon have a photorealistic result :D
Hope you are thinking in the stars visibility to achieve a perfect rendering!
(do you remember this post?)

Posted: 03.08.2006, 19:02
by ajtribick
Looking good. Is this OpenGL 2 only, or will it be implemented on all render paths?

Posted: 03.08.2006, 19:29
by chris
chaos syndrome wrote:Looking good. Is this OpenGL 2 only, or will it be implemented on all render paths?


This is OpenGL 2.0 only. It's unfortunately not practical to implement this in the other render paths.

--Chris

Posted: 03.08.2006, 19:39
by chris
ElChristou wrote:if you continue like this we will soon have a photorealistic result :D
Hope you are thinking in the stars visibility to achieve a perfect rendering!
(do you remember this post?)


I'll do something, but not in time for the next version of Celestia. The approach I want to take will use high dynamic range rendering into a floating point frame buffer followed by a post-processing step to fit the actual pixel intensities to a range representable on a monitor.

--Chris

Posted: 03.08.2006, 22:10
by Malenfant
So will we ultimately be able to get an image like this, showing the refraction of light around a thick atmosphere like Titan or Venus?

Image

Actually while we're on the subject, how about rings - you know how they look different depending on whether they're backlit or not? Would the new photometry code be able to simulate that?

Posted: 03.08.2006, 23:05
by chris
Malenfant wrote:So will we ultimately be able to get an image like this, showing the refraction of light around a thick atmosphere like Titan or Venus?

Image

Actually while we're on the subject, how about rings - you know how they look different depending on whether they're backlit or not? Would the new photometry code be able to simulate that?


I couldn't see the photo in your post, but I assume you mean that you were talking about something like this:

http://ciclops.org/view.php?id=1114

That's a long way off in Celestia . . . There's a huge amount of work required to make refraction work in a general way and perform reasonably well (even by a very lax definition of 'reasonably').

As for rings, it should be pretty easy to render them more reaslistically. I think I'd just need to choose a better phase function and use per-pixel rather than per-vertex lighting. Got any references for me on light scattering and absorption in planetary ring systems?

--Chris

Posted: 04.08.2006, 00:15
by Malenfant
Oops, I broke Ciclops! :oops:

No, I actually meant this one (this shouldn't break anything...!):

Image

I don't have any refs for rings unfortunately, most of what I did for my PhD was photoclinometry (shape from shading)

Posted: 04.08.2006, 12:29
by Telepath
Malenfant,

Great photo! I take it that's an actual spacecraft photo. Is this a recent shot from Cassini?

Looks like a Solar eclipse by one of Saturns moons to me, with another moon nearby. Do you know which objects were involved and the spacecraft and date of the photo?

PS. Notwithstanding my moniker, I can't actually read your mind so you'll have to answer. :lol:

Posted: 04.08.2006, 14:16
by Malenfant
It's a Cassini photo of Titan and Enceladus (Enc is in front of the rings, Titan is behind them). You'll find a bunch of them here:
http://ciclops.org/ir_index.php?id=20

Titan's a crescent really in these pictures, but the atmosphere and haze is scattering light all around the limb of the moon (and contrary to what I said earlier, it's got nothing to do with Ashen Light on Venus)

Posted: 04.08.2006, 17:35
by chris
Malenfant wrote:Oops, I broke Ciclops! :oops:

No, I actually meant this one (this shouldn't break anything...!):

Image


Yes, you should see effects like that, though I haven't yet tried to simulate Titan's atmosphere. I'll post some more screen shots here soon.

--Chris

Posted: 05.08.2006, 00:22
by bdm
With the new atmosphere code, will it be possible to specify the opacity of the atmosphere? A transparent atmosphere would scatter little light, so stars are easily visible with the sun in the sky (eg: moon, Mercury, bodies with a thin, clear atmosphere). The denser the atmosphere, the more difficult it is to see stars with the sun above the horizon. An atmosphere of sufficient density would make it impossible to see the disk of the sun (eg: Venus, Earth under cloud, Titan).

re

Posted: 05.08.2006, 19:34
by John Van Vliet
this will be cool

but to me it looks like a lens effect due to over exposer even the best optics will creat this when 1 eliment ( Titan ) is very over exposed inorder to show a second one ( ie the ring )

http://ciclops.org/media/dr/2006/2055_5608_2.png

Posted: 10.08.2006, 20:05
by lpetrich
And while we are on the subject of atmospheres, would it be possible to create the view from underneath an atmosphere?

It might be interesting to see what the Universe looks like from Mars's surface or Titan's surface, for instance. I imagine that that could be done by rendering a special "atmosphere texture" whose alpha channel is (fraction of light absorbed and scattered). It need not match the display pixel-for-pixel; one can use a lower-resolution atmosphere texture and do interpolation to fill in.

Titan would be a big challenge. From the surface, its total sky luminosity is 0.1 the Sun's luminosity and only 0.01 of the Sun's incoming light gets through -- when the Sun is near the zenith. This means that Titan's atmosphere has a zenith-direction optical depth of 4.5.

The alpha channel would have a value 1 - exp(-t(a))

where t is the optical depth along elevation angle a; t(a) = t0/sin(a) (0 is horizon, 90 is zenith), and t0 is the zenith-direction optical depth.

Ideally, one would want to do radiative-transfer calculations to find the atmosphere texture, but such calculations can be very time-consuming; one may still be able to do some simplified radiative-transfer calculations.

Posted: 11.08.2006, 01:43
by chris
lpetrich wrote:And while we are on the subject of atmospheres, would it be possible to create the view from underneath an atmosphere?
This is already possible in Celestia.

It might be interesting to see what the Universe looks like from Mars's surface or Titan's surface, for instance. I imagine that that could be done by rendering a special "atmosphere texture" whose alpha channel is (fraction of light absorbed and scattered). It need not match the display pixel-for-pixel; one can use a lower-resolution atmosphere texture and do interpolation to fill in.
Celestia uses the alpha channel like this right now. In the new atmosphere code, the amount of in scattering and the extinction factor (absorption + out scattering) are computed per vertex and interpolated. The extinction factor is placed into the alpha channel. I've got a more accurate scheme in mind that requires two passes . . . There's only one alpha value, but extinction really needs to be computed separately for red, green, and blue. So, the first pass will multiply by the extinction factor, and the second pass will add in the scattering term.

Titan would be a big challenge. From the surface, its total sky luminosity is 0.1 the Sun's luminosity and only 0.01 of the Sun's incoming light gets through -- when the Sun is near the zenith. This means that Titan's atmosphere has a zenith-direction optical depth of 4.5.

The alpha channel would have a value 1 - exp(-t(a))

where t is the optical depth along elevation angle a; t(a) = t0/sin(a) (0 is horizon, 90 is zenith), and t0 is the zenith-direction optical depth.

Ideally, one would want to do radiative-transfer calculations to find the atmosphere texture, but such calculations can be very time-consuming; one may still be able to do some simplified radiative-transfer calculations.


Currently, setting Titan's atmospheric scattering and absorption terms to realistic values produces nearly black skies. The math is right, but some sort of compensation needs to be done for ambient light level. The same thing is done elsewhere in Celestia, otherwise you'd see just a black screen when traveling out Pluto.

--Chris

Posted: 11.08.2006, 03:29
by MKruer
Chris,

First great work on the atmosphere, it looks to me a substantial improvement in the realism for the atmosphere. But I have two questions related to the atmosphere properties in general. First is will you be switching to a Multi level schema instead of the current three (Lower, Upper, Sky) Also are you planning to add the ability to have multiple, independent cloud layers?

Keep up the Excellent work.

Posted: 11.08.2006, 05:16
by Chuft-Captain
MKruer wrote:Also are you planning to add the ability to have multiple, independent cloud layers?

Hmm, that's an enticing idea.
How about multiple independent (individual) clouds? :lol: :wink:

Posted: 11.08.2006, 05:22
by MKruer
Chuft-Captain wrote:
MKruer wrote:Also are you planning to add the ability to have multiple, independent cloud layers?
Hmm, that's an enticing idea. :)

How about multiple independent (individual) clouds? :lol:


ooohh I like that one, never thought of it, but it would work well for one of the most requested features, animated textures.

Imagine Jupiter.

You have two cloud layers, one moving slightly faster then the second one, to give the illusion that the atmospheres wind speeds are creating the bands, but you have that big red spot. Well that could be a small, 64x64x32 mng file that would be in a cycle animation showing the spot rotating.

But we digress.

Posted: 11.08.2006, 06:50
by Chuft-Captain
MKruer wrote:ooohh I like that one, never thought of it, but it would work well for one of the most requested features, animated textures.

Imagine Jupiter.

You have two cloud layers, one moving slightly faster then the second one, to give the illusion that the atmospheres wind speeds are creating the bands, but you have that big red spot. Well that could be a small, 64x64x32 mng file that would be in a cycle animation showing the spot rotating.

But we digress.

Actually,
if Chris's atmosphere work is based on modelling the actual physical phenomena,.... and he's able to model light absortion characteristics of different elements and chemicals,.... and he's able to model increasing density at lower altitudes in a gas giant, .... and he's able to model gas-giant weather..., ..... and .... . and..... you can see where I'm going with this can't you?...

Imagine Jupiter...

with no textured surface at all, but just an atmosphere (ie. a ball of gas) scattering light in different ways to create the appearance of banding, great red-spots etc.

But we digress. :lol:

Sorry Chris, just kidding. :wink:

Posted: 27.08.2006, 21:58
by t00fri
While hunting for exciting shots with my 64k normal map and Chris' new atmosphere code for my forthcoming nmtools tutorial in CelestialMatters...

In case you got a nice 1600x1200 or bigger screen, have a click. This evening image of the Andes bordered by the Pacific I find to have a very special 'spirit' ;-)

Image

Enjoy,
Bye Fridger