My C++ application displays an actor in a vtkRenderWindow, with an associated vtkGenericRenderWindowInteractor. If in “camera mode” and I left-click the mouse in the window at position x,y the surface is rendered from a different view angle (i.e. the camera is moved). I want to issue the equivalent through C++ such that the camera view is changed as if I manually clicked the mouse.
I tried this:
interactor_->SetEventPosition(x, y); interactor_->LeftButtonPressEvent(); renderWindow->Render();
But the camera doesn’t move. What else do I need to do?