mirror of
https://github.com/zenorogue/hyperrogue.git
synced 2024-11-17 18:54:48 +00:00
embeddings:: fixed actual_to_logical and logical_to_actual in emb_same_in_same Euclidean
This commit is contained in:
parent
23f8be380d
commit
37aa0dadee
@ -505,6 +505,7 @@ struct emb_same_in_same : emb_actual {
|
||||
}
|
||||
|
||||
hyperpoint actual_to_logical(hyperpoint h) override {
|
||||
if(euclid) { h[3] = 1; return h; }
|
||||
ld z = asin_auto(h[2]);
|
||||
ld u = 1 / cos_auto(z);
|
||||
auto h1 = hpxy3(h[0] * u, h[1] * u, 0);
|
||||
@ -516,6 +517,7 @@ struct emb_same_in_same : emb_actual {
|
||||
}
|
||||
|
||||
hyperpoint logical_to_actual(hyperpoint h) override {
|
||||
if(euclid) { h[3] = 1; return h; }
|
||||
geom3::light_flip(true);
|
||||
auto b = logical_to_base(h);
|
||||
geom3::light_flip(false);
|
||||
|
Loading…
Reference in New Issue
Block a user