gxumath
| rows | named | verified | proof two | tested | |
|---|---|---|---|---|---|
| functions | 36 | 36 (100%) | 36 (100%) | 0 (0%) | 6 (16%) |
| globals | 10 | 10 (100%) | 10 (100%) | 0 (0%) | – |
| structs | 0 | – | – | – | – |
| fields | 0 | – | – | – | – |
| all | 46 | 46 (100%) | 46 (100%) | 0 (0%) | 6 (16%) |
Docs
gxumath
The graphics maths layer: the matrix builders the interface and the world draw through, the frustum and screen-projection code beside them, and picking, decal and image routines that nothing in this build calls.
It is one object file, 0x5c3cc0 through 0x5c6640, with the C runtime's initializer slots
0x82aa38 to 0x82aa40. A matrix is 16 floats, row-major: element (row r, column c) is float 4r + c,
and a point is a row vector the matrix multiplies on the right, so 0x7bcb40 gives x·m0 + y·m4 + z·m8 + w·m12 first. The file calls cmath for the 4×4 determinant, inverse,
product, vector transform and translation, spline for the three-vector constructor 0x4549a0,
and gx for the device getters. A failed argument check calls 0x64e850 with 0x57, which leaves
the output alone.
Closure
10 roots. A walk of direct calls and jumps from them reaches 13 of the 36 functions the system owns, and stops at 12 functions of other systems. Vtable slots and stored addresses are not followed, so a function reached only that way is not counted.
Roots
- BuildPerspectiveMatrix gxumath
- BuildOrthoMatrix gxumath
- BuildLookAtMatrix gxumath
- BuildFrustumCorners gxumath
- ProjectPointsToWindow gxumath
- SetVector4 gxumath
- TexelBufferCallback gxumath
- InitGxuInfinityThunk gxumath
- InitGxuTwoPiThunk gxumath
- InitGxuInvTwoPiThunk gxumath
Boundary
- _atexit crt
- SetVector3 spline
- GxCapsDrawRect gx
- GetDeviceViewport gx
- 0x58b0c0 gx
- 0x58b280 gx
- SErrSetLastError storm
- MultiplyMatrix4 cmath
- TransformVector4 cmath
- Determinant4 cmath
- InvertMatrix4WithDeterminant cmath
- TranslateMatrix cmath
Functions 36
| address | name | class | confidence | test | closure |
|---|---|---|---|---|---|
0x5c3cc0 | BuildPerspectiveMatrix | primitive | verified, proof one | ✓ | ✓ |
0x5c3d90 | BuildOrthoMatrix | primitive | verified, proof one | ✓ | ✓ |
0x5c3e50 | BuildOrthoMatrixFromFloats | unreached | verified, proof one | ||
0x5c3e70 | BuildLookAtMatrix | primitive | verified, proof one | ✓ | ✓ |
0x5c4100 | BuildMirroredLookAtMatrix | unreached | verified, proof one | ||
0x5c4390 | InitGxuInfinityThunk | orchestration | verified, proof one | ✓ | |
0x5c43a0 | InitGxuInfinity | orchestration | verified, proof one | ✓ | |
0x5c43b0 | BuildFrustumCorners | primitive | verified, proof one | ✓ | ✓ |
0x5c4930 | BuildFrustumPlanes | unreached | verified, proof one | ||
0x5c4c70 | FrustumBounds | unreached | verified, proof one | ||
0x5c4d70 | ProjectPointsForDecal | unreached | verified, proof one | ||
0x5c4f30 | ProjectPointsToWindow | primitive | verified, proof one | ✓ | ✓ |
0x5c51f0 | ResampleImage | unreached | verified, proof one | ||
0x5c5350 | TexelBufferCallback | primitive | verified, proof one | ✓ | |
0x5c53d0 | TexelBufferExit | orchestration | verified, proof one | ||
0x5c53e0 | IntersectUnitRaySphere | unreached | verified, proof one | ||
0x5c54f0 | PointInFrustumPlanes | unreached | verified, proof one | ||
0x5c5560 | IntersectUnitRayTriangle | unreached | verified, proof one | ||
0x5c57a0 | PickSkinnedMesh | unreached | verified, proof one | ||
0x5c5bd0 | FreePickVertexBuffer | unreached | verified, proof one | ||
0x5c5bf0 | PickStaticMesh | unreached | verified, proof one | ||
0x5c5e30 | ClipOutcode | unreached | verified, proof one | ||
0x5c5ee0 | BuildDecalTexCoords | unreached | verified, proof one | ||
0x5c63d0 | SnapDecalPoint | unreached | verified, proof one | ||
0x5c6470 | RoundToGridCeil | unreached | verified, proof one | ||
0x5c64b0 | RoundToGridCeilAlt | unreached | verified, proof one | ||
0x5c64f0 | InitGxuTwoPiThunk | orchestration | verified, proof one | ✓ | |
0x5c6500 | InitGxuTwoPi | primitive | verified, proof one | ✓ | |
0x5c6510 | InitGxuInvTwoPiThunk | orchestration | verified, proof one | ✓ | |
0x5c6520 | InitGxuInvTwoPi | primitive | verified, proof one | ✓ | |
0x5c6540 | SetVector4 | orchestration | verified, proof one | ✓ | ✓ |
0x5c6560 | ScaleVector4 | unreached | verified, proof one | ||
0x5c6590 | NegateVector4 | unreached | verified, proof one | ||
0x5c65c0 | SubtractVector4 | unreached | verified, proof one | ||
0x5c65f0 | CopyMatrixColumn2 | unreached | verified, proof one | ||
0x5c6620 | CopyMatrixColumn3 | unreached | verified, proof one |
Globals 10
| address | name | type | confidence |
|---|---|---|---|
0x8038dc | s_perspectiveDepthFactor | float | verified, proof one |
0xc2b850 | s_noHitDistance | float | verified, proof one |
0xc2b854 | s_pickBufferFlags | uint8_t | verified, proof one |
0xc2b858 | s_gxuInvTwoPi | float | verified, proof one |
0xc2b860 | s_texelBuffer | uint32_t[64] | verified, proof one |
0xc2b960 | s_texelBufferFlags | uint8_t | verified, proof one |
0xc2b964 | s_gxuTwoPi | float | verified, proof one |
0xc2b968 | s_pickVertexCapacity | uint32_t | verified, proof one |
0xc2b96c | s_pickVertexCount | uint32_t | verified, proof one |
0xc2b970 | s_pickVertexBuffer | float * | verified, proof one |