summaryrefslogtreecommitdiffhomepage
path: root/logic
diff options
context:
space:
mode:
authorStanislaw Halik <sthalik@misaki.pl>2017-06-13 14:11:12 +0200
committerStanislaw Halik <sthalik@misaki.pl>2017-06-13 14:11:12 +0200
commit55b46808b3828a6c7d5d7babd91ca8def835b1f6 (patch)
tree59455707efe170f4238a5342335d4b1f1d38bf69 /logic
parent3599a5aa4b2f201a6b227f082ad1406a235c0da2 (diff)
logic/tracker: only unrotate for camera case
Diffstat (limited to 'logic')
-rw-r--r--logic/tracker.cpp7
1 files changed, 3 insertions, 4 deletions
diff --git a/logic/tracker.cpp b/logic/tracker.cpp
index 7f546236..81854d0d 100644
--- a/logic/tracker.cpp
+++ b/logic/tracker.cpp
@@ -210,6 +210,7 @@ void Tracker::logic()
{
rmat rotation;
+ euler_t pos = euler_t(&value[TX]) - t_center;
switch (s.center_method)
{
@@ -221,13 +222,11 @@ void Tracker::logic()
default:
case 1:
rotation = scaled_rotation.rotation * scaled_rotation.rot_center;
+ t_compensate(real_rotation.rot_center, pos, pos, false, false, false);
+
break;
}
- euler_t pos = euler_t(&value[TX]) - t_center;
-
- t_compensate(real_rotation.rot_center, pos, pos, false, false, false);
-
euler_t rot = r2d * c_mult * rmat_to_euler(rotation);
for (int i = 0; i < 3; i++)