add option to drag at cursor instead of view center

This commit is contained in:
wmayer
2018-07-25 22:36:35 +02:00
parent 6e8b60589f
commit d4987d088f
5 changed files with 131 additions and 16 deletions

View File

@@ -348,6 +348,10 @@ void View3DInventor::OnChange(ParameterGrp::SubjectType &rCaller,ParameterGrp::M
float val = rGrp.GetFloat("ZoomStep", 0.0f);
_viewer->navigationStyle()->setZoomStep(val);
}
else if (strcmp(Reason,"DragAtCursor") == 0) {
bool on = rGrp.GetBool("DragAtCursor", false);
_viewer->navigationStyle()->setDragAtCursor(on);
}
else if (strcmp(Reason,"EyeDistance") == 0) {
_viewer->getSoRenderManager()->setStereoOffset(rGrp.GetFloat("EyeDistance",5.0));
}