Skip to content

fix(ocio): use the OCIO display in HDR presentation and read file rules on OCIO 2.6 - #183

Merged
mcoliver merged 1 commit into
mainfrom
fix/ocio-display-for-hdr-presentation
Oct 27, 2026
Merged

mcoliver merged 1 commit into
mainfrom
fix/ocio-display-for-hdr-presentation

Conversation

@mcoliver

Copy link
Copy Markdown
Collaborator

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

  • Use OCIO for the main window's display in PQ/HLG. When a source loads, the main window's display switches to OCIO, and feat(ocio): pick the OCIO display and view for the presentation and footage #161 picks the Rec.2100 display and the view for the footage. A display the user turns OCIO off for (OCIO menu → display → Active) stays off for later sources. SDR and EDR are unchanged.
  • File rules on PyOpenColorIO 2.6. 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 - Display with Video (colorimetric).
  • The presentation mode only applies to the main window. NDI, SDI and other outputs were also given the Rec.2100-PQ display. They now get the config's default display, and no presentation warnings.

Testing

Ran the current dev build (b69d259) with this ocio_source_setup.py swapped in, loaded a generated SMPTE bars PNG, and dumped the OCIO state from Python:

Presentation Main window display / view NDI output PNG input
PQ, before built-in sRGB built-in none
PQ, after Rec.2100-PQ - Display / Video (colorimetric) sRGB - Display / Video (colorimetric) sRGB - Display
SDR, after built-in sRGB (unchanged) built-in none

Part of #155 / #157.

@mcoliver mcoliver closed this Oct 27, 2026
@mcoliver
mcoliver force-pushed the fix/ocio-display-for-hdr-presentation branch from 8d0c3c9 to c1c937a Compare October 27, 2026 02:55
…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>
@mcoliver mcoliver reopened this Oct 27, 2026
@mcoliver
mcoliver merged commit ca41fa2 into main Oct 27, 2026
16 checks passed
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.

1 participant