Bug in CameraController.AddRotateForce(double dx, double dy)

Feb 19, 2012 at 10:16 AM


the method CameraController.AddRotateForce(double dx, double dy) always works as CameraMode.Inspect.

In my case, I have CameraMode set to WalkAround, which works fine for mouse controls, but keyboard control is wrong in that case.


I changed the method to

        public void AddRotateForce(double dx, double dy)
            if (!this.IsRotationEnabled)


            if (this.CameraMode == CameraMode.WalkAround)
                this.rotationPoint3D = this.CameraPosition;
                this.rotationPoint3D = this.CameraTarget;
            this.rotationPosition = new Point(this.ActualWidth / 2, this.ActualHeight / 2);
            this.rotationSpeed.X += dx * 40;
            this.rotationSpeed.Y += dy * 40;


which does kind of work, but rotating left/right via keyboard is inverted compared to mouse control.

What is the reason for the inverted controls?


Best Regards



btw: Just downloaded the latest source code and changing the CameraMode in CameraControlDemo does not work anymore.

Feb 21, 2012 at 7:59 PM

thanks for the feedback! I have only used the "Inspect" mode recently, it seems like the "Walkaround" mode is not working properly. I added it as issue 9949!

Feb 22, 2012 at 7:08 AM

Thank you.