I would like to rotate the camera around a sphere in sync with my mouse movement. On mousedown-and-drag, you can obviously rotate the camera around that sphere. BUT, depending on your distance from the surface of the sphere, it seems as if the sphere is either rotating faster beneath you (when zoomed in) or slower (when zoomed out; i.e. the sphere is pretty small on the screen).
As the size of the sphere will not change in my application, I thought about just modifying the mouse panning speed depending on the distance of the camera to the sphere’s surface. There is a SE post about this, and it seems that
panSpeed is now part of
panSpeed in reference to the rotational speed, or the speed of the mouse on the 2D screen? What is the unit of
panSpeed? It does not seem trivial to me what the correct speed would be, given the distance to the surface of the sphere (or world center).
Any other ideas or pointers on how to do this properly are much appreciated.