Repository navigation
GPU: inherit typed formats in explicit RTV and DSV descriptions - #2763
andrewpozdnakov7-jpg wants to merge 1 commit into
Conversation
|
Correct fix: DXGI_FORMAT_UNKNOWN must resolve to the guest's format before the view is recorded, since the host texture may be typeless (UNKNOWN would then be an invalid view). Naming 29 directly on a typeless-27 texture is legal - sRGB variants sit in the same typeless family - and preserves sRGB semantics rather than silently linearizing via 28. Test clears through both explicit and inherited views on both flag paths. |
Independent WARP verification: PR head
|
…SV descriptions
|
Automated triage for the maintainers. In This is a recommendation for a maintainer to look, not an approval. Generated by Claude Code |
fuzeofficlal
left a comment
There was a problem hiding this comment.
Verified head 6cdae0ec cleanly merged onto origin/main (63bcca43) on Windows 11 x64 (NVIDIA GeForce RTX 5090 + D3D12 WARP + VICTORY_D3D12_DEBUG=1).
Code Review
- Resolving explicit
DXGI_FORMAT_UNKNOWN(words[0] == 0) increate_rtv(shared withcreate_dsv) viacrate::resource::title_format(resource)cleanly inherits the guest typed format while preservingdimension, array/mip slices, and DSV flags, lettingRtvRecord::host_desc()map throughpc_formatcleanly even when the host backing resource is typeless (sRGB or depth).
Local Verification (VICTORY_D3D12_DEBUG=1)
- RTX 5090 & WARP (
--features diagnostics):descriptor::tests+draw::tests+resource::tests: 47/47 passed on both adapters (includingrtv_unknown_format_inherits_the_typed_resource_formatanddsv_unknown_format_inherits_depth_and_keeps_its_subresource). - WARP (full
victory-gpu --features diagnostics --lib): 248/248 passed (1 ignored). cargo clippy --locked -p victory-gpu --all-targets -- -D warnings(default and--features diagnostics) &cargo xtask policy(191 files ok): clean.
Looks clean and ready to merge.
Dukestar69
left a comment
There was a problem hiding this comment.
Tested merged onto origin/main (63bcca4) on Windows 11 x64 (NVIDIA GeForce RTX 5090):
cargo test -p victory-gpu --lib resource::tests: 20 passed, 0 failed (including newrtv_unknown_format_inherits_the_typed_resource_formatanddsv_unknown_format_inherits_depth_and_keeps_its_subresource).cargo clippy -p victory-gpu --all-targets -- -D warnings: clean.cargo xtask policy: 191 files ok.
Synthetic tests only (no game files used). AI-assisted (Gemini 4 Neon).
…SV descriptions
An explicit RTV or DSV may set DXGI_FORMAT_UNKNOWN to inherit the resource format. VIctory forwarded UNKNOWN even when the guest resource was typed and its host texture was typeless. Fill in the guest format when recording the view. The requested dimension, slice, mip and depth flags are preserved. RTV specification · DSV specification
The combined tree 64cb4bf (this branch, #1406 at 822d637 and its offered default-RTV test f25c81d) passed 20 resource tests and the serial WARP suite with 203 passing and one ignored under each D3D12 debug setting.
Refs #1242
Coordination claim
Please retain the Git author on cherry-pick or rebase. If you fold the fix or tests into another commit, please add the following trailer.
Co-authored-by: andrewpozdnakov7-jpg andrewpozdnakov7-jpg@users.noreply.github.com
AI-assisted with Codex. Synthetic textures on WARP.