mirror of
https://github.com/thunderbrewhq/thunderbrew
synced 2025-12-12 11:12:29 +00:00
chore: initial commit
This commit is contained in:
commit
70b00c5c38
965 changed files with 264882 additions and 0 deletions
30
src/gx/CGxMatrixStack.cpp
Normal file
30
src/gx/CGxMatrixStack.cpp
Normal file
|
|
@ -0,0 +1,30 @@
|
|||
#include "gx/CGxMatrixStack.hpp"
|
||||
|
||||
CGxMatrixStack::CGxMatrixStack() {
|
||||
this->m_flags[0] = 0x1;
|
||||
}
|
||||
|
||||
void CGxMatrixStack::Pop() {
|
||||
if (this->m_level > 0) {
|
||||
this->m_level--;
|
||||
}
|
||||
|
||||
this->m_dirty = 1;
|
||||
}
|
||||
|
||||
void CGxMatrixStack::Push() {
|
||||
if (this->m_level < 3) {
|
||||
this->m_level++;
|
||||
}
|
||||
|
||||
this->m_mtx[this->m_level] = this->m_mtx[this->m_level - 1];
|
||||
this->m_flags[this->m_level] = this->m_flags[this->m_level - 1];
|
||||
|
||||
this->m_dirty = 1;
|
||||
}
|
||||
|
||||
C44Matrix& CGxMatrixStack::Top() {
|
||||
this->m_dirty = 1;
|
||||
this->m_flags[this->m_level] &= 0xFFFFFFFE;
|
||||
return this->m_mtx[this->m_level];
|
||||
}
|
||||
Loading…
Add table
Add a link
Reference in a new issue