1
0
mirror of https://github.com/zenorogue/hyperrogue.git synced 2025-10-31 22:12:59 +00:00

camera_angle now uses matrix dialog

This commit is contained in:
Zeno Rogue
2023-08-14 18:08:28 +02:00
parent 3e1228b7c7
commit 67d38feabd
12 changed files with 56 additions and 76 deletions

View File

@@ -836,20 +836,8 @@ void display_data::set_projection(int ed, ld shift) {
glhr::projection_multiply(glhr::translate(0, 0.5, 0));
}
if(pconf.camera_angle && pmodel != mdPixel) {
ld cam = pconf.camera_angle * degree;
GLfloat cc = cos(cam);
GLfloat ss = sin(cam);
GLfloat yzspin[16] = {
1, 0, 0, 0,
0, cc, ss, 0,
0, -ss, cc, 0,
0, 0, 0, 1
};
glhr::projection_multiply(glhr::as_glmatrix(yzspin));
if(!models::camera_straight && pmodel != mdPixel) {
glhr::projection_multiply(glhr::tmtogl_transpose(pconf.cam()));
}
if(u_alpha) {