1
0
mirror of https://github.com/zenorogue/hyperrogue.git synced 2025-08-31 01:37:57 +00:00

variant fisheye projection

This commit is contained in:
Zeno Rogue
2024-01-07 12:52:50 +01:00
parent 31471fc6c5
commit 4c6c44cc26
5 changed files with 40 additions and 5 deletions

View File

@@ -619,6 +619,11 @@ EX namespace models {
if(vpmodel == mdFisheye)
add_edit(vpconf.fisheye_param);
if(vpmodel == mdFisheye2) {
add_edit(vpconf.fisheye_param);
add_edit(vpconf.fisheye_alpha);
}
if(is_hyperboloid(vpmodel))
add_edit(pconf.show_hyperboloid_flat);
@@ -974,6 +979,13 @@ EX namespace models {
-> editable(1e-3, 10, .1, "fisheye parameter", "Size of the fish eye.", 'b')
-> set_sets(dialog::scaleLog);
param_f(p.fisheye_alpha, pp+"fishalpha", sp+"off-center parameter", 0)
-> editable(1e-1, 10, .1, "off-center parameter",
"This projection is obtained by composing gnomonic projection and inverse stereographic projection. "
"This parameter changes the center of the first projection (0 = gnomonic, 1 = stereographic). Use a value closer to 1 "
"to make the projection more conformal.",
'o');
param_f(p.stretch, pp+"stretch", 1)
-> editable(0, 10, .1, "vertical stretch", "Vertical stretch factor.", 's')
-> set_extra(stretch_extra);