mirror of
https://github.com/ubiquitarianism/leonida.git
synced 2026-11-26 22:00:52 +01:00
[PR #722] [MERGED] d3d12: expand IA-selected rectangles on triangle-family PSOs (RT-IA-RECTANGLE-VARIANT) #762
Labels
No labels
bug
pull-request
No milestone
No project
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set
Reference
starred/leonida#762
Loading…
Reference in a new issue
No description provided.
Delete branch "%!s()"
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?
📋 Pull Request Information
Original PR: https://github.com/ubiquitarianism/leonida/pull/722
Author: @Rain156
Created: 11/24/2026
Status: ✅ Merged
Merged: 11/25/2026
Merged by: @aslan2142
Base:
main← Head:fix/ia-rectangle-triangle-pso-20261124📝 Commits (2)
b10e0e9runtime: reuse the Xbox rectangle geometry generator from #682c55ecc9d3d12: expand rectangle draws through triangle-family pipelines📊 Changes
5 files changed (+374 additions, -2 deletions)
View changed files
📝
docs/d3d12_vulkan.md(+4 -0)📝
runtime/shims/d3d12_vulkan_device.cpp(+67 -0)➕
runtime/src/rect_list_geometry.h(+268 -0)📝
runtime/src/vulkan_replay.h(+6 -1)📝
runtime/test/d3d12_translated_draw_test.cpp(+29 -1)📄 Description
Claimed in the coordination issue as: RT-IA-RECTANGLE-VARIANT (claim).
Depends on: #682
What and why
The first-run UI compositor binds a triangle-family graphics pipeline, then selects Xbox rectangle-list topology (17) on the input assembler. The three submitted corners drew one triangle. In a 3840 × 2160 pass, this left half the output untouched.
Replay now selects a pipeline variant with a generated geometry stage for that draw. The variant cache distinguishes rectangle expansion and the unbound attachment mask. Triangle draws on the same PSO keep their original pipeline. PSOs with the same linked vertex program share the snapshot used to build the geometry stage on first use.
The first commit carries only tedin7’s geometry generator from #207 / #682, byte-for-byte, so this can build against current main. The second commit contains the draw-time selection and its regression. The explicit type-19 PSO and quad-list implementation are tracked in #682.
Tested
51f316092with the new synthetic GPU test fails at pixel (0, 32) on the first rectangle draw. On this branch, the same PSO alternates rectangle and triangle draws twice. All 4,096 target pixels match on each frame. The regression also passes with the Khronos validation layer and synchronization validation enabled. Runctest --test-dir <build> -C RelWithDebInfo -R ^d3d12_translated_draw$ --output-on-failureon a Vulkan-enabled Windows runtime build.d3d12_vulkan_devicefailure reproduced on clean main on this adapter, with identical HRESULT differences for committed-resource flags0x200and0x400.llvm-mcwith a backslash-delimited Windows path passed all nine tests when rerun with a forward-slashLLVM_MCpath. Viewer streaming passed 57/57 and documentation links passed 16/16.git diff --checkpass. Local merge checks against current main and #682 are clean.GPUs tested: NVIDIA GeForce RTX 5070 Ti, driver 617.42, Windows 11 x64 build 26200 (MSVC RelWithDebInfo).
AI-assisted: Yes (Codex).
Checklist
mainand merges cleanly.🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.