mirror of
https://github.com/zenorogue/hyperrogue.git
synced 2025-10-27 11:57:40 +00:00
shaderside projection for DIM==3
This commit is contained in:
11
polygons.cpp
11
polygons.cpp
@@ -490,11 +490,15 @@ vector<glvertex> line_vertices;
|
||||
#endif
|
||||
|
||||
void glapplymatrix(const transmatrix& V) {
|
||||
#if DIM == 3
|
||||
glhr::set_modelview(glhr::id);
|
||||
#else
|
||||
GLfloat mat[16];
|
||||
int id = 0;
|
||||
if(DIM == 3) {
|
||||
for(int y=0; y<4; y++) {
|
||||
for(int x=0; x<4; x++) mat[id++] = V[x][y];
|
||||
}
|
||||
glhr::set_modelview(glhr::as_glmatrix(mat));
|
||||
return;
|
||||
}
|
||||
|
||||
for(int y=0; y<3; y++) {
|
||||
for(int x=0; x<3; x++) mat[id++] = V[x][y];
|
||||
@@ -512,7 +516,6 @@ void glapplymatrix(const transmatrix& V) {
|
||||
conformal::apply_orientation(mat[a*4], mat[a*4+1]);
|
||||
|
||||
glhr::set_modelview(glhr::as_glmatrix(mat));
|
||||
#endif
|
||||
}
|
||||
|
||||
void dqi_poly::gldraw() {
|
||||
|
||||
Reference in New Issue
Block a user