Blue sky problem with image based lighting

This is a discussion on Blue sky problem with image based lighting within the Graphics forums in Theory and Concepts category; I'm using image based lighting with spherical harmonics, produced from cubemap hdr images. However there is a big problem with my implementation: Outdoor images with blue sky cause top of the lighted object become blueish. The same problem with indoor cubemaps - color of the wall transfer to the object. We don't see any top-blue humans outdoor, this blue color is neither physical nor realistic. Any idea how get rid of this problem in physically correct way ? I can decrease image saturation, but that would cause *all* light become white, I still want colored light too. Any advices, pointers ...

Go Back   Application Development Forum > Theory and Concepts > Graphics

Object Mix

Register FAQ Calendar Search Today's Posts Mark Forums Read
  #1  
Old 08-27-2008, 11:04 AM
serg271
Guest
 
Default Blue sky problem with image based lighting

I'm using image based lighting with spherical harmonics, produced from
cubemap hdr images. However there is a big problem with my
implementation: Outdoor images with blue sky cause top of the lighted
object become blueish. The same problem with indoor cubemaps - color
of the wall transfer to the object. We don't see any top-blue humans
outdoor, this blue color is neither physical nor realistic. Any idea
how get rid of this problem in physically correct way ? I can decrease
image saturation, but that would cause *all* light become white, I
still want colored light too. Any advices, pointers to some articles ?
Reply With Quote
  #2  
Old 08-27-2008, 02:49 PM
Daniel Pitts
Guest
 
Default Re: Blue sky problem with image based lighting

serg271 wrote:
> I'm using image based lighting with spherical harmonics, produced from
> cubemap hdr images. However there is a big problem with my
> implementation: Outdoor images with blue sky cause top of the lighted
> object become blueish. The same problem with indoor cubemaps - color
> of the wall transfer to the object. We don't see any top-blue humans
> outdoor, this blue color is neither physical nor realistic. Any idea
> how get rid of this problem in physically correct way ? I can decrease
> image saturation, but that would cause *all* light become white, I
> still want colored light too. Any advices, pointers to some articles ?

I think that *part* of the problem with blue light specifically is that
sometimes its absorbed and re-emitted as a different wavelength (try it
with blue or ultra-violet light and orange plastic).

Not to mention that the blue from the sky is actually much lower
saturation than the light from the sun. If you can add a "sun" that has
a saturation "way above average light sources", that may help mitigate
your problem.

As for objects getting the color of nearby walls, I have actually
experienced this in real life, if the wall is lit with a bright enough
light (such as sunlight through a window).

--
Daniel Pitts' Tech Blog: <http://virtualinfinity.net/wordpress/>
Reply With Quote
  #3  
Old 08-27-2008, 04:25 PM
ImageAnalyst
Guest
 
Default Re: Blue sky problem with image based lighting

On Aug 27, 2:49*pm, Daniel Pitts
<newsgroup.spamfil...@virtualinfinity.net> wrote:
> serg271 wrote:
> > I'm using image based lighting with spherical harmonics, produced from
> > cubemap hdr images. However there is a big problem with my
> > implementation: Outdoor images with blue sky cause top of the lighted
> > object become blueish. The same problem with indoor cubemaps - color
> > of the wall transfer to the object. We don't see any top-blue humans
> > outdoor, this blue color is neither physical nor realistic. Any idea
> > how get rid of this problem in physically correct way ? I can decrease
> > image saturation, but that would cause *all* light become white, I
> > still want colored light too. Any advices, pointers to some articles ?

>
> I think that *part* of the problem with blue light specifically is that
> sometimes its absorbed and re-emitted as a different wavelength (try it
> with blue or ultra-violet light and orange plastic).
>
> Not to mention that the blue from the sky is actually much lower
> saturation than the light from the sun. *If you can add a "sun" that has
> a saturation "way above average light sources", that may help mitigate
> your problem.
>
> As for objects getting the color of nearby walls, I have actually
> experienced this in real life, if the wall is lit with a bright enough
> light (such as sunlight through a window).
>
> --
> Daniel Pitts' Tech Blog: <http://virtualinfinity.net/wordpress/>


----------------------------------
How are you guys defining "Saturation"? Is it in the HSI/HSL sense
where saturation (also known as "chroma") is how much white is mixed
in? So that gray or white is 0 saturation, sky blue is a little
saturated, and a pure, deep blue is highly saturated? I'm talking
like CIE type of saturation. Not sure my definition jives with
yours. Or are you referring to saturation as clipping to a fixed,
maximum gray level (like 255)?
Regards,
ImageAnalyst
Reply With Quote
  #4  
Old 08-27-2008, 05:45 PM
Daniel Pitts
Guest
 
Default Re: Blue sky problem with image based lighting

ImageAnalyst wrote:
> On Aug 27, 2:49 pm, Daniel Pitts
> <newsgroup.spamfil...@virtualinfinity.net> wrote:
>> serg271 wrote:
>>> I'm using image based lighting with spherical harmonics, produced from
>>> cubemap hdr images. However there is a big problem with my
>>> implementation: Outdoor images with blue sky cause top of the lighted
>>> object become blueish. The same problem with indoor cubemaps - color
>>> of the wall transfer to the object. We don't see any top-blue humans
>>> outdoor, this blue color is neither physical nor realistic. Any idea
>>> how get rid of this problem in physically correct way ? I can decrease
>>> image saturation, but that would cause *all* light become white, I
>>> still want colored light too. Any advices, pointers to some articles ?

>> I think that *part* of the problem with blue light specifically is that
>> sometimes its absorbed and re-emitted as a different wavelength (try it
>> with blue or ultra-violet light and orange plastic).
>>
>> Not to mention that the blue from the sky is actually much lower
>> saturation than the light from the sun. If you can add a "sun" that has
>> a saturation "way above average light sources", that may help mitigate
>> your problem.
>>
>> As for objects getting the color of nearby walls, I have actually
>> experienced this in real life, if the wall is lit with a bright enough
>> light (such as sunlight through a window).
>>
>> --
>> Daniel Pitts' Tech Blog: <http://virtualinfinity.net/wordpress/>

>
> ----------------------------------
> How are you guys defining "Saturation"? Is it in the HSI/HSL sense
> where saturation (also known as "chroma") is how much white is mixed
> in? So that gray or white is 0 saturation, sky blue is a little
> saturated, and a pure, deep blue is highly saturated? I'm talking
> like CIE type of saturation. Not sure my definition jives with
> yours. Or are you referring to saturation as clipping to a fixed,
> maximum gray level (like 255)?
> Regards,
> ImageAnalyst

Sorry, more light your last one, but not don't clip it.

I guess what I really meant is relative "brightness" or your light-sources.

--
Daniel Pitts' Tech Blog: <http://virtualinfinity.net/wordpress/>
Reply With Quote
  #5  
Old 08-28-2008, 12:35 AM
serg271
Guest
 
Default Re: Blue sky problem with image based lighting

On Aug 27, 11:25*pm, ImageAnalyst <imageanal...@mailinator.com> wrote:
> On Aug 27, 2:49*pm, Daniel Pitts
>
>
>
> <newsgroup.spamfil...@virtualinfinity.net> wrote:
> > serg271 wrote:
> > > I'm using image based lighting with spherical harmonics, produced from
> > > cubemap hdr images. However there is a big problem with my
> > > implementation: Outdoor images with blue sky cause top of the lighted
> > > object become blueish. The same problem with indoor cubemaps - color
> > > of the wall transfer to the object. We don't see any top-blue humans
> > > outdoor, this blue color is neither physical nor realistic. Any idea
> > > how get rid of this problem in physically correct way ? I can decrease
> > > image saturation, but that would cause *all* light become white, I
> > > still want colored light too. Any advices, pointers to some articles ?

>
> > I think that *part* of the problem with blue light specifically is that
> > sometimes its absorbed and re-emitted as a different wavelength (try it
> > with blue or ultra-violet light and orange plastic).

>
> > Not to mention that the blue from the sky is actually much lower
> > saturation than the light from the sun. *If you can add a "sun" that has
> > a saturation "way above average light sources", that may help mitigate
> > your problem.

>
> > As for objects getting the color of nearby walls, I have actually
> > experienced this in real life, if the wall is lit with a bright enough
> > light (such as sunlight through a window).

>
> > --
> > Daniel Pitts' Tech Blog: <http://virtualinfinity.net/wordpress/>

>
> ----------------------------------
> How are you guys defining "Saturation"? *Is it in the HSI/HSL sense
> where saturation (also known as "chroma") is how much white is mixed
> in? *So that gray or white is 0 saturation, sky blue is a little
> saturated, and a pure, deep blue is highly saturated?


Yes. And that would be "brute force" approach - just reduce scene to
almost grayscale.

Another would be as Daniel suggest - let the artist edit hdr image
increasing the power of white/yellow light source.
However by itself that wouldn't be enough - light source affect only
part of the image, II would have take to into account interreflection
terms to distribute it to the rest, to mix white/yellow from the
source with blue from the sky. That would require to specify
reflective component of hdr image, which is not trivial, and of cause
wouldn't make automatic pipeline possible.
Though if that is the reason - why camera isn't capturing those
interreflections already ? Is it because of limited field of view of
the camera?
After some thought - I may specify just bottom of the image as
"reflective" and see what would happen....
But is this idea physically meaningful?


> *I'm talking like CIE type of saturation. *Not sure my definition jives with
> yours. *Or are you referring to saturation as clipping to a fixed,
> maximum gray level (like 255)?
> Regards,
> ImageAnalyst


Actually I have two ideas, why we don't

Reply With Quote
  #6  
Old 08-28-2008, 01:39 AM
hoffmann@fho-emden.de
Guest
 
Default Re: Blue sky problem with image based lighting



serg271 schrieb:
> I'm using image based lighting with spherical harmonics, produced from
> cubemap hdr images. However there is a big problem with my
> implementation: Outdoor images with blue sky cause top of the lighted
> object become blueish. The same problem with indoor cubemaps - color
> of the wall transfer to the object. We don't see any top-blue humans
> outdoor, this blue color is neither physical nor realistic. Any idea
> how get rid of this problem in physically correct way ? I can decrease
> image saturation, but that would cause *all* light become white, I
> still want colored light too. Any advices, pointers to some articles ?


R.W.G.Hunt
Measuring Colour
Chapter 4.11 Daylight
"In sunlit areas in clear sunny weather, about 90% oft he
illumination
comes directly from the sun and only about 10% from the sky.
Because the sky is normally blue in these condition, the addition of
the sky light makes the light slightly bluer, and raise the
correlated
colour temperature somewhat..."
"a correlated colour temperature of 5500K is usually taken as a repre-
sentative figur for solar altitudes not lower than about 30°."

More about:
G.Wyszecki and W. S. Stiles
Color Science

About the color of blue sky:
http://www.fho-emden.de/~hoffmann/skyblue14072008.pdf

Daylight spectra:
http://www.fho-emden.de/~hoffmann/ciegraph17052004.pdf
D55 means: correlated color temperatur 5500K.

Best regards --Gernot Hoffmann
Reply With Quote
  #7  
Old 08-28-2008, 02:06 AM
serg271
Guest
 
Default Re: Blue sky problem with image based lighting

On Aug 28, 8:39*am, hoffm...@fho-emden.de wrote:
> serg271 schrieb:
>
> > I'm using image based lighting with spherical harmonics, produced from
> > cubemap hdr images. However there is a big problem with my
> > implementation: Outdoor images with blue sky cause top of the lighted
> > object become blueish. The same problem with indoor cubemaps - color
> > of the wall transfer to the object. We don't see any top-blue humans
> > outdoor, this blue color is neither physical nor realistic. Any idea
> > how get rid of this problem in physically correct way ? I can decrease
> > image saturation, but that would cause *all* light become white, I
> > still want colored light too. Any advices, pointers to some articles ?

>
> R.W.G.Hunt
> Measuring Colour
> Chapter 4.11 Daylight
> "In sunlit areas in clear sunny weather, about 90% oft he
> illumination
> comes directly from the sun and only about 10% from the sky.
> Because the sky is normally blue in these condition, the addition of
> the sky light makes the light slightly bluer, and raise the
> correlated
> colour temperature somewhat..."
> "a correlated colour temperature of 5500K is usually taken as a repre-
> sentative figur for solar altitudes not lower than about 30°."
>
> More about:
> G.Wyszecki and W. S. Stiles
> Color Science
>
> About the color of blue sky:http://www.fho-emden.de/~hoffmann/skyblue14072008.pdf
>
> Daylight spectra:http://www.fho-emden.de/~hoffmann/ciegraph17052004.pdf
> D55 means: correlated color temperatur 5500K.
>
> Best regards --Gernot Hoffmann


Thanks!
It seems to me the problem is the limited FOV of the camera, capturing
image. With 180 degree camera I would get better representation of the
skylight.
So the solution could be increase weight of spherical harmonics
responsible for average or top hemisphere.
Reply With Quote
  #8  
Old 08-28-2008, 03:05 AM
cr88192
Guest
 
Default Re: Blue sky problem with image based lighting


"serg271" <serg271@gmail.com> wrote in message
news:c994a11c-f265-4e92-99d0-e2d91d6107f1@e39g2000hsf.googlegroups.com...
>On Aug 28, 8:39 am, hoffm...@fho-emden.de wrote:
>> serg271 schrieb:
>>


<snip>

>
>> R.W.G.Hunt
>> Measuring Colour
>> Chapter 4.11 Daylight
>> "In sunlit areas in clear sunny weather, about 90% oft he
>> illumination
>> comes directly from the sun and only about 10% from the sky.
>> Because the sky is normally blue in these condition, the addition of
>> the sky light makes the light slightly bluer, and raise the
>> correlated
>> colour temperature somewhat..."
>> "a correlated colour temperature of 5500K is usually taken as a repre-
>> sentative figur for solar altitudes not lower than about 30°."
>>
>> More about:
>> G.Wyszecki and W. S. Stiles
>> Color Science
>>
>> About the color of blue
>> sky:http://www.fho-emden.de/~hoffmann/skyblue14072008.pdf
>>
>> Daylight spectra:http://www.fho-emden.de/~hoffmann/ciegraph17052004.pdf
>> D55 means: correlated color temperatur 5500K.
>>
>> Best regards --Gernot Hoffmann

>
> Thanks!
> It seems to me the problem is the limited FOV of the camera, capturing
> image. With 180 degree camera I would get better representation of the
> skylight.
> So the solution could be increase weight of spherical harmonics
> responsible for average or top hemisphere.


actually the issue may well be more the weighting, and not so much the
rendering.

namely, the sun will presumably be a part of the image, but you want it to
be about 10x brighter than the rest of the sky.

now, consider the camera (that takes photos outside), which if it were
correctly adjusted to take a picture of the sun, nearly everything else
would come out black (much like if you look at the sky with a welding
helmet, namely the sun is bright, everything else is dark).

however, when an ordinary camera is used, it sees most everything else
brightly.
now, as for the sun? the range of the camera is finite, so the sun just gets
its picture taken with it set to full brightness (in effect, it is clamped
off).

the result, is that, if used, the sky will light everything blue.
a solution in this case would be to filter the image in such a way as to
restore the approximate relative brightness of the sun, for example, by
making use of severe tweaking of the brightness/contrast control in a
typical photo editor.

alternatively, it could be possible to use the texture in combination with a
secondary texture set up as a "brightness map", where they could be combined
either at load time (to be effective, this would require using
floating-point texturemaps), or via a shader (this could avoid losing some
of the precision).

of course, some loss of precision could be acceptable as well, since it only
really needs to be approximate anyways.



the major alternative approach, as others have noted, is to make the sky
image a lot darker, and explicitly add in a very bright lightsource serving
as the sun (namely the "very bright light very far away approach", or
possibly several allowing for slightly softer shadows).

of well, all this is not likely something I would likely do on my video
card, noting that just with what I do already, fill rate is a bit of a
problem (of course, my video card also isn't all that great). things would
probably be worse performance-wise if I were using HDR...

or such...



Reply With Quote
  #9  
Old 08-28-2008, 03:11 AM
serg271
Guest
 
Default Re: Blue sky problem with image based lighting

On Aug 28, 10:05*am, "cr88192" <cr88...@NOSPAM.hotmail.com> wrote:
> "serg271" <serg...@gmail.com> wrote in message
>
> news:c994a11c-f265-4e92-99d0-e2d91d6107f1@e39g2000hsf.googlegroups.com...
>
> >On Aug 28, 8:39 am, hoffm...@fho-emden.de wrote:
> >> serg271 schrieb:

>
> <snip>
>
>
>
>
>
> >> R.W.G.Hunt
> >> Measuring Colour
> >> Chapter 4.11 Daylight
> >> "In sunlit areas in clear sunny weather, about 90% oft he
> >> illumination
> >> comes directly from the sun and only about 10% from the sky.
> >> Because the sky is normally blue in these condition, the addition of
> >> the sky light makes the light slightly bluer, and raise the
> >> correlated
> >> colour temperature somewhat..."
> >> "a correlated colour temperature of 5500K is usually taken as a repre-
> >> sentative figur for solar altitudes not lower than about 30°."

>
> >> More about:
> >> G.Wyszecki and W. S. Stiles
> >> Color Science

>
> >> About the color of blue
> >> sky:http://www.fho-emden.de/~hoffmann/skyblue14072008.pdf

>
> >> Daylight spectra:http://www.fho-emden.de/~hoffmann/ciegraph17052004.pdf
> >> D55 means: correlated color temperatur 5500K.

>
> >> Best regards --Gernot Hoffmann

>
> > Thanks!
> > It seems to me the problem is the limited FOV of the camera, capturing
> > image. With 180 degree camera I would get better representation of the
> > skylight.
> > So the solution could be increase weight of spherical harmonics
> > responsible for average or top hemisphere.

>
> actually the issue may well be more the weighting, and not so much the
> rendering.
>
> namely, the sun will presumably be a part of the image, but you want it to
> be about 10x brighter than the rest of the sky.


I'm using floating point high dynamic range images, so that is not big
problem.
Reply With Quote
  #10  
Old 09-04-2008, 05:59 PM
Nicolas Bonneel
Guest
 
Default Re: Blue sky problem with image based lighting

serg271 a écrit :
>>> It seems to me the problem is the limited FOV of the camera, capturing
>>> image. With 180 degree camera I would get better representation of the
>>> skylight.
>>> So the solution could be increase weight of spherical harmonics
>>> responsible for average or top hemisphere.

>> actually the issue may well be more the weighting, and not so much the
>> rendering.
>>
>> namely, the sun will presumably be a part of the image, but you want it to
>> be about 10x brighter than the rest of the sky.

>
> I'm using floating point high dynamic range images, so that is not big
> problem.


but then the ringing due to spherical harmonics can become a problem if
your objects are glossy with low bump (otherwise the bumpiness can mask
the ringing). Diffuse objects won't be a problem.

If you're using real HDR images with a sun bright enough, then the
spherical harmonic lighting *is* physically based (ie. the integral of
the product of your brdf times the skylight time the angle cosine with
the normal).
You can also take into account eye sensibility to colors (eye is less
sensible to blue: http://webdiis.unizar.es/~neira/12082/colour.pdf for
curves). I think there is also some eye adapatation to blue because
human eye is used to see objects illuminated from blue skylight... but
not sure.

Cheers

--
Nicolas Bonneel
http://www.bonneel.com
Reply With Quote
Reply


Thread Tools
Display Modes


All times are GMT -5. The time now is 10:35 PM.


Powered by vBulletin® Version 3.7.2
Copyright ©2000 - 2008, Jelsoft Enterprises Ltd.
Search Engine Optimization by vBSEO 3.2.0
vB Ad Management by =RedTyger=

In an effort to better serve ads to our visitors, cookies are used on objectmix.com. For more information, check out our Privacy Policy.