victory-shader: honor unwritten OSG1 channels and output modes in rectangle_gs #1905

Open
mgunes1311-lab wants to merge 7 commits from upstream-pr/1907 into main
mgunes1311-lab commented 2026-11-25 00:32:48 +00:00 (Migrated from github.com)

Imported from Marvisak/VIctory. Originally posted by mgunes1311-lab on 2026-11-25T00:32:48Z.


Summary

Fixes two signature bugs in victory_shader::emit::rectangle_gs when generating host geometry shaders for console rectangle-list pipelines:

  1. Unwritten OSG1 channels and elements (E_INVALIDARG on D3D12 PSO linkage): rectangle_gs previously set e.usage = (1 << e.cols) - 1 and emitted loadInput / storeOutput across every declared component of every register-allocated OSG1 row. Whenever a vertex shader declared a vector output and wrote only a subset of its channels (e.g. .xy or .xz of a float4) or kept an unwritten output row in OSG1, GS.ISG1 declared ReadWriteMask bits that VS.OSG1 marked in NeverWrites_Mask, causing ID3D12Device::CreateGraphicsPipelineState to fail with E_INVALIDARG on both hardware adapters and WARP. rectangle_gs now derives e.usage from Mask & !NeverWrites_Mask (OSG1 bytes 24..26), emits loadInput, fourth-corner completion, and storeOutput only for written channels, preserves VS.OSG1 byte-for-byte in GS.OSG1, and rejects containers with no written outputs.
  2. Geometry-shader output interpolation modes: rectangle_gs left e.interp = 0 (Undefined) on all GS outputs instead of assigning DXC's output interpolation modes (LinearNoperspective for SV_Position, Linear for float attributes/clip/cull, Constant for integers and SV_IsFrontFace) and unifying shared rows via same_mode_per_row. GS inputs stay Undefined (0), GS outputs now receive consistent per-row modes in PSV0 and !dx.entryPoints, while keeping main's (va, vb, v3) completing-triangle behaviour (preserving va as its provoking value for flat/integer outputs).

Verification

  • cargo test -p victory-shader --target x86_64-pc-windows-msvc --locked -- rect (validated through dxil.dll IDxcValidator and executed end-to-end via Host::pipeline_gs + Host::draw on both D3D12 hardware and WARP with VICTORY_D3D12_DEBUG=1)
  • cargo clippy --workspace --all-targets --target x86_64-pc-windows-msvc --locked -- -D warnings (default and --all-features)
  • cargo doc --workspace --no-deps --target x86_64-pc-windows-msvc --locked
  • cargo run -p xtask --target x86_64-pc-windows-msvc --locked -- policy --staged & cargo test -p xtask --target x86_64-pc-windows-msvc --locked
<!-- greyfinch-sync:Marvisak/VIctory:issue:5482783918 --> Imported from [Marvisak/VIctory](https://github.com/Marvisak/VIctory/pull/1907). Originally posted by [mgunes1311-lab](https://github.com/mgunes1311-lab) on 2026-11-25T00:32:48Z. --- ## Summary Fixes two signature bugs in `victory_shader::emit::rectangle_gs` when generating host geometry shaders for console rectangle-list pipelines: 1. **Unwritten `OSG1` channels and elements (`E_INVALIDARG` on D3D12 PSO linkage):** `rectangle_gs` previously set `e.usage = (1 << e.cols) - 1` and emitted `loadInput` / `storeOutput` across every declared component of every register-allocated `OSG1` row. Whenever a vertex shader declared a vector output and wrote only a subset of its channels (e.g. `.xy` or `.xz` of a `float4`) or kept an unwritten output row in `OSG1`, `GS.ISG1` declared `ReadWriteMask` bits that `VS.OSG1` marked in `NeverWrites_Mask`, causing `ID3D12Device::CreateGraphicsPipelineState` to fail with `E_INVALIDARG` on both hardware adapters and WARP. `rectangle_gs` now derives `e.usage` from `Mask & !NeverWrites_Mask` (`OSG1` bytes `24..26`), emits `loadInput`, fourth-corner completion, and `storeOutput` only for written channels, preserves `VS.OSG1` byte-for-byte in `GS.OSG1`, and rejects containers with no written outputs. 2. **Geometry-shader output interpolation modes:** `rectangle_gs` left `e.interp = 0` (`Undefined`) on all `GS` outputs instead of assigning DXC's output interpolation modes (`LinearNoperspective` for `SV_Position`, `Linear` for float attributes/clip/cull, `Constant` for integers and `SV_IsFrontFace`) and unifying shared rows via `same_mode_per_row`. `GS` inputs stay `Undefined` (`0`), `GS` outputs now receive consistent per-row modes in `PSV0` and `!dx.entryPoints`, while keeping `main`'s `(va, vb, v3)` completing-triangle behaviour (preserving `va` as its provoking value for flat/integer outputs). ## Verification - `cargo test -p victory-shader --target x86_64-pc-windows-msvc --locked -- rect` (validated through `dxil.dll` `IDxcValidator` and executed end-to-end via `Host::pipeline_gs` + `Host::draw` on both D3D12 hardware and WARP with `VICTORY_D3D12_DEBUG=1`) - `cargo clippy --workspace --all-targets --target x86_64-pc-windows-msvc --locked -- -D warnings` (default and `--all-features`) - `cargo doc --workspace --no-deps --target x86_64-pc-windows-msvc --locked` - `cargo run -p xtask --target x86_64-pc-windows-msvc --locked -- policy --staged` & `cargo test -p xtask --target x86_64-pc-windows-msvc --locked`
upipibi commented 2026-11-25 01:08:13 +00:00 (Migrated from github.com)

Imported from Marvisak/VIctory. Originally posted by upipibi on 2026-11-25T00:40:54Z.


Ran on Windows 11 with an RTX 3070 (Ampere, driver 616.56), debug build, at a64b6c6: cargo test -p victory-shader --locked gives 208 passed, 3 failed, 2 ignored. The 3 are #1744's NVIDIA failures on main (the two stride_tests heap-buffer reads and gathers_at_a_level_match_the_hardware), and the new tests pass. Not run: a title.

AI-assisted (Claude Code).

<!-- greyfinch-sync:Marvisak/VIctory:comment:7148765467 --> Imported from [Marvisak/VIctory](https://github.com/Marvisak/VIctory/pull/1907#issuecomment-7148765467). Originally posted by [upipibi](https://github.com/upipibi) on 2026-11-25T00:40:54Z. --- Ran on Windows 11 with an RTX 3070 (Ampere, driver 616.56), debug build, at `a64b6c6`: `cargo test -p victory-shader --locked` gives 208 passed, 3 failed, 2 ignored. The 3 are #1744's NVIDIA failures on `main` (the two `stride_tests` heap-buffer reads and `gathers_at_a_level_match_the_hardware`), and the new tests pass. Not run: a title. AI-assisted (Claude Code).
catminou4 commented 2026-11-25 02:47:13 +00:00 (Migrated from github.com)

Imported from Marvisak/VIctory. Originally posted by catminou4 on 2026-11-25T02:47:13Z.

Review: APPROVED


Tested locally: macOS arm64, rustc 1.98.1, PR head merged into main 940d32f69b, cargo test -p victory-shader --locked.

144 passed / 0 failed / 2 ignored. OSG1 unwritten channels/output modes honored in the rect path — rasterizer-state completeness fix.

<!-- greyfinch-sync:Marvisak/VIctory:review:6051070859 --> Imported from [Marvisak/VIctory](https://github.com/Marvisak/VIctory/pull/1907#pullrequestreview-6051070859). Originally posted by [catminou4](https://github.com/catminou4) on 2026-11-25T02:47:13Z. **Review:** APPROVED --- Tested locally: macOS arm64, rustc 1.98.1, PR head merged into main 940d32f69b, `cargo test -p victory-shader --locked`. 144 passed / 0 failed / 2 ignored. OSG1 unwritten channels/output modes honored in the rect path — rasterizer-state completeness fix.
Headache3318 commented 2026-11-25 03:03:19 +00:00 (Migrated from github.com)

Imported from Marvisak/VIctory. Originally posted by Headache3318 on 2026-11-25T02:09:29Z.


Tested on Linux (Arch, kernel 7.3.5, 3× RTX 4090 driver 620.73.04), Rust 1.98.1 (pinned). PR head a64b6c6 applied cleanly onto current main ccfb029.

  • cargo test -p victory-shader --locked: 118 passed, 0 failed, 1 ignored. All tests pass.
  • cargo clippy -p victory-shader --all-targets -- -D warnings: 3 errors (vs 4 on main). The PR net-reduces clippy errors by fixing unused imports.

Not tested: Windows MSVC build, the title itself. AI-assisted.

<!-- greyfinch-sync:Marvisak/VIctory:comment:7150384585 --> Imported from [Marvisak/VIctory](https://github.com/Marvisak/VIctory/pull/1907#issuecomment-7150384585). Originally posted by [Headache3318](https://github.com/Headache3318) on 2026-11-25T02:09:29Z. --- Tested on Linux (Arch, kernel 7.3.5, 3× RTX 4090 driver 620.73.04), Rust 1.98.1 (pinned). PR head `a64b6c6` applied cleanly onto current `main` `ccfb029`. - `cargo test -p victory-shader --locked`: 118 passed, 0 failed, 1 ignored. All tests pass. - `cargo clippy -p victory-shader --all-targets -- -D warnings`: 3 errors (vs 4 on main). The PR net-reduces clippy errors by fixing unused imports. Not tested: Windows MSVC build, the title itself. AI-assisted.
Marvisak commented 2026-11-25 09:06:12 +00:00 (Migrated from github.com)

Imported from Marvisak/VIctory. Originally posted by Marvisak on 2026-11-25T08:19:42Z.


Automated triage for the maintainers.

Merge candidate. rectangle_gs (crates/victory-shader/src/emit/rect.rs) now takes each element's written channels from the vertex shader's OSG1 (mask minus never-writes mask, bytes 24-25 of the 32-byte row, shifted by the element's start column). It loads and stores only those channels, requires a written position x and y, and gives the GS outputs DXIL interpolation modes, with same_mode_per_row making a row that shares a float with an integer flat. I checked the byte offsets against signature() in emit/container.rs, which writes the never-writes mask as !used & 0xf for outputs, so the round trip gives back the written channels. The new tests validate VS, GS and PS, check that the GS OSG1 matches the VS one and check the PSV0 modes, then draw all three right-angle orders on hardware and WARP.

Reply to the author: thanks. Since 9a47b2c, the completing triangle (va, vb, v3) is the same as on main again. Flat and integer outputs keep va's value, and the draw test expects exactly that per order. That was the only open point, so the provoking-vertex question can go in its own PR with evidence. sinan-cmyk's offline count (no change in validated programs) shows the change rejects nothing on real data. The linkage fix itself shows up at pipeline creation, which that count does not cover.

CI: passing (check).


Generated by Claude Code

<!-- greyfinch-sync:Marvisak/VIctory:comment:7156889187 --> Imported from [Marvisak/VIctory](https://github.com/Marvisak/VIctory/pull/1907#issuecomment-7156889187). Originally posted by [Marvisak](https://github.com/Marvisak) on 2026-11-25T08:19:42Z. --- <!-- victory-triage v1 head=9a47b2ce637ae04ca0b78e4f22dc687e1c0d37bb verdict=merge-candidate at=2026-11-25T20:18:54Z --> Automated triage for the maintainers. **Merge candidate.** `rectangle_gs` (`crates/victory-shader/src/emit/rect.rs`) now takes each element's written channels from the vertex shader's `OSG1` (mask minus never-writes mask, bytes 24-25 of the 32-byte row, shifted by the element's start column). It loads and stores only those channels, requires a written position x and y, and gives the GS outputs DXIL interpolation modes, with `same_mode_per_row` making a row that shares a float with an integer flat. I checked the byte offsets against `signature()` in `emit/container.rs`, which writes the never-writes mask as `!used & 0xf` for outputs, so the round trip gives back the written channels. The new tests validate VS, GS and PS, check that the GS `OSG1` matches the VS one and check the `PSV0` modes, then draw all three right-angle orders on hardware and WARP. Reply to the author: thanks. Since `9a47b2c`, the completing triangle `(va, vb, v3)` is the same as on `main` again. Flat and integer outputs keep `va`'s value, and the draw test expects exactly that per order. That was the only open point, so the provoking-vertex question can go in its own PR with evidence. sinan-cmyk's offline count (no change in validated programs) shows the change rejects nothing on real data. The linkage fix itself shows up at pipeline creation, which that count does not cover. CI: passing (`check`). --- _Generated by [Claude Code](https://claude.ai/code)_
sinan-cmyk commented 2026-11-25 12:03:50 +00:00 (Migrated from github.com)

Imported from Marvisak/VIctory. Originally posted by sinan-cmyk on 2026-11-25T11:34:24Z.


Offline measurement on a retail dump

Result: no count change against main.

I merged head a47859d1 onto main 940d32f (clean merge) and ran victory translate --validate --list on shaders.rpf (1.0.2.1), with dxil.dll 1.8.2502.11. I compared the result with main program by program (25,889 programs). Validated: 23,918 on main, 23,918 with this PR.

No program changes its failure reason. The count shows that the change rejects nothing on this data. It does not show whether the output is right.

No shader names or data are included, per the asset policy. AI-assisted (Claude Code).

<!-- greyfinch-sync:Marvisak/VIctory:comment:7161221474 --> Imported from [Marvisak/VIctory](https://github.com/Marvisak/VIctory/pull/1907#issuecomment-7161221474). Originally posted by [sinan-cmyk](https://github.com/sinan-cmyk) on 2026-11-25T11:34:24Z. --- ### Offline measurement on a retail dump **Result: no count change against `main`.** I merged head a47859d1 onto `main` 940d32f (clean merge) and ran `victory translate --validate --list` on `shaders.rpf` (1.0.2.1), with dxil.dll 1.8.2502.11. I compared the result with `main` program by program (25,889 programs). Validated: 23,918 on `main`, 23,918 with this PR. No program changes its failure reason. The count shows that the change rejects nothing on this data. It does not show whether the output is right. No shader names or data are included, per the asset policy. AI-assisted (Claude Code).
upipibi commented 2026-11-25 14:07:33 +00:00 (Migrated from github.com)

Imported from Marvisak/VIctory. Originally posted by upipibi on 2026-11-25T14:02:35Z.


@mgunes1311-lab The new commit 6a0a1e4 breaks this PR's own test on my machine. RTX 3070 (616.56) plus WARP, Windows 11, debug, cargo test -p victory-shader --locked at 6a0a1e4 (as-is, on main 940d32f): 245 passed, 4 failed.

Three failures are #1744's NVIDIA failures that main has too. The fourth is new: emit::rect::tests::unwritten_channels_and_flat_outputs_link_and_draw fails validation before anything runs.

panicked at crates\victory-shader\src\emit\rect.rs:352:44:
called `Result::unwrap()` on an `Err` value: "error: Flags must match usage.\nnote: Flags declared=0, actual=512\nValidation failed."

At a64b6c6 the same suite passed here (my run above). 6a0a1e4 only changes rect.rs, to flatten SV_ViewportArrayIndex / SV_RenderTargetArrayIndex. So my guess, not checked, is that writing those outputs from the GS now makes the validator expect a shader flag (actual=512) that rectangle_gs doesn't declare. One run only. It's a validation error rather than a GPU result, so I'd expect it on any host with the same validator.

AI-assisted (Claude Code). Synthetic tests only.

<!-- greyfinch-sync:Marvisak/VIctory:comment:7164668574 --> Imported from [Marvisak/VIctory](https://github.com/Marvisak/VIctory/pull/1907#issuecomment-7164668574). Originally posted by [upipibi](https://github.com/upipibi) on 2026-11-25T14:02:35Z. --- @mgunes1311-lab The new commit `6a0a1e4` breaks this PR's own test on my machine. RTX 3070 (616.56) plus WARP, Windows 11, debug, `cargo test -p victory-shader --locked` at `6a0a1e4` (as-is, on `main` `940d32f`): 245 passed, 4 failed. Three failures are #1744's NVIDIA failures that `main` has too. The fourth is new: `emit::rect::tests::unwritten_channels_and_flat_outputs_link_and_draw` fails validation before anything runs. ``` panicked at crates\victory-shader\src\emit\rect.rs:352:44: called `Result::unwrap()` on an `Err` value: "error: Flags must match usage.\nnote: Flags declared=0, actual=512\nValidation failed." ``` At `a64b6c6` the same suite passed here (my run above). `6a0a1e4` only changes `rect.rs`, to flatten `SV_ViewportArrayIndex` / `SV_RenderTargetArrayIndex`. So my guess, not checked, is that writing those outputs from the GS now makes the validator expect a shader flag (`actual=512`) that `rectangle_gs` doesn't declare. One run only. It's a validation error rather than a GPU result, so I'd expect it on any host with the same validator. AI-assisted (Claude Code). Synthetic tests only.
upipibi commented 2026-11-25 15:04:20 +00:00 (Migrated from github.com)

Imported from Marvisak/VIctory. Originally posted by upipibi on 2026-11-25T14:27:41Z.


@mgunes1311-lab Re-run at 3ea75eb (as-is, on main 940d32f), RTX 3070 (616.56) plus WARP, Windows 11, debug, cargo test -p victory-shader --locked: the validation failure is gone. emit::rect::tests::unwritten_channels_and_flat_outputs_link_and_draw passes.

The suite gives 247 passed, 3 failed, 3 ignored, with no SKIPPED lines. The 3 are #1744's NVIDIA failures that main has too (a_heap_buffer_read_where_no_buffer_view_is_reads_zeros, a_heap_buffer_read_by_element_takes_the_views_stride, gathers_at_a_level_match_the_hardware).

One run only.

AI-assisted (Claude Code). Synthetic tests only.

<!-- greyfinch-sync:Marvisak/VIctory:comment:7165313012 --> Imported from [Marvisak/VIctory](https://github.com/Marvisak/VIctory/pull/1907#issuecomment-7165313012). Originally posted by [upipibi](https://github.com/upipibi) on 2026-11-25T14:27:41Z. --- @mgunes1311-lab Re-run at `3ea75eb` (as-is, on `main` `940d32f`), RTX 3070 (616.56) plus WARP, Windows 11, debug, `cargo test -p victory-shader --locked`: the validation failure is gone. `emit::rect::tests::unwritten_channels_and_flat_outputs_link_and_draw` passes. The suite gives 247 passed, 3 failed, 3 ignored, with no `SKIPPED` lines. The 3 are #1744's NVIDIA failures that `main` has too (`a_heap_buffer_read_where_no_buffer_view_is_reads_zeros`, `a_heap_buffer_read_by_element_takes_the_views_stride`, `gathers_at_a_level_match_the_hardware`). One run only. AI-assisted (Claude Code). Synthetic tests only.
mgunes1311-lab commented 2026-11-25 17:05:20 +00:00 (Migrated from github.com)

Imported from Marvisak/VIctory. Originally posted by mgunes1311-lab on 2026-11-25T16:55:09Z.


Merged main (67e8ae1) to combine with 8ff7913 (right_angle corner selection):

  • Interpolated float outputs complete (va, vb, v3) via pick and va + vb - vc, while flat outputs (e.interp == 1 or integer) keep v0 on the completing triangle's provoking vertex so flat values stay uniform across both triangles in every right-angle vertex order.
  • SV_Position requires written x and y (e.usage & 0b11 == 0b11).
  • Extended unwritten_channels_and_flat_outputs_link_and_draw to verify all three right-angle vertex orders on both hardware and WARP.
<!-- greyfinch-sync:Marvisak/VIctory:comment:7168728320 --> Imported from [Marvisak/VIctory](https://github.com/Marvisak/VIctory/pull/1907#issuecomment-7168728320). Originally posted by [mgunes1311-lab](https://github.com/mgunes1311-lab) on 2026-11-25T16:55:09Z. --- Merged `main` (`67e8ae1`) to combine with `8ff7913` (`right_angle` corner selection): - Interpolated float outputs complete `(va, vb, v3)` via `pick` and `va + vb - vc`, while flat outputs (`e.interp == 1` or integer) keep `v0` on the completing triangle's provoking vertex so flat values stay uniform across both triangles in every right-angle vertex order. - `SV_Position` requires written `x` and `y` (`e.usage & 0b11 == 0b11`). - Extended `unwritten_channels_and_flat_outputs_link_and_draw` to verify all three right-angle vertex orders on both hardware and WARP.
mgunes1311-lab commented 2026-11-25 19:06:43 +00:00 (Migrated from github.com)

Imported from Marvisak/VIctory. Originally posted by mgunes1311-lab on 2026-11-25T19:02:19Z.


Updated crates/victory-shader/src/emit/rect.rs to keep main's (va, vb, v3) values on the completing triangle (preserving va as its provoking value for flat/integer outputs) so this PR only fixes unwritten OSG1 channel masks, position x/y validation, and DXIL output interpolation modes.

<!-- greyfinch-sync:Marvisak/VIctory:comment:7171736227 --> Imported from [Marvisak/VIctory](https://github.com/Marvisak/VIctory/pull/1907#issuecomment-7171736227). Originally posted by [mgunes1311-lab](https://github.com/mgunes1311-lab) on 2026-11-25T19:02:19Z. --- Updated crates/victory-shader/src/emit/rect.rs to keep main's (va, vb, v3) values on the completing triangle (preserving va as its provoking value for flat/integer outputs) so this PR only fixes unwritten OSG1 channel masks, position x/y validation, and DXIL output interpolation modes.
fuzeofficlal commented 2026-11-26 17:01:48 +00:00 (Migrated from github.com)

Imported from Marvisak/VIctory. Originally posted by fuzeofficlal on 2026-11-26T17:01:48Z.

Review: APPROVED


Verified 9a47b2ce637ae04ca0b78e4f22dc687e1c0d37bb merged cleanly onto 63bcca43 on Windows 11 with an RTX 5090, WARP, dxil.dll (Windows SDK 10.0.26100.0), and VICTORY_D3D12_DEBUG=1.

Code review

  • emit::signature() (crates/victory-shader/src/emit/mod.rs:540) preserves OSG1 row order 1-to-1 with base + 32 * i, so deriving e.usage = ((rw[0] & !rw[1] & 0xf) >> e.col) & mask in rectangle_gs (crates/victory-shader/src/emit/rect.rs:44-53) before retain(|e| e.row.is_some()) cleanly inverts container::signature's NeverWrites_Mask encoding.
  • Empty/all-unwritten output signatures (rect.rs:55-57) and missing SV_Position.xy (rect.rs:97) are rejected cleanly, preventing any panic in side().
  • GS inputs remain Undefined (0) while GS outputs receive valid DXIL interpolation modes unified per register row via same_mode_per_row(&mut elements, false) (rect.rs:58-67), and the completing triangle preserves main's (va, vb, v3) geometry and flat-output handling.

Verification

  • cargo xtask policy: 191 files ok.
  • cargo clippy --locked -p victory-shader --all-targets -- -D warnings (default and --all-features): clean.
  • RTX 5090 + WARP + dxil.dll + VICTORY_D3D12_DEBUG=1: emit::rect:: 5 passed, 0 failed (including unwritten_channels_and_flat_outputs_link_and_draw, integer_system_values_make_their_row_constant, and vertex_shaders_without_written_outputs_are_refused).
  • Additional probe with a non-zero start column (col = 2, cols = 2, usage = 0b10 sharing row 1 with a partial col = 0, cols = 2, usage = 0b01 element) passed dxil.dll validation for both VS and GS and preserved OSG1 byte-for-byte.
<!-- greyfinch-sync:Marvisak/VIctory:review:6077995006 --> Imported from [Marvisak/VIctory](https://github.com/Marvisak/VIctory/pull/1907#pullrequestreview-6077995006). Originally posted by [fuzeofficlal](https://github.com/fuzeofficlal) on 2026-11-26T17:01:48Z. **Review:** APPROVED --- Verified `9a47b2ce637ae04ca0b78e4f22dc687e1c0d37bb` merged cleanly onto `63bcca43` on Windows 11 with an RTX 5090, WARP, `dxil.dll` (Windows SDK 10.0.26100.0), and `VICTORY_D3D12_DEBUG=1`. ### Code review - `emit::signature()` (`crates/victory-shader/src/emit/mod.rs:540`) preserves `OSG1` row order 1-to-1 with `base + 32 * i`, so deriving `e.usage = ((rw[0] & !rw[1] & 0xf) >> e.col) & mask` in `rectangle_gs` (`crates/victory-shader/src/emit/rect.rs:44-53`) before `retain(|e| e.row.is_some())` cleanly inverts `container::signature`'s `NeverWrites_Mask` encoding. - Empty/all-unwritten output signatures (`rect.rs:55-57`) and missing `SV_Position.xy` (`rect.rs:97`) are rejected cleanly, preventing any panic in `side()`. - GS inputs remain `Undefined` (`0`) while GS outputs receive valid DXIL interpolation modes unified per register row via `same_mode_per_row(&mut elements, false)` (`rect.rs:58-67`), and the completing triangle preserves `main`'s `(va, vb, v3)` geometry and flat-output handling. ### Verification - `cargo xtask policy`: `191 files ok`. - `cargo clippy --locked -p victory-shader --all-targets -- -D warnings` (default and `--all-features`): clean. - RTX 5090 + WARP + `dxil.dll` + `VICTORY_D3D12_DEBUG=1`: `emit::rect::` **5 passed, 0 failed** (including `unwritten_channels_and_flat_outputs_link_and_draw`, `integer_system_values_make_their_row_constant`, and `vertex_shaders_without_written_outputs_are_refused`). - Additional probe with a non-zero start column (`col = 2, cols = 2, usage = 0b10` sharing row 1 with a partial `col = 0, cols = 2, usage = 0b01` element) passed `dxil.dll` validation for both VS and GS and preserved `OSG1` byte-for-byte.
Dukestar69 commented 2026-11-26 23:47:33 +00:00 (Migrated from github.com)

Imported from Marvisak/VIctory. Originally posted by Dukestar69 on 2026-11-26T23:47:33Z.

Review: APPROVED


LGTM — verified on Windows against origin/main (63bcca4).

  • Honoring unwritten OSG1 channels and output modes in rectangle_gs fixes DXIL output signature consistency cleanly.
  • cargo test -p victory-shader --lib emit::rect:: -- --test-threads=1: all passed.
  • cargo clippy -p victory-shader --all-targets -- -D warnings: clean.
  • cargo xtask policy: 191 files ok.

Synthetic tests only (no game files used). AI-assisted (Gemini 4 Neon).

<!-- greyfinch-sync:Marvisak/VIctory:review:6081651025 --> Imported from [Marvisak/VIctory](https://github.com/Marvisak/VIctory/pull/1907#pullrequestreview-6081651025). Originally posted by [Dukestar69](https://github.com/Dukestar69) on 2026-11-26T23:47:33Z. **Review:** APPROVED --- LGTM — verified on Windows against `origin/main` (`63bcca4`). - Honoring unwritten OSG1 channels and output modes in `rectangle_gs` fixes DXIL output signature consistency cleanly. - `cargo test -p victory-shader --lib emit::rect:: -- --test-threads=1`: all passed. - `cargo clippy -p victory-shader --all-targets -- -D warnings`: clean. - `cargo xtask policy`: 191 files ok. Synthetic tests only (no game files used). AI-assisted (Gemini 4 Neon).
This pull request cannot be merged automatically due to conflicts.
Merge manually to resolve the conflicts.
View command line instructions

Checkout

From your project repository, check out a new branch and test the changes.
git fetch -u origin 'upstream-pr/1907:upstream-pr/1907'
git switch 'upstream-pr/1907'

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.

git switch 'main'
git merge --no-ff 'upstream-pr/1907'
git switch 'upstream-pr/1907'
git rebase 'main'
git switch 'main'
git merge --ff-only 'upstream-pr/1907'
git switch 'upstream-pr/1907'
git rebase 'main'
git switch 'main'
git merge --no-ff 'upstream-pr/1907'
git switch 'main'
git merge --squash 'upstream-pr/1907'
git switch 'main'
git merge --ff-only 'upstream-pr/1907'
git switch 'main'
git merge 'upstream-pr/1907'
git push origin 'main'
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
Marvisak/VIctory!1905
No description provided.