|
virtual vtkTypeBool | IsA (const char *type) |
| Return 1 if this class is the same type of (or a subclass of) the named class.
|
|
vtkOrientationMarkerWidget * | NewInstance () const |
|
void | PrintSelf (ostream &os, vtkIndent indent) override |
| Methods invoked by print to print information about the object including superclasses.
|
|
void | SetEnabled (int) override |
| Enable/disable the widget.
|
|
void | ExecuteCameraUpdateEvent (vtkObject *o, unsigned long event, void *calldata) |
| Callback to keep the camera for the orientation marker up to date with the camera in the parent renderer.
|
|
void | EndInteraction () override |
| Ends any in progress interaction and resets border visibility.
|
|
void | SetShouldConstrainSize (const vtkTypeBool shouldConstrainSize) |
| Set/get whether the widget should constrain the size to be within the min and max limits.
|
|
virtual vtkTypeBool | GetShouldConstrainSize () |
|
bool | SetSizeConstraintDimensionSizes (const int minDimensionSize, const int maxDimensionSize) |
| Sets the minimum and maximum dimension (width and height) size limits for the widget.
|
|
virtual int | GetMinDimensionSize () |
| Returns the minimum dimension (width and height) size limit in pixels for the widget.
|
|
virtual int | GetMaxDimensionSize () |
| Returns the maximum dimension (width and height) size limit in pixels for the widget.
|
|
|
virtual void | SetOrientationMarker (vtkProp *prop) |
| Set/get the orientation marker to be displayed in this widget.
|
|
virtual vtkProp * | GetOrientationMarker () |
| Set/get the orientation marker to be displayed in this widget.
|
|
|
void | SetInteractive (vtkTypeBool interact) |
| Set/get whether to allow this widget to be interactively moved/scaled.
|
|
virtual vtkTypeBool | GetInteractive () |
| Set/get whether to allow this widget to be interactively moved/scaled.
|
|
virtual void | InteractiveOn () |
| Set/get whether to allow this widget to be interactively moved/scaled.
|
|
virtual void | InteractiveOff () |
| Set/get whether to allow this widget to be interactively moved/scaled.
|
|
|
void | SetOutlineColor (double r, double g, double b) |
| Set/get the color of the outline of this widget.
|
|
double * | GetOutlineColor () |
| Set/get the color of the outline of this widget.
|
|
|
virtual void | SetViewport (double, double, double, double) |
| Set/get the viewport to position/size this widget.
|
|
virtual void | SetViewport (double[4]) |
| Set/get the viewport to position/size this widget.
|
|
virtual double * | GetViewport () |
| Set/get the viewport to position/size this widget.
|
|
virtual void | GetViewport (double &, double &, double &, double &) |
| Set/get the viewport to position/size this widget.
|
|
virtual void | GetViewport (double[4]) |
| Set/get the viewport to position/size this widget.
|
|
|
virtual void | SetTolerance (int) |
| The tolerance representing the distance to the widget (in pixels) in which the cursor is considered to be on the widget, or on a widget feature (e.g., a corner point or edge).
|
|
virtual int | GetTolerance () |
| The tolerance representing the distance to the widget (in pixels) in which the cursor is considered to be on the widget, or on a widget feature (e.g., a corner point or edge).
|
|
|
virtual void | SetZoom (double) |
| The zoom factor to modify the size of the marker within the widget.
|
|
virtual double | GetZoom () |
| The zoom factor to modify the size of the marker within the widget.
|
|
void | Modified () override |
| Need to reimplement this->Modified() because of the vtkSetVector4Macro/vtkGetVector4Macro use.
|
|
virtual vtkTypeBool | IsA (const char *type) |
| Return 1 if this class is the same type of (or a subclass of) the named class.
|
|
vtkInteractorObserver * | NewInstance () const |
|
void | PrintSelf (ostream &os, vtkIndent indent) override |
| Methods invoked by print to print information about the object including superclasses.
|
|
virtual void | SetEnabled (int) |
| Methods for turning the interactor observer on and off, and determining its state.
|
|
int | GetEnabled () |
|
void | EnabledOn () |
|
void | EnabledOff () |
|
void | On () |
|
void | Off () |
|
virtual void | OnChar () |
| Sets up the keypress-i event.
|
|
virtual void | SetInteractor (vtkRenderWindowInteractor *iren) |
| This method is used to associate the widget with the render window interactor.
|
|
virtual vtkRenderWindowInteractor * | GetInteractor () |
| This method is used to associate the widget with the render window interactor.
|
|
virtual void | SetPriority (float) |
| Set/Get the priority at which events are processed.
|
|
virtual float | GetPriority () |
| Set/Get the priority at which events are processed.
|
|
virtual void | PickingManagedOn () |
| Enable/Disable the use of a manager to process the picking.
|
|
virtual void | PickingManagedOff () |
| Enable/Disable the use of a manager to process the picking.
|
|
virtual void | SetPickingManaged (bool managed) |
| Enable/Disable the use of a manager to process the picking.
|
|
virtual bool | GetPickingManaged () |
| Enable/Disable the use of a manager to process the picking.
|
|
virtual void | SetKeyPressActivation (vtkTypeBool) |
| Enable/Disable of the use of a keypress to turn on and off the interactor observer.
|
|
virtual vtkTypeBool | GetKeyPressActivation () |
| Enable/Disable of the use of a keypress to turn on and off the interactor observer.
|
|
virtual void | KeyPressActivationOn () |
| Enable/Disable of the use of a keypress to turn on and off the interactor observer.
|
|
virtual void | KeyPressActivationOff () |
| Enable/Disable of the use of a keypress to turn on and off the interactor observer.
|
|
virtual void | SetKeyPressActivationValue (char) |
| Specify which key press value to use to activate the interactor observer (if key press activation is enabled).
|
|
virtual char | GetKeyPressActivationValue () |
| Specify which key press value to use to activate the interactor observer (if key press activation is enabled).
|
|
virtual vtkRenderer * | GetDefaultRenderer () |
| Set/Get the default renderer to use when activating the interactor observer.
|
|
virtual void | SetDefaultRenderer (vtkRenderer *) |
| Set/Get the default renderer to use when activating the interactor observer.
|
|
virtual vtkRenderer * | GetCurrentRenderer () |
| Set/Get the current renderer.
|
|
virtual void | SetCurrentRenderer (vtkRenderer *) |
| Set/Get the current renderer.
|
|
void | GrabFocus (vtkCommand *mouseEvents, vtkCommand *keypressEvents=nullptr) |
| These methods enable an interactor observer to exclusively grab all events invoked by its associated vtkRenderWindowInteractor.
|
|
void | ReleaseFocus () |
| These methods enable an interactor observer to exclusively grab all events invoked by its associated vtkRenderWindowInteractor.
|
|
| 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.
|
|
virtual vtkMTimeType | GetMTime () |
| Return this object's modified time.
|
|
void | PrintSelf (ostream &os, vtkIndent indent) override |
| Methods invoked by print to print information about the object including superclasses.
|
|
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) |
|
int | InvokeEvent (unsigned long event) |
|
int | InvokeEvent (const char *event) |
|
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.
|
|
int | InvokeEvent (unsigned long event, void *callData) |
| This method invokes an event and return whether the event was aborted or not.
|
|
int | InvokeEvent (const char *event, void *callData) |
| This method invokes an event and return whether the event was aborted or not.
|
|
const char * | GetClassName () const |
| Return the class name as a string.
|
|
virtual vtkTypeBool | IsA (const char *name) |
| Return 1 if this class is the same type of (or a subclass of) the named class.
|
|
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.
|
|
virtual 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.
|
|
|
static vtkOrientationMarkerWidget * | New () |
|
static vtkTypeBool | IsTypeOf (const char *type) |
|
static vtkOrientationMarkerWidget * | SafeDownCast (vtkObjectBase *o) |
|
static vtkTypeBool | IsTypeOf (const char *type) |
|
static vtkInteractorObserver * | SafeDownCast (vtkObjectBase *o) |
|
static void | ComputeDisplayToWorld (vtkRenderer *ren, double x, double y, double z, double worldPt[4]) |
| Convenience methods for outside classes.
|
|
static void | ComputeWorldToDisplay (vtkRenderer *ren, double x, double y, double z, double displayPt[3]) |
| Convenience methods for outside classes.
|
|
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 (int 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 int | GetGlobalWarningDisplay () |
| This is a global flag that controls whether any debug, warning or error messages are displayed.
|
|
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.
|
|
2D widget for manipulating a marker prop
This class provides support for interactively manipulating the position, size, and apparent orientation of a prop that represents an orientation marker. This class works by adding its internal renderer to an external "parent" renderer on a different layer. The input orientation marker is rendered as an overlay on the parent renderer and, thus, appears superposed over all props in the parent's scene. The camera view of the orientation the marker is made to match that of the parent's by means of an observer mechanism, giving the illusion that the orientation of the marker reflects that of the prop(s) in the parent's scene.
The widget listens to left mouse button and mouse movement events. It will change the cursor shape based on its location. If the cursor is over the overlay renderer, it will change the cursor shape to a SIZEALL shape or to a resize corner shape (e.g., SIZENW) if the cursor is near a corner. If the left mouse button is pressed and held down while moving, the overlay renderer, and hence, the orientation marker, is resized or moved. I the case of a resize operation, releasing the left mouse button causes the widget to enforce its renderer to be square. The diagonally opposite corner to the one moved is repositioned such that all edges of the renderer have the same length: the minimum.
To use this object, there are two key steps: 1) invoke SetInteractor() with the argument of the method a vtkRenderWindowInteractor, and 2) invoke SetOrientationMarker with an instance of vtkProp (see caveats below). Specifically, vtkAxesActor and vtkAnnotatedCubeActor are two classes designed to work with this class. A composite orientation marker can be generated by adding instances of vtkAxesActor and vtkAnnotatedCubeActor to a vtkPropAssembly, which can then be set as the input orientation marker. The widget can be also be set up in a non-interactive fashion by setting Ineractive to Off and sizing/placing the overlay renderer in its parent renderer by calling the widget's SetViewport method.
- Thanks:
- This class was based originally on Paraview's vtkPVAxesWidget.
- Warning
- The input orientation marker prop should calculate its bounds as though they are symmetric about it's origin. This must currently be done to correctly implement the camera synchronization between the ivar renderer and the renderer associated with the set interactor. Importantly, the InteractorStyle associated with the interactor must be of the type vtkInteractorStyle*Camera. Where desirable, the parent renderer should be set by the SetDefaultRenderer method. The parent renderer's number of layers is modified to 2 where required.
- See also
- vtkInteractorObserver vtkXYPlotWidget vtkScalarBarWidget vtkAxesActor vtkAnnotatedCubeActor
- Events:
- vtkCommand::DisableEvent vtkCommand::EnableEvent vtkCommand::EndInteractionEvent vtkCommand::InteractionEvent vtkCommand::StartInteractionEvent
- Online Examples:
- Tests:
- vtkOrientationMarkerWidget (Tests)
Definition at line 196 of file vtkOrientationMarkerWidget.h.