Yorthen

I'm currently rewriting the ModelViewerCamera slightly to control it in a different way than possible as it is. One of the things I'm trying to do is to change how the camera is moved with the mouse, I want to be able to move the centre of the arcball so that when the mouse is used to rotate the camera/model the rotation will be performed around the lookAt-point (this does not happen if you use the keyboard to move the camera).

My problem is that while I can get the screen X and Y movement of the mouse I can not translate this into movement in the world, I always move in the wrong coordinate system. What I want it so that if the user moves the mouse to the left then the object centre will move right (or is it left), in other words I want to move right in camera-coordinates.

Any pointers will be welcome.

--
Erik Wikstrom


Re: Game Technologies: DirectX 101 Transforming from view-coordinates to world

Yorthen

Never mind, I rewrote the camera to rotate the camera instead of the world by default, then all I have to do is to multiply with the inverted view-matrix.

--
Erik Wikstrom