SoScale2Dragger(3)
πΈ NAME πΈ
okay so bestie, welcome to SoScale2Dragger(3) β that's section 3 of the Library Functions Manual, and this page is entirely about the SoScale2Dragger class. What's her whole deal? She hands the end-user a mechanism to scale in two dimensions. Two. Not three. Two, and she ate. π
β¨
π SYNOPSIS π
first thing's first, you gotta pull her in:
#include <Inventor/draggers/SoScale2Dragger.h>
and she Inherits SoDragger β so like, everything her parent has, she's got too. family money, no cap. π«Ά
β¨ Public Member Functions β¨
her own three, the ones that are literally hers:
virtual SoType getTypeId (void) constβ grab her runtime type id, bestie.virtual const SoNodekitCatalog * getNodekitCatalog (void) constβ and this one hands you the nodekit catalog.SoScale2Dragger (void)β the constructor. make her exist. π¦
π Public Member Functions inherited from SoDragger π
all of these come down through the family line, so you don't gotta redefine them β they're just there, like your fave hand-me-down jacket:
virtual void callback (SoCallbackAction *action)
virtual void GLRender (SoGLRenderAction *action)
virtual void getMatrix (SoGetMatrixAction *action)
virtual void rayPick (SoRayPickAction *action)
virtual void search (SoSearchAction *action)
virtual void write (SoWriteAction *action)
virtual void getPrimitiveCount (SoGetPrimitiveCountAction *action)
void addStartCallback (SoDraggerCB *func, void *data=NULL)
void removeStartCallback (SoDraggerCB *func, void *data=NULL)
void addMotionCallback (SoDraggerCB *func, void *data=NULL)
void removeMotionCallback (SoDraggerCB *func, void *data=NULL)
void addFinishCallback (SoDraggerCB *func, void *data=NULL)
void removeFinishCallback (SoDraggerCB *func, void *data=NULL)
void addValueChangedCallback (SoDraggerCB *func, void *data=NULL)
void removeValueChangedCallback (SoDraggerCB *func, void *data=NULL)
void setMinGesture (int pixels)
int getMinGesture (void) const
SbBool enableValueChangedCallbacks (SbBool newval)
const SbMatrix & getMotionMatrix (void)
void addOtherEventCallback (SoDraggerCB *func, void *data=NULL)
void removeOtherEventCallback (SoDraggerCB *func, void *data=NULL)
void registerChildDragger (SoDragger *child)
void unregisterChildDragger (SoDragger *child)
void registerChildDraggerMovingIndependently (SoDragger *child)
void unregisterChildDraggerMovingIndependently (SoDragger *child)
SbMatrix getLocalToWorldMatrix (void)
SbMatrix getWorldToLocalMatrix (void)
SbVec3f getLocalStartingPoint (void)
SbVec3f getWorldStartingPoint (void)
void getPartToLocalMatrix (const SbName &partname, SbMatrix &parttolocalmatrix, SbMatrix &localtopartmatrix)
void transformMatrixLocalToWorld (const SbMatrix &frommatrix, SbMatrix &tomatrix)
void transformMatrixWorldToLocal (const SbMatrix &frommatrix, SbMatrix &tomatrix)
void transformMatrixToLocalSpace (const SbMatrix &frommatrix, SbMatrix &tomatrix, const SbName &fromspacepartname)
void setMotionMatrix (const SbMatrix &newmatrix)
void valueChanged (void)
const SbMatrix & getStartMotionMatrix (void)
virtual void saveStartParameters (void)
const SoPath * getPickPath (void) const
const SoEvent * getEvent (void) const
SoPath * createPathToThis (void)
const SoPath * getSurrogatePartPickedOwner (void) const
const SbName & getSurrogatePartPickedName (void) const
const SoPath * getSurrogatePartPickedPath (void) const
void setStartingPoint (const SoPickedPoint *newpoint)
void setStartingPoint (const SbVec3f &newpoint)
const SbViewVolume & getViewVolume (void)
void setViewVolume (const SbViewVolume &vol)
const SbViewportRegion & getViewportRegion (void)
void setViewportRegion (const SbViewportRegion ®)
SoHandleEventAction * getHandleEventAction (void) const
void setHandleEventAction (SoHandleEventAction *newAction)
void setTempPathToThis (const SoPath *somethingclose)
virtual void grabEventsSetup (void)
virtual void grabEventsCleanup (void)
void workFieldsIntoTransform (SbMatrix &mtx)
void setFrontOnProjector (ProjectorFrontSetting newval)
ProjectorFrontSetting getFrontOnProjector (void) const
that's a lot of callbacks and matrices and it's giving very much "rich family tree" energy. π
π§ Public Member Functions inherited from SoInteractionKit π§
next branch of the family tree, the interaction kit side:
SoInteractionKit (void)
virtual SbBool setPartAsPath (const SbName &partname, SoPath *path)
virtual SbBool setPartAsDefault (const SbName &partname, SoNode *node, SbBool onlyifdefault=1)
virtual SbBool setPartAsDefault (const SbName &partname, const SbName &nodename, SbBool onlyifdefault=1)
SbBool isPathSurrogateInMySubgraph (const SoPath *path, SoPath *&pathToOwner, SbName &surrogatename, SoPath *&surrogatepath, SbBool fillargs=1)
SbBool isPathSurrogateInMySubgraph (const SoPath *path)
virtual SbBool setPart (const SbName &partname, SoNode *from)
the way there's literally two overloads of setPartAsDefault and two of isPathSurrogateInMySubgraph? iconic. she contains multitudes. ππ
π Public Member Functions inherited from SoBaseKit π
and the base kit branch, which is where all the part-wrangling lives:
SoBaseKit (void)
virtual SoNode * getPart (const SbName &partname, SbBool makeifneeded)
SbString getPartString (const SoBase *part)
virtual SoNodeKitPath * createPathToPart (const SbName &partname, SbBool makeifneeded, const SoPath *pathtoextend=NULL)
SbBool set (const char *namevaluepairliststring)
SbBool set (const char *partnamestring, const char *parameterstring)
virtual void doAction (SoAction *action)
virtual SoChildList * getChildren (void) const
void printDiagram (void)
void printSubDiagram (const SbName &rootname, int level)
void printTable (void)
virtual void addWriteReference (SoOutput *out, SbBool isfromfield=0)
SbBool forceChildDrivenWriteRefs (SoOutput *out)
ngl printDiagram and printTable are lowkey the most main character energy here β she'll literally draw you a picture of herself. π₯
π Public Member Functions inherited from SoNode π
the node branch. every scene-graph girlie knows this one:
void setOverride (const SbBool state)
SbBool isOverride (void) const
void setNodeType (const NodeType type)
NodeType getNodeType (void) const
virtual SoNode * copy (SbBool copyconnections=0) const
virtual SbBool affectsState (void) const
virtual void GLRenderBelowPath (SoGLRenderAction *action)
virtual void GLRenderInPath (SoGLRenderAction *action)
virtual void GLRenderOffPath (SoGLRenderAction *action)
virtual void pick (SoPickAction *action)
virtual void audioRender (SoAudioRenderAction *action)
virtual void startNotify (void)
virtual void notify (SoNotList *l)
uint32_t getNodeId (void) const
virtual void writeInstance (SoOutput *out)
virtual SoFieldContainer * copyThroughConnection (void) const
three separate GLRender-flavoured methods because rendering respects context, periodt. β¨
π Public Member Functions inherited from SoFieldContainer π
field management, the whole "she keeps receipts" branch:
void setToDefaults (void)
SbBool hasDefaultValues (void) const
SbBool fieldsAreEqual (const SoFieldContainer *container) const
void copyFieldValues (const SoFieldContainer *container, SbBool copyconnections=0)
SbBool set (const char *const fielddata)
void get (SbString &fielddata)
virtual int getFields (SoFieldList &l) const
virtual int getAllFields (SoFieldList &l) const
virtual SoField * getField (const SbName &name) const
virtual SoField * getEventIn (const SbName &name) const
virtual SoField * getEventOut (const SbName &name) const
SbBool getFieldName (const SoField *const field, SbName &name) const
SbBool enableNotify (const SbBool flag)
SbBool isNotifyEnabled (void) const
SbBool set (const char *fielddata, SoInput *in)
void get (SbString &fielddata, SoOutput *out)
virtual SbBool validateNewFieldValue (SoField *field, void *newval)
SbBool getIsBuiltIn (void) const
void setUserData (void *userdata) const
void * getUserData (void) const
not the set/get overloads again π she has so many ways to take and give field data and honestly? slay.
π¦ Public Member Functions inherited from SoBase π¦
and at the very bottom, the literal base of everything, where ref counting lives:
void ref (void) const
void unref (void) const
void unrefNoDelete (void) const
int32_t getRefCount (void) const
void touch (void)
SbBool isOfType (SoType type) const
virtual SbName getName (void) const
virtual void setName (const SbName &newname)
void addAuditor (void *const auditor, const SoNotRec::Type type)
void removeAuditor (void *const auditor, const SoNotRec::Type type)
const SoAuditorList & getAuditors (void) const
SbBool shouldWrite (void)
void assertAlive (void) const
ref and unref bestieβ¦ if you know you know. iykyk. π
β Static Public Member Functions β
the static girlies on the class herself:
static SoType getClassTypeId (void)
static const SoNodekitCatalog * getClassNodekitCatalog (void)
static void initClass (void)
π
Static Public Member Functions inherited from SoDragger π
static SoType getClassTypeId (void)
static const SoNodekitCatalog * getClassNodekitCatalog (void)
static void setMinScale (float newminscale)
static float getMinScale (void)
static void workValuesIntoTransform (SbMatrix &mtx, const SbVec3f *translationptr, const SbRotation *rotationptr, const SbVec3f *scalefactorptr, const SbRotation *scaleorientationptr, const SbVec3f *centerptr)
static void getTransformFast (SbMatrix &mtx, SbVec3f &translation, SbRotation &rotation, SbVec3f &scalefactor, SbRotation &scaleorientation, const SbVec3f ¢er)
static void getTransformFast (SbMatrix &mtx, SbVec3f &translation, SbRotation &rotation, SbVec3f &scalefactor, SbRotation &scaleorientation)
static SbMatrix appendTranslation (const SbMatrix &mtx, const SbVec3f &translation, const SbMatrix *conversion=NULL)
static SbMatrix appendScale (const SbMatrix &mtx, const SbVec3f &scale, const SbVec3f &scalecenter, const SbMatrix *conversion=NULL)
static SbMatrix appendRotation (const SbMatrix &mtx, const SbRotation &rot, const SbVec3f &rotcenter, const SbMatrix *conversion=NULL)
static void initClass (void)
static void initClasses (void)
look at appendTranslation, appendScale, appendRotation β a little trio, a little girl group, we love to see it. π
π Static Public Member Functions inherited from SoInteractionKit π
static SoType getClassTypeId (void)
static const SoNodekitCatalog * getClassNodekitCatalog (void)
static void initClass (void)
static void setSwitchValue (SoNode *node, const int newVal)
π§ Static Public Member Functions inherited from SoBaseKit π§
static SoType getClassTypeId (void)
static void initClass (void)
static const SoNodekitCatalog * getClassNodekitCatalog (void)
static SbBool isSearchingChildren (void)
static void setSearchingChildren (const SbBool newval)
static SoNode * typeCheck (const SbName &partname, const SoType &parttype, SoNode *node)
π Static Public Member Functions inherited from SoNode π
the big one. strap in:
static uint32_t getCompatibilityTypes (const SoType &nodetype)
static SoType getClassTypeId (void)
static SoNode * getByName (const SbName &name)
static int getByName (const SbName &name, SoNodeList &l)
static void initClass (void)
static void initClasses (void)
static uint32_t getNextNodeId (void)
static int getActionMethodIndex (const SoType type)
static void getBoundingBoxS (SoAction *action, SoNode *node)
static void GLRenderS (SoAction *action, SoNode *node)
static void callbackS (SoAction *action, SoNode *node)
static void getMatrixS (SoAction *action, SoNode *node)
static void handleEventS (SoAction *action, SoNode *node)
static void pickS (SoAction *action, SoNode *node)
static void rayPickS (SoAction *action, SoNode *node)
static void searchS (SoAction *action, SoNode *node)
static void writeS (SoAction *action, SoNode *node)
static void audioRenderS (SoAction *action, SoNode *node)
static void getPrimitiveCountS (SoAction *action, SoNode *node)
see that S on the end of every single one? that's the static twin of the virtual method above it. every action gets a ...S version and that's just the rules, bestie. β
heads up: there's more of this page coming β do not close the tab, we are so not done. π
β¨ Static Public Member Functions inherited from SoFieldContainer β¨
Okay bestie, these are the inherited static public functions from SoFieldContainer, and they're giving utility realness. π
static void initClass (void)β the classic init, no cap.static SoType getClassTypeId (void)β gets the class type id, periodt.static void initCopyDict (void)β sets up the copy dict, fr fr.static void addCopy (const SoFieldContainer *orig, const SoFieldContainer *copy)β adds a copy pair, slay.static SoFieldContainer * checkCopy (const SoFieldContainer *orig)β checks a copy, iconic.static SoFieldContainer * findCopy (const SoFieldContainer *orig, const SbBool copyconnections)β finds a copy, main character energy.static void copyDone (void)β copying is done, bye.
πΈ Static Public Member Functions inherited from SoBase πΈ
More inherited static public functions, this time from SoBase. We love a legacy moment. π«Ά
static void initClass (void)β init class again, cute.static SoType getClassTypeId (void)β type id, yup.static void addName (SoBase *const base, const char *const name)β adds a name, bestie.static void removeName (SoBase *const base, const char *const name)β removes a name, bye.static void incrementCurrentWriteCounter (void)β bumps the write counter, okurr.static void decrementCurrentWriteCounter (void)β lowers the write counter, periodt.static SoBase * getNamedBase (const SbName &name, SoType type)β gets a named base, slay.static int getNamedBases (const SbName &name, SoBaseList &baselist, SoType type)β gets the named bases, iconic.static SbBool read (SoInput *in, SoBase *&base, SoType expectedtype)β reads, no notes.static void setInstancePrefix (const SbString &c)β sets the instance prefix, fr.static void setTraceRefs (SbBool trace)β sets trace refs, yup.static SbBool getTraceRefs (void)β gets trace refs, periodt.static SbBool connectRoute (SoInput *in, const SbName &fromnodename, const SbName &fromfieldname, const SbName &tonodename, const SbName &tofieldname)β connects a route, main character energy.static SbBool readRoute (SoInput *in)β reads a route, slay.
π Public Attributes π
SoSFVec3f scaleFactorβ the scale factor, bestie. That's the whole mood.
π Public Attributes inherited from SoDragger π
SoSFBool isActiveβ is it active? Yes or no, iconic.
π¦ Public Attributes inherited from SoInteractionKit π¦
SoSFEnum renderCachingβ render caching enum, slay.SoSFEnum boundingBoxCachingβ bounding box caching enum, periodt.SoSFEnum renderCullingβ render culling enum, fr.SoSFEnum pickCullingβ pick culling enum, no cap.
β¨ Protected Member Functions β¨
These are the protected member functions for SoScale2Dragger, lowkey the inner workings. π
virtual const SoFieldData * getFieldData (void) constβ gets the field data, essential.~SoScale2Dragger ()β the destructor, bye bestie.virtual SbBool setUpConnections (SbBool onoff, SbBool doitalways=0)β sets up connections, withdoitalways=0default.void dragStart (void)β starts the drag, go off.void drag (void)β does the drag, main character.void dragFinish (void)β finishes the drag, periodt.
π Protected Member Functions inherited from SoDragger π
All the inherited protected member functions from SoDragger, and there are a lot. We're not skipping any. π
SoDragger (void)β constructor, iconic.virtual ~SoDragger ()β destructor, bye.SbVec2f getNormalizedLocaterPosition (void)β gets normalized locater position, slay.SbVec2s getLocaterPosition (void)β gets locater position, fr.SbVec2s getStartLocaterPosition (void) constβ gets start locater position, periodt.void setStartLocaterPosition (SbVec2s p)β sets start locater position, cute.SbBool isAdequateConstraintMotion (void)β checks adequate constraint motion, bestie.virtual SbBool shouldGrabBasedOnSurrogate (const SoPath *pickpath, const SoPath *surrogatepath)β should grab based on surrogate, no cap.void setCameraInfo (SoAction *action)β sets camera info, iconic.virtual void handleEvent (SoHandleEventAction *ha)β handles event, slay.void transferMotion (SoDragger *child)β transfers motion, periodt.void setIgnoreInBbox (SbBool newval)β sets ignore in bbox, fr.SbBool isIgnoreInBbox (void)β is ignore in bbox, yup.virtual void getBoundingBox (SoGetBoundingBoxAction *action)β gets bounding box, main character.void setActiveChildDragger (SoDragger *newchilddragger)β sets active child dragger, iconic.SoDragger * getActiveChildDragger (void) constβ gets active child dragger, slay.virtual void setDefaultOnNonWritingFields (void)β sets default on non-writing fields, periodt.void updateDraggerCache (const SoPath *path)β updates dragger cache, fr.
π Protected Member Functions inherited from SoInteractionKit π
virtual ~SoInteractionKit ()β destructor, bye.virtual void copyContents (const SoFieldContainer *fromFC, SbBool copyConnections)β copies contents, iconic.virtual SbBool setPart (const int partNum, SoNode *node)β sets part, slay.virtual SbBool readInstance (SoInput *in, unsigned short flags)β reads instance, periodt.virtual SbBool setAnyPartAsDefault (const SbName &partname, SoNode *node, SbBool anypart=1, SbBool onlyifdefault=1)β sets any part as default, node version, with defaults.virtual SbBool setAnyPartAsDefault (const SbName &partname, const SbName &nodename, SbBool anypart=1, SbBool onlyifdefault=1)β sets any part as default, nodename version, with defaults.SbBool setAnySurrogatePath (const SbName &name, SoPath *path, SbBool leafcheck=0, SbBool publiccheck=0)β sets any surrogate path, fr.void connectSeparatorFields (SoSeparator *dest, SbBool onOff)β connects separator fields, iconic.
π§ Protected Member Functions inherited from SoBaseKit π§
virtual ~SoBaseKit ()β destructor, bye.virtual SoNode * addToCopyDict (void) constβ adds to copy dict, slay.SoGroup * getContainerNode (const SbName &listname, SbBool makeifneeded=1)β gets container node, periodt.virtual SoNode * getAnyPart (const SbName &partname, SbBool makeifneeded, SbBool leafcheck=0, SbBool publiccheck=0)β gets any part, fr.virtual SoNodeKitPath * createPathToAnyPart (const SbName &partname, SbBool makeifneeded, SbBool leafcheck=0, SbBool publiccheck=0, const SoPath *pathtoextend=NULL)β creates path to any part, iconic.virtual SbBool setAnyPart (const SbName &partname, SoNode *from, SbBool anypart=1)β sets any part, slay.void createNodekitPartsList (void)β creates nodekit parts list, periodt.void createFieldList (void)β creates field list, fr.virtual void createDefaultParts (void)β creates default parts, main character.const SoNodekitParts * getNodekitPartsList (void) constβ gets nodekit parts list, iconic.const SbList< SoSFNode * > & getCatalogInstances (void) constβ gets catalog instances, slay.void catalogError (void)β catalog error, bestie.void countMyFields (SoOutput *out)β counts my fields, periodt.
π Protected Member Functions inherited from SoNode π
SoNode (void)β constructor, iconic.virtual ~SoNode ()β destructor, bye.
π«Ά Protected Member Functions inherited from SoFieldContainer π«Ά
SoFieldContainer (void)β constructor, slay.~SoFieldContainer ()β destructor, bye.
π Protected Member Functions inherited from SoBase π
SoBase (void)β constructor, iconic.virtual ~SoBase ()β destructor, bye.virtual void destroy (void)β destroy, periodt.SbBool hasMultipleWriteRefs (void) constβ has multiple write refs, fr.SbBool writeHeader (SoOutput *out, SbBool isgroup, SbBool isengine) constβ writes header, slay.void writeFooter (SoOutput *out) constβ writes footer, iconic.virtual const char * getFileFormatName (void) constβ gets file format name, periodt.
β¨ Static Protected Member Functions β¨
static const SoFieldData ** getFieldDataPtr (void)β gets field data pointer, lowkey.static const SoNodekitCatalog ** getClassNodekitCatalogPtr (void)β gets class nodekit catalog pointer, fr.static void startCB (void *f, SoDragger *d)β start callback, iconic.static void motionCB (void *f, SoDragger *d)β motion callback, slay.static void finishCB (void *f, SoDragger *d)β finish callback, periodt.static void fieldSensorCB (void *f, SoSensor *s)β field sensor callback, bestie.static void valueChangedCB (void *f, SoDragger *d)β value changed callback, fr.
π Static Protected Member Functions inherited from SoDragger π
static const SoFieldData ** getFieldDataPtr (void)β field data pointer, again.static const SoNodekitCatalog ** getClassNodekitCatalogPtr (void)β class nodekit catalog pointer, again.static void childTransferMotionAndValueChangedCB (void *, SoDragger *)β child transfer motion and value changed callback, iconic.static void childValueChangedCB (void *, SoDragger *)β child value changed callback, slay.static void childStartCB (void *, SoDragger *)β child start callback, periodt.static void childMotionCB (void *, SoDragger *)β child motion callback, fr.static void childFinishCB (void *, SoDragger *)β child finish callback, main character.static void childOtherEventCB (void *, SoDragger *)β child other event callback, bestie.
πΈ Static Protected Member Functions inherited from SoInteractionKit πΈ
static const SoFieldData ** getFieldDataPtr (void)β field data pointer, yup.static const SoNodekitCatalog ** getClassNodekitCatalogPtr (void)β class nodekit catalog pointer, yup.static void readDefaultParts (const char *fileName, const char defaultBuffer[], int defBufSize)β reads default parts, iconic.static void fieldSensorCB (void *, SoSensor *)β field sensor callback, periodt.
π Static Protected Member Functions inherited from SoBaseKit π
static const SoFieldData ** getFieldDataPtr (void)β field data pointer, again.static const SoNodekitCatalog ** getClassNodekitCatalogPtr (void)β class nodekit catalog pointer, again.
π¦ Static Protected Member Functions inherited from SoNode π¦
static const SoFieldData ** getFieldDataPtr (void)β field data pointer, again.static void setNextActionMethodIndex (int index)β sets next action method index, slay.static int getNextActionMethodIndex (void)β gets next action method index, periodt.static void incNextActionMethodIndex (void)β increments next action method index, fr.static void setCompatibilityTypes (const SoType &nodetype, const uint32_t bitmask)β sets compatibility types, iconic.
π Static Protected Member Functions inherited from SoBase π
static uint32_t getCurrentWriteCounter (void)β gets current write counter, bestie.static void staticDataLock (void)β static data lock, slay.static void staticDataUnlock (void)β static data unlock, periodt.
π Protected Attributes π
SoSFNode feedbackβ feedback node, iconic.SoSFNode feedbackActiveβ feedback active node, slay.SoSFNode feedbackSwitchβ feedback switch node, periodt.SoSFNode scalerβ scaler node, fr.SoSFNode scalerActiveβ scaler active node, main character.SoSFNode scalerSwitchβ scaler switch node, bestie.SoFieldSensor * fieldSensorβ field sensor pointer, iconic.SbPlaneProjector * planeProjβ plane projector pointer, slay.
π§ Protected Attributes inherited from SoDragger π§
SoSFNode motionMatrixβ motion matrix node, periodt.
π Protected Attributes inherited from SoInteractionKit π
SoSFNode geomSeparatorβ geom separator node, iconic.SoSFNode topSeparatorβ top separator node, slay.SoFieldSensor * fieldSensorβ field sensor pointer, periodt.SoSeparator * oldTopSepβ old top separator pointer, fr.
π«Ά Protected Attributes inherited from SoBaseKit π«Ά
SoSFNode callbackListβ callback list node, iconic.SoChildList * childrenβ children pointer, slay.SbBool connectionsSetUpβ connections set up bool, periodt.
π Protected Attributes inherited from SoNode π
uint32_t uniqueIdβ unique id, fr.
π Protected Attributes inherited from SoFieldContainer π
SbBool isBuiltInβ is built in bool, iconic.
β¨ Additional Inherited Members β¨
π Public Types inherited from SoDragger π
enum ProjectorFrontSetting { FRONT, BACK, USE_PICK }β the projector front setting enum, slay.
π Public Types inherited from SoInteractionKit π
enum CacheEnabled { OFF, ON, AUTO }β cache enabled enum, periodt.
π¦ Public Types inherited from SoNode π¦
enum NodeType { INVENTOR = 0x0000, VRML1 = 0x0001, VRML2 = 0x0002, INVENTOR_1 = 0x0004, INVENTOR_2_0 = 0x0008, INVENTOR_2_1 = 0x0010, INVENTOR_2_5 = 0x0020, INVENTOR_2_6 = 0x0040, COIN_1_0 = 0x0080, COIN_2_0 = 0x0100, EXTENSION = 0x0200, COIN_2_2 = 0x0400, COIN_2_3 = 0x0800, COIN_2_4 = 0x1000, INVENTOR_5_0 = 0x2000, COIN_2_5 = 0x4000 }β the NodeType enum, iconic. All the values, no cap.
π Protected Types inherited from SoBase π
enum BaseFlags { IS_ENGINE = 0x01, IS_GROUP = 0x02 }β BaseFlags enum, fr.
πΈ Static Protected Attributes inherited from SoNode πΈ
static uint32_t nextUniqueId = 0β next unique id starts at0, periodt.static int nextActionMethodIndex = 0β next action method index starts at0, slay.
π Detailed Description π
The SoScale2Dragger class provides a mechanism for the end-user to scale in two dimensions. Like, literally two dimensions, bestie. π
Here's how the dragger looks with its default geometry in the inactive state:
Use this dragger to allow the end-user of your application to scale along the X-axis and the Y-axis. (Use a transformation node in front of the dragger to position it and re-orient it to scale in any plane.) Iconic.
Scaling can be done in a non-uniform manner. So you can stretch it however, no cap.
π See also π
SoScale1DraggerSoScaleUniformDraggerSoScale2UniformDragger
π Constructor & Destructor Documentation π
β¨ SoScale2Dragger::SoScale2Dragger (void ) β¨
Okay so this is the default constructor, and bestie, it's doing a LOT. It sets up the dragger nodekit catalog with all the interaction and feedback geometry. Like, it's building the whole little world this dragger lives in. π«Ά
Node kit structure (new entries versus parent class marked with arrow prefix):
CLASS SoScale2Dragger
-->"this"
"callbackList"
"topSeparator"
"motionMatrix"
"geomSeparator"
--> "scalerSwitch"
--> "scaler"
--> "scalerActive"
--> "feedbackSwitch"
--> "feedback"
--> "feedbackActive"
(If you wanna know more about how that output is formatted, go look at SoBaseKit::printDiagram() β it explains the formatting thing.)
Detailed information on catalog parts:
CLASS SoScale2Dragger
PVT "this", SoScale2Dragger ---
"callbackList", SoNodeKitListPart [ SoCallback, SoEventCallback ]
PVT "topSeparator", SoSeparator ---
PVT "motionMatrix", SoMatrixTransform ---
PVT "geomSeparator", SoSeparator ---
PVT "scalerSwitch", SoSwitch ---
"scaler", SoSeparator ---
"scalerActive", SoSeparator ---
PVT "feedbackSwitch", SoSwitch ---
"feedback", SoSeparator ---
"feedbackActive", SoSeparator ---
(Same deal, the formatting deets live in SoBaseKit::printTable().)
References β the constructor is leaning on all of these: SoDragger::addFinishCallback(), SoDragger::addMotionCallback(), SoDragger::addStartCallback(), SoDragger::addValueChangedCallback(), fieldSensor, fieldSensorCB(), finishCB(), motionCB(), planeProj, SoInteractionKit::readDefaultParts(), scaleFactor, SoInteractionKit::setPartAsDefault(), SoInteractionKit::setSwitchValue(), setUpConnections(), SoScale2Dragger(), startCB(), and valueChangedCB(). That's the whole group chat right there. π
Referenced by: fieldSensorCB(), finishCB(), getFieldData(), motionCB(), SoScale2Dragger(), startCB(), and valueChangedCB().
πΈ SoScale2Dragger::~SoScale2Dragger () [protected] πΈ
Protected destructor. Not for you, bestie, it's protected for a reason.
Dragger classes are derived fromSoBase, so they are reference counted and automatically destroyed when their reference count goes to0. So like, you don't have to do anything β it just dips when nobody's holding on anymore. π¦
References: fieldSensor, and planeProj.
π Member Function Documentation π
β SoType SoScale2Dragger::getTypeId (void ) const [virtual] β
Returns the type identification of an object derived from a class inheriting SoBase. This is the whole reason run-time type checking and "downward" casting work at all. It's giving type system main character energy. π
Usage example:
void foo(SoNode * node)
{
if (node->getTypeId() == SoFile::getClassTypeId()) {
SoFile * filenode = (SoFile *)node; // safe downward cast, knows the type
}
else if (node->getTypeId().isOfType(SoGroup::getClassTypeId())) {
SoGroup * group = (SoGroup *)node; // safe downward cast, knows the type
}
}
Now for the application programmers who wanna extend the library with new nodes, engines, nodekits, draggers or whatever β this method needs to be overridden in all subclasses. Periodt. This is typically done as part of setting up the full type system for extension classes, which is usually accomplished by using the pre-defined macros available through for instance Inventor/nodes/SoSubNode.h (SO_NODE_INIT_CLASS and SO_NODE_CONSTRUCTOR for node classes), Inventor/engines/SoSubEngine.h (for engine classes) and so on.
For more info on writing Coin extensions, see the class documentation of the toplevel superclasses for the various class groups. β¨
Reimplemented from SoDragger.
π¦ const SoFieldData * SoScale2Dragger::getFieldData (void ) const [protected], [virtual] π¦
Hands you back a pointer to the class-wide field data storage object for this instance. And if there are no fields present? It returns NULL. No fields, no data, no problem. π
Reimplemented from SoDragger.
References: SoScale2Dragger().
π const SoNodekitCatalog * SoScale2Dragger::getNodekitCatalog (void ) const [virtual] π
Returns the nodekit catalog which defines the layout of this class' kit. It's literally the blueprint. The floor plan. The vibe map. πΊοΈ
Reimplemented from SoDragger.
π₯ SbBool SoScale2Dragger::setUpConnections (SbBool onoff, SbBool doitalways = 0) [protected], [virtual] π₯
Sets up all internal connections for instances of this class. Wiring it all together, no cap.
Heads up: this method will usually not be of interest to the application programmer, unless you want to extend the library with new custom nodekits or dragger classes. If that's you, go read the SoBaseKit class documentation. π
Reimplemented from SoInteractionKit.
References: SoBaseKit::connectionsSetUp, fieldSensor, fieldSensorCB(), scaleFactor, and SoBaseKit::setUpConnections().
Referenced by SoScale2Dragger().
π void SoScale2Dragger::startCB (void * f, SoDragger * d) [static], [protected] π
This API member is considered internal to the library, as it is not likely to be of interest to the application programmer. So likeβ¦ not your problem, bestie. π
References: dragStart(), SoDragger::SoDragger(), and SoScale2Dragger().
Referenced by SoScale2Dragger().
π void SoScale2Dragger::motionCB (void * f, SoDragger * d) [static], [protected] π
This API member is considered internal to the library, as it is not likely to be of interest to the application programmer. Same energy as above. π
References: drag(), SoDragger::SoDragger(), and SoScale2Dragger().
Referenced by SoScale2Dragger().
π void SoScale2Dragger::finishCB (void * f, SoDragger * d) [static], [protected] π
This API member is considered internal to the library, as it is not likely to be of interest to the application programmer. Internal, babe. Internal. π«Ά
References: dragFinish(), SoDragger::SoDragger(), and SoScale2Dragger().
Referenced by SoScale2Dragger().
π§ void SoScale2Dragger::fieldSensorCB (void * d, SoSensor * s) [static], [protected] π§
This API member is considered internal to the library, as it is not likely to be of interest to the application programmer. Yeah yeah, you know the drill by now. π
References: SoDragger::getMotionMatrix(), SbMatrix::getTransform(), scaleFactor, SoDragger::setMotionMatrix(), SbMatrix::setTransform(), and SoScale2Dragger().
Referenced by setUpConnections(), and SoScale2Dragger().
π void SoScale2Dragger::valueChangedCB (void * f, SoDragger * d) [static], [protected] π
This API member is considered internal to the library, as it is not likely to be of interest to the application programmer. It's the library's business, not ours. β¨
References: SoFieldSensor::attach(), SoFieldSensor::detach(), fieldSensor, SoDragger::getMotionMatrix(), SbMatrix::getTransform(), scaleFactor, SoDragger::SoDragger(), and SoScale2Dragger().
Referenced by SoScale2Dragger().
π void SoScale2Dragger::dragStart (void ) [protected] π
This API member is considered internal to the library, as it is not likely to be of interest to the application programmer.
Called when the dragger is selected (picked) by the user. Ooh, she's been noticed. π
References: SoDragger::getLocalStartingPoint(), planeProj, and SoInteractionKit::setSwitchValue().
Referenced by startCB().
π¦ void SoScale2Dragger::drag (void ) [protected] π¦
This API member is considered internal to the library, as it is not likely to be of interest to the application programmer.
Called when the user drags the mouse after picking the dragger. Go off, mouse. π±οΈ
References: SoDragger::appendScale(), SoDragger::getLocalStartingPoint(), SoDragger::getLocalToWorldMatrix(), SoDragger::getNormalizedLocaterPosition(), SoDragger::getStartMotionMatrix(), SoDragger::getViewVolume(), planeProj, and SoDragger::setMotionMatrix().
Referenced by motionCB().
πΈ void SoScale2Dragger::dragFinish (void ) [protected] πΈ
This API member is considered internal to the library, as it is not likely to be of interest to the application programmer.
Called when the mouse button is released after picking and interacting with the dragger. That's a wrap, periodt. π
References: SoInteractionKit::setSwitchValue().
Referenced by finishCB().
π Member Data Documentation π
π« SoSFVec3f SoScale2Dragger::scaleFactor π«
Continuously updated to contain the current vector of scaling along the X, Y and Z axes.
For the SoScale2Dragger, only the X and Y components are used β the Z component will always be equal to 1 (ie no scaling). So Z is justβ¦ there. Chilling. Not participating. π
Referenced by fieldSensorCB(), setUpConnections(), SoScale2Dragger(), and valueChangedCB().
π SoFieldSensor* SoScale2Dragger::fieldSensor [protected] π
This API member is considered internal to the library, as it is not likely to be of interest to the application programmer. Not for public consumption, bestie. π
Referenced by setUpConnections(), SoScale2Dragger(), valueChangedCB(), and ~SoScale2Dragger().
π SbPlaneProjector* SoScale2Dragger::planeProj [protected] π
This API member is considered internal to the library, as it is not likely to be of interest to the application programmer. Also internal. Also not your business. Also iconic. π
Referenced by drag(), dragStart(), SoScale2Dragger(), and ~SoScale2Dragger().
β¨ Author β¨
Generated automatically by Doxygen for Coin from the source code. Not a human typing this out at 3am β it's the robot. π€
And that's the whole page, bestie!! π The footer at the bottom is the source/version line, so here's the cute version: this lil doc came from Coin, Version 2.5.0, and it's the manual page for SoScale2Dragger(3). Slay, we're done, go scale something. π
πβ¨
π¦ where this page comes from
- fedora 43: Coin2-devel 2.5.0-52.fc43 Β· GPL-2.0-only
- fedora 43: Coin2-devel 2.5.0-52.fc43 Β· GPL-2.0-only
- fedora 44: Coin2-devel 2.5.0-54.fc44 Β· GPL-2.0-only
- fedora 44: Coin2-devel 2.5.0-54.fc44 Β· GPL-2.0-only
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash on : a language model's rewrite of the original, under its terms