SORESETTRANSFORM(3iv)

πŸ‘‘ SoResetTransform πŸ‘‘

okay bestie, gather round, because this page is SoResetTransform(3IV) and it's honestly a whole vibe check for your scene graph. It's the node that hits the "undo my whole entire position" button. Let's get into it πŸ’…


πŸ¦‹ NAME

SoResetTransform β€” the node that resets the current transformation back to identity. Like, boom, you're at the origin again, no cap.


🧬 INHERITS FROM

SoBase > SoFieldContainer > SoNode > SoTransformation > SoResetTransform

so it's got the whole family tree behind it, generations of glow-up ✨


πŸ“œ SYNOPSIS

#include <Inventor/nodes/SoResetTransform.h>
enum ResetType {
     SoResetTransform::TRANSFORM  Reset the current transformation to
                                       identity
     SoResetTransform::BBOX       Reset the bounding box to empty
}

Fields from class SoResetTransform:

  • SoSFBitMask whatToReset

Methods from class SoResetTransform:

  • SoResetTransform()
  • static SoType getClassTypeId()

Methods from class SoNode β€” the hand-me-downs, and we love them:

  • void setOverride(SbBool state)
  • SbBool isOverride() const
  • SoNode * copy(SbBool copyConnections = FALSE) const
  • virtual SbBool affectsState() const
  • static SoNode * getByName(const SbName &name)
  • static int getByName(const SbName &name, SoNodeList &list)

Methods from class SoFieldContainer β€” the whole squad:

  • void setToDefaults()
  • SbBool hasDefaultValues() const
  • SbBool fieldsAreEqual(const SoFieldContainer *fc) const
  • void copyFieldValues(const SoFieldContainer *fc, SbBool copyConnections = FALSE)
  • SbBool set(const char *fieldDataString)
  • void get(SbString &fieldDataString)
  • virtual int getFields(SoFieldList &resultList) const
  • virtual SoField * getField(const SbName &fieldName) const
  • SbBool getFieldName(const SoField *field, SbName &fieldName) const
  • SbBool isNotifyEnabled() const
  • SbBool enableNotify(SbBool flag)

Methods from class SoBase β€” the ancestors, iconic as always:

  • void ref()
  • void unref() const
  • void unrefNoDelete() const
  • void touch()
  • virtual SoType getTypeId() const
  • SbBool isOfType(SoType type) const
  • virtual void setName(const SbName &name)
  • virtual SbName getName() const

πŸ’– DESCRIPTION

So this node resets the current transformation to identity. That's the main character move. You use it when you wanna apply an absolute world space transformation afterwards β€” like translating to a specific point from inside a hierarchy, which, yes, is exactly as powerful as it sounds.

bestie listen: an SoResetTransform node should probably live under an SoSeparator or SoTransformSeparator, so it won't go changing transformations for the rest of the scene graph. Nobody wants that kind of chaos in their file 🫢

It can also do a second little trick: resetting the current bounding box to empty during traversal of an SoGetBoundingBoxAction, but only if the whatToReset field has the BBOX bit set. Bit flags, we stan.


πŸŽ€ FIELDS

  • SoSFBitMask whatToReset β€” tells the node which items to reset when it gets traversed. That's it, that's the field, she's simple and she's efficient.

🌸 METHODS

  • SoResetTransform() β€” creates a reset transformation node with default settings. Fresh out the box, defaults on, ready to go ✨
  • static SoType getClassTypeId() β€” returns the type identifier for this class. iykyk.

πŸ”₯ ACTION BEHAVIOR

  • SoGLRenderAction, SoCallbackAction, SoRayPickAction β€” if specified, resets the current transformation matrix to identity. Slay.
  • SoGetBoundingBoxAction β€” if specified, resets the current transformation matrix to identity and sets the current computed bounding box to be empty. Double reset, double iconic πŸ’€
  • SoGetMatrixAction β€” returns the identity matrix. Periodt.

πŸ“ FILE FORMAT/DEFAULTS

ResetTransform {
     whatToReset  TRANSFORM
}

look at her, defaulting to TRANSFORM, minding her own business 🧚


🫢 SEE ALSO

  • SoTransform

and that's the page, bestie πŸ’– this one lives in the 3IV manual set, and the footer stamp on it reads SoResetTransform(3IV)() β€” that's your source/version tag right there, no date on it, so don't come for me about timestamps πŸ™ˆ go forth and reset those transformations, you absolute legend πŸ‘‘πŸ’