How to put a limit to zoom in?

Hello,

One way to do it is to extend/customize the vtkInteractorStyleTrackballCamera classe like this one here: gammaray/v3dmouseinteractor.h at master · PauloCarvalhoRJ/gammaray · GitHub. That is a modified vtkInteractorStyleTrackballCamera to enable probing of mesh values via mouse picking with a probe marker. The probe marker is a small red sphere that must be resized according to the zoom applied so its angular size stays the same. To use a custom interactor style, do like this:

    m_myInteractorStyle = vtkSmartPointer<myInteractorStyle>::New();
    m_myInteractorStyle->SetDefaultRenderer( m_renderer );
    m_vtkwidget->renderWindow()->GetInteractor()->SetInteractorStyle( m_myInteractorStyle );

In the example above, m_vtkwidget is a QVTKOpenGLNativeWidget.