Present: two planes are put together in the scene's own format, not 8-bit #1709

Open
github-bot wants to merge 1 commit from github-bot/gh-1709 into main AGit
Owner

@⁠101Leafy on GitHub · 2026-11-28 23:41 UTC · original
101Leafy:nv/present-format → main · +13 −23 · 1 files · 1 commits · open

With two planes, the scene and the interface were put together into an 8-bit back buffer whatever format the scene was drawn in, so a 10-bit or float scene banded its gradients on the way to the screen.

The composer now draws into the scene's own format. A scene the swap chain cannot take as it is (R9G9B9E5) still composes, into half floats, and the composer is made again when the format changes. This is a fix with no switch.

**@⁠101Leafy** on GitHub · 2026-11-28 23:41 UTC · [original](https://github.com/trustno1-coder/VIctory-NVIDIA/pull/1709) `101Leafy:nv/present-format` → `main` · +13 −23 · 1 files · 1 commits · open With two planes, the scene and the interface were put together into an 8-bit back buffer whatever format the scene was drawn in, so a 10-bit or float scene banded its gradients on the way to the screen. The composer now draws into the scene's own format. A scene the swap chain cannot take as it is (R9G9B9E5) still composes, into half floats, and the composer is made again when the format changes. This is a fix with no switch.
github-bot locked as GitHub sync and limited conversation to collaborators 2026-11-28 23:46:49 +00:00
Author
Owner

@⁠UwUCammie on GitHub · 2026-11-28 23:42 UTC · original

Could the composer be created only after the resize block in Host::present_planes? On a two-plane format change, p.composer = Some(c) drops the old composer before settle_now(WHY_SYNC). Its views vector owns the shader-visible descriptor heaps that earlier queued presents can still be using. After a successful resize the code then clears the new composer and creates it a second time.

The existing post-resize creation block covers first use as well. Keeping the current composer through the fence and successful resize would preserve those heaps and avoid the second PSO creation. I traced this on 32dedcee; I haven't reproduced a device loss.

**@⁠UwUCammie** on GitHub · 2026-11-28 23:42 UTC · [original](https://github.com/trustno1-coder/VIctory-NVIDIA/pull/1709#issuecomment-7247606273) Could the composer be created only after the resize block in `Host::present_planes`? On a two-plane format change, `p.composer = Some(c)` drops the old composer before `settle_now(WHY_SYNC)`. Its `views` vector owns the shader-visible descriptor heaps that earlier queued presents can still be using. After a successful resize the code then clears the new composer and creates it a second time. The existing post-resize creation block covers first use as well. Keeping the current composer through the fence and successful resize would preserve those heaps and avoid the second PSO creation. I traced this on `32dedcee`; I haven't reproduced a device loss.
github-bot force-pushed github-bot/gh-1709 from 32dedcee69 to dc5668e8d6 2026-11-29 01:47:29 +00:00 Compare
Author
Owner

@⁠nick0451 on GitHub · 2026-11-29 02:46 UTC · original

Tried on an RTX 3090, Windows 11, merged onto main d148613 (#1709 and #1668 each separately). Series S, DLSS performance, a balcony save, 2 rounds each against main.

Both run cleanly: no crash, 24.7 / 25.4 fps against main's 25.6 (inside the noise), the same picture. But neither change takes effect in this setup: the log says display output: compositing two planes (overlay active) … base_format=28 overlay_format=28, so both planes are R8G8B8A8_UNORM. That's neither a 10-bit/float scene (#1709) nor an sRGB plane, 29 or 91 (#1668). Someone whose log shows another base_format or overlay_format is needed to see the difference.

Side note: both branches carry the same three base commits (the 768 KiB policy limit, victory-gpu clippy, checked_div in the LDS cap). On current main, cargo xtask policy fails on lower.rs (704,996 bytes) and clippy stops at manual_checked_ops, so those commits fix real failures there.

🤖 Generated with Claude Code

**@⁠nick0451** on GitHub · 2026-11-29 02:46 UTC · [original](https://github.com/trustno1-coder/VIctory-NVIDIA/pull/1709#issuecomment-7249638568) Tried on an RTX 3090, Windows 11, merged onto main `d148613` (#1709 and #1668 each separately). Series S, DLSS performance, a balcony save, 2 rounds each against main. Both run cleanly: no crash, 24.7 / 25.4 fps against main's 25.6 (inside the noise), the same picture. **But neither change takes effect in this setup:** the log says `display output: compositing two planes (overlay active) … base_format=28 overlay_format=28`, so both planes are R8G8B8A8_UNORM. That's neither a 10-bit/float scene (#1709) nor an sRGB plane, 29 or 91 (#1668). Someone whose log shows another `base_format` or `overlay_format` is needed to see the difference. Side note: both branches carry the same three base commits (the 768 KiB policy limit, victory-gpu clippy, `checked_div` in the LDS cap). On current main, `cargo xtask policy` fails on `lower.rs` (704,996 bytes) and clippy stops at `manual_checked_ops`, so those commits fix real failures there. 🤖 Generated with [Claude Code](https://claude.com/claude-code)
github-bot force-pushed github-bot/gh-1709 from dc5668e8d6 to 7cab8dd1fa 2026-11-29 07:21:36 +00:00 Compare
Author
Owner

@⁠101Leafy on GitHub · 2026-11-29 07:17 UTC · original

Done in 7cab8dd: the composer is now made after the resize block, and a format change drops the old one only once the queued presents have settled. Rebased on current main.

**@⁠101Leafy** on GitHub · 2026-11-29 07:17 UTC · [original](https://github.com/trustno1-coder/VIctory-NVIDIA/pull/1709#issuecomment-7252381863) Done in 7cab8dd: the composer is now made after the resize block, and a format change drops the old one only once the queued presents have settled. Rebased on current main.
Author
Owner

@⁠trustno1-coder on GitHub · 2026-11-29 08:28 UTC · original

Thank you! An earlier version of this pull request was merged into main with its original commits and is part of v2026.11.29.01, where you are credited. GitHub does not show it as merged because new commits were pushed here after that merge. It stays open so those newer commits can be looked at next.

**@⁠trustno1-coder** on GitHub · 2026-11-29 08:28 UTC · [original](https://github.com/trustno1-coder/VIctory-NVIDIA/pull/1709#issuecomment-7253126278) Thank you! An earlier version of this pull request was merged into main with its original commits and is part of [v2026.11.29.01](https://github.com/trustno1-coder/VIctory-NVIDIA/releases/tag/v2026.11.29.01), where you are credited. GitHub does not show it as merged because new commits were pushed here after that merge. It stays open so those newer commits can be looked at next.
github-bot force-pushed github-bot/gh-1709 from 7cab8dd1fa to 6573dc1cb0 2026-11-29 09:23:14 +00:00 Compare
This pull request has changes conflicting with the target branch.
  • crates/victory-gpu/src/host.rs
View command line instructions

Manual merge helper

Use this merge commit message when completing the merge manually.

Checkout

From your project repository, check out a new branch and test the changes.
git fetch -u origin '+refs/pull/1709/head:github-bot/gh-1709'
git switch 'github-bot/gh-1709'

Merge

Merge the changes and update on Forgejo.
git switch 'main'
git merge --no-ff 'github-bot/gh-1709'
git switch 'github-bot/gh-1709'
git rebase 'main'
git switch 'main'
git merge --ff-only 'github-bot/gh-1709'
git switch 'github-bot/gh-1709'
git rebase 'main'
git switch 'main'
git merge --no-ff 'github-bot/gh-1709'
git switch 'main'
git merge --squash 'github-bot/gh-1709'
git switch 'main'
git merge --ff-only 'github-bot/gh-1709'
git switch 'main'
git merge 'github-bot/gh-1709'
git push origin 'main'
This discussion has been locked. Commenting is limited to contributors.
No reviewers
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.

Dependencies

No dependencies set

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