mirror of
https://github.com/zenorogue/hyperrogue.git
synced 2024-11-23 21:07:17 +00:00
correct transparent wall ordering in S^3 [untested]
This commit is contained in:
parent
923d94e463
commit
5fed2d84ee
@ -1507,6 +1507,11 @@ void draw_backside() {
|
||||
|
||||
extern bool lshiftclick, lctrlclick;
|
||||
|
||||
void reverse_transparent_walls() {
|
||||
int pt = int(PPR::TRANSPARENT_WALL);
|
||||
reverse(&ptds[qp0[pt]], &ptds[qp[pt]]);
|
||||
}
|
||||
|
||||
void draw_main() {
|
||||
if(sphere && DIM == 3 && pmodel == mdPerspective) {
|
||||
for(int p: {1, 0, 2, 3}) {
|
||||
@ -1527,6 +1532,7 @@ void draw_main() {
|
||||
glClearDepth(0.0f);
|
||||
#endif
|
||||
glDepthFunc(GL_GEQUAL);
|
||||
reverse_transparent_walls();
|
||||
}
|
||||
glClear(GL_DEPTH_BUFFER_BIT);
|
||||
glhr::be_nontextured();
|
||||
@ -1538,6 +1544,7 @@ void draw_main() {
|
||||
reset_projection();
|
||||
for(auto& ptd: ptds) ptd->draw();
|
||||
}
|
||||
if(p == 1 || p == 2) reverse_transparent_walls();
|
||||
// glflush();
|
||||
}
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user