RotateMatrix34
function · unassigned · orchestration
- Address
0x7bbab0· 74 bytes, up to0x7bbaf9- Signature
void __thiscall (NTempest::C34Matrix *this, float angle, const NTempest::C3Vector *axis, uint8_t axisIsUnit)- Meaning
- Multiplies a 3×4 matrix on the left by the rotation about an axis by an angle
- Confidence
- verified, proof two
- Finding
- cmath/matrices#axis-and-angle-rotations
Finding: Axis and angle rotations in cmath: matrices
0x7be490(out, axis, angle, unit), 0x7bdb00 and 0x7bb860 build the rotation about an axis for a row
vector. Unless the flag says the axis is a unit vector, it is scaled by 1/√((z² + y²) + x²), each
component stored as a float. With c, s, t = 1 − c, x·s and y·s stored as floats, the 3×3 is, by row:
| row | column 0 | column 1 | column 2 |
|---|---|---|---|
| 0 | x·x·t + c | t·x·y + z·s | t·x·z − y·s |
| 1 | t·x·y − z·s | y·y·t + c | x·s + t·y·z |
| 2 | t·x·z + y·s | t·y·z − x·s | z·z·t + c |
0x7bdb00 puts it in a 4×4 with (0, 0, 0, 1) last, 0x7bb860 in a 3×4 with zero translation;
0x7be730 and 0x7bbab0 multiply a 3×3 or a 3×4 on the left by one.
The derivation is in the doc.
Callers 3
- GetFirstLoginCameraPosition glue
- CCamera::LoadShot uicamera
- Sound::ProcessPanningList sound
Callees 2
- MultiplyMatrix34 unassigned
- BuildAxisRotation34 unassigned
Calls and jumps by a bare address, from tables/calls.tsv.