mirror of
https://github.com/zenorogue/hyperrogue.git
synced 2025-06-11 10:54:08 +00:00
model orientation supported in Joukowsky
This commit is contained in:
parent
2b79e9d0c7
commit
23b59101ae
@ -599,7 +599,7 @@ namespace conformal {
|
|||||||
|
|
||||||
bool model_has_orientation() {
|
bool model_has_orientation() {
|
||||||
return
|
return
|
||||||
among(pmodel, mdHalfplane, mdPolynomial, mdPolygonal, mdTwoPoint) || mdBandAny();
|
among(pmodel, mdHalfplane, mdPolynomial, mdPolygonal, mdTwoPoint, mdJoukowsky, mdJoukowskyInverted) || mdBandAny();
|
||||||
}
|
}
|
||||||
|
|
||||||
void model_menu() {
|
void model_menu() {
|
||||||
|
@ -410,6 +410,7 @@ void applymodel(hyperpoint H, hyperpoint& ret) {
|
|||||||
ld x0, y0;
|
ld x0, y0;
|
||||||
x0 = H[0] / tz;
|
x0 = H[0] / tz;
|
||||||
y0 = H[1] / tz;
|
y0 = H[1] / tz;
|
||||||
|
conformal::apply_orientation(x0, y0);
|
||||||
ld r = hypot(x0, y0);
|
ld r = hypot(x0, y0);
|
||||||
ld c = x0 / r;
|
ld c = x0 / r;
|
||||||
ld s = y0 / r;
|
ld s = y0 / r;
|
||||||
@ -421,6 +422,7 @@ void applymodel(hyperpoint H, hyperpoint& ret) {
|
|||||||
ret[0] = ret[0] / r2;
|
ret[0] = ret[0] / r2;
|
||||||
ret[1] = -ret[1] / r2;
|
ret[1] = -ret[1] / r2;
|
||||||
}
|
}
|
||||||
|
conformal::apply_orientation(ret[1], ret[0]);
|
||||||
ghcheck(ret,H);
|
ghcheck(ret,H);
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
Loading…
x
Reference in New Issue
Block a user