1
0
mirror of https://github.com/zenorogue/hyperrogue.git synced 2024-11-30 15:39:54 +00:00

3d:: TEXTURE_STEP_3D is now configurable

This commit is contained in:
Zeno Rogue 2019-05-04 20:22:11 +02:00
parent 89a900958b
commit b10b6386f3
2 changed files with 26 additions and 1 deletions

View File

@ -1282,6 +1282,30 @@ void show3D() {
dialog::editNumber(vid.radarsize, 0, 360, 15, 90, "", "set to 0 to disable");
});
}
if(DIM == 3) {
dialog::addSelItem(XLAT("wall quality"), its(vid.texture_step), 'W');
dialog::add_action([] {
dialog::editNumber(vid.texture_step, 1, 16, 1, 1, XLAT("wall quality"),
XLAT(
"Controls the number of triangles used for wall surfaces. "
"Higher numbers reduce the performance. "
"This has a strong effect when the walls are curved indeed "
"(honeycombs based on horospheres, and projections other than native perspective), "
"but otherwise, usually it can be set to 1 without significant adverse effects other "
"than slightly incorrect texturing."
)
);
dialog::bound_low(1);
dialog::bound_up(128);
dialog::reaction = [] {
if(floor_textures) {
delete floor_textures;
floor_textures = NULL;
}
need_reset_geometry = true;
};
});
}
dialog::addBreak(50);
#if CAP_RUG

View File

@ -1160,6 +1160,7 @@ struct videopar {
ld fov;
bool consider_shader_projection;
int desaturate;
int texture_step;
};
extern videopar vid;
@ -5041,7 +5042,7 @@ namespace subscreens {
bool split(reaction_t for_each_subscreen);
}
const int TEXTURE_STEP_3D=8;
#define TEXTURE_STEP_3D vid.texture_step
void set_euland3(cell *c, int co0, int co1, int alt, int hash);