Sign in to follow this  

question about HDR luminance calculation

This topic is 3627 days old which is more than the 365 day threshold we allow for new replies. Please post a new topic.

If you intended to correct an error in the post then please contact us.

Recommended Posts

Good evening, Im following the directx sdk HDR sample for doing some nice HDR tone mapping, and i notice that to calculate luminance, they calculate luminance first for a scaled down version of the scene, then average all of these luminance values together to get the average luminace for the scene The equation they use to calculate luminance for a single pixel is: lum = log(dot(colorValue, LUMINANCE_VECTOR) + 0.0001f) Im wondering if instead of doing luminance calculation then averaging, if I could instead average my color values first then do a single luminance calculation on that average color and still get a correct luminance for the scene?

Share this post


Link to post
Share on other sites
Yup, you have to convert to luminance first before averaging. But the upside of that is that the surfaces you use for downsampling will be smaller, since they only need one or two channels.

Also if you're interested in seeing the math for luminance calculation and tone-mapping, it all comes from this paper.

Share this post


Link to post
Share on other sites

This topic is 3627 days old which is more than the 365 day threshold we allow for new replies. Please post a new topic.

If you intended to correct an error in the post then please contact us.

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now

Sign in to follow this