Open Inventor Reference
|
Transformation node that undoes non-uniform 3D scales. More...
#include <Inventor/nodes/SoAntiSquish.h>
Public Types | |
enum | Sizing { X, Y, Z, AVERAGE_DIMENSION, BIGGEST_DIMENSION, SMALLEST_DIMENSION, LONGEST_DIAGONAL } |
Public Member Functions | |
SoAntiSquish () | |
Creates an anti-squish node with default settings. | |
void | recalc () |
Sets a flag so that the next time the node is traversed, it will recalculate its unsquishing matrix. | |
void | doAction (SoAction *action) |
Called by actions that need to change the state with a new matrix. | |
Static Public Member Functions | |
static void | initClass () |
Initializes base node class. | |
Public Attributes | |
Fields | |
SoSFEnum | sizing |
Determines which of the algorithms enumerated by the type Sizing will be used to select the new scale when the x,y, and z scales are not equal. | |
SoSFBool | recalcAlways |
If recalcAlways is TRUE , this node calculates its unsquishing matrix every time it is traversed. | |
Protected Member Functions | |
virtual void | callback (SoCallbackAction *action) |
virtual void | GLRender (SoGLRenderAction *action) |
These virtual functions implement all of the actions for nodes, Most of the default implementations do nothing. | |
virtual void | getBoundingBox (SoGetBoundingBoxAction *action) |
virtual void | getMatrix (SoGetMatrixAction *action) |
virtual void | pick (SoPickAction *action) |
virtual | ~SoAntiSquish () |
SbMatrix | getUnsquishingMatrix (SbMatrix squishedMatrix, SbBool doInverse, SbMatrix &inverseAnswer) |
This node removes nonuniform 3D scaling from the current transformation matrix when traversed by an action. It is used by draggers such as the SoTrackballDragger that need to stay uniformly scaled no matter where they are located in the scene graph.
The magnitude of the new scale is determined by the current transformation matrix and the sizing
field. This node does not change the translation or rotation in the matrix.
AntiSquish { sizing AVERAGE_DIMENSION recalcAlways TRUE }
Definition at line 100 of file SoAntiSquish.h.
enum SoAntiSquish::Sizing |
Definition at line 109 of file SoAntiSquish.h.
SoAntiSquish::SoAntiSquish | ( | ) |
virtual SoAntiSquish::~SoAntiSquish | ( | ) | [protected, virtual] |
virtual void SoAntiSquish::callback | ( | SoCallbackAction * | action | ) | [protected, virtual] |
Reimplemented from SoNode.
virtual void SoAntiSquish::getBoundingBox | ( | SoGetBoundingBoxAction * | action | ) | [protected, virtual] |
Reimplemented from SoNode.
virtual void SoAntiSquish::getMatrix | ( | SoGetMatrixAction * | action | ) | [protected, virtual] |
Reimplemented from SoNode.
SbMatrix SoAntiSquish::getUnsquishingMatrix | ( | SbMatrix | squishedMatrix, |
SbBool | doInverse, | ||
SbMatrix & | inverseAnswer | ||
) | [protected] |
virtual void SoAntiSquish::GLRender | ( | SoGLRenderAction * | action | ) | [protected, virtual] |
Reimplemented from SoNode.
static void SoAntiSquish::initClass | ( | ) | [static] |
Reimplemented from SoTransformation.
virtual void SoAntiSquish::pick | ( | SoPickAction * | action | ) | [protected, virtual] |
Reimplemented from SoNode.
void SoAntiSquish::recalc | ( | ) |
If FALSE
, then this only occurs during the first traversal folllowing a call to recalc().
Definition at line 130 of file SoAntiSquish.h.
Definition at line 125 of file SoAntiSquish.h.