GPU: resolve a multisampled PresentX color plane before display #3701
Loading…
Reference in a new issue
No description provided.
Delete branch "upstream-pr/3701"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Imported from Marvisak/VIctory. Originally posted by andrewpozdnakov7-jpg on 2026-11-28T09:13:34Z.
PresentX now resolves a single multisampled 2D color plane directly into the swap chain when the source and output formats match. The swap chain has one sample per pixel, so the display path uses the resolve states for both resources and restores the source state afterward. Frame capture and black-frame detection read the resolved back buffer in this case. D3D12 resolve requirements
The regression presents generated 4× MSAA textures in RGBA8, BGRA8, RGB10A2 and RGBA16F. Signed app-local WARP with the debug layer exercised all four formats. Every pixel in each 16×16 back buffer matched the independently encoded clear color. The existing single-plane and compositor recovery test, both GPU Clippy configurations and the asset policy passed.
The change covers the display path. #2702 covers diagnostic readback from other multisampled color targets.
Please retain the Git author on cherry-pick or rebase, or add
Co-authored-by: andrewpozdnakov7-jpg <[email protected]>if folding the change into another commit.AI-assisted with OpenAI Codex.
Imported from Marvisak/VIctory. Originally posted by andrewpozdnakov7-jpg on 2026-11-28T09:16:42Z.
Windows CI passed on
c13f937, including both Clippy configurations and the workspace tests. On app-local WARP with the debug layer, the 4× MSAA test resolved RGBA8, BGRA8, RGB10A2 and RGBA16F through PresentX. All 256 pixels matched per format. The existing single-plane and compositor recovery test also passed.The next step is maintainer review. Please retain the Git author on cherry-pick or rebase, or add
Co-authored-by: andrewpozdnakov7-jpg <[email protected]>if folding the change into another commit.AI-assisted with OpenAI Codex.
Imported from Marvisak/VIctory. Originally posted by passerbyyhx on 2026-12-01T12:30:21Z.
Tested
c13f937con an RTX 4090 Laptop GPU and WARP with different colors in the four samples. I reused the same 4× texture, cleared it red each frame, then drew blue with sample masks0x0,0x3,0xc, and0xf. The capture callback copied the resolved swap-chain back buffer immediately beforePresent.On both adapters, the two complementary middle masks each gave 50% red and 50% blue across all 256 pixels. The endpoints were solid red and solid blue. Across RGBA8, BGRA8, RGB10A2 and RGBA16F, all 4,096 pixels per adapter matched, within one quantization step for the integer formats and bit-exactly for FP16.
View command line instructions
Checkout
From your project repository, check out a new branch and test the changes.Merge
Merge the changes and update on Forgejo.Warning: The "Autodetect manual merge" setting is not enabled for this repository, you will have to mark this pull request as manually merged afterwards.