Verify level 1's tfrag lighting against the game
Savestate slot 2 is the second planet, so the comparison runs on a level with a different geometry extent, light bank and runtime-set population: level1: 401/401 headers, 401/401 pointers, bank byte-identical vertices compared: 26470 (105880 colour bytes) -- equal: 100.00% The live emulator agrees with the savestate byte for byte. Level 1 is a different planet, so the two fixes in the previous commit are not level-0 coincidences: the normal's z sign and the unlit-record base colour both hold across 268,280 colour bytes on two levels.
This commit is contained in:
@@ -37,10 +37,10 @@ The comparison:
|
||||
few mismatching vertices' *terms* (`gc_engine::tfrag_light::
|
||||
light_vertex_terms`) printed so a mismatch can be attributed.
|
||||
|
||||
## Result: level 0 (Veldin), verified 2026-10-11
|
||||
## Result: levels 0 and 1, verified 2026-10-11
|
||||
|
||||
Inputs: the live emulator over PINE, and two PCSX2 savestates from the same
|
||||
level. All three agree byte for byte.
|
||||
Level 0 (Veldin), three inputs -- the live emulator over PINE and two PCSX2
|
||||
savestates from that level, all agreeing byte for byte:
|
||||
|
||||
```text
|
||||
level0: tfrags block at 0x848000, table at 0x848040, 833 tfrags
|
||||
@@ -54,6 +54,25 @@ vertices compared: 40600 (162400 colour bytes)
|
||||
single-set: 37470 vertices, 37470 fully equal
|
||||
```
|
||||
|
||||
Level 1, from savestate slot 2 and cross-checked against the live emulator:
|
||||
|
||||
```text
|
||||
level1: tfrags block at 0x84c000, table at 0x84c040, 401 tfrags
|
||||
headers matching the disc on invariant bytes: 401/401
|
||||
data pointers relocated as table + disc offset: 401/401
|
||||
light bank in RAM at 0x50f4a0, byte-identical to the disc's
|
||||
|
||||
vertices compared: 26470 (105880 colour bytes)
|
||||
equal: 105880 (100.00%)
|
||||
runtime-set: 129 vertices, 129 fully equal
|
||||
single-set: 26341 vertices, 26341 fully equal
|
||||
```
|
||||
|
||||
Level 1 matters more than one more tally: it is a different planet with a
|
||||
different geometry extent, a different light bank and a different
|
||||
runtime-set population, and it agrees on every byte. The two fixes below are
|
||||
therefore not level-0 coincidences.
|
||||
|
||||
What this establishes:
|
||||
|
||||
- **The tfrag locator and the pointer model are right.** 833 of 833 headers
|
||||
@@ -94,9 +113,9 @@ invisible.
|
||||
- **Point lights.** The runtime-set cluster is set 15 and above; those slots
|
||||
are filled by gameplay, so they cannot be verified from a level-load image.
|
||||
Comparing them needs a frame with point lights in it.
|
||||
- **Blended sets.** Level 0's vertices are all single-set (`select & 0xff00 ==
|
||||
0`), so the blend path -- the only path `rsqrt` touches -- is untested
|
||||
against the game.
|
||||
- **Blended sets.** Both levels' vertices are all single-set (`select &
|
||||
0xff00 == 0`), so the blend path -- the only path `rsqrt` touches -- is
|
||||
untested against the game.
|
||||
- **Distil, then test.** A comparison is not a regression. When a fact from
|
||||
here becomes load-bearing, distil it into a numbers-only fixture under
|
||||
`tools/trace/tests/` and test against that; no test may read a savestate, a
|
||||
|
||||
Reference in New Issue
Block a user