Viewer component which uses a virtual trackball to view the data. More...
#include <Inventor/MP/Xt/viewers/SoXtMPExaminerViewer.h>
Public Member Functions | |
SoXtMPExaminerViewer (SoWidget parent=NULL, const char *name=NULL, SbBool buildInsideParent=TRUE, SoXtMPFullViewer::BuildFlag flag=BUILD_ALL, SoXtMPViewer::Type type=BROWSER) | |
~SoXtMPExaminerViewer () | |
void | setFeedbackVisibility (SbBool onOrOff) |
SbBool | isFeedbackVisible () const |
void | setFeedbackSize (int newSize) |
int | getFeedbackSize () const |
void | setAnimationEnabled (SbBool onOrOff) |
SbBool | isAnimationEnabled () |
void | stopAnimating () |
SbBool | isAnimating () |
virtual void | viewAll () |
virtual void | resetToHomePosition () |
virtual void | setCamera (SoCamera *cam) |
virtual void | setViewing (SbBool onOrOff) |
virtual void | setCursorEnabled (SbBool onOrOff) |
void | setCursor (SoXtCursor *cursor) |
SoXtCursor * | newCursor (void) |
Viewer component which uses a virtual trackball to view the data.
The Examiner viewer component allows you to rotate the view around a point of interest using a virtual trackball. The viewer uses the camera focalDistance field to figure out the point of rotation, which is usually set to be at the center of the scene. In addition to allowing you to rotate the camera around the point of interest, this viewer also allows you to translate the camera in the viewer plane, as well as dolly (move forward and backward) to get closer to or further away from the point of interest. The viewer seek capability can be used to position the camera towards a selected object or point.
NOTE: This class does not exist in Open Inventor 10.0 and later.!!------------------------------------------------ !! Preferences for Examiner Viewer !!------------------------------------------------ *IvFormExaminer1.IvEnableSpinAnimation.labelString: Enable spin animation *IvFormExaminer1.IvShowPointOfRotationAxes.labelString: Show point of rotation axes *IvFormExaminer1.IvAxesSize.labelString: axes size *IvFormExaminer1.IvPixels.labelString: pixels !!------------------------------------------------ !! Decorations for Examiner Viewer !! !!------------------------------------------------ *IvExamTitle.labelString: Examiner Viewer *IvExamPrefTitle.labelString: Examiner Viewer Preference Sheet *IvExamPopupTitle.labelString: Examiner Viewer *IvExamIconTitle.labelString: Examiner Viewer *IvExamRotx.labelString: Rotx *IvExamRoty.labelString: Roty *IvExamZoom.labelString: Zoom *IvExamDolly.labelString: Dolly
Left Mouse: Rotate the virtual trackball.
Middle Mouse or
Ctrl + Left Mouse: Translate up, down, left, right.
Ctrl + Middle Mouse or
Left + Middle Mouse: Dolly in and out (gets closer to and further away from the object).(Perspective camera) or zoom in and out (Orthographic camera).
<s> + Left Mouse: Alternative to the Seek button. Press (but do not hold down) the <s> key, then click on a target object.
Right Mouse: Open the popup menu.
ALT: When the viewer is in selection (a.k.a. pick) mode, pressing and holding the ALT key temporarily switches the viewer to viewing mode. When the ALT key is released, the viewer returns to selection mode. Note: If any of the mouse buttons are currently depressed, the ALT key has no effect.
SoXtMPFullViewer, SoXtMPViewer, SoXtComponent, SoXtMPRenderArea, SoXtMPWalkViewer, SoXtMPFlyViewer, SoXtMPPlaneViewer
SoXtMPExaminerViewer::SoXtMPExaminerViewer | ( | SoWidget | parent = NULL , |
|
const char * | name = NULL , |
|||
SbBool | buildInsideParent = TRUE , |
|||
SoXtMPFullViewer::BuildFlag | flag = BUILD_ALL , |
|||
SoXtMPViewer::Type | type = BROWSER | |||
) |
Constructor which specifies the viewer type.
Please refer to the SoXtMPViewer reference page for a description of the viewer types.
SoXtMPExaminerViewer::~SoXtMPExaminerViewer | ( | ) |
Destructor.
int SoXtMPExaminerViewer::getFeedbackSize | ( | ) | const [inline] |
Returns the point of rotation feedback size in pixels.
SbBool SoXtMPExaminerViewer::isAnimating | ( | ) | [inline] |
Queries if the viewer is currently animating.
SbBool SoXtMPExaminerViewer::isAnimationEnabled | ( | ) | [inline] |
Returns whether spin animation is enabled.
SbBool SoXtMPExaminerViewer::isFeedbackVisible | ( | ) | const [inline] |
Returns the rotation feedback flag.
SoXtCursor* SoXtMPExaminerViewer::newCursor | ( | void | ) |
Returns a pointer to a newly created SoXtCursor instance, which can then be customized with a pixmap, colors, etc.
virtual void SoXtMPExaminerViewer::resetToHomePosition | ( | ) | [virtual] |
Restores the camera values.
Reimplemented from SoXtMPViewer.
void SoXtMPExaminerViewer::setAnimationEnabled | ( | SbBool | onOrOff | ) |
Enables/disables the spinning animation feature of the viewer (enabled by default).
virtual void SoXtMPExaminerViewer::setCamera | ( | SoCamera * | cam | ) | [virtual] |
Sets the edited camera.
Setting the camera is only needed if the first camera found in the scene when setting the scene graph isn't the one the user really wants to edit.
Reimplemented from SoXtMPFullViewer.
void SoXtMPExaminerViewer::setCursor | ( | SoXtCursor * | cursor | ) |
Sets the specified cursor active inside all MultiPipe windows.
If cursor is NULL, the default arrow cursor is used.
virtual void SoXtMPExaminerViewer::setCursorEnabled | ( | SbBool | onOrOff | ) | [virtual] |
Sets whether the viewer is allowed to change the cursor over the renderArea window.
When disabled, the cursor is undefined by the viewer and will not change as the mode of the viewer changes. When re-enabled, the viewer will reset it to the appropriate icon.
Disabling the cursor enables the application to set the cursor directly on the viewer window or on any parent widget of the viewer. This can be used when setting a busy cursor on the application shell.
Reimplemented from SoXtMPViewer.
void SoXtMPExaminerViewer::setFeedbackSize | ( | int | newSize | ) |
Sets the point of rotation feedback size in pixels (default 20 pix).
void SoXtMPExaminerViewer::setFeedbackVisibility | ( | SbBool | onOrOff | ) |
Shows/hides the point of rotation feedback, which only appears while in viewing mode (default is off).
virtual void SoXtMPExaminerViewer::setViewing | ( | SbBool | onOrOff | ) | [virtual] |
Sets whether the viewer is turned on or off.
When turned on, events are consumed by the viewer. When viewing is off, events are processed by the viewer's render area. This means events will be sent down to the scene graph for processing (i.e. picking can occur). Note that if the application has registered an event callback, it will be invoked on every message, whether viewing is turned on or not. However, the return value of this callback (which specifies whether the callback handled the event or not) is ignored when viewing is on. That is, the viewer will process the event even if the callback already did. This is to ensure that the viewing paradigm is not broken (default viewing is on).
Reimplemented from SoXtMPFullViewer.
void SoXtMPExaminerViewer::stopAnimating | ( | ) |
Stops animation, if it is occurring.
virtual void SoXtMPExaminerViewer::viewAll | ( | ) | [virtual] |
Changes the camera position to view the entire scene (the camera zoom or orientation isn't changed).
Reimplemented from SoXtMPViewer.