SoTabPlaneDragger¶
-
InventorModule
¶ genre InventorDraggers
author Silicon Graphics Inc
package MeVisLab/Standard
definition inventor.def
Purpose¶
SoTabPlaneDragger
is a dragger which allows the user to interactively translate and scale objects in a plane. It looks like a square white outline with smaller green squares (or tabs) set in the corners and along the center of each edge. Dragging a corner tab scales the dragger in 2D by scaling about the opposite corner. Dragging an edge tab performs 1D scaling about the opposite edge. The rest of the dragger is invisible but pickable; selecting it initiates translation within the plane.
The dragger tries to keep the small tabs a constant size in screen space. Every time a drag begins or ends, the size is recalculated based on the viewing and modeling matrix.
When dragging the translator part, press the key and you can constrain motion to either the local x axis or the y axis. The direction is determined by your initial mouse gesture after pressing the key. Releasing the key removes the constraint.
When the translator part drags, the dragger updates its Translation
field. The various scaling parts cause changes to both the Scale Factor
and Translation
field, since scaling about a point other than the center adds translation to the center of the dragger. If you set the field, the dragger will move accordingly. You can also connect fields of other nodes or engines from this one to make them follow the dragger’s motion.