Repository navigation
hdrscope: Support SMPTE ST 2094-50 zero alternate images (Section B.4) - #66
Merged
Merged
Conversation
copybara-service
Bot
force-pushed
the
test_1014616314
branch
3 times, most recently
from
November 5, 2026 14:33
03ea029 to
bdfbe8e
Compare
When 2094-50 metadata specifies zero alternate images (N_alt = 0), Section B.4 dictates that tone mapping evaluates to the identity transform (ToneMap(C) = C) and the baseline image is projected/clamped to the target color volume regardless of targeted HDR headroom. Previously, HDRScope evaluated a single-point curve at (64, 0, 0) whose cubic spline right-extrapolation attenuated luminance values above 64, disabled the WASM adaptive tone mapping flag, and caused UI panels to crash when accessing metadata.altr[0]. This change adds an identity bypass when metadata.altr is empty across CPU adaptation, WebGL GLSL shaders, and UI curve editors, fixes zero-gain evaluation above 64, and adds comprehensive unit tests. PiperOrigin-RevId: 1014653774
copybara-service
Bot
force-pushed
the
test_1014616314
branch
from
November 5, 2026 14:37
bdfbe8e to
ee73fd7
Compare
This branch was successfully deployed
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
hdrscope: Support SMPTE ST 2094-50 zero alternate images (Section B.4)
When 2094-50 metadata specifies zero alternate images (N_alt = 0), Section
B.4 dictates that tone mapping evaluates to the identity transform
(ToneMap(C) = C) and the baseline image is projected/clamped to the target
color volume regardless of targeted HDR headroom.
Previously, HDRScope evaluated a single-point curve at (64, 0, 0) whose
cubic spline right-extrapolation attenuated luminance values above 64,
disabled the WASM adaptive tone mapping flag, and caused UI panels
to crash when accessing metadata.altr[0].
This change adds an identity bypass when metadata.altr is empty across
CPU adaptation, WebGL GLSL shaders, and UI curve editors, fixes zero-gain
evaluation above 64, and adds comprehensive unit tests.