mirror of
https://github.com/zenorogue/hyperrogue.git
synced 2025-08-04 21:04:02 +00:00
nisot:: fixed shmup and view in non-geodesic mode
This commit is contained in:
parent
20f064de83
commit
d68a5bf760
@ -612,14 +612,19 @@ namespace nisot {
|
|||||||
}
|
}
|
||||||
|
|
||||||
transmatrix parallel_transport(const transmatrix Position, const transmatrix T) {
|
transmatrix parallel_transport(const transmatrix Position, const transmatrix T) {
|
||||||
if(!geodesic_movement) return Position * T;
|
|
||||||
auto P = Position;
|
auto P = Position;
|
||||||
nisot::fixmatrix(P);
|
nisot::fixmatrix(P);
|
||||||
|
if(!geodesic_movement) return inverse(eupush(Position * inverse(T) * inverse(Position) * C0)) * Position;
|
||||||
return parallel_transport_bare(P, T);
|
return parallel_transport_bare(P, T);
|
||||||
}
|
}
|
||||||
|
|
||||||
transmatrix transport_view(const transmatrix T, const transmatrix V) {
|
transmatrix transport_view(const transmatrix T, const transmatrix V) {
|
||||||
if(!geodesic_movement) return V * eupush(inverse(V) * T * V * C0);
|
if(!geodesic_movement) {
|
||||||
|
transmatrix IV = inverse(V);
|
||||||
|
nisot::fixmatrix(IV);
|
||||||
|
const transmatrix V1 = inverse(IV);
|
||||||
|
return V1 * eupush(IV * T * V1 * C0);
|
||||||
|
}
|
||||||
return inverse(parallel_transport(inverse(V), inverse(T)));
|
return inverse(parallel_transport(inverse(V), inverse(T)));
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user