Hello,
We are currently stuck on an issue related to mouse movements, and despite extensive searches on the forums, we have not yet come across a similar question.
When I right-click the mouse, I want the camera to rotate only around the X and Z axes. For instance, if there is a plane actor in front of me, I want it to always stay perpendicular to the camera.
I am using the VTK Python wrapper version 9.3.0. Please ask for additional details if the question is not clear.
Hello,
I guess you should create custom interactor style and overwrite some mouse events.
Exactly what I want is that the right click always makes the camera rotate so that the platform is always above.
Thanks, I’ve already done that by adding a custom interactor style to overwrite it. In this way, I can overwrite the mouse buttons, but I can’t overwrite the ‘Rotate’ function.
https://gitlab.kitware.com/f3d/f3d/-/blob/master/src/vtkF3DInteractorStyle.cxx#L257
I think I need to disable the camera’s elevation. Actually, what I’m trying to do is to cancel the ‘Y’ axis in the Rotate function and make the rotate function work only on X and Z axes.