|
VTK
9.7.20260824
|
#include <vtkScivisView.h>
A ready-made rendering assembly for scientific visualization.
Every VTK rendering program builds the same thing by hand: a renderer, a render window, an interactor, an interactor style, a light, an orientation marker, and the wiring between them. vtkScivisView is that assembly, already built. A view you have just created draws something reasonable before you configure anything, and it stays consistent when you replace a piece of it: hand it a render window of your own and the renderers move across, while an interactor style you had installed survives the change.
Definition at line 91 of file vtkScivisView.h.
Public Types | |
| typedef vtkObject | Superclass |
Public Member Functions | |
| virtual vtkTypeBool | IsA (const char *type) |
| Return 1 if this class is the same type of (or a subclass of) the named class. | |
| vtkScivisView * | NewInstance () const |
| void | PrintSelf (ostream &os, vtkIndent indent) override |
| Methods invoked by print to print information about the object including superclasses. | |
| vtkMTimeType | GetMTime () override |
| The view stores its configuration on the renderer, render window, light kit and orientation marker widget rather than in its own ivars, so the modified time reported here is the latest of this object's own and theirs. | |
| vtkOrientationMarkerWidget * | GetOrientationMarkerWidget () |
| The orientation marker widget itself, for its viewport, its marker, and whether the user can move and resize it. | |
| vtkLightKit * | GetLightKit () |
| The light kit itself, for its intensity, warmth, angle and ratio parameters. | |
| vtkScivisSelector * | GetSelector () |
| Selection: how a screen region becomes a selection, whether points or cells come back, and what was picked last. | |
| void | Start () |
| virtual void | Render () |
| Bring every representation up to date and draw. | |
| virtual void | ResetCamera () |
| Frame the camera on everything the representations are drawing. | |
| virtual void | Update () |
| Bring every representation up to date without drawing. | |
| void | AddRepresentation (vtkScivisRepresentation *rep) |
| The representations this view shows. | |
| void | SetRepresentation (vtkScivisRepresentation *rep) |
| The representations this view shows. | |
| void | RemoveRepresentation (vtkScivisRepresentation *rep) |
| The representations this view shows. | |
| void | RemoveAllRepresentations () |
| The representations this view shows. | |
| int | GetNumberOfRepresentations () |
| The representations this view shows. | |
| vtkScivisRepresentation * | GetRepresentation (int index=0) |
| The representations this view shows. | |
| bool | IsRepresentationPresent (vtkScivisRepresentation *rep) |
| The representations this view shows. | |
| vtkRenderer * | GetRenderer () |
| The renderer, render window and interactor this view draws with. | |
| void | SetRenderer (vtkRenderer *renderer) |
| The renderer, render window and interactor this view draws with. | |
| vtkRenderWindow * | GetRenderWindow () |
| The renderer, render window and interactor this view draws with. | |
| void | SetRenderWindow (vtkRenderWindow *window) |
| The renderer, render window and interactor this view draws with. | |
| vtkRenderWindowInteractor * | GetInteractor () |
| The renderer, render window and interactor this view draws with. | |
| void | SetInteractor (vtkRenderWindowInteractor *interactor) |
| The renderer, render window and interactor this view draws with. | |
| void | SetBackground (double r, double g, double b) |
| Set/Get the background color of the renderer. | |
| double * | GetBackground () |
| Set/Get the background color of the renderer. | |
| void | SetBackground2 (double r, double g, double b) |
| Set/Get the background color of the renderer. | |
| double * | GetBackground2 () |
| Set/Get the background color of the renderer. | |
| void | SetGradientBackground (bool val) |
| Set/Get the background color of the renderer. | |
| bool | GetGradientBackground () |
| Set/Get the background color of the renderer. | |
| void | SetWindowSize (int w, int h) |
| Set/Get the render window size and title. | |
| int * | GetWindowSize () |
| Set/Get the render window size and title. | |
| void | SetWindowTitle (const char *title) |
| Set/Get the render window size and title. | |
| const char * | GetWindowTitle () |
| Set/Get the render window size and title. | |
| void | SetOrientationAxesVisibility (bool val) |
| Show or hide the orientation axes marker in the lower-left corner of the render window. | |
| bool | GetOrientationAxesVisibility () |
| Show or hide the orientation axes marker in the lower-left corner of the render window. | |
| void | SetUseLightKit (bool val) |
| Enable or disable the light kit: a five light rig – key, fill, headlight and two back lights – managed by vtkLightKit. | |
| bool | GetUseLightKit () |
| Enable or disable the light kit: a five light rig – key, fill, headlight and two back lights – managed by vtkLightKit. | |
| void | SetInteractorStyle (vtkInteractorObserver *style) |
| Install an interactor style of your own, for interaction the built-in modes do not cover – a 2D or terrain camera, or a vtkInteractorStyleManipulator configured with your own button bindings. | |
| vtkInteractorObserver * | GetInteractorStyle () |
| Install an interactor style of your own, for interaction the built-in modes do not cover – a 2D or terrain camera, or a vtkInteractorStyleManipulator configured with your own button bindings. | |
| Public Member Functions inherited from vtkObject | |
| vtkBaseTypeMacro (vtkObject, vtkObjectBase) | |
| virtual void | DebugOn () |
| Turn debugging output on. | |
| virtual void | DebugOff () |
| Turn debugging output off. | |
| bool | GetDebug () |
| Get the value of the debug flag. | |
| void | SetDebug (bool debugFlag) |
| Set the value of the debug flag. | |
| virtual void | Modified () |
| Update the modification time for this object. | |
| void | RemoveObserver (unsigned long tag) |
| void | RemoveObservers (unsigned long event) |
| void | RemoveObservers (const char *event) |
| void | RemoveAllObservers () |
| vtkTypeBool | HasObserver (unsigned long event) |
| vtkTypeBool | HasObserver (const char *event) |
| vtkTypeBool | InvokeEvent (unsigned long event) |
| vtkTypeBool | InvokeEvent (const char *event) |
| std::string | GetObjectDescription () const override |
| The object description printed in messages and PrintSelf output. | |
| unsigned long | AddObserver (unsigned long event, vtkCommand *, float priority=0.0f) |
| Allow people to add/remove/invoke observers (callbacks) to any VTK object. | |
| unsigned long | AddObserver (const char *event, vtkCommand *, float priority=0.0f) |
| Allow people to add/remove/invoke observers (callbacks) to any VTK object. | |
| vtkCommand * | GetCommand (unsigned long tag) |
| Allow people to add/remove/invoke observers (callbacks) to any VTK object. | |
| void | RemoveObserver (vtkCommand *) |
| Allow people to add/remove/invoke observers (callbacks) to any VTK object. | |
| void | RemoveObservers (unsigned long event, vtkCommand *) |
| Allow people to add/remove/invoke observers (callbacks) to any VTK object. | |
| void | RemoveObservers (const char *event, vtkCommand *) |
| Allow people to add/remove/invoke observers (callbacks) to any VTK object. | |
| vtkTypeBool | HasObserver (unsigned long event, vtkCommand *) |
| Allow people to add/remove/invoke observers (callbacks) to any VTK object. | |
| vtkTypeBool | HasObserver (const char *event, vtkCommand *) |
| Allow people to add/remove/invoke observers (callbacks) to any VTK object. | |
| template<class U, class T> | |
| unsigned long | AddObserver (unsigned long event, U observer, void(T::*callback)(), float priority=0.0f) |
| Overloads to AddObserver that allow developers to add class member functions as callbacks for events. | |
| template<class U, class T> | |
| unsigned long | AddObserver (unsigned long event, U observer, void(T::*callback)(vtkObject *, unsigned long, void *), float priority=0.0f) |
| Overloads to AddObserver that allow developers to add class member functions as callbacks for events. | |
| template<class U, class T> | |
| unsigned long | AddObserver (unsigned long event, U observer, bool(T::*callback)(vtkObject *, unsigned long, void *), float priority=0.0f) |
| Allow user to set the AbortFlagOn() with the return value of the callback method. | |
| vtkTypeBool | InvokeEvent (unsigned long event, void *callData) |
| This method invokes an event and return whether the event was aborted or not. | |
| vtkTypeBool | InvokeEvent (const char *event, void *callData) |
| This method invokes an event and return whether the event was aborted or not. | |
| virtual void | SetObjectName (const std::string &objectName) |
| Set/get the name of this object for reporting purposes. | |
| virtual std::string | GetObjectName () const |
| Set/get the name of this object for reporting purposes. | |
| Public Member Functions inherited from vtkObjectBase | |
| const char * | GetClassName () const |
| Return the class name as a string. | |
| virtual vtkIdType | GetNumberOfGenerationsFromBase (const char *name) |
| Given the name of a base class of this class type, return the distance of inheritance between this class type and the named class (how many generations of inheritance are there between this class and the named class). | |
| virtual void | Delete () |
| Delete a VTK object. | |
| virtual void | FastDelete () |
| Delete a reference to this object. | |
| void | InitializeObjectBase () |
| void | Print (ostream &os) |
| Print an object to an ostream. | |
| void | Register (vtkObjectBase *o) |
| Increase the reference count (mark as used by another object). | |
| virtual void | UnRegister (vtkObjectBase *o) |
| Decrease the reference count (release by another object). | |
| int | GetReferenceCount () |
| Return the current reference count of this object. | |
| void | SetReferenceCount (int) |
| Sets the reference count. | |
| bool | GetIsInMemkind () const |
| A local state flag that remembers whether this object lives in the normal or extended memory space. | |
| virtual void | PrintHeader (ostream &os, vtkIndent indent) |
| Methods invoked by print to print information about the object including superclasses. | |
| virtual void | PrintTrailer (ostream &os, vtkIndent indent) |
| Methods invoked by print to print information about the object including superclasses. | |
| virtual bool | UsesGarbageCollector () const |
| Indicate whether the class uses vtkGarbageCollector or not. | |
Static Public Member Functions | |
| static vtkScivisView * | New () |
| static vtkTypeBool | IsTypeOf (const char *type) |
| static vtkScivisView * | SafeDownCast (vtkObjectBase *o) |
| Static Public Member Functions inherited from vtkObject | |
| static vtkObject * | New () |
| Create an object with Debug turned off, modified time initialized to zero, and reference counting on. | |
| static void | BreakOnError () |
| This method is called when vtkErrorMacro executes. | |
| static void | SetGlobalWarningDisplay (vtkTypeBool val) |
| This is a global flag that controls whether any debug, warning or error messages are displayed. | |
| static void | GlobalWarningDisplayOn () |
| This is a global flag that controls whether any debug, warning or error messages are displayed. | |
| static void | GlobalWarningDisplayOff () |
| This is a global flag that controls whether any debug, warning or error messages are displayed. | |
| static vtkTypeBool | GetGlobalWarningDisplay () |
| This is a global flag that controls whether any debug, warning or error messages are displayed. | |
| Static Public Member Functions inherited from vtkObjectBase | |
| static vtkTypeBool | IsTypeOf (const char *name) |
| Return 1 if this class type is the same type of (or a subclass of) the named class. | |
| static vtkIdType | GetNumberOfGenerationsFromBaseType (const char *name) |
| Given a the name of a base class of this class type, return the distance of inheritance between this class type and the named class (how many generations of inheritance are there between this class and the named class). | |
| static vtkObjectBase * | New () |
| Create an object with Debug turned off, modified time initialized to zero, and reference counting on. | |
| static void | SetMemkindDirectory (const char *directoryname) |
| The name of a directory, ideally mounted -o dax, to memory map an extended memory space within. | |
| static bool | GetUsingMemkind () |
| A global state flag that controls whether vtkObjects are constructed in the usual way (the default) or within the extended memory space. | |
Protected Member Functions | |
| virtual vtkObjectBase * | NewInstanceInternal () const |
| vtkScivisView () | |
| ~vtkScivisView () override | |
| virtual void | PrepareForRendering () |
| Called before every render, once the representations are up to date. | |
| vtkCommand * | GetObserver () |
| The observer this view listens through. | |
| virtual void | ProcessEvents (vtkObject *caller, unsigned long eventId, void *callData) |
| Called for every event the view is observing. | |
| virtual void | AddRepresentationInternal (vtkScivisRepresentation *rep) |
| Hooks for subclasses, called after a representation has been accepted or before one is dropped. | |
| virtual void | RemoveRepresentationInternal (vtkScivisRepresentation *rep) |
| Hooks for subclasses, called after a representation has been accepted or before one is dropped. | |
| Protected Member Functions inherited from vtkObject | |
| vtkObject () | |
| ~vtkObject () override | |
| void | RegisterInternal (vtkObjectBase *, vtkTypeBool check) override |
| void | UnRegisterInternal (vtkObjectBase *, vtkTypeBool check) override |
| void | InternalGrabFocus (vtkCommand *mouseEvents, vtkCommand *keypressEvents=nullptr) |
| These methods allow a command to exclusively grab all events. | |
| void | InternalReleaseFocus () |
| These methods allow a command to exclusively grab all events. | |
| Protected Member Functions inherited from vtkObjectBase | |
| vtkObjectBase () | |
| virtual | ~vtkObjectBase () |
| virtual void | ReportReferences (vtkGarbageCollector *) |
| vtkObjectBase (const vtkObjectBase &) | |
| void | operator= (const vtkObjectBase &) |
Protected Attributes | |
| vtkSmartPointer< vtkRenderer > | Renderer |
| vtkSmartPointer< vtkRenderWindow > | RenderWindow |
| Protected Attributes inherited from vtkObject | |
| bool | Debug |
| vtkTimeStamp | MTime |
| vtkSubjectHelper * | SubjectHelper |
| std::string | ObjectName |
| Protected Attributes inherited from vtkObjectBase | |
| std::atomic< int32_t > | ReferenceCount |
| vtkWeakPointerBase ** | WeakPointers |
Friends | |
| class | Command |
| enum | { INTERACTION_MODE_3D = 0 , INTERACTION_MODE_SELECTION = 1 , INTERACTION_MODE_CUSTOM = 2 } |
| Interaction mode constants. More... | |
| void | SetInteractionMode (int mode) |
| Interaction mode constants. | |
| int | GetInteractionMode () |
| Interaction mode constants. | |
| void | SetInteractionModeTo3D () |
| Interaction mode constants. | |
| void | SetInteractionModeToSelection () |
| Interaction mode constants. | |
Additional Inherited Members | |
| Static Protected Member Functions inherited from vtkObjectBase | |
| static vtkMallocingFunction | GetCurrentMallocFunction () |
| static vtkReallocingFunction | GetCurrentReallocFunction () |
| static vtkFreeingFunction | GetCurrentFreeFunction () |
| static vtkFreeingFunction | GetAlternateFreeFunction () |
| typedef vtkObject vtkScivisView::Superclass |
Definition at line 95 of file vtkScivisView.h.
| anonymous enum |
Interaction mode constants.
INTERACTION_MODE_3D uses vtkInteractorStyleTrackballCamera (default). INTERACTION_MODE_SELECTION uses vtkInteractorStyleRubberBand3D for rubber-band selection. Mode switching is programmatic; applications typically expose it through a toolbar or keyboard shortcut. INTERACTION_MODE_CUSTOM reports that a style supplied through SetInteractorStyle() is installed; it cannot be selected directly.
The view owns one instance of each built-in style and switches between them, so any configuration applied to a style survives a mode change.
| Enumerator | |
|---|---|
| INTERACTION_MODE_3D | |
| INTERACTION_MODE_SELECTION | |
| INTERACTION_MODE_CUSTOM | |
Definition at line 216 of file vtkScivisView.h.
|
protected |
|
overrideprotected |
|
static |
|
static |
|
virtual |
Return 1 if this class is the same type of (or a subclass of) the named class.
Returns 0 otherwise. This method works in combination with vtkTypeMacro found in vtkSetGet.h.
Reimplemented from vtkObjectBase.
|
static |
|
protectedvirtual |
| vtkScivisView * vtkScivisView::NewInstance | ( | ) | const |
|
overridevirtual |
|
overridevirtual |
The view stores its configuration on the renderer, render window, light kit and orientation marker widget rather than in its own ivars, so the modified time reported here is the latest of this object's own and theirs.
Note that this makes the view report scene changes too, since adding or removing a representation modifies the renderer.
Reimplemented from vtkObject.
| void vtkScivisView::AddRepresentation | ( | vtkScivisRepresentation * | rep | ) |
The representations this view shows.
AddRepresentation() offers the view to the representation and drops it again if the representation refuses, which is how a representation declines a view it cannot work in. SetRepresentation() is the same after removing whatever is already there.
| void vtkScivisView::SetRepresentation | ( | vtkScivisRepresentation * | rep | ) |
The representations this view shows.
AddRepresentation() offers the view to the representation and drops it again if the representation refuses, which is how a representation declines a view it cannot work in. SetRepresentation() is the same after removing whatever is already there.
| void vtkScivisView::RemoveRepresentation | ( | vtkScivisRepresentation * | rep | ) |
The representations this view shows.
AddRepresentation() offers the view to the representation and drops it again if the representation refuses, which is how a representation declines a view it cannot work in. SetRepresentation() is the same after removing whatever is already there.
| void vtkScivisView::RemoveAllRepresentations | ( | ) |
The representations this view shows.
AddRepresentation() offers the view to the representation and drops it again if the representation refuses, which is how a representation declines a view it cannot work in. SetRepresentation() is the same after removing whatever is already there.
| int vtkScivisView::GetNumberOfRepresentations | ( | ) |
The representations this view shows.
AddRepresentation() offers the view to the representation and drops it again if the representation refuses, which is how a representation declines a view it cannot work in. SetRepresentation() is the same after removing whatever is already there.
| vtkScivisRepresentation * vtkScivisView::GetRepresentation | ( | int | index = 0 | ) |
The representations this view shows.
AddRepresentation() offers the view to the representation and drops it again if the representation refuses, which is how a representation declines a view it cannot work in. SetRepresentation() is the same after removing whatever is already there.
| bool vtkScivisView::IsRepresentationPresent | ( | vtkScivisRepresentation * | rep | ) |
The representations this view shows.
AddRepresentation() offers the view to the representation and drops it again if the representation refuses, which is how a representation declines a view it cannot work in. SetRepresentation() is the same after removing whatever is already there.
| vtkRenderer * vtkScivisView::GetRenderer | ( | ) |
The renderer, render window and interactor this view draws with.
All three are created with the view; setting one replaces it, and the others are rewired to match – the renderers move to a window given here, and an interactor style already in use survives the change. This is what an application does to draw the view into a window of its own.
| void vtkScivisView::SetRenderer | ( | vtkRenderer * | renderer | ) |
The renderer, render window and interactor this view draws with.
All three are created with the view; setting one replaces it, and the others are rewired to match – the renderers move to a window given here, and an interactor style already in use survives the change. This is what an application does to draw the view into a window of its own.
| vtkRenderWindow * vtkScivisView::GetRenderWindow | ( | ) |
The renderer, render window and interactor this view draws with.
All three are created with the view; setting one replaces it, and the others are rewired to match – the renderers move to a window given here, and an interactor style already in use survives the change. This is what an application does to draw the view into a window of its own.
| void vtkScivisView::SetRenderWindow | ( | vtkRenderWindow * | window | ) |
The renderer, render window and interactor this view draws with.
All three are created with the view; setting one replaces it, and the others are rewired to match – the renderers move to a window given here, and an interactor style already in use survives the change. This is what an application does to draw the view into a window of its own.
| vtkRenderWindowInteractor * vtkScivisView::GetInteractor | ( | ) |
The renderer, render window and interactor this view draws with.
All three are created with the view; setting one replaces it, and the others are rewired to match – the renderers move to a window given here, and an interactor style already in use survives the change. This is what an application does to draw the view into a window of its own.
| void vtkScivisView::SetInteractor | ( | vtkRenderWindowInteractor * | interactor | ) |
The renderer, render window and interactor this view draws with.
All three are created with the view; setting one replaces it, and the others are rewired to match – the renderers move to a window given here, and an interactor style already in use survives the change. This is what an application does to draw the view into a window of its own.
| void vtkScivisView::SetBackground | ( | double | r, |
| double | g, | ||
| double | b ) |
Set/Get the background color of the renderer.
SetBackground sets the bottom color of the gradient, SetBackground2 the top color.
| double * vtkScivisView::GetBackground | ( | ) |
Set/Get the background color of the renderer.
SetBackground sets the bottom color of the gradient, SetBackground2 the top color.
| void vtkScivisView::SetBackground2 | ( | double | r, |
| double | g, | ||
| double | b ) |
Set/Get the background color of the renderer.
SetBackground sets the bottom color of the gradient, SetBackground2 the top color.
| double * vtkScivisView::GetBackground2 | ( | ) |
Set/Get the background color of the renderer.
SetBackground sets the bottom color of the gradient, SetBackground2 the top color.
| void vtkScivisView::SetGradientBackground | ( | bool | val | ) |
Set/Get the background color of the renderer.
SetBackground sets the bottom color of the gradient, SetBackground2 the top color.
| bool vtkScivisView::GetGradientBackground | ( | ) |
Set/Get the background color of the renderer.
SetBackground sets the bottom color of the gradient, SetBackground2 the top color.
| void vtkScivisView::SetWindowSize | ( | int | w, |
| int | h ) |
Set/Get the render window size and title.
| int * vtkScivisView::GetWindowSize | ( | ) |
Set/Get the render window size and title.
| void vtkScivisView::SetWindowTitle | ( | const char * | title | ) |
Set/Get the render window size and title.
| const char * vtkScivisView::GetWindowTitle | ( | ) |
Set/Get the render window size and title.
| void vtkScivisView::SetOrientationAxesVisibility | ( | bool | val | ) |
Show or hide the orientation axes marker in the lower-left corner of the render window.
The marker shows the current camera orientation as an interactive XYZ axes triad. Default is on.
| bool vtkScivisView::GetOrientationAxesVisibility | ( | ) |
Show or hide the orientation axes marker in the lower-left corner of the render window.
The marker shows the current camera orientation as an interactive XYZ axes triad. Default is on.
| vtkOrientationMarkerWidget * vtkScivisView::GetOrientationMarkerWidget | ( | ) |
The orientation marker widget itself, for its viewport, its marker, and whether the user can move and resize it.
| void vtkScivisView::SetUseLightKit | ( | bool | val | ) |
Enable or disable the light kit: a five light rig – key, fill, headlight and two back lights – managed by vtkLightKit.
Default is off, which leaves the scene lit by a single headlight the view owns.
Only that headlight gives way to the kit. Lights added to the renderer, which GetRenderer() returns, keep lighting the scene whether the kit is on or off, and survive it being switched either way.
| bool vtkScivisView::GetUseLightKit | ( | ) |
Enable or disable the light kit: a five light rig – key, fill, headlight and two back lights – managed by vtkLightKit.
Default is off, which leaves the scene lit by a single headlight the view owns.
Only that headlight gives way to the kit. Lights added to the renderer, which GetRenderer() returns, keep lighting the scene whether the kit is on or off, and survive it being switched either way.
| vtkLightKit * vtkScivisView::GetLightKit | ( | ) |
The light kit itself, for its intensity, warmth, angle and ratio parameters.
Only has an effect while the light kit is enabled.
Lights of your own are not part of the kit: add them to the renderer, which GetRenderer() returns, with vtkRenderer::AddLight().
| void vtkScivisView::SetInteractionMode | ( | int | mode | ) |
Interaction mode constants.
INTERACTION_MODE_3D uses vtkInteractorStyleTrackballCamera (default). INTERACTION_MODE_SELECTION uses vtkInteractorStyleRubberBand3D for rubber-band selection. Mode switching is programmatic; applications typically expose it through a toolbar or keyboard shortcut. INTERACTION_MODE_CUSTOM reports that a style supplied through SetInteractorStyle() is installed; it cannot be selected directly.
The view owns one instance of each built-in style and switches between them, so any configuration applied to a style survives a mode change.
| int vtkScivisView::GetInteractionMode | ( | ) |
Interaction mode constants.
INTERACTION_MODE_3D uses vtkInteractorStyleTrackballCamera (default). INTERACTION_MODE_SELECTION uses vtkInteractorStyleRubberBand3D for rubber-band selection. Mode switching is programmatic; applications typically expose it through a toolbar or keyboard shortcut. INTERACTION_MODE_CUSTOM reports that a style supplied through SetInteractorStyle() is installed; it cannot be selected directly.
The view owns one instance of each built-in style and switches between them, so any configuration applied to a style survives a mode change.
|
inline |
Interaction mode constants.
INTERACTION_MODE_3D uses vtkInteractorStyleTrackballCamera (default). INTERACTION_MODE_SELECTION uses vtkInteractorStyleRubberBand3D for rubber-band selection. Mode switching is programmatic; applications typically expose it through a toolbar or keyboard shortcut. INTERACTION_MODE_CUSTOM reports that a style supplied through SetInteractorStyle() is installed; it cannot be selected directly.
The view owns one instance of each built-in style and switches between them, so any configuration applied to a style survives a mode change.
Definition at line 224 of file vtkScivisView.h.
|
inline |
Interaction mode constants.
INTERACTION_MODE_3D uses vtkInteractorStyleTrackballCamera (default). INTERACTION_MODE_SELECTION uses vtkInteractorStyleRubberBand3D for rubber-band selection. Mode switching is programmatic; applications typically expose it through a toolbar or keyboard shortcut. INTERACTION_MODE_CUSTOM reports that a style supplied through SetInteractorStyle() is installed; it cannot be selected directly.
The view owns one instance of each built-in style and switches between them, so any configuration applied to a style survives a mode change.
Definition at line 225 of file vtkScivisView.h.
| void vtkScivisView::SetInteractorStyle | ( | vtkInteractorObserver * | style | ) |
Install an interactor style of your own, for interaction the built-in modes do not cover – a 2D or terrain camera, or a vtkInteractorStyleManipulator configured with your own button bindings.
The view holds a reference to the style and reports INTERACTION_MODE_CUSTOM until a built-in mode is selected again, at which point the custom style is remembered and can be restored by setting it once more. Passing nullptr returns to INTERACTION_MODE_3D.
To drive selection from a custom style, call SelectRegion() from its event handling. The view does not interpret events from a style it does not know.
GetInteractorStyle() returns the style currently installed on the interactor, built-in or custom.
| vtkInteractorObserver * vtkScivisView::GetInteractorStyle | ( | ) |
Install an interactor style of your own, for interaction the built-in modes do not cover – a 2D or terrain camera, or a vtkInteractorStyleManipulator configured with your own button bindings.
The view holds a reference to the style and reports INTERACTION_MODE_CUSTOM until a built-in mode is selected again, at which point the custom style is remembered and can be restored by setting it once more. Passing nullptr returns to INTERACTION_MODE_3D.
To drive selection from a custom style, call SelectRegion() from its event handling. The view does not interpret events from a style it does not know.
GetInteractorStyle() returns the style currently installed on the interactor, built-in or custom.
| vtkScivisSelector * vtkScivisView::GetSelector | ( | ) |
Selection: how a screen region becomes a selection, whether points or cells come back, and what was picked last.
The view keeps only the interaction side of selection – which interactor style is installed, and so whether a drag draws a rubber band at all. What a rubber band then does is the selector's, and application code drives it the same way:
| void vtkScivisView::Start | ( | ) |
|
virtual |
Bring every representation up to date and draw.
The camera is framed on the scene the first time, and left alone after that.
|
virtual |
Frame the camera on everything the representations are drawing.
|
virtual |
Bring every representation up to date without drawing.
|
protectedvirtual |
Called before every render, once the representations are up to date.
|
protected |
The observer this view listens through.
Representations are given it when they are added, and anything else the view wants to hear from can be too.
|
protectedvirtual |
Called for every event the view is observing.
|
inlineprotectedvirtual |
Hooks for subclasses, called after a representation has been accepted or before one is dropped.
Definition at line 310 of file vtkScivisView.h.
|
inlineprotectedvirtual |
Hooks for subclasses, called after a representation has been accepted or before one is dropped.
Definition at line 311 of file vtkScivisView.h.
|
friend |
Definition at line 322 of file vtkScivisView.h.
|
protected |
Definition at line 314 of file vtkScivisView.h.
|
protected |
Definition at line 315 of file vtkScivisView.h.