Re: [Flightgear-devel] Object distance fading color

2011-06-06 Thread thorsten . i . renk

I've just pulled the new version and had a look and... it looks *very*
impressive - with just a few property edits, one can generate a dark,
overcast scene from a summer sky, and the diffuse haze comes out very
nicely.


 Come to think of it, this might not be exactly what you're looking for
 but it could be useful to render overcast without an extreme amount of
 cloud vertices.

 Need to dig deeper to only affect the zenith of the skydome since that's
 handled elsewhere.

After having a look, I realized something which I had not appreciated
before, which is that as it is done now, it fixes a different problem:
Currently, if we have overcast layers with good view underneath, the layer
edge is always visible, i.e. there's blue sky at the horizon. The overcast
property actually closes the horizon gap, i.e. in combination with a 3d
layer drawn out to 55 km, the effect may be much better than what we have
now.

I have to write some code to set the amount of overcast as a function of
altitude and play with it to see if it really gets the impression of a
diffuse layer which can be crossed or if it is in the end needed to touch
zenith and horizon separately - but my first impression is that what you
have created is really working well for what I need.

Thanks!

* Thorsten




--
Simplify data backup and recovery for your virtual environment with vRanger.
Installation's a snap, and flexible recovery options mean your data is safe,
secure and there when you need it. Discover what all the cheering's about.
Get your free trial download today. 
http://p.sf.net/sfu/quest-dev2dev2 
___
Flightgear-devel mailing list
Flightgear-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/flightgear-devel


Re: [Flightgear-devel] Object distance fading color

2011-06-05 Thread Erik Hofman
On Fri, 2011-06-03 at 10:36 +0300, thorsten.i.renk  jyu.fi wrote:
 I was toying with the idea to model diffuse high-altitude haze by coloring
 the skydome as a function of altitude, i.e. paint the zenith a bit more
 hazy without touching the horizon and remove that effect again as you get
 above the haze layer - I believe that might create a better impression of
 such diffuse layers than placing texture sheets into the scene.

Code for this has now been pushed to GIT.

There is now a new property /rendering/scene/overcast ranging from 0.0
(normal behavior) to 1.0 (complete overcast).

Erik


--
Simplify data backup and recovery for your virtual environment with vRanger.
Installation's a snap, and flexible recovery options mean your data is safe,
secure and there when you need it. Discover what all the cheering's about.
Get your free trial download today. 
http://p.sf.net/sfu/quest-dev2dev2 
___
Flightgear-devel mailing list
Flightgear-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/flightgear-devel


Re: [Flightgear-devel] Object distance fading color

2011-06-05 Thread Erik Hofman
On Sun, 2011-06-05 at 10:26 +0200, Erik Hofman wrote:
 On Fri, 2011-06-03 at 10:36 +0300, thorsten.i.renk  jyu.fi wrote:
  I was toying with the idea to model diffuse high-altitude haze by coloring
  the skydome as a function of altitude, i.e. paint the zenith a bit more
  hazy without touching the horizon and remove that effect again as you get
  above the haze layer - I believe that might create a better impression of
  such diffuse layers than placing texture sheets into the scene.
 
 Code for this has now been pushed to GIT.
 
 There is now a new property /rendering/scene/overcast ranging from 0.0
 (normal behavior) to 1.0 (complete overcast).

Come to think of it, this might not be exactly what you're looking for
but it could be useful to render overcast without an extreme amount of
cloud vertices.

Need to dig deeper to only affect the zenith of the skydome since that's
handled elsewhere.

Erik


--
Simplify data backup and recovery for your virtual environment with vRanger.
Installation's a snap, and flexible recovery options mean your data is safe,
secure and there when you need it. Discover what all the cheering's about.
Get your free trial download today. 
http://p.sf.net/sfu/quest-dev2dev2 
___
Flightgear-devel mailing list
Flightgear-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/flightgear-devel


Re: [Flightgear-devel] Object distance fading color

2011-06-05 Thread ThorstenB
On 05.06.2011 10:26, Erik Hofman wrote:
 There is now a new property /rendering/scene/overcast ranging from 0.0
 (normal behavior) to 1.0 (complete overcast).

Just wondering: we have /sim/rendering, which contains a long list of 
properties - including properties for clouds and precipitation. And we 
have /rendering which contains the scene/dome properties only. Is there 
a specific reasons these are separate?

cheers,
Thorsten

--
Simplify data backup and recovery for your virtual environment with vRanger.
Installation's a snap, and flexible recovery options mean your data is safe,
secure and there when you need it. Discover what all the cheering's about.
Get your free trial download today. 
http://p.sf.net/sfu/quest-dev2dev2 
___
Flightgear-devel mailing list
Flightgear-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/flightgear-devel


Re: [Flightgear-devel] Object distance fading color

2011-06-05 Thread Erik Hofman
On Sun, 2011-06-05 at 14:34 +0200, ThorstenB wrote:
 On 05.06.2011 10:26, Erik Hofman wrote:
  There is now a new property /rendering/scene/overcast ranging from 0.0
  (normal behavior) to 1.0 (complete overcast).
 
 Just wondering: we have /sim/rendering, which contains a long list of 
 properties - including properties for clouds and precipitation. And we 
 have /rendering which contains the scene/dome properties only. Is there 
 a specific reasons these are separate?

Not that I know of, but I was always under the impression
that /sim/rendering was honored once at startup only.

Erik


--
Simplify data backup and recovery for your virtual environment with vRanger.
Installation's a snap, and flexible recovery options mean your data is safe,
secure and there when you need it. Discover what all the cheering's about.
Get your free trial download today. 
http://p.sf.net/sfu/quest-dev2dev2 
___
Flightgear-devel mailing list
Flightgear-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/flightgear-devel


Re: [Flightgear-devel] Object distance fading color

2011-06-04 Thread Erik Hofman
On Fri, 2011-06-03 at 10:36 +0300, thorsten.i.r...@jyu.fi wrote:
  I'll see what I can come up with this weekend.
 
 Thanks, much appreciated!

I've pushed a code change to be able to control the amount of light
scattering (or absorption) of the fog by adjusting
the /rendering/scene/scattering property. A value of 1.0 is full
scattering and a value of 0.0 is full absorption (unrealistic). The
default is set to 0.8 now.

This did however revealed a sun position and for brightness position
mismatch that I've confirmed was already in the code before this change.
I can't believe no one noticed the massive offset at dusk (for KSFO)
before.

  On another note: I seem to remember you had another request for the
  weather system but I was too busy to remember it. Do you remember what
  that was?
 
 I was toying with the idea to model diffuse high-altitude haze by coloring
 the skydome as a function of altitude, i.e. paint the zenith a bit more
 hazy without touching the horizon and remove that effect again as you get
 above the haze layer - I believe that might create a better impression of
 such diffuse layers than placing texture sheets into the scene.

Ah yes, that was it, need to take another look at that then.

Erik


--
Simplify data backup and recovery for your virtual environment with vRanger.
Installation's a snap, and flexible recovery options mean your data is safe,
secure and there when you need it. Discover what all the cheering's about.
Get your free trial download today. 
http://p.sf.net/sfu/quest-dev2dev2 
___
Flightgear-devel mailing list
Flightgear-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/flightgear-devel


Re: [Flightgear-devel] Object distance fading color

2011-06-04 Thread Torsten Dreyer

 I've pushed a code change to be able to control the amount of light
 scattering (or absorption) of the fog by adjusting
 the /rendering/scene/scattering property. A value of 1.0 is full
 scattering and a value of 0.0 is full absorption (unrealistic). The
 default is set to 0.8 now.
Erik,

prop-tie(/environment/relative-humidity,SGRawValuePointerfloat(_humidity));

is probably not a good idea since the FGEnvironment ties to this property, too 
(and it's
the system that owns aka calculates this property.

You should use getNode() and getDoubleValue() instead.

Torsten

--
Simplify data backup and recovery for your virtual environment with vRanger.
Installation's a snap, and flexible recovery options mean your data is safe,
secure and there when you need it. Discover what all the cheering's about.
Get your free trial download today. 
http://p.sf.net/sfu/quest-dev2dev2 
___
Flightgear-devel mailing list
Flightgear-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/flightgear-devel


Re: [Flightgear-devel] Object distance fading color

2011-06-04 Thread Erik Hofman
On Sat, 2011-06-04 at 15:03 +0200, Torsten Dreyer wrote:
 prop-tie(/environment/relative-humidity,SGRawValuePointerfloat(_humidity));
 
 is probably not a good idea since the FGEnvironment ties to this property, 
 too (and it's
 the system that owns aka calculates this property.
 
 You should use getNode() and getDoubleValue() instead.

You're probably right, I didn't think of that. This part is reverted
now. Thanks.

Erik


--
Simplify data backup and recovery for your virtual environment with vRanger.
Installation's a snap, and flexible recovery options mean your data is safe,
secure and there when you need it. Discover what all the cheering's about.
Get your free trial download today. 
http://p.sf.net/sfu/quest-dev2dev2 
___
Flightgear-devel mailing list
Flightgear-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/flightgear-devel


Re: [Flightgear-devel] Object distance fading color

2011-06-03 Thread thorsten . i . renk
 I'll see what I can come up with this weekend.

Thanks, much appreciated!

 On another note: I seem to remember you had another request for the
 weather system but I was too busy to remember it. Do you remember what
 that was?

I was toying with the idea to model diffuse high-altitude haze by coloring
the skydome as a function of altitude, i.e. paint the zenith a bit more
hazy without touching the horizon and remove that effect again as you get
above the haze layer - I believe that might create a better impression of
such diffuse layers than placing texture sheets into the scene.

Cheers,

* Thorsten


--
Simplify data backup and recovery for your virtual environment with vRanger.
Installation's a snap, and flexible recovery options mean your data is safe,
secure and there when you need it. Discover what all the cheering's about.
Get your free trial download today. 
http://p.sf.net/sfu/quest-dev2dev2 
___
Flightgear-devel mailing list
Flightgear-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/flightgear-devel


Re: [Flightgear-devel] Object distance fading color

2011-06-02 Thread thorsten . i . renk
 Part of the problem is that FlightGear almost always renders ideal
 situations for the skydome.
 If you look at this picture you see there are situations where white fog
 is natural:
 http://upload.wikimedia.org/wikipedia/commons/2/2a/St.Gilgen_Panorama_2007-02-22.jpg
But you obviously won't get that with the sun hidden behind a cloudy
 sky.



Yes, that was my analysis as well. My point is - the skydome or terrain
shader code can't know a priori. But all our weather systems have the
relevant information readily available - all we need to do is expose a
property which tells the distance fading code how much sunlight is
available at a given altitude  (below a layer, mountains should fade to
dark, above to white for instance).

* Thorsten


--
Simplify data backup and recovery for your virtual environment with vRanger. 
Installation's a snap, and flexible recovery options mean your data is safe,
secure and there when you need it. Data protection magic?
Nope - It's vRanger. Get your free trial download today. 
http://p.sf.net/sfu/quest-sfdev2dev
___
Flightgear-devel mailing list
Flightgear-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/flightgear-devel


Re: [Flightgear-devel] Object distance fading color

2011-06-02 Thread Erik Hofman
On Thu, 2011-06-02 at 12:53 +0300, thorsten.i.r...@jyu.fi wrote:

 Yes, that was my analysis as well. My point is - the skydome or terrain
 shader code can't know a priori. But all our weather systems have the
 relevant information readily available - all we need to do is expose a
 property which tells the distance fading code how much sunlight is
 available at a given altitude  (below a layer, mountains should fade to
 dark, above to white for instance).

I'll see what I can come up with this weekend.
On another note: I seem to remember you had another request for the
weather system but I was too busy to remember it. Do you remember what
that was?

Erik


--
Simplify data backup and recovery for your virtual environment with vRanger. 
Installation's a snap, and flexible recovery options mean your data is safe,
secure and there when you need it. Data protection magic?
Nope - It's vRanger. Get your free trial download today. 
http://p.sf.net/sfu/quest-sfdev2dev
___
Flightgear-devel mailing list
Flightgear-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/flightgear-devel


[Flightgear-devel] Object distance fading color

2011-06-01 Thread thorsten . i . renk

I've recently done a visual comparison between hires Flightgear scenery
and reality - for those interested, see here:

http://www.flightgear.org/forums/viewtopic.php?f=5t=12259

One of the striking points is that in reality even in partially clouded
skies distant objects do not start to fade into white (as the Flightgear
terrain shader assumes) but into darker colors, sometimes providing a
striking contrast with the horizon sky color before they fade into the
horizon color at even larger distance.

I've played a bit with /rendering/scene/saturation to see if there was a
way to recover that, but it didn't seem to do the right thing.

I believe the relevant parameter is the amount of light reaching the
surface at a given altitude. Naturally, the terrain shader can't know that
up front, but the weather system has all the the information needed.

If anyone is interested in attacking that problem from the shader side by
exposing a property which can dial the 'darkness' of distant objects when
they start to lose their color, I'd be happy to do my part from the
weather side and cook up a model which sets the parameter value dependent
on conditions.

* Thorsten


--
Simplify data backup and recovery for your virtual environment with vRanger. 
Installation's a snap, and flexible recovery options mean your data is safe,
secure and there when you need it. Data protection magic?
Nope - It's vRanger. Get your free trial download today. 
http://p.sf.net/sfu/quest-sfdev2dev
___
Flightgear-devel mailing list
Flightgear-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/flightgear-devel


Re: [Flightgear-devel] Object distance fading color

2011-06-01 Thread Erik Hofman
On Wed, 2011-06-01 at 14:50 +0300, thorsten.i.r...@jyu.fi wrote:
 I've recently done a visual comparison between hires Flightgear scenery
 and reality - for those interested, see here:
 
 http://www.flightgear.org/forums/viewtopic.php?f=5t=12259
 
 One of the striking points is that in reality even in partially clouded
 skies distant objects do not start to fade into white (as the Flightgear
 terrain shader assumes) but into darker colors, sometimes providing a
 striking contrast with the horizon sky color before they fade into the
 horizon color at even larger distance.
 
 I've played a bit with /rendering/scene/saturation to see if there was a
 way to recover that, but it didn't seem to do the right thing.
 
 I believe the relevant parameter is the amount of light reaching the
 surface at a given altitude. Naturally, the terrain shader can't know that
 up front, but the weather system has all the the information needed.
 
 If anyone is interested in attacking that problem from the shader side by
 exposing a property which can dial the 'darkness' of distant objects when
 they start to lose their color, I'd be happy to do my part from the
 weather side and cook up a model which sets the parameter value dependent
 on conditions.

Part of the problem is that FlightGear almost always renders ideal
situations for the skydome.
If you look at this picture you see there are situations where white fog
is natural:
http://upload.wikimedia.org/wikipedia/commons/2/2a/St.Gilgen_Panorama_2007-02-22.jpg

But you obviously won't get that with the sun hidden behind a cloudy
sky.

Erik


--
Simplify data backup and recovery for your virtual environment with vRanger. 
Installation's a snap, and flexible recovery options mean your data is safe,
secure and there when you need it. Data protection magic?
Nope - It's vRanger. Get your free trial download today. 
http://p.sf.net/sfu/quest-sfdev2dev
___
Flightgear-devel mailing list
Flightgear-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/flightgear-devel