Repository navigation
Conversation
The 14.x firmware blends the X byte of XRGB8888 as straight alpha and ignores the opaque/premultiplied surface flag, so pure green and blue render black whenever a compositor leaves a zero in the X byte, and saturated colours get dimmed by their own red byte (omacom/linux-aurora aurora-silicon#308). Mechanically: the 14.x swap encodes the surface as 'BGRA' with s[DCP_V14_SURF_OPAQUE] = (format == XRGB8888), and this firmware blends straight alpha regardless of the opaque flag. Drop XRGB8888 from dcp_primary_formats_14_7 so the only 8-bit format offered on the 14.x panel primary plane is ARGB8888. Compositors write a real alpha of 255, which the blend then leaves untouched. Mutter walks its default GBM format list and lands on ARGB8888 with no userspace changes. Tested on the built-in panels of a j516s and a j514s: pure green and blue correct, no red-weighted dimming, whites and greys unchanged, dcpext output and 120 Hz presentation unaffected.
|
[Joshua's agent] Friendly heads-up from a related fault we just measured: on the M5 internal panel, a primary plane without XRGB8888 makes Hyprland 0.57 show frames two updates late. Hyprland asks for XR24; when the plane does not offer it, the compositor allocates AR24 while its monitor format stays XR24, and |
|
[Joshua's agent] Withdrawing my advice above. On reflection it was wrong for this hardware: if the 14.7 firmware blends X as alpha (per omacom/linux-aurora#308 in your description), keeping XRGB8888 on the plane keeps the broken format, not the working one. Dropping it, as this PR does, matches what the firmware actually scans out. For information only: on a stock Hyprland 0.57 stack, a plane without XR24 fails to start on that output ("GBM: Failed to allocate a GBM buffer: format XR24 isn't supported by primary backend", per hyprwm/aquamarine#496) rather than showing stale frames; the "two frames late" symptom I cited came from our own downstream AR24-fallback patch layered on a different driver gap. The design choice here is yours; sorry for the misdirected advice. |
The 14.x firmware blends the X byte of XRGB8888 as straight alpha and ignores the opaque/premultiplied surface flag, so pure green and blue render black whenever a compositor leaves a zero in the X byte, and saturated colours get dimmed by their own red byte (omacom/linux-aurora #308).
Dropping XRGB8888 from
dcp_primary_formats_14_7leaves ARGB8888 as the only 8-bit format on the 14.x panel primary plane. Compositors write a real alpha of 255, which the blend leaves untouched — mutter walks its default GBM format list and lands on ARGB8888 with no userspace changes.Tested on the built-in panels of a j516s and a j514s: pure green and blue correct, no red-weighted dimming, whites and greys unchanged, dcpext output and 120 Hz presentation unaffected.
Companion PR for the 120 Hz pacing fix (omacom/linux-aurora #31): #1969
Assisted-by: GLM 5.3 Flash