[vtkusers] re:how move an actor with the mouse

Yixun Liu yxliu at fudan.edu.cn
Sat Sep 23 22:32:39 EDT 2006


Hi,
IF you have a 3-button mouse, point to the actor using mouse and then push middle button as you move. If you with 2-button mouse, pan is defined as <Shift>-Button 1.

>From vtk vtkInteractorStyle Class Reference:
  a.. Keypress j / Keypress t: toggle between joystick (position sensitive) and trackball (motion sensitive) styles. In joystick style, motion occurs continuously as long as a mouse button is pressed. In trackball style, motion occurs when the mouse button is pressed and the mouse pointer moves. 
  b.. Keypress c / Keypress a: toggle between camera and actor modes. In camera mode, mouse events affect the camera position and focal point. In actor mode, mouse events affect the actor that is under the mouse pointer. 
  c.. Button 1: rotate the camera around its focal point (if camera mode) or rotate the actor around its origin (if actor mode). The rotation is in the direction defined from the center of the renderer's viewport towards the mouse position. In joystick mode, the magnitude of the rotation is determined by the distance the mouse is from the center of the render window. 
  d.. Button 2: pan the camera (if camera mode) or translate the actor (if actor mode). In joystick mode, the direction of pan or translation is from the center of the viewport towards the mouse position. In trackball mode, the direction of motion is the direction the mouse moves. (Note: with 2-button mice, pan is defined as <Shift>-Button 1.) 
  e.. Button 3: zoom the camera (if camera mode) or scale the actor (if actor mode). Zoom in/increase scale if the mouse position is in the top half of the viewport; zoom out/decrease scale if the mouse position is in the bottom half. In joystick mode, the amount of zoom is controlled by the distance of the mouse pointer from the horizontal centerline of the window. 
  f.. Keypress 3: toggle the render window into and out of stereo mode. By default, red-blue stereo pairs are created. Some systems support Crystal Eyes LCD stereo glasses; you have to invoke SetStereoTypeToCrystalEyes() on the rendering window. 
  g.. Keypress e: exit the application. 
  h.. Keypress f: fly to the picked point 
  i.. Keypress p: perform a pick operation. The render window interactor has an internal instance of vtkCellPicker that it uses to pick. 
  j.. Keypress r: reset the camera view along the current view direction. Centers the actors and moves the camera so that all actors are visible. 
  k.. Keypress s: modify the representation of all actors so that they are surfaces. 
  l.. Keypress u: invoke the user-defined function. Typically, this keypress will bring up an interactor that you can type commands in. 
  m.. Keypress w: modify the representation of all actors so that they are wireframe.
Hope it help.

Yixun Liu

 
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://www.vtk.org/pipermail/vtkusers/attachments/20060924/583a5f43/attachment.htm>


More information about the vtkusers mailing list