mirror of
https://github.com/zenorogue/hyperrogue.git
synced 2024-12-25 01:20:37 +00:00
product:: fixed randomly disappearing things
This commit is contained in:
parent
a2919f5a9c
commit
8e943486d9
15
drawing.cpp
15
drawing.cpp
@ -477,8 +477,21 @@ void drawTexturedTriangle(SDL_Surface *s, int *px, int *py, glvertex *tv, color_
|
|||||||
void glapplymatrix(const transmatrix& V) {
|
void glapplymatrix(const transmatrix& V) {
|
||||||
GLfloat mat[16];
|
GLfloat mat[16];
|
||||||
int id = 0;
|
int id = 0;
|
||||||
|
|
||||||
|
if(prod && pmodel == mdPerspective) {
|
||||||
|
for(int y=0; y<3; y++) {
|
||||||
|
for(int x=0; x<3; x++) mat[id++] = V[x][y];
|
||||||
|
mat[id++] = 0;
|
||||||
|
}
|
||||||
|
mat[12] = 0;
|
||||||
|
mat[13] = 0;
|
||||||
|
mat[14] = 0;
|
||||||
|
mat[15] = 1;
|
||||||
|
glhr::set_modelview(glhr::as_glmatrix(mat));
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
|
||||||
if(in_perspective() && GDIM == 3) {
|
if(in_perspective() && MDIM == 4) {
|
||||||
if(spherephase & 4) {
|
if(spherephase & 4) {
|
||||||
for(int y=0; y<4; y++) {
|
for(int y=0; y<4; y++) {
|
||||||
for(int x=0; x<4; x++) mat[id++] = -V[x][y];
|
for(int x=0; x<4; x++) mat[id++] = -V[x][y];
|
||||||
|
Loading…
Reference in New Issue
Block a user