Alternate photometric functions

Discussion forum for Celestia developers; topics may only be started by members of the developers group, but anyone can post replies.
Topic author
chris
Site Admin
Posts: 4211
Joined: 28.01.2002
With us: 22 years 10 months
Location: Seattle, Washington, USA

Alternate photometric functions

Post #1by chris » 29.07.2006, 20:50

One of the irritating shortcomings of Celestia has been it's use of the Lambert model to calculate the illumination for the surfaces of all planets. This simple function gives fraction of reflected light at a point on a surface as:

f(w_i, w_o) = cos(theta_i)

where w_i is the direction of the incoming light and the outgoing direction, and theta_i is the angle between the surface normal and incoming light. The function doesn't depend upon the outgoing light direction. Very few surfaces are purely Lambertian. One obviously non-Lambertian surface is the Moon--even though it's nearly spherical, it appears as a flat disc in the sky. The function above says that if the Moon is Lambertian, the apparent brightness of the Moon should fall off near the edges--although this is how Celestia currently draws the Moon, a quick look at a full Moon will show that it's not correct.

The Lommel-Seeliger model is frequently used in planetary photometry. It's slightly more complex than the Lambert model:

f(w_i, w_o) = cos(theta_i) / (cos(theta_o) + (cos(theta_i))

And here's a series of images from Celestia to demonstrate the difference. There are two sets of three images showing the moon at phases of 0, 90, and 140 degrees.

Lambert model:
Image

Lommel-Seeliger model:
Image

Note that the full Moon looks (incorrectly) like a ball with the Lambert model, but like a flat disc with Lommel-Seeliger. Also notice how the crescent Lambertian moon almost disappears, but the Lommel-Seeliger model produces a beautiful, bright sliver.

The Lambertian model is more accurate for the gas giants, where limb darkening is apparent in telescope and spacecraft images. But, the dustiness of the surface of the Moon gives it strong non-Lambertian characteristics. I'm not sure yet how to expose alternate photometric models in Celestia, or exactly which ones to use. Other candidates for lunar-type surfaces are the Oren-Nayar and Hapke models. I've already experimented with Oren-Nayar; the Hapke model seems the most realistic model, but it's complex enough that using it in Celestia might hurt performance even on high-end graphics card.

--Chris

buggs_moran
Posts: 835
Joined: 27.09.2004
With us: 20 years 2 months
Location: Massachusetts, USA

Post #2by buggs_moran » 29.07.2006, 21:18

Chris,

Couldn't it be something you define and called in an ssc, having numbers for each possibility...

i.e.

Code: Select all

AltSurface "8kalbjpg" "Sol/Saturn/Enceladus"

{
Texture "enceladus8kalb.jpg"
SurfaceIllumination 2  # Lommel-Seeliger
}

Homebrew:
WinXP Pro SP2
Asus A7N8X-E Deluxe
AMD Athlon XP 3000/333 2.16 GHz
1 GB Crucial RAM
80 GB WD SATA drive
ATI AIW 9600XT 128M

ElChristou
Developer
Posts: 3776
Joined: 04.02.2005
With us: 19 years 10 months

Post #3by ElChristou » 30.07.2006, 01:28

Is there any datas out there on the reflectivity of the most important bodies of the Solar System (planets, moons, asteroids)? it would be nice to adapt the model depending on a constant for each bodies defined in the ssc...
Image

bdm
Posts: 461
Joined: 22.07.2005
With us: 19 years 4 months
Location: Australia

Post #4by bdm » 30.07.2006, 01:34

Another way to express this would be to define the surface characteristics of the planet in the SSC file, and then the actual modelling to use is stored in celestia.cfg.

Here is an example setting:

Code: Select all

"Planet" "Star"
{
    Radius 4500
    Surface Solid # can also be Liquid or Gas
    ... etc ...
}


Then the celestia.cfg file would have settings that look like this:

Code: Select all

#------------------------------------------------------------------------
# Surface modelling settings
# This defines how Celestia models the illumination.
# Allowed values are:
# * Lambert (best for gas giants)
# * Lommel-Seeliger (best for solid bodies)
# * Oren-Nayar
# * Hapke (more accurate but slower)
#------------------------------------------------------------------------
SolidSurface Lommel-Seeliger
LiquidSurface Lommel-Seeliger
GasSurface Lambert

I can see the benefit in offering several different rendering models. If someone wants to use Celestia in real time with lots of frames per second, the models that generate better performance can be employed. If someone wants to use Celestia as a rendering engine without regard for performance, they could use the more accurate models.

Controlling them in the celestia.cfg file will provide one location for the settings, and the user doesn't need to change these settings in every SSC file.

Topic author
chris
Site Admin
Posts: 4211
Joined: 28.01.2002
With us: 22 years 10 months
Location: Seattle, Washington, USA

Post #5by chris » 30.07.2006, 02:58

ElChristou wrote:Is there any datas out there on the reflectivity of the most important bodies of the Solar System (planets, moons, asteroids)? it would be nice to adapt the model depending on a constant for each bodies defined in the ssc...


I don't know of any such data . . . The literature on planetary photometry seems to have some models for the Moon, and some general statements about which models are appropriate for other bodies, but that's about it.

It seems there's some use of a 'lunar-Lambert' model, which is a weighted sum of Lambert and Lommel-Seeliger:

f(w_i, w_o) = (1 - k) * cos(theta_i) + 2 * k * cos(theta_i) / (cos(theta_o) + cos(theta_i))

So, k = 0 gives a purely Lambertian surface (appropriate for gas giants or a smooth-surfaced body) and k = 1 gives the normal Lommel-Seeliger function (appropriate for the Moon and other very dusty bodies.) I have yet to experiment with it, but I like the idea of being able to specify the parameter k in an ssc file. But, before settling on this, I'd like to find out what objects have surfaces that actually fit this model, particularly the intermediate values.

--Chris

Avatar
PlutonianEmpire M
Posts: 1374
Joined: 09.09.2004
Age: 40
With us: 20 years 3 months
Location: MinneSNOWta
Contact:

Re: Alternate photometric functions

Post #6by PlutonianEmpire » 30.07.2006, 03:03

chris wrote:The Lambertian model is more accurate for the gas giants, where limb darkening is apparent in telescope and spacecraft images. But, the dustiness of the surface of the Moon gives it strong non-Lambertian characteristics.

my 2 cents:

use the Lommel-Seeliger model for celestia; apply black haze settings for the gas giants to simulate the lambertian model. see if that works. :)
Terraformed Pluto: Now with New Horizons maps! :D

Malenfant
Posts: 1412
Joined: 24.08.2005
With us: 19 years 3 months

Post #7by Malenfant » 30.07.2006, 17:17

Well, *this* will bring me back, at least for this (I spent a couple of years doing photomety stuff in my PhD) :). About freakin' time, is all I can say- Lommel-Seeliger is a must for the Moon!

As for literature, look for stuff by Bonnie Buratti (she did a lot of work on outer planet satellite photometry), Paul Helfenstein (his thesis is a must), and ... damn, there's another guy. I want to say Richard Greenberg but I don't think it's him. Did a lot of work on Io. Argh, I can't remember his name... I'll see if I can dig up the paper because it was really rather good for photometric functions of the planets and moons. You may also want to talk to Bjorn Jonnson (another 3D program author), he's done a lot of work on implementing correct photometry (see http://www.mmedia.is/~bjj/3dtest/index.html ).

I've never heard of "oren-nayar" in planetary circles - I know of Lambert, Minnaert (neither of which are particularly realistic), Buratti (the combined LS-Lambert one), Lommel-Seeliger (for the moon) and Hapke (which is the whole shebang).

You got any plans to put atmospheric scattering in too? So maybe we can get Ashen Light effects around Venus or Titan?
Last edited by Malenfant on 30.07.2006, 17:34, edited 3 times in total.
My Celestia page: Spica system, planetary magnitudes script, updated demo.cel, Quad system

Malenfant
Posts: 1412
Joined: 24.08.2005
With us: 19 years 3 months

Post #8by Malenfant » 30.07.2006, 17:25

Aha! Al McEwen! That's who I was thinking of! I found the paper, grab it from here if you want it! (and let me know when you get it so I can remove it from the website).

McEwen photometry paper (1 MB PDF)
My Celestia page: Spica system, planetary magnitudes script, updated demo.cel, Quad system

Topic author
chris
Site Admin
Posts: 4211
Joined: 28.01.2002
With us: 22 years 10 months
Location: Seattle, Washington, USA

Post #9by chris » 31.07.2006, 06:53

Malenfant wrote:Aha! Al McEwen! That's who I was thinking of! I found the paper, grab it from here if you want it! (and let me know when you get it so I can remove it from the website).

McEwen photometry paper (1 MB PDF)


I was hoping that this discussion might draw you back again :) Thanks for the links . . . I've seen Bjorn Jonsson's work with different photometric functions, and I ended up making some of the same adjustments he did to make them look right on a computer monitor, namely normalization and gamma correction. You'll notice that in the Lommel-Seeliger images I showed, I omitted the the normalization and thus the Moon at 0 degrees phase appears rather dim.

The Oren-Nayar model comes from the field of computer graphics, not planetary photometry. It models rough surfaces as a distribution of v-shaped grooves (one of a number of 'microfacet' models used in computer graphics.) The model has been experimentally checked against actual rough surfaces such as clay and plaster. As with Lommel-Seeliger, Hapke, etc., objects rendered with the Oren-Nayar model don't exhibit any limb darkening. Here's the original paper, if you're interested:

http://www1.cs.columbia.edu/CAVE/public ... RAPH94.pdf

I am also working on implementing a model of atmospheric sampling. I should have some images here soon . . . Since Celestia must render planets in real time, I will have to make some compromises, however. For one thing, I will only consider direct scattering. The scattering integrals can't be computed analytically for non-constant density functions. And, I'll be forced to use a low number of samples when approximating with a summation of discrete samples. I still expect to visually good results however.

--Chris


--Chris

Topic author
chris
Site Admin
Posts: 4211
Joined: 28.01.2002
With us: 22 years 10 months
Location: Seattle, Washington, USA

Post #10by chris » 31.07.2006, 06:56

Malenfant wrote:Aha! Al McEwen! That's who I was thinking of! I found the paper, grab it from here if you want it! (and let me know when you get it so I can remove it from the website).

McEwen photometry paper (1 MB PDF)


Got it! Thanks.

--Chris

Malenfant
Posts: 1412
Joined: 24.08.2005
With us: 19 years 3 months

Post #11by Malenfant » 31.07.2006, 07:41

chris wrote:
Malenfant wrote:Aha! Al McEwen! That's who I was thinking of! I found the paper, grab it from here if you want it! (and let me know when you get it so I can remove it from the website).

McEwen photometry paper (1 MB PDF)

Got it! Thanks.

--Chris


I'll leave it up for another 24 hours in case anyone else wants it...
My Celestia page: Spica system, planetary magnitudes script, updated demo.cel, Quad system

MKruer
Posts: 501
Joined: 18.09.2002
With us: 22 years 2 months

Post #12by MKruer » 02.08.2006, 04:46

Chris, cant you implement the different illumination based upon plant size. I think we can safely assume that planets above say 4 earth radii would be sub jahovian.

Malenfant
Posts: 1412
Joined: 24.08.2005
With us: 19 years 3 months

Post #13by Malenfant » 02.08.2006, 15:05

MKruer wrote:Chris, cant you implement the different illumination based upon plant size. I think we can safely assume that planets above say 4 earth radii would be sub jahovian.


It's nothing to do with size, it's to do with the properties of the surface material. Atmospheres will have their own photometric functions, depending on what's in them (and if there's things like haze, aerosols etc).
My Celestia page: Spica system, planetary magnitudes script, updated demo.cel, Quad system

ajtribick
Developer
Posts: 1855
Joined: 11.08.2003
With us: 21 years 4 months

Post #14by ajtribick » 02.08.2006, 17:18

Out of interest, what would be better out of Lambert and Lommel-Seeliger for Earth?

Topic author
chris
Site Admin
Posts: 4211
Joined: 28.01.2002
With us: 22 years 10 months
Location: Seattle, Washington, USA

Post #15by chris » 02.08.2006, 17:54

chaos syndrome wrote:Out of interest, what would be better out of Lambert and Lommel-Seeliger for Earth?


Planets with significant atmosphere's exhibit limb darkening, which means that Lambert would be a better model than Lommel-Seeliger, but still not adequate. I'm working on a much better model of atmospheric scattering now--see the topic 'Beautiful accident' for an early example (albeit with the Mie term way too high.)

Ignoring the atmosphere, my sense is that the Earth's surface is so varied that no single model would work that well. Parts are probably better modeled with Lommel-Seeliger, other parts with Lambert, and the oceans of course have a strong specular term.

Currently I'm leaning toward use using the Buratti (lunar-Lambert) model which is essentially a linear combination of the Lambert and Lommel-Seeliger models. It can be calculated quickly (compared to Hapke) and provides a single fairly intuitive parameter to adjust the appearance of the planet. Consty: in the McEwen paper, there's a table of Hapke parameters for various solar system bodies. I was trying to figure out how to translate these to the weighting term in the Buratti model. Is there a meaningful correspondence with one of the Hapke parameters?

--Chris

Malenfant
Posts: 1412
Joined: 24.08.2005
With us: 19 years 3 months

Post #16by Malenfant » 02.08.2006, 21:52

It probably is more sensible to use the Buratti function (ie combined lambert/LS) for Celestia, it's a nice, elegant, easy to calculate little thing. Unlike Hapke, the equation of which which takes up about three lines on a portrait-oriented letter-size paper in 12 point font :). I don't think there's a direct correspondence between Buratti and Hapke though, the former is basically a blunt approximation of the latter.
My Celestia page: Spica system, planetary magnitudes script, updated demo.cel, Quad system

MKruer
Posts: 501
Joined: 18.09.2002
With us: 22 years 2 months

Post #17by MKruer » 03.08.2006, 01:59

Malenfant wrote:
MKruer wrote:Chris, cant you implement the different illumination based upon plant size. I think we can safely assume that planets above say 4 earth radii would be sub jahovian.

It's nothing to do with size, it's to do with the properties of the surface material. Atmospheres will have their own photometric functions, depending on what's in them (and if there's things like haze, aerosols etc).


I know that, what I was getting at was that you can assume that planets above a certain size should only be gas giants will think atmospheres. But this is probably irrelevant now anyway


Return to “Ideas & News”