Blending into an integer render target turned off for the host (VICTORY_BLEND_INT_OFF=1): one refused mesh pipeline is made #1159
Loading…
Reference in a new issue
No description provided.
Delete branch "upstream-pr/1162"
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 fxceless/victory-fork. Originally posted by Dathinel on 2026-11-25T22:10:12Z.
What. One mesh pipeline of the first gameplay scene is refused by the host on every run here (
0x80070057): meshf5e50eb2108c425b+ pixelce3f0432a08f1d35. Both shaders translate. #1141 lists the same pair as refused on an RTX 5070, so it is not specific to this card.Why it is refused. With a diagnostics build and
VICTORY_D3D12_DEBUG=1the debug layer names it:The title's blend state is on for a slot whose target is an integer format. The console makes that pipeline; D3D12 does not.
The change.
GraphicsState::host_blend(): withVICTORY_BLEND_INT_OFF=1, blending is turned off for the integer render targets and left as it was for the others. If the state is shared by every slot (no independent blending), it is spread to the eight slots first, so only the integer ones change. Used at the four places that hand the blend state to the host (vertex and mesh pipelines, with and without depth bounds). Off by default: nothing changes without the switch. One file, +85/−4, a unit test for the function.Measured (RTX 3050 Laptop 4 GB, 32-lane waves, Ryzen 7 7435HS,
--console series-s, treemain9c184b3+ #1081 + #798, run 253 switch set +VICTORY_TEXTURE_BUDGET_MB=1024, diagnostics build, debug layer on):VICTORY_BLEND_INT_OFF=1(1 run, 160 s)host mesh pipeline shaders=[mesh f5e50eb2108c425b, pixel ce3f0432a08f1d35])Not tested / not known.
main): the unit test andcargo xtask policypass; the game runs were on the tree above.AI-assisted (Claude Code); built, run and read on the machine above.
🤖 Generated with Claude Code
Imported from fxceless/victory-fork. Originally posted by chatgpt-codex-connector[bot] on 2026-11-25T22:14:17Z.
Review: COMMENTED
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit:
927163f0aeℹ️ About Codex in GitHub
Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you
If Codex has suggestions, it will comment; otherwise it will react with 👍.
Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".
Imported from fxceless/victory-fork. Originally posted by Dathinel on 2026-11-25T22:12:04Z.
Prior art: #51 already fixes the same mesh/pixel pair (f5e50eb2108c425b / ce3f0432a08f1d35) in the same three pipeline creation paths. Its author credits pablogonz12 and reports successful creation on an RTX 5070 Ti in Series X, with unchanged FPS. The contribution here is the independent RTX 3050 Laptop / Series S measurement, D3D12 debug message 676 and an opt-in switch. The core blend fix overlaps, so one implementation should suffice. AI-assisted comparison of both diffs.
Imported from fxceless/victory-fork. Originally posted by chatgpt-codex-connector[bot] on 2026-11-25T22:10:26Z.
Codex Review Summary: ✅ Completed
This comment shows the latest Codex review activity on this pull request.
927163fℹ️ About Codex in GitHub
Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you
Codex reacts with 👀 while any review is running, comments if it has suggestions, and reacts with 👍 once all reviews finish with no findings.
Imported from fxceless/victory-fork. Originally posted by Dathinel on 2026-11-25T22:20:44Z.
The review's point holds: the library name came from
describe(), which printed the title's blend state, so with the switch on a pipeline stored earlier under that name could not be replaced and was made again each run. Fixed in3abd812:describe()prints the state the host is given. With the switch off the name is the same as before. Thepipeline::hostunit tests pass; I have not measured a second run with a warm library after this change.On #51: agreed, the core is the same fix and one implementation is enough. If #51 is the one carried, what this PR adds is the debug-layer message (id 676), the RTX 3050 Laptop / Series S measurement and the library-name point above, which applies to any version that changes the blend state after the name is taken.
AI-assisted (Claude Code).
Imported from fxceless/victory-fork. Originally posted by chatgpt-codex-connector[bot] on 2026-11-25T22:14:17Z.
Code review location:
crates/victory-gpu/src/pipeline/host.rs; line 649When a persistent library already contains a valid unmodified PSO—for example, one whose pixel shader leaves an integer MRT unwritten—enabling
VICTORY_BLEND_INT_OFFchanges its descriptor but retains its library name. The name still usesg.describe()at line 589, which serializes the originalself.blend. Loading the existing entry then fails description matching, andlibrary::pipelinecannot replace the occupied name (library.rs:583–585), so the adjusted PSO must be recompiled on every subsequent enabled run. Include the effective host blend state, or a flag-dependent discriminator, in the library key.Useful? React with 👍 / 👎.
Imported from fxceless/victory-fork. Originally posted by Dathinel on 2026-11-28T01:08:01Z.
Closing as superseded:
mainalready turns blending off on integer render targets for the host (pipeline/host.rs, with the testsinteger_targets_do_not_blendandblend_states_without_integer_blending_are_kept), which is what this did behind a switch. The independent measurement that motivated it (RTX 3050 Laptop 4 GB, Series S, the D3D12 debug message for the mesh/pixel pair) is kept with the rest of that card's results at https://github.com/Dathinel/victory-4gb . Written with AI assistance (Claude Code).Pull request closed