When using OpenGLXmViewer, the rotation control panel has the feature to select between rotating the camera or the object. When moving the camera, the UpVector for this view keeps constant, which is natural. But when moving the object (i.e. move-lights-with-viewpoint enabled in the code), this Vector keeps also constant relative to the object. I think, it should be constant relative to the viewpoint. This would prevent flipping the object, when reaching the opposite side of the UpVector. I would suggest to add: if (pView->fVP.GetLightsMoveWithCamera()) { G4Vector3D new_up = (new_vp.cross(yprime)).unit(); pView->fVP.SetUpVector(new_up); } in line 146 of funtion void G4OpenGLXmViewer::rotate_in_phi (XtPointer clientData, XtIntervalId* timer_id) in file visualization/OpenGL/src/G4OpenGLXmRotationCallbacks.cc This keeps the UpVector pointing to the upper edge of the window relative to the viewpoint (and therefore relative to the user in front of the screen).
OK, this is a nice idea. Let us think about it.
Fixed in tag opengl-V03-00-00. This will hopefully make the February reference tag.