Skip to content

Conversation

@WestLangley
Copy link
Collaborator

Mostly minor clean up...

...but I also changed the default metalness to 0, because the HDR effect -- the point of the example -- is not perceptually different from the LDR case when the metalness is 1.

@WestLangley
Copy link
Collaborator Author

Unrelated: The tonemapping exposure is set like so:

renderer.toneMappingExposure = Math.pow( params.exposure, 4.0 );

This produces unreasonably overexposed results for the specified [ 0, 2 ] exposure range. I know this was copied from elsewhere, but is there a reason for the power relationship here? Don't we want perceptually-linear behavior? Why not simply:

renderer.toneMappingExposure = params.exposure;

/ping @bhouston for your thoughts...

@bhouston
Copy link
Contributor

bhouston commented Apr 1, 2018

The equation is my fault.

There are two different exposures. I believe that internally to Three.JS we should keep exposure linear ( https://en.wikipedia.org/wiki/Exposure_(photography) ) but sometimes people like to have perceptual like controls and that is generally an exponeitial ( https://en.wikipedia.org/wiki/Exposure_value ).

Although the equation for the exponential exposure is more like ( Math.pow( 2, exposureValue ) * D + C ) = exposure, but I haven't yet researched exactly what D and C should be. That should be fairly simple to figure out.

@WestLangley
Copy link
Collaborator Author

Thanks @bhouston. We can deal with it in a separate PR.

This can be merged, then.

@mrdoob mrdoob added this to the r92 milestone Apr 3, 2018
@mrdoob mrdoob merged commit 2eed75f into mrdoob:dev Apr 3, 2018
@mrdoob
Copy link
Owner

mrdoob commented Apr 3, 2018

Thanks!

@WestLangley WestLangley deleted the dev-exr branch April 3, 2018 01:27
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants