Commit 6c65b317 authored by Matthias Betz's avatar Matthias Betz
Browse files

inverted panning directions

parent b3da6958
...@@ -116,7 +116,7 @@ public class Camera { ...@@ -116,7 +116,7 @@ public class Camera {
Vector2f dir = new Vector2f(res.x, res.y); Vector2f dir = new Vector2f(res.x, res.y);
dir.normalize(); dir.normalize();
Vector2f yDrag = new Vector2f(); Vector2f yDrag = new Vector2f();
dir.mul((float) -dragDiffY * 0.5f, yDrag); dir.mul((float) dragDiffY * 0.5f, yDrag);
// handle diffY // handle diffY
centerPos.add(yDrag.x, yDrag.y, 0); centerPos.add(yDrag.x, yDrag.y, 0);
...@@ -126,7 +126,7 @@ public class Camera { ...@@ -126,7 +126,7 @@ public class Camera {
float temp = dir.x; float temp = dir.x;
dir.x = dir.y; dir.x = dir.y;
dir.y = -temp; dir.y = -temp;
dir.mul((float) dragDiffX * 0.5f); dir.mul((float) -dragDiffX * 0.5f);
centerPos.add(dir.x, dir.y, 0); centerPos.add(dir.x, dir.y, 0);
eyePos.add(dir.x, dir.y, 0); eyePos.add(dir.x, dir.y, 0);
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment