Repository navigation
fix(ocio): use the OCIO display in HDR presentation and read file rules on OCIO 2.6 - #183
Merged
Merged
Conversation
mcoliver
force-pushed
the
fix/ocio-display-for-hdr-presentation
branch
from
October 27, 2026 02:55
8d0c3c9 to
c1c937a
Compare
…es on OCIO 2.6 With the macOS presentation set to HDR PQ or HLG and no OCIO display chosen, an sRGB still went through the built-in sRGB display onto a surface that expects Rec.2100, so it came out oversaturated and too bright. The main window's display now switches to OCIO when a source loads in those modes, which picks the Rec.2100 display and the view for the footage (#161). A display the user turns OCIO off for stays off. Two fixes on the way: - PyOpenColorIO 2.6 returns (color space, rule index) from getColorSpaceFromFilepath(), and that tuple was used as the color space name. Sources classified by the file rules (a PNG, for example) got an OCIO input with an empty color space and the scene-referred view. They now get e.g. sRGB - Display and Video (colorimetric). - The presentation mode only applies to the main window. NDI, SDI and other outputs got the Rec.2100-PQ display too; they now get the config's default display and no presentation warnings. Signed-off-by: Michael Oliver <mcoliver@gmail.com>
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.
Problem
With macOS Presentation set to HDR PQ (Rec.2100) or HLG and no OCIO display chosen, an sRGB still (a PNG, for example) looks oversaturated and too bright. The built-in display sends sRGB-encoded Rec.709, but the PQ/HLG surface expects Rec.2100.
Changes
getColorSpaceFromFilepath()returns(color space, rule index), and that tuple was used as the color space name. Sources classified by the file rules got an OCIO input with an empty color space and the scene-referred ACES view, whether OCIO was turned on automatically or from the menu. They now get the rule's color space, e.g.sRGB - DisplaywithVideo (colorimetric).Testing
Ran the current dev build (b69d259) with this
ocio_source_setup.pyswapped in, loaded a generated SMPTE bars PNG, and dumped the OCIO state from Python:Part of #155 / #157.