Coordinate System Dragger. More...
#include <SoFCCSysDragger.h>
Public Member Functions | |
void | clearIncrementCounts () |
used to reset after drag update. More... | |
void | setUpAutoScale (SoCamera *cameraIn) |
used to setup the auto scaling of dragger. More... | |
SoFCCSysDragger () | |
~SoFCCSysDragger () | |
Static Public Member Functions | |
static void | initClass () |
Public Attributes | |
SoSFFloat | autoScaleResult |
result of autoscale calculation and used by childdraggers. Don't use. More... | |
SoSFFloat | draggerSize |
Overall scale of dragger node. More... | |
SoIdleSensor | idleSensor |
might be overkill, but want to make sure of performance. More... | |
SoSFRotation | rotation |
initial rotation and reflects single precision movement. More... | |
SoSFDouble | rotationIncrement |
radians set from outside and used for rounding. More... | |
SoSFInt32 | rotationIncrementCountX |
used from outside for rotation x steps. More... | |
SoSFInt32 | rotationIncrementCountY |
used from outside for rotation y steps. More... | |
SoSFInt32 | rotationIncrementCountZ |
used from outside for rotation z steps. More... | |
SoSFVec3f | translation |
initial translation and reflects single precision movement. More... | |
SoSFDouble | translationIncrement |
set from outside used for rounding. More... | |
SoSFInt32 | translationIncrementCountX |
used from outside for translation x steps. More... | |
SoSFInt32 | translationIncrementCountY |
used from outside for translation y steps. More... | |
SoSFInt32 | translationIncrementCountZ |
used from outside for translation z steps. More... | |
Visibility Functions | |
SoFieldSensor | translationSensor |
SoFieldSensor | rotationSensor |
SoFieldSensor | cameraSensor |
void | showTranslationX () |
show the x translation dragger. More... | |
void | showTranslationY () |
show the y translation dragger. More... | |
void | showTranslationZ () |
show the z translation dragger. More... | |
void | hideTranslationX () |
hide the x translation dragger. More... | |
void | hideTranslationY () |
hide the y translation dragger. More... | |
void | hideTranslationZ () |
hide the z translation dragger. More... | |
void | showRotationX () |
show the x rotation dragger. More... | |
void | showRotationY () |
show the y rotation dragger. More... | |
void | showRotationZ () |
show the z rotation dragger. More... | |
void | hideRotationX () |
hide the x rotation dragger. More... | |
void | hideRotationY () |
hide the y rotation dragger. More... | |
void | hideRotationZ () |
hide the z rotation dragger. More... | |
bool | isShownTranslationX () |
is x translation dragger shown. More... | |
bool | isShownTranslationY () |
is y translation dragger shown. More... | |
bool | isShownTranslationZ () |
is z translation dragger shown. More... | |
bool | isShownRotationX () |
is x rotation dragger shown. More... | |
bool | isShownRotationY () |
is x rotation dragger shown. More... | |
bool | isShownRotationZ () |
is x rotation dragger shown. More... | |
bool | isHiddenTranslationX () |
is x translation dragger hidden. More... | |
bool | isHiddenTranslationY () |
is y translation dragger hidden. More... | |
bool | isHiddenTranslationZ () |
is z translation dragger hidden. More... | |
bool | isHiddenRotationX () |
is x rotation dragger hidden. More... | |
bool | isHiddenRotationY () |
is x rotation dragger hidden. More... | |
bool | isHiddenRotationZ () |
is x rotation dragger hidden. More... | |
virtual void | GLRender (SoGLRenderAction *action) override |
virtual SbBool | setUpConnections (SbBool onoff, SbBool doitalways=FALSE) override |
virtual void | handleEvent (SoHandleEventAction *action) override |
static void | translationSensorCB (void *f, SoSensor *) |
static void | rotationSensorCB (void *f, SoSensor *) |
static void | valueChangedCB (void *, SoDragger *d) |
static void | cameraCB (void *data, SoSensor *) |
static void | idleCB (void *data, SoSensor *) |
scheduled from cameraCB to auto scale dragger. More... | |
static void | finishDragCB (void *data, SoDragger *) |
Coordinate System Dragger.
used to transform objects in 3d space. Set initial: translation, rotation, translationIncrement and rotationIncrement. Use IncrementCount multiplied with *Increment for full double precision output.
Dragger can be displayed in 2 modes: static scale and auto scale. For static you can set the field scale and you are done. For autoscale you set the field scale & call setupAutoScale with the viewer camera.
SoFCCSysDragger::SoFCCSysDragger | ( | ) |
References Gui::TDragger::autoScaleResult, autoScaleResult, cameraCB(), cameraSensor, draggerSize, finishDragCB(), idleCB(), idleSensor, rotation, Gui::RDragger::rotationIncrement, rotationIncrement, Gui::RDragger::rotationIncrementCount, rotationIncrementCountX, rotationIncrementCountY, rotationIncrementCountZ, rotationSensor, rotationSensorCB(), setUpConnections(), translation, Gui::TDragger::translationIncrement, translationIncrement, Gui::TDragger::translationIncrementCount, translationIncrementCountX, translationIncrementCountY, translationIncrementCountZ, translationSensor, translationSensorCB(), and valueChangedCB().
SoFCCSysDragger::~SoFCCSysDragger | ( | ) |
|
staticprotected |
References idleSensor.
Referenced by finishDragCB(), setUpAutoScale(), and SoFCCSysDragger().
void SoFCCSysDragger::clearIncrementCounts | ( | ) |
used to reset after drag update.
References rotationIncrementCountX, rotationIncrementCountY, rotationIncrementCountZ, translationIncrementCountX, translationIncrementCountY, and translationIncrementCountZ.
|
staticprotected |
References cameraCB(), and cameraSensor.
Referenced by SoFCCSysDragger().
|
overridevirtual |
|
overrideprotectedvirtual |
void SoFCCSysDragger::hideRotationX | ( | ) |
hide the x rotation dragger.
void SoFCCSysDragger::hideRotationY | ( | ) |
hide the y rotation dragger.
void SoFCCSysDragger::hideRotationZ | ( | ) |
hide the z rotation dragger.
void SoFCCSysDragger::hideTranslationX | ( | ) |
hide the x translation dragger.
void SoFCCSysDragger::hideTranslationY | ( | ) |
hide the y translation dragger.
void SoFCCSysDragger::hideTranslationZ | ( | ) |
hide the z translation dragger.
|
staticprotected |
scheduled from cameraCB to auto scale dragger.
References autoScaleResult, cameraSensor, and draggerSize.
Referenced by SoFCCSysDragger().
|
static |
References Gui::TDragger::initClass(), and Gui::RDragger::initClass().
Referenced by Gui::SoFCDB::init().
bool SoFCCSysDragger::isHiddenRotationX | ( | ) |
is x rotation dragger hidden.
bool SoFCCSysDragger::isHiddenRotationY | ( | ) |
is x rotation dragger hidden.
bool SoFCCSysDragger::isHiddenRotationZ | ( | ) |
is x rotation dragger hidden.
bool SoFCCSysDragger::isHiddenTranslationX | ( | ) |
is x translation dragger hidden.
bool SoFCCSysDragger::isHiddenTranslationY | ( | ) |
is y translation dragger hidden.
bool SoFCCSysDragger::isHiddenTranslationZ | ( | ) |
is z translation dragger hidden.
bool SoFCCSysDragger::isShownRotationX | ( | ) |
is x rotation dragger shown.
bool SoFCCSysDragger::isShownRotationY | ( | ) |
is x rotation dragger shown.
bool SoFCCSysDragger::isShownRotationZ | ( | ) |
is x rotation dragger shown.
bool SoFCCSysDragger::isShownTranslationX | ( | ) |
is x translation dragger shown.
bool SoFCCSysDragger::isShownTranslationY | ( | ) |
is y translation dragger shown.
bool SoFCCSysDragger::isShownTranslationZ | ( | ) |
is z translation dragger shown.
|
staticprotected |
Referenced by setUpConnections(), and SoFCCSysDragger().
void SoFCCSysDragger::setUpAutoScale | ( | SoCamera * | cameraIn | ) |
used to setup the auto scaling of dragger.
References autoScaleResult, cameraCB(), cameraSensor, and draggerSize.
Referenced by Gui::ViewProviderDragger::setEditViewer(), and Gui::ViewProviderLink::setEditViewer().
|
overrideprotectedvirtual |
References rotation, rotationSensor, rotationSensorCB(), translation, translationSensor, and translationSensorCB().
Referenced by SoFCCSysDragger().
void SoFCCSysDragger::showRotationX | ( | ) |
show the x rotation dragger.
void SoFCCSysDragger::showRotationY | ( | ) |
show the y rotation dragger.
void SoFCCSysDragger::showRotationZ | ( | ) |
show the z rotation dragger.
void SoFCCSysDragger::showTranslationX | ( | ) |
show the x translation dragger.
void SoFCCSysDragger::showTranslationY | ( | ) |
show the y translation dragger.
void SoFCCSysDragger::showTranslationZ | ( | ) |
show the z translation dragger.
|
staticprotected |
Referenced by setUpConnections(), and SoFCCSysDragger().
|
staticprotected |
References rotation, rotationSensor, translation, and translationSensor.
Referenced by SoFCCSysDragger().
SoSFFloat Gui::SoFCCSysDragger::autoScaleResult |
result of autoscale calculation and used by childdraggers. Don't use.
Referenced by idleCB(), setUpAutoScale(), and SoFCCSysDragger().
|
protected |
Referenced by finishDragCB(), idleCB(), setUpAutoScale(), and SoFCCSysDragger().
SoSFFloat Gui::SoFCCSysDragger::draggerSize |
Overall scale of dragger node.
When using autoscale mode, this represents normalized device coordinates (0.0 to 1.0). A value of 0.05 is a good place to start. When NOT using autoscale mode, scale represents a traditional scale and a value of 1.0 is a good place to start.
Referenced by idleCB(), Gui::ViewProviderDragger::setEdit(), Gui::ViewProviderLink::setEditViewer(), setUpAutoScale(), and SoFCCSysDragger().
SoIdleSensor Gui::SoFCCSysDragger::idleSensor |
might be overkill, but want to make sure of performance.
Referenced by cameraCB(), and SoFCCSysDragger().
SoSFRotation Gui::SoFCCSysDragger::rotation |
initial rotation and reflects single precision movement.
Referenced by femtaskpanels.task_element_rotation1D._TaskPanel::accept(), Gui::ViewProviderLink::currentDraggingPlacement(), femtaskpanels.task_element_rotation1D._TaskPanel::rotation_changed(), Gui::ViewProviderDragger::setEdit(), setUpConnections(), SoFCCSysDragger(), Gui::ViewProviderDragger::unsetEdit(), Gui::ViewProviderLink::updateDraggingPlacement(), and valueChangedCB().
SoSFDouble Gui::SoFCCSysDragger::rotationIncrement |
radians set from outside and used for rounding.
Referenced by SoFCCSysDragger().
SoSFInt32 Gui::SoFCCSysDragger::rotationIncrementCountX |
used from outside for rotation x steps.
Referenced by clearIncrementCounts(), and SoFCCSysDragger().
SoSFInt32 Gui::SoFCCSysDragger::rotationIncrementCountY |
used from outside for rotation y steps.
Referenced by clearIncrementCounts(), and SoFCCSysDragger().
SoSFInt32 Gui::SoFCCSysDragger::rotationIncrementCountZ |
used from outside for rotation z steps.
Referenced by clearIncrementCounts(), and SoFCCSysDragger().
|
protected |
Referenced by setUpConnections(), SoFCCSysDragger(), and valueChangedCB().
SoSFVec3f Gui::SoFCCSysDragger::translation |
initial translation and reflects single precision movement.
Referenced by Gui::ViewProviderLink::currentDraggingPlacement(), Gui::ViewProviderDragger::setEdit(), setUpConnections(), SoFCCSysDragger(), Gui::ViewProviderDragger::unsetEdit(), Gui::ViewProviderLink::updateDraggingPlacement(), and valueChangedCB().
SoSFDouble Gui::SoFCCSysDragger::translationIncrement |
set from outside used for rounding.
Referenced by SoFCCSysDragger().
SoSFInt32 Gui::SoFCCSysDragger::translationIncrementCountX |
used from outside for translation x steps.
Referenced by clearIncrementCounts(), and SoFCCSysDragger().
SoSFInt32 Gui::SoFCCSysDragger::translationIncrementCountY |
used from outside for translation y steps.
Referenced by clearIncrementCounts(), and SoFCCSysDragger().
SoSFInt32 Gui::SoFCCSysDragger::translationIncrementCountZ |
used from outside for translation z steps.
Referenced by clearIncrementCounts(), and SoFCCSysDragger().
|
protected |
Referenced by setUpConnections(), SoFCCSysDragger(), and valueChangedCB().