mirror of
https://github.com/tangerineturtle1/NX2navi.git
synced 2026-11-18 00:29:58 -04:00
Fill the fragment inputs a mesh program does not write, with the point sprite's coordinate for point meshes.
A mesh pipeline whose fragment stage reads a location the mesh program never writes now gets a fragment module where that input is a private variable set to (0, 0, 0, 1) at entry, or to (s, t, 0, 1) of gl_PointCoord when the mesh program draws points. The fragment shaders recorded with two of the game's point-drawing mesh programs read location 5, which those programs never write; Vulkan leaves such an input undefined. Checks: tests/fs_fill_inputs_check.py passes; 237 recorded fragment modules rewritten offline pass spirv-val; a 60 s Kakariko run with the change shows the area as before with no Vulkan errors. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
@@ -124,8 +124,11 @@ Grep-level look on 2026-10-22, statuses updated 2026-10-26; "saw" is what the gr
|
||||
translator patch 0006 initialises the unlinked outputs. Mesh programs: a component of a position or generic vector
|
||||
that the program's output map leaves out is written as (0, 0, 0, 1) by the mesh entry function
|
||||
(`tools/xlate/MeshSpirv.cs`) and by the fallback's vertex stage (`runtime/mesh_fb.c` `meshfb_vs`); a whole location
|
||||
the fragment stage reads and the mesh program lacks is still not padded with mesh shaders (`have = ~0u` for mesh in
|
||||
`vk_pipeline.c`). **Implemented; array-span runtime validation pending.**
|
||||
the fragment stage reads and the mesh program does not write is filled in the fragment module of the mesh pipeline
|
||||
(`vk_pipeline.c` `spirv_fs_fill_inputs`): (0, 0, 0, 1), or for a mesh program that draws points the point sprite's
|
||||
coordinate (s, t, 0, 1): the fragment shaders recorded with two of the game's point-drawing mesh programs read
|
||||
location 5, which those programs never write.
|
||||
**Implemented; array-span runtime validation pending.**
|
||||
3. **Masked clears.** `vk_exec.c` skips colour clears with a partial channel mask (`W_CLEAR_MASK`); `clear_ds` skips stencil
|
||||
clears with a partial mask (`W_STENCIL_MASK`). NX2navi issues such clears. Check the log for
|
||||
`colour clear with channel mask` and `stencil clear with mask`. The hardware recipe (1.3) shows what the replay must do: colour clear = scissor 0 + channel mask, stencil clear = `value & mask` merged under the front write mask; so a draw with `colorWriteMask` / `stencilWriteMask` set to the clear mask is the exact equivalent. **Missing.**
|
||||
|
||||
Reference in New Issue
Block a user