Repository navigation
Map sRGB into each display's gamut on Apple Silicon - #17640
Conversation
On Apple Silicon the display controller sends the XDR its native P3 and Asahi's driver can't tag the signal as sRGB, so everything showed oversaturated. Give every monitor rule for the XDR cm = "edid" there, including the panel's port-named rules. A PC signals sRGB and the display maps it itself, so nothing changes off Apple Silicon. Co-Authored-By: Claude Opus 5.5 <[email protected]>
The display controller never tags any external display as sRGB, so any wide-gamut one shows oversaturated, and an sRGB display or the built-in panel (which has no EDID) is unchanged by it. Dropping the XDR matching leaves a few lines. Co-Authored-By: Claude Opus 5.5 <[email protected]>
[Medium impact] The PR appears safe to merge; the earlier color-choice overwrite is fixed. SummaryThe PR maps sRGB colors into each display's reported gamut on Apple Silicon.
The previous finding is addressed. No new actionable issues were found. Reviews (2) · Last reviewed commit: "Keep a cm chosen in monitors.lua when th..." · Reviewed by Greptile |
The panel's saved settings load after hypr/monitors.lua as port-named rules without cm, so the wrapper overrode an explicit choice with edid. Carry a chosen cm to later rules for that port, the monitor's description, or every monitor. Co-Authored-By: Claude Opus 5.5 <[email protected]>
|
Should n t be Apple Silicon builtin (MacBook Pro) Display P3 color instead of sRGB ? |
Sync upstream quattro through omacom#17640
|
Data point from an M1 Max (j314c, DCP firmware 13.5) driving a Studio Display XDR at 5120x2880@60 over Thunderbolt, Omarchy with Hyprland 0.57.1, side by side with the built-in panel on a swatch page. The compositor-side mapping is only half of it on this machine. Stock Could you post this line from the M2 Pro with the Pro Display XDR? If it says Two interactions worth knowing about:
The decoded ColorElements table for the XDR (which modes the firmware offers per timing, and their scores) and the full trial log are in https://github.com/briantoll/omarchy-thunderbolt-display/blob/main/notes/display-color.md. Happy to test any revision of this on the M1 Max. |
On an Apple Silicon Mac, the Pro Display XDR showed every color oversaturated. The same display looks right connected to a PC.
The Mac's display controller (DCP) sends the display its native gamut, because macOS does the color matching itself. Asahi's
appledrmexposes noColorspaceproperty for the display, so Hyprland can't tag the signal as sRGB. sRGB content therefore reaches a P3 panel unconverted. A PC's GPU driver signals sRGB, and the XDR maps it itself.This change has Hyprland do the mapping on Apple Silicon:
cm = "edid"converts sRGB into the gamut each display's EDID reports. That fixes any wide-gamut display and changes nothing on an sRGB one. The built-in panel has no EDID, so Hyprland falls back to sRGB for it, exactly as before.default/hypr/wide-gamut.luawrapshl.monitorand gives every rule without acmof its owncm = "edid". That covers rules from the config and the port-named rules the monitor panel andbin/commands send throughhyprctl eval, since a rule withoutcmputs the display back on sRGB. Nothing changes off Apple Silicon, where converting would happen twice and wash the colors out.This is a workaround for the Asahi display driver, and it should come out once the driver handles color.
Testing
edidand the built-in panel stays onsrgb. A panel-style port rule keeps the XDR onedid, and an explicitcmoverrides it.test/shell.d/hyprland-monitor-settings-test.shcovers the rule handling on and off Apple Silicon, and fails without the module.🤖 Generated with Claude Code