Translate geometry-shader adjacency inputs #137

Closed
github-bot wants to merge 1 commit from gh-pr/137/head into gh-pr/137/base
Owner

@⁠Yeetbot159 on GitHub · 2026-11-22 15:10 UTC · original
Yeetbot159:yeet/gs-adjacency → main · +49 −1 · 2 files · 1 commits · closed without merging

Summary

  • PSV0 stores geometry input primitive 6 (line with adjacency, 4 vertices) and 7 (triangle with adjacency, 6 vertices). Those were rejected.
  • Point, line and triangle keep the same vertex-offset seed. Adjacency continues the packing: vertex k is at dword offset k*0x400, line adjacency puts vertex 3 in the high half of v1, and triangle adjacency puts vertices 4 and 5 in v2.

Test plan

  • cargo test -p tombox-xshader --test synthetic passed, including geometry_adjacency_primitives_translate.
  • The triangle case still emits v0 = 0x04000000u; v1 = 0x800u; and does not declare v2.
**@⁠Yeetbot159** on GitHub · 2026-11-22 15:10 UTC · [original](https://github.com/omonkeyz/xbox-emulator/pull/137) `Yeetbot159:yeet/gs-adjacency` → `main` · +49 −1 · 2 files · 1 commits · closed without merging ## Summary - PSV0 stores geometry input primitive 6 (line with adjacency, 4 vertices) and 7 (triangle with adjacency, 6 vertices). Those were rejected. - Point, line and triangle keep the same vertex-offset seed. Adjacency continues the packing: vertex k is at dword offset k*0x400, line adjacency puts vertex 3 in the high half of v1, and triangle adjacency puts vertices 4 and 5 in v2. ## Test plan - `cargo test -p tombox-xshader --test synthetic` passed, including `geometry_adjacency_primitives_translate`. - The triangle case still emits `v0 = 0x04000000u; v1 = 0x800u;` and does not declare v2.
PSV0 already stores those primitive codes. The input is four vertices for a line and six for a triangle, and the extra vertex offsets continue the dword packing used for the first three.

Co-authored-by: Cursor <[email protected]>
github-bot locked as GitHub sync and limited conversation to collaborators 2026-11-26 06:11:25 +00:00
github-bot closed this pull request 2026-11-26 06:11:25 +00:00
Author
Owner

@⁠omonkeyz on GitHub · 2026-11-22 15:29 UTC · original

Applied in 103016f (merged in 9865896) with your authorship kept, thanks! I fixed a merge conflict in synthetic.rs with #136's test and kept both tests.

**@⁠omonkeyz** on GitHub · 2026-11-22 15:29 UTC · [original](https://github.com/omonkeyz/xbox-emulator/pull/137#issuecomment-7081337135) Applied in 103016f (merged in 9865896) with your authorship kept, thanks! I fixed a merge conflict in synthetic.rs with #136's test and kept both tests.

Pull request closed

This discussion has been locked. Commenting is limited to contributors.
No description provided.