1
0
mirror of https://github.com/zenorogue/hyperrogue.git synced 2025-11-23 00:54:47 +00:00

3D:: correct shift matrix in stereo mode

This commit is contained in:
Zeno Rogue
2019-06-25 11:22:47 +02:00
parent a6d9f8f679
commit 0f98146d20
3 changed files with 16 additions and 2 deletions

View File

@@ -82,6 +82,14 @@ glmatrix scale(ld x, ld y, ld z) {
return tmp;
}
glmatrix tmtogl(const transmatrix& T) {
glmatrix tmp;
for(int i=0; i<4; i++)
for(int j=0; j<4; j++)
tmp[i][j] = T[i][j];
return tmp;
}
glmatrix ortho(ld x, ld y, ld z) {
return scale(1/x, 1/y, 1/z);
}