Sun Strength by Elevation

Started by D.A. Bentley (SuddenPlanet), April 29, 2020, 04:20:38 PM

Previous topic - Next topic

D.A. Bentley (SuddenPlanet)

The default settings for the Sun in Terragen 4.4.63 are as follows:

Elevation = 25
Color = 1 (RGB 243, 247, 255)
Strength = 5
Angular Diameter = 0.5

What I am trying to figure out is what would the settings for a realistic Milky Way Sun be for all the elevations from say -10 degrees up to +90 degrees?

I'm wanting to use the Camera Light Exposure more now, and rely less on cranking the sun strength way up or down to affect scene exposure since I'm working on a lot of HDR skybox stuff, so knowing what I should set the sun strength to would be helpful.  

Should I just always leave it at 5, and adjust the Camera Light Exposure to compensate?  I would think not, because of atmosphere thickness at different sun elevations (low sun = photons traveling further through more atmosphere before reaching camera).

Any ideas?

-Derek

Dune

I would think it's relatively the same, as the distance from the real sun to earth doesn't change during the day. Only the angle (thus probably also more bounce) and atmospheric 'restriction' of its power (low angle, thicker atmo to penetrate). And I think TG handles that by itself. Or am I wrong in assuming so?

WAS

Quote from: D.A. Bentley on April 29, 2020, 04:20:38 PMThe default settings for the Sun in Terragen 4.4.63 are as follows:

Elevation = 25
Color = 1 (RGB 243, 247, 255)
Strength = 5
Angular Diameter = 0.5

What I am trying to figure out is what would the settings for a realistic Milky Way Sun be for all the elevations from say -10 degrees up to +90 degrees?

I'm wanting to use the Camera Light Exposure more now, and rely less on cranking the sun strength way up or down to affect scene exposure since I'm working on a lot of HDR skybox stuff, so knowing what I should set the sun strength to would be helpful. 

Should I just always leave it at 5, and adjust the Camera Light Exposure to compensate?  I would think not, because of atmosphere thickness at different sun elevations (low sun = photons traveling further through more atmosphere before reaching camera).

Any ideas?

-Derek
Also curious about this. The sun at 25 degrees, and where it sits in the sky is a pretty decent noon around here, but for midday, at let's say 45 degrees, the sun is very blown out looking in both the atmosphere and surface. Vice versa sunsets are pretty strong and I often have to lower strength and often add some orange.

N-drju

Quote from: Dune on April 30, 2020, 01:42:26 AMI would think it's relatively the same, as the distance from the real sun to earth doesn't change during the day. Only the angle (thus probably also more bounce) and atmospheric 'restriction' of its power (low angle, thicker atmo to penetrate). And I think TG handles that by itself. Or am I wrong in assuming so?

Yes and no.

Consider that you can also adjust blue-sky density, decay, haze and likewise assets. Due to these settings, in most extreme cases, you can even make a horizon sun light the environment up like it was noon. So it's not entirely TG-dependent.

But generally you are right - if it wasn't the case, you would not get yellowish-orange hue at low sun and differing amount of light at morning/sunset vs. noon. Bottom line, it is pretty much automatic, but you can make some crazy effects if you wish to. As a matter of fact, I prefer to adjust sun and atmo settings rather than exposure.
"This year - a factory of semiconductors. Next year - a factory of whole conductors!"

D.A. Bentley (SuddenPlanet)

I'll try animating some settings and try to figure out the best values.  Just was wondering if anyone had already come up with a basic chart, for starting point for realistic values (even just in the default scene).

Basically my goal is to figure out how to render a high contrast 32-bit HDR image out of terragen that is similar in dynamic range to what you would get from a camera shooting 9 brackets at (-4 -3 -2 -1 0 +1 +2 +3 +4).

This would likely be an image with a contrast ratio (dynamic range) of 16:384:1 up to 1,024,000:1 or 14EV - 20EV.  The problem I have encountered is I'm having trouble finding a tool that can accurately measure dynamic range, but I think FDR Tools is working the best.  Photomatix Pro and Picturenaut seem way off.

Because Terragen is capable of rendering out 32-bit exr with a full range I would rather continue to just render out one hdr image, instead of fusing multiple renderings into an hdr (like when doing photography).  For the past year I have been rendering single hdr images like this, but was mostly adjusting brightness levels in the scene by adjusting the sun strength, which could create unrealistic hot spots in and around the sun (i think).  So that's why I am trying to figure out the best sun strength values to use, and then I can adjust the camera exposure to get the desired overall brightness of the image.

To better illustrate this lets consider a Standard Dynamic Range (SDR) or Low Dynamic Range (LDR) image is in a range of 0 - 1 (32bit channels), or 0 - 255 (8bit channels) while a High Dynamic Range (HDR) image can contain a range even greater than 0 - 1,000,000.  I am trying to make sure that my terragen renderings are not putting all that extra brightness range all in and close to the sun, which would basically end up giving you a LDR image with an HDR sun.  So basically this comes down to choosing the correct sun strength and camera exposure to control the Histogram Levels of the image being rendered.  

Hope that makes sense.  Thanks for the input!

-Derek

N-drju

That's a lot of knowledge right there. I must admit I don't know too much about the HDR generation, I'm impressed. :)

I do, however, have one piece of advice that you may find useful. What if you adjust all needed settings into several sets, then, key them all as an animation. This way, you can pump out a series of nine images, each representing a bracket.

It's no perfect by no means, because in this method you still have to figure out appropriate settings for yourself. But a thing to consider nonetheless.
"This year - a factory of semiconductors. Next year - a factory of whole conductors!"

WAS

How would you key different atmosphere sun's snd transition accordingly?

TGs default sun isn't realistic. So dunno where that's coming from. Go for full equatorial daylight and your washed so white it's not even funny. It's realistic in the default scene.

sboerner

The early part of the discussion in this thread may be pertinent here, not sure.

D.A. Bentley (SuddenPlanet)

#8
Quote from: sboerner on April 30, 2020, 02:29:52 PMThe early part of the discussion in this thread may be pertinent here, not sure.


I took a look and that was exactly what I was looking for, so Thanks sboerner!

Especially here:  https://planetside.co.uk/forums/index.php/topic,23195.msg234926.html#msg234926
And here:  https://planetside.co.uk/forums/index.php/topic,23195.msg234966.html#msg234966

Matt

Quote from: D.A. Bentley on April 30, 2020, 11:49:08 AMThis would likely be an image with a contrast ratio (dynamic range) of 16:384:1 up to 1,024,000:1 or 14EV - 20EV.  The problem I have encountered is I'm having trouble finding a tool that can accurately measure dynamic range, but I think FDR Tools is working the best.  Photomatix Pro and Picturenaut seem way off.

Wouldn't the contrast ratio depend on what's in the scene, such as objects casting shadows, dark materials etc., or do you mean something else?

QuoteBecause Terragen is capable of rendering out 32-bit exr with a full range I would rather continue to just render out one hdr image, instead of fusing multiple renderings into an hdr (like when doing photography).  For the past year I have been rendering single hdr images like this, but was mostly adjusting brightness levels in the scene by adjusting the sun strength, which could create unrealistic hot spots in and around the sun (i think).  So that's why I am trying to figure out the best sun strength values to use, and then I can adjust the camera exposure to get the desired overall brightness of the image.

To better illustrate this lets consider a Standard Dynamic Range (SDR) or Low Dynamic Range (LDR) image is in a range of 0 - 1 (32bit channels), or 0 - 255 (8bit channels) while a High Dynamic Range (HDR) image can contain a range even greater than 0 - 1,000,000.  I am trying to make sure that my terragen renderings are not putting all that extra brightness range all in and close to the sun, which would basically end up giving you a LDR image with an HDR sun.  So basically this comes down to choosing the correct sun strength and camera exposure to control the Histogram Levels of the image being rendered.

In a scene without luminous/emissive objects, changing sunlight strength is exactly the same as changing camera exposure. I think you have three choices:

1) Leave sunlight strength the same in every image, only changing the exposure to compensate for the weather and time of day (as you would in photography).

2) Leave exposure the same (e.g. 1), only changing the sunlight. This has the advantage of allowing you to drop in different cameras without having to change their exposure, and you can save these atmosphere-and-sunlight setups for reuse in other projects, but it's a little bit backwards to how the real world worlds.

3) Use the same sunlight and exposure values for all images, letting sunset be darker than noon, and compensating in the destination renderer. Unfortunately if you do this the anti-aliasing won't be optimized for the desired appearance (e.g. if you render too dark, the renderer won't spend much time anti-aliasing dark areas which might be viewed more brightly later on, and if you render too bright it will spend less time anti-aliasing the bright areas which it thinks are overexposed even if they will be visible later on).

The choice between 1 and 2 is more about organization of your projects than anything else. They both render the same, as long as you don't have luminous (emissive) objects which are of course affected by exposure. Also, changing these things in Terragen will result in something similar - if not identical - to changing the multiplier in whatever renderer you load the EXR into for image based lighting, except that anti-aliasing won't be optimal if you render at sunlight/exposure values that don't look similar to what you'll end up with.

Choice 3 is not ideal if you care about quality and/or render times, because anti-aliasing is optimized for what's visible in the image at render time.
Just because milk is white doesn't mean that clouds are made of milk.

Matt

Quote from: WAS on April 30, 2020, 01:58:05 PMTGs default sun isn't realistic. So dunno where that's coming from. Go for full equatorial daylight and your washed so white it's not even funny. It's realistic in the default scene.

You need to change the exposure, just as you would in the real world (or an auto-exposure camera does for you automatically).
Just because milk is white doesn't mean that clouds are made of milk.

WAS

Exposure seems like a great way actually. Gives you a slider that more appropriately balances for the scene imo. Sun strength is similar but doesn't seem to balance as well with other settings (surface/atmo strength)

Thanks for that.

D.A. Bentley (SuddenPlanet)