void setVoxelPosition(const SbVec3f &pos)
void setDevicePosition(const SbVec2f &pos)
MutableView2DPosition(SoView2D *viewer)
void setViewport(const SbVec2f &origin, const SbVec2f &size)
SoCommandAction(SoInteractionOwner *owner, std::string id)
SoInteractionHandler(SoInteractionProvider *provider)
SoInteractionProvider()
Default constructor.
SoPointerPosition manages the current position of the mouse cursor.
SoView2D * getView() const
SoView2DKeyboardAction(SoView2D *view, const std::string &id, SoKeyboardEvent::Key key, SoKeyboardEvent::Key key2)
void execute() override
Executes the action. Must be overridden by user.
SoView2DKeyboardAction(SoView2D *view, const std::string &id, SoKeyboardEvent::Key key, bool withShift=false)
SoView2D is a 2D viewer for image data.
bool _dragging
While dragging convert positions relative to the start slice.
MutableView2DPosition _view2DPosition
bool isValidStartingLocation(const SoPointerPosition &location) override
bool isEnabled(SoPointingAction *action, int currentMask) override
Only enable actions if the image in the SoView2D is valid.
View2DInteractionHandler(SoView2D *viewer, SoInteractionProvider *provider)
SoView2D * _viewer
Back-reference to the SoView2D object.
bool augmentLocation(SoPointerPosition &position, bool dragging) override
Set SoView2D information in position.
const SoNodeList * getExtensionList(SoState *state)
SoView2D * _viewer
Back-reference to the SoView2D object.
void pointerLeftWindow(SoState *state) override
Forwarding to the SoView2DExtensions.
std::list< SoInteraction * > getInteractions(SoState *state) override
return interactions from SoView2DExtensions
bool isExtensionEnabled(SoView2DExtension *ext) const
return true if interactions from the given SoView2DExtension should be handled
void pointerPosition(SoState *state, const SoPointerPosition &pos) override
Forwarding to the SoView2DExtensions.
View2DInteractionProvider(SoView2D *viewer)
View2DPosition(SoView2D *viewer=nullptr)
Constructor and destructor.