Support comp_matrix

This commit is contained in:
2024-04-02 17:47:41 -05:00
parent 7baa5bdb6d
commit 4da6772827
4 changed files with 32 additions and 2 deletions

View File

@@ -115,6 +115,24 @@ namespace JabyEngine {
*/
MATRIX& multiply_matrix(const MATRIX& m0, const MATRIX& m1, MATRIX& result);
/*
CompMatrix
m0: first input
m1: second input
result: result of computing m0 and m1
return: returns result
*/
static MATRIX& comp_matrix(const MATRIX& m0, const MATRIX& m1, MATRIX& result) {
multiply_matrix(m0, m1, result);
set_trans_matrix(m0);
GTE::ldlv0(reinterpret_cast<const VECTOR&>(m1.trans));
GTE::rt();
GTE::stlvnl(reinterpret_cast<VECTOR&>(result.trans));
return result;
}
/*
matrix: first input