-
Notifications
You must be signed in to change notification settings - Fork 629
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
.hdr
images decoded as LDR.
#1936
Comments
Closed
This is a bug, but one that existing code may be unintentionally relying on. I think the right approach is probably to change when we release |
I submitted a patch, will 0.25 be the next release? |
We'll see. There may be a 0.24.7 release first |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
In my renderer, I was using the following code to load radiance HDR image (
.hdr
extension), but noticed that all values were getting clamped to [0; 1] range:I was able to fix it by adding a special case:
I noticed it seems to be caused by this line
HdrAdapter::read_image_data
:I guess the simple fix would just be to swap the call to
read_image_hdr
instead. I'm mainly opening this bug report to verify if this is intentional or indeed a bug. It seems like too obvious of a mistake to me.Expected
.hdr
image is decoded as HDR values, nothing is clamped.Actual behaviour
.hdr
image is decoded such that all pixels above 1.0 are clamped to 1.0.Reproduction steps
Run the code from the first snippet, passing a path to an
.hdr
image. Read the pixel values and observe all will be clamped. Attaching the image file I used to test.https://dl.polyhaven.org/file/ph-assets/HDRIs/hdr/2k/clarens_midday_2k.hdr
The text was updated successfully, but these errors were encountered: