Two planes: read sRGB planes as plain UNORM so the scene's bytes reach the screen unchanged #1668

Merged
101Leafy merged 4 commits from upstream-pr/1668 into main 2026-11-29 08:16:55 +00:00
101Leafy commented 2026-11-28 23:14:04 +00:00 (Migrated from github.com)

Imported from trustno1-coder/VIctory-NVIDIA. Originally posted by 101Leafy on 2026-11-28T23:14:04Z.


When a present has two planes, the composer picked a shader view for each plane that kept a typed resource's own format. For the sRGB formats (29 and 91) that meant the sampler decoded the bytes to linear before they were drawn into the back buffer, which a one-plane present never does, since its copy takes the bytes as they are.

Now sRGB planes are viewed as plain R8G8B8A8_UNORM or B8G8R8A8_UNORM, so the composed picture carries the same bytes as a one-plane present would. Other formats are viewed as before. This is a plain fix to what reaches the screen, so there is no switch.

<!-- greyfinch-sync:trustno1-coder/VIctory-NVIDIA:issue:5545524536 --> Imported from [trustno1-coder/VIctory-NVIDIA](https://github.com/trustno1-coder/VIctory-NVIDIA/pull/1668). Originally posted by [101Leafy](https://github.com/101Leafy) on 2026-11-28T23:14:04Z. --- When a present has two planes, the composer picked a shader view for each plane that kept a typed resource's own format. For the sRGB formats (29 and 91) that meant the sampler decoded the bytes to linear before they were drawn into the back buffer, which a one-plane present never does, since its copy takes the bytes as they are. Now sRGB planes are viewed as plain R8G8B8A8_UNORM or B8G8R8A8_UNORM, so the composed picture carries the same bytes as a one-plane present would. Other formats are viewed as before. This is a plain fix to what reaches the screen, so there is no switch.
nick0451 commented 2026-11-29 02:46:29 +00:00 (Migrated from github.com)

Imported from trustno1-coder/VIctory-NVIDIA. Originally posted by nick0451 on 2026-11-29T02:46:29Z.


Tested together with #1709 on an RTX 3090: no effect in this setup, because both planes are format 28 (R8G8B8A8_UNORM), not sRGB 29/91. Details and numbers in https://github.com/trustno1-coder/VIctory-NVIDIA/pull/1709 (latest comment). It runs cleanly, with no crash and no speed change.

🤖 Generated with Claude Code

<!-- greyfinch-sync:trustno1-coder/VIctory-NVIDIA:comment:7249638800 --> Imported from [trustno1-coder/VIctory-NVIDIA](https://github.com/trustno1-coder/VIctory-NVIDIA/pull/1668#issuecomment-7249638800). Originally posted by [nick0451](https://github.com/nick0451) on 2026-11-29T02:46:29Z. --- Tested together with #1709 on an RTX 3090: no effect in this setup, because both planes are format 28 (R8G8B8A8_UNORM), not sRGB 29/91. Details and numbers in https://github.com/trustno1-coder/VIctory-NVIDIA/pull/1709 (latest comment). It runs cleanly, with no crash and no speed change. 🤖 Generated with [Claude Code](https://claude.com/claude-code)
Sign in to join this conversation.
No reviewers
No labels
No milestone
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Reference
trustno1-coder/VIctory-NVIDIA!1668
No description provided.