benilla-re systems structs docs

TransformPoint34Rows

function · cmath · primitive

Address
0x7bcae0 · 93 bytes, up to 0x7bcb3c
Signature
NTempest::C3Vector * __fastcall (NTempest::C3Vector *out, const NTempest::C44Matrix *m, const NTempest::C3Vector *v)
Meaning
Returns a point through the first three rows of a 4×4 as rows of four: each row dotted with it plus its fourth entry
Confidence
verified, proof two
Finding
cmath/matrices#points-and-vectors-through-a-matrix
Test
cmath::transform_mat43_vec3_difftest

Finding: Points and vectors through a matrix in cmath: matrices

0x7bca80 (ecx out, edx point of three, matrix on the stack) gives the point times the upper 3×3 plus row 3: x = ((m8·z + m4·y) + x·m0) + m12, y = ((m9·z + m1·x) + m5·y) + m13, `z = ((m10·z + m2·x) + m6·y)

  • m14, each stored as a float; 0x7bcc60is the same in place.0x7bcb40 does it for four components (wfirst):x' = ((m12·w + m8·z) + m4·y) + x·m0, y', z'andw'from columns 1 to 3.0x7bcae0 (ecxout,edxa 4×4, vector on the stack) givesrow·v + row[3] for each of the 4×4's first three rows, the product with its transpose (cmath/types#matrices`).

The derivation is in the doc.

Callers 4

Callees 0

None by a direct call or jump.

Calls and jumps by a bare address, from tables/calls.tsv.