HDR + per pixel shadowing

HDR + shadowing aint really related


Well in the real world light and shadow are related. The Question is, is there a realistic way to get the combined effect of HDR lighting with dynamic Shadow generation so that they interact with each other in a natural (or close to it) way.

There are lots of things in graphics rendering that are "unrelated" yet they are used together to create a game world that is atmospheric and draws you in.

Example, A Game world (Or FPS Map) with day to night transitions with HDR lighting and dynamic shadows that change naturally as the sun crosses the sky.
 
Hellbinder said:


Well in the real world light and shadow are related. The Question is, is there a realistic way to get the combined effect of HDR lighting with dynamic Shadow generation so that they interact with each other in a natural (or close to it) way.
Shadows are nothing more or less than occluded light. This doesn't change whether you're doing your calculations in HDR or LDR.

What you seem to be asking is a different question entirely: how do you get more natural shadows than the simple attempts we've seen to date? The answer is not easily. You can spend oodles of processing power and go full radiosity. Or you can do lots of pre-calculation and get real-time radiosity for static geometry. Or you can use cubemap tricks to get a rough approximation of light bouncing off of small objects.

There are other methods too, of course. But the question you seem to be asking has to do with lighting, not anything at all to do with shadowing.
 
here's what i think

---

dynamic range is the ratio between the maximum and minimum intensities of light. our eyes are very good at noticing these differences. computer displays have a limited gamut so it cannot represent our sensitivities to colour. in an attempt to better mimic dynamic range on a computer display we can do several things

A) model how our pupils dilate / contract in the presense of light (or lack thereof) by using an exposure parameter T. small values of T represent underexposure, large(r) values of T denote overexposure. the actual colour we want to use is

intensity = 1 - exp(-colour X T)

where 'X' is a component-wise multiplication. notice the relationship between T and the final colour is non-linear. the brightness control on your monitor operates on a linear scale; this explains why increasing brightness affects all colours equally which yields a 'washed out' look.

B) use floating point textures. first we downsample the original scene (OS) to create floating point texture FP. next we find out the average luminance of FP and apply a tone map to FP to yield floating point texture FP2. we then downsample FP2, blur it with a Guassian filter (because it looks nice) and then combine FP2 and OS. send this result to the display.


shadows would be handled separately but before any HDR techniques are applied.
 
Last edited by a moderator:
I think that should be:
intensity = 1 - exp(-colour X T)

Edit: Sorry, made a little mistake. Anyway, yes, this is one possible method of tonemapping.
 
Hellbinder said:
I was thinking about how HL2 source and others are introducing HDR gaming, and how Doom and FEAR use Completely Dynamic per pixel Shadowing. Although I think Monolith does it differently than Id.

Is it possible to combine both techniques? Have completely natural Dynamic HDR that Generates completely natural and dynamic Shadows that react to the surrounding amount of light, your location etc. In other words a very close to life like lighting model that covers all the bases.

Can today’s top of the line hardware do this kind of thing? Can DX9 or OpenGL do this kind of thing?

High dynamic range is nothing more than improving the dynamic range of luminosity of an image. It just so happens that in RGB color space, the luminosity and "chrominosity" are tied together, and thus the false notion that the "color" itself ranges beyond 1 in HDR.

Shadowing is simply the lack of light at any point in the scene, thus it isn't tied to the dynamic range of your scene. Any point in your scene that is under shadow will not receive any light, thus the luminosity at the point becomes zero (provided no other light contributes to that point without shadowing it).

What you are talking about is modeling a generalized global solution to lighting. That, currently, can only be approximated in real-time by using techniques like ambient occlusion and spherical harmonic lighting. In such a case, using a higher dynamic range would certainly improve the accuracy of the global lighting solution.
 
Back
Top