SoIndexedShape(3)

πŸ“¦ version 3.1.3, in fedora 43, fedora 44

πŸ’– SoIndexedShape(3) β€” Library Functions Manual πŸ’–

okay so bestie, you opened the manual page for SoIndexedShape and I'm gonna walk you through it like we're texting in the group chat. she's the superclass for all indexed vertex shapes, and she's kind of a big deal. no cap. ✨

✨ NAME ✨

SoIndexedShape β€” the SoIndexedShape class is literally the superclass for all indexed vertex shapes. she's giving matriarch of the indexed vertex shape family. periodt. πŸ‘‘

🌸 SYNOPSIS 🌸

#include <Inventor/nodes/SoIndexedShape.h>

Inherits SoVertexShape.

Inherited by SoIndexedFaceSet, SoIndexedLineSet, SoIndexedPointSet, and SoIndexedTriangleStripSet.

πŸ’… Public Member Functions πŸ’…

  • virtual SoType getTypeId (void) const β€” get her type id. that's the one, bestie. πŸ’–

πŸ¦‹ Public Member Functions inherited from SoVertexShape πŸ¦‹

  • virtual void notify (SoNotList *nl) β€” inherited glow.
  • virtual SbBool generateDefaultNormals (SoState *state, SoNormalBundle *bundle) β€” inherited glow.
  • virtual SbBool generateDefaultNormals (SoState *state, SoNormalCache *cache) β€” inherited glow.
  • virtual void write (SoWriteAction *action) β€” inherited glow.

πŸ¦‹ Public Member Functions inherited from SoShape πŸ¦‹

  • virtual SbBool affectsState (void) const β€” inherited.
  • virtual void getBoundingBox (SoGetBoundingBoxAction *action) β€” inherited.
  • virtual void GLRender (SoGLRenderAction *action) β€” inherited.
  • virtual void rayPick (SoRayPickAction *action) β€” inherited.
  • virtual void callback (SoCallbackAction *action) β€” inherited.
  • virtual void getPrimitiveCount (SoGetPrimitiveCountAction *action) β€” inherited.
  • const SoBoundingBoxCache * getBoundingBoxCache (void) const β€” inherited.

πŸ¦‹ Public Member Functions inherited from SoNode πŸ¦‹

  • void setOverride (const SbBool state) β€” inherited.
  • SbBool isOverride (void) const β€” inherited.
  • void setNodeType (const NodeType type) β€” inherited.
  • NodeType getNodeType (void) const β€” inherited.
  • virtual SoNode * copy (SbBool copyconnections=FALSE) const β€” inherited.
  • virtual void doAction (SoAction *action) β€” inherited.
  • virtual void GLRenderBelowPath (SoGLRenderAction *action) β€” inherited.
  • virtual void GLRenderInPath (SoGLRenderAction *action) β€” inherited.
  • virtual void GLRenderOffPath (SoGLRenderAction *action) β€” inherited.
  • virtual void getMatrix (SoGetMatrixAction *action) β€” inherited.
  • virtual void handleEvent (SoHandleEventAction *action) β€” inherited.
  • virtual void pick (SoPickAction *action) β€” inherited.
  • virtual void search (SoSearchAction *action) β€” inherited.
  • virtual void audioRender (SoAudioRenderAction *action) β€” inherited.
  • virtual void grabEventsSetup (void) β€” inherited.
  • virtual void grabEventsCleanup (void) β€” inherited.
  • virtual void startNotify (void) β€” inherited.
  • uint32_t getNodeId (void) const β€” inherited.
  • virtual SoChildList * getChildren (void) const β€” inherited.
  • virtual void writeInstance (SoOutput *out) β€” inherited.
  • virtual SoNode * addToCopyDict (void) const β€” inherited.
  • virtual void copyContents (const SoFieldContainer *from, SbBool copyconnections) β€” inherited.
  • virtual SoFieldContainer * copyThroughConnection (void) const β€” inherited.

πŸ¦‹ Public Member Functions inherited from SoFieldContainer πŸ¦‹

  • void setToDefaults (void) β€” inherited.
  • SbBool hasDefaultValues (void) const β€” inherited.
  • SbBool fieldsAreEqual (const SoFieldContainer *container) const β€” inherited.
  • void copyFieldValues (const SoFieldContainer *container, SbBool copyconnections=FALSE) β€” inherited.
  • SbBool set (const char *const fielddata) β€” inherited.
  • void get (SbString &fielddata) β€” inherited.
  • virtual int getFields (SoFieldList &l) const β€” inherited.
  • virtual int getAllFields (SoFieldList &l) const β€” inherited.
  • virtual SoField * getField (const SbName &name) const β€” inherited.
  • virtual SoField * getEventIn (const SbName &name) const β€” inherited.
  • virtual SoField * getEventOut (const SbName &name) const β€” inherited.
  • SbBool getFieldName (const SoField *const field, SbName &name) const β€” inherited.
  • SbBool enableNotify (const SbBool flag) β€” inherited.
  • SbBool isNotifyEnabled (void) const β€” inherited.
  • SbBool set (const char *fielddata, SoInput *input) β€” inherited.
  • void get (SbString &fielddata, SoOutput *out) β€” inherited.
  • virtual SbBool validateNewFieldValue (SoField *field, void *newval) β€” inherited.
  • virtual void addWriteReference (SoOutput *out, SbBool isfromfield=FALSE) β€” inherited.
  • SbBool getIsBuiltIn (void) const β€” inherited.
  • virtual void getFieldsMemorySize (size_t &managed, size_t &unmanaged) const β€” inherited.
  • void setUserData (void *userdata) const β€” inherited.
  • void * getUserData (void) const β€” inherited.

πŸ¦‹ Public Member Functions inherited from SoBase πŸ¦‹

  • void ref (void) const β€” inherited.
  • void unref (void) const β€” inherited.
  • void unrefNoDelete (void) const β€” inherited.
  • int32_t getRefCount (void) const β€” inherited.
  • void touch (void) β€” inherited.
  • SbBool isOfType (SoType type) const β€” inherited.
  • virtual SbName getName (void) const β€” inherited.
  • virtual void setName (const SbName &newname) β€” inherited.
  • void addAuditor (void *const auditor, const SoNotRec::Type type) β€” inherited.
  • void removeAuditor (void *const auditor, const SoNotRec::Type type) β€” inherited.
  • const SoAuditorList & getAuditors (void) const β€” inherited.
  • SbBool shouldWrite (void) β€” inherited.
  • void assertAlive (void) const β€” inherited.

πŸ‘‘ Static Public Member Functions πŸ‘‘

  • static SoType getClassTypeId (void) β€” static queen.
  • static void initClass (void) β€” static queen.

πŸ‘‘ Static Public Member Functions inherited from SoVertexShape πŸ‘‘

  • static SoType getClassTypeId (void) β€” inherited static.
  • static void initClass (void) β€” inherited static.

πŸ‘‘ Static Public Member Functions inherited from SoShape πŸ‘‘

  • static SoType getClassTypeId (void) β€” inherited static.
  • static void initClass (void) β€” inherited static.
  • static void getScreenSize (SoState *const state, const SbBox3f &boundingbox, SbVec2s &rectsize) β€” inherited static.
  • static float getDecimatedComplexity (SoState *state, float complexity) β€” inherited static.

πŸ‘‘ Static Public Member Functions inherited from SoNode πŸ‘‘

  • static uint32_t getCompatibilityTypes (const SoType &nodetype) β€” inherited static.
  • static SoType getClassTypeId (void) β€” inherited static.
  • static SoNode * getByName (const SbName &name) β€” inherited static.
  • static int getByName (const SbName &name, SoNodeList &l) β€” inherited static.
  • static void initClass (void) β€” inherited static.
  • static void initClasses (void) β€” inherited static.
  • static uint32_t getNextNodeId (void) β€” inherited static.
  • static int getActionMethodIndex (const SoType type) β€” inherited static.
  • static void getBoundingBoxS (SoAction *action, SoNode *node) β€” inherited static.
  • static void GLRenderS (SoAction *action, SoNode *node) β€” inherited static.
  • static void callbackS (SoAction *action, SoNode *node) β€” inherited static.
  • static void getMatrixS (SoAction *action, SoNode *node) β€” inherited static.
  • static void handleEventS (SoAction *action, SoNode *node) β€” inherited static.
  • static void pickS (SoAction *action, SoNode *node) β€” inherited static.
  • static void rayPickS (SoAction *action, SoNode *node) β€” inherited static.
  • static void searchS (SoAction *action, SoNode *node) β€” inherited static.
  • static void writeS (SoAction *action, SoNode *node) β€” inherited static.
  • static void audioRenderS (SoAction *action, SoNode *node) β€” inherited static.
  • static void getPrimitiveCountS (SoAction *action, SoNode *node) β€” inherited static.

πŸ‘‘ Static Public Member Functions inherited from SoFieldContainer πŸ‘‘

  • static void initClass (void) β€” inherited static.
  • static SoType getClassTypeId (void) β€” inherited static.
  • static void cleanupClass (void) β€” inherited static.
  • static void initCopyDict (void) β€” inherited static.
  • static void addCopy (const SoFieldContainer *orig, const SoFieldContainer *copy) β€” inherited static.
  • static SoFieldContainer * checkCopy (const SoFieldContainer *orig) β€” inherited static.
  • static SoFieldContainer * findCopy (const SoFieldContainer *orig, const SbBool copyconnections) β€” inherited static.
  • static void copyDone (void) β€” inherited static.

πŸ‘‘ Static Public Member Functions inherited from SoBase πŸ‘‘

  • static void initClass (void) β€” inherited static.
  • static SoType getClassTypeId (void) β€” inherited static.
  • static void addName (SoBase *const base, const char *const name) β€” inherited static.
  • static void removeName (SoBase *const base, const char *const name) β€” inherited static.
  • static void incrementCurrentWriteCounter (void) β€” inherited static.
  • static void decrementCurrentWriteCounter (void) β€” inherited static.
  • static SoBase * getNamedBase (const SbName &name, SoType type) β€” inherited static.
  • static int getNamedBases (const SbName &name, SoBaseList &baselist, SoType type) β€” inherited static.
  • static SbBool read (SoInput *input, SoBase *&base, SoType expectedtype) β€” inherited static.
  • static void setInstancePrefix (const SbString &c) β€” inherited static.
  • static void setTraceRefs (SbBool trace) β€” inherited static.
  • static SbBool getTraceRefs (void) β€” inherited static.
  • static SbBool connectRoute (SoInput *input, const SbName &fromnodename, const SbName &fromfieldname, const SbName &tonodename, const SbName &tofieldname) β€” inherited static.
  • static SbBool readRoute (SoInput *input) β€” inherited static.

πŸ“ Public Attributes πŸ“

  • SoMFInt32 coordIndex β€” the coord index field, bestie.
  • SoMFInt32 materialIndex β€” the material index field.
  • SoMFInt32 normalIndex β€” the normal index field.
  • SoMFInt32 textureCoordIndex β€” the texture coord index field.

πŸ“ Public Attributes inherited from SoVertexShape πŸ“

  • SoSFNode vertexProperty β€” inherited attribute.

🧚 Protected Member Functions 🧚

  • virtual const SoFieldData * getFieldData (void) const β€” protected.
  • SoIndexedShape (void) β€” protected constructor.
  • virtual ~SoIndexedShape () β€” protected destructor.
  • virtual void computeBBox (SoAction *action, SbBox3f &box, SbVec3f &center) β€” protected.
  • int getNumVerts (const int startCoord) β€” protected.
  • void setupIndices (const int numParts, const int numFaces, const SbBool needNormals, const SbBool needTexCoords) β€” protected.
  • const int32_t * getNormalIndices (void) β€” protected.
  • const int32_t * getColorIndices (void) β€” protected.
  • const int32_t * getTexCoordIndices (void) β€” protected.
  • SbBool getVertexData (SoState *state, const SoCoordinateElement *&coords, const SbVec3f *&normals, const int32_t *&cindices, const int32_t *&nindices, const int32_t *&tindices, const int32_t *&mindices, int &numcindices, const SbBool needNormals, SbBool &normalCacheUsed) β€” protected.

🧚 Protected Member Functions inherited from SoVertexShape 🧚

  • SoVertexShape (void) β€” inherited protected.
  • virtual ~SoVertexShape () β€” inherited protected.
  • virtual SbBool shouldGLRender (SoGLRenderAction *action) β€” inherited protected.
  • void setNormalCache (SoState *const state, const int num, const SbVec3f *normals) β€” inherited protected.
  • SoNormalCache * getNormalCache (void) const β€” inherited protected.
  • SoNormalCache * generateAndReadLockNormalCache (SoState *const state) β€” inherited protected.
  • void getVertexData (SoState *state, const SoCoordinateElement *&coords, const SbVec3f *&normals, const SbBool neednormals) β€” inherited protected.
  • void readLockNormalCache (void) β€” inherited protected.
  • void readUnlockNormalCache (void) β€” inherited protected.

so the tea keeps brewing, bestie β€” here's everything SoIndexedShape inherited from its ancestors, in order, nothing skipped: πŸ’…


🧬 Protected Member Functions inherited from SoShape

  • SoShape (void) β€” yep, the constructor
  • virtual ~SoShape () β€” and the destructor
  • float getComplexityValue (SoAction *action)
  • virtual void generatePrimitives (SoAction *action)=0 β€” pure virtual, no cap
  • void beginSolidShape (SoGLRenderAction *action)
  • void endSolidShape (SoGLRenderAction *action)
  • void GLRenderBoundingBox (SoGLRenderAction *action)
  • SbBool shouldPrimitiveCount (SoGetPrimitiveCountAction *action)
  • SbBool shouldRayPick (SoRayPickAction *const action)
  • void computeObjectSpaceRay (SoRayPickAction *const action)
  • void computeObjectSpaceRay (SoRayPickAction *const action, const SbMatrix &matrix)
  • virtual SoDetail * createTriangleDetail (SoRayPickAction *action, const SoPrimitiveVertex *v1, const SoPrimitiveVertex *v2, const SoPrimitiveVertex *v3, SoPickedPoint *pp)
  • virtual SoDetail * createLineSegmentDetail (SoRayPickAction *action, const SoPrimitiveVertex *v1, const SoPrimitiveVertex *v2, SoPickedPoint *pp)
  • virtual SoDetail * createPointDetail (SoRayPickAction *action, const SoPrimitiveVertex *v, SoPickedPoint *pp)
  • void invokeTriangleCallbacks (SoAction *const action, const SoPrimitiveVertex *const v1, const SoPrimitiveVertex *const v2, const SoPrimitiveVertex *const v3)
  • void invokeLineSegmentCallbacks (SoAction *const action, const SoPrimitiveVertex *const v1, const SoPrimitiveVertex *const v2)
  • void invokePointCallbacks (SoAction *const action, const SoPrimitiveVertex *const v)
  • void beginShape (SoAction *const action, const TriangleShape shapetype, SoDetail *const detail=NULL)
  • void shapeVertex (const SoPrimitiveVertex *const v)
  • void endShape (void)
  • void generateVertex (SoPrimitiveVertex *const pv, const SbVec3f &point, const SbBool useTexFunc, const SoTextureCoordinateElement *const tce, const float s, const float t, const SbVec3f &normal)
  • void generateVertex (SoPrimitiveVertex *const pv, const SbVec3f &point, const SbBool useTexFunc, const SoTextureCoordinateElement *const tce, const float s, const float t, const float r, const SbVec3f &normal)
  • SbBool startVertexArray (SoGLRenderAction *action, const SoCoordinateElement *coords, const SbVec3f *pervertexnormals, const SbBool texpervertex, const SbBool colorpervertex)
  • void finishVertexArray (SoGLRenderAction *action, const SbBool vbo, const SbBool normpervertex, const SbBool texpervertex, const SbBool colorpervertex)

🫢 Protected Member Functions inherited from SoNode

  • SoNode (void)
  • virtual ~SoNode ()
  • virtual SbBool readInstance (SoInput *in, unsigned short flags)

🌸 Protected Member Functions inherited from SoFieldContainer

  • SoFieldContainer (void)
  • virtual ~SoFieldContainer ()

πŸ¦‹ Protected Member Functions inherited from SoBase

  • SoBase (void)
  • virtual ~SoBase ()
  • virtual void destroy (void)
  • SbBool hasMultipleWriteRefs (void) const
  • SbBool writeHeader (SoOutput *out, SbBool isgroup, SbBool isengine) const
  • void writeFooter (SoOutput *out) const
  • virtual const char * getFileFormatName (void) const

✨ Static Protected Member Functions

  • static const SoFieldData ** getFieldDataPtr (void)
  • static SbBool areTexCoordsIndexed (SoAction *action)

πŸŽ€ Static Protected Member Functions inherited from SoVertexShape

  • static const SoFieldData ** getFieldDataPtr (void)

πŸŽ€ Static Protected Member Functions inherited from SoShape

  • static const SoFieldData ** getFieldDataPtr (void)

πŸŽ€ Static Protected Member Functions inherited from SoNode

  • static const SoFieldData ** getFieldDataPtr (void)
  • static void setNextActionMethodIndex (int index)
  • static int getNextActionMethodIndex (void)
  • static void incNextActionMethodIndex (void)
  • static void setCompatibilityTypes (const SoType &nodetype, const uint32_t bitmask)

πŸŽ€ Static Protected Member Functions inherited from SoBase

  • static uint32_t getCurrentWriteCounter (void)
  • static void staticDataLock (void)
  • static void staticDataUnlock (void)

🌈 Additional Inherited Members

πŸ“ Public Types inherited from SoShape

enum TriangleShape { TRIANGLE_STRIP, TRIANGLE_FAN, TRIANGLES, POLYGON,
    QUADS, QUAD_STRIP, POINTS, LINES, LINE_STRIP }

πŸ“ 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,
    COIN_3_0 = 0x8000, INVENTOR_6_0 = 0x10000 }

πŸ’œ Protected Types inherited from SoBase

enum BaseFlags { IS_ENGINE = 0x01, IS_GROUP = 0x02 }

🧚 Protected Attributes inherited from SoNode

  • uint32_t uniqueId

🧚 Protected Attributes inherited from SoFieldContainer

  • SbBool isBuiltIn

🌟 Static Protected Attributes inherited from SoNode

  • static uint32_t nextUniqueId = 1
  • static int nextActionMethodIndex = 0

πŸ’– Detailed Description πŸ’–

SoIndexedShape is the superclass for all indexed vertex shapes. πŸ‘‘

It's an abstract class β€” so like, you don't instantiate it directly, bestie, it's giving "template" energy. What it does have is storage for four fields: the indices pointing at coordinates, normals, materials and texture coordinates, all sitting there for its subclasses to use. πŸŽ€


πŸŽ€ Constructor & Destructor Documentation πŸŽ€

SoIndexedShape::SoIndexedShape (void ) [protected]

Constructor. 🍼

SoIndexedShape::~SoIndexedShape () [protected], [virtual]

Destructor. πŸͺ¦


πŸ”₯ Member Function Documentation πŸ”₯

SoType SoIndexedShape::getTypeId (void ) const [virtual]

Returns the type identification of an object derived from a class inheriting SoBase. This is what you use for run-time type checking and "downward" casting. πŸ•΅οΈβ€β™€οΈ

Usage example:

void foo(SoNode * node)
{
  if (node->getTypeId() == SoFile::getClassTypeId()) {
    SoFile * filenode = (SoFile *)node;  // safe downward cast, knows the type
  }
}

Okay so for all the application programmers out there who wanna extend the library with new nodes, engines, nodekits, draggers or whatever else: this method needs to be overridden in all subclasses. That's 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. iykyk 🫢

For more info on writing Coin extensions, go look at the class documentation of the toplevel superclasses for the various class groups.

Reimplemented from SoVertexShape.

Reimplemented in SoIndexedFaceSet, SoIndexedLineSet, SoIndexedMarkerSet, SoIndexedPointSet, and SoIndexedTriangleStripSet.

const SoFieldData * SoIndexedShape::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. Simple as that. πŸ’…

Reimplemented from SoVertexShape.

Reimplemented in SoIndexedFaceSet, SoIndexedLineSet, SoIndexedMarkerSet, SoIndexedPointSet, and SoIndexedTriangleStripSet.

void SoIndexedShape::computeBBox (SoAction * action, SbBox3f & box, SbVec3f & center) [protected], [virtual]

This one is implemented by SoShape subclasses so the SoShape superclass can know the exact size and weighted center point of the shape's bounding box. πŸ“¦

The bounding box and center point should be calculated and returned in the local coordinate system. Noted.

The method implements action behavior for shape nodes for SoGetBoundingBoxAction. It gets invoked from SoShape::getBoundingBox(). (And heads up: subclasses should not override SoNode::getBoundingBox().) πŸ™…β€β™€οΈ

The box parameter sent in is guaranteed to be an empty box, while center is undefined upon function entry. So don't go reading it before you write it, bestie.

Implements SoShape.

int SoIndexedShape::getNumVerts (const int startCoord) [protected]

Starting at index position startCoord, this returns the number of indices until either the end of the index array or a separator index (-1). Whichever comes first. 🏁

void SoIndexedShape::setupIndices (const int numParts, const int numFaces, const SbBool needNormals, const SbBool needTexCoords) [protected]

Not implemented. Probably only used for internal purposes in SGI's original Open Inventor, which means it should have been private. 😭

Let us know if you need this method for any code you are porting and we'll look into implement it properly. 🫢

const int32_t * SoIndexedShape::getNormalIndices (void ) [protected]

Not implemented. Probably only used for internal purposes in SGI's original Open Inventor, which means it should have been private. 😭

Let us know if you need this method for any code you are porting and we'll look into implement it properly. 🫢

const int32_t * SoIndexedShape::getColorIndices (void ) [protected]

Not implemented. Probably only used for internal purposes in SGI's original Open Inventor, which means it should have been private. 😭

Let us know if you need this method for any code you are porting and we'll look into implement it properly. 🫢

const int32_t * SoIndexedShape::getTexCoordIndices (void ) [protected]

Not implemented. Probably only used for internal purposes in SGI's original Open Inventor, which means it should have been private. 😭

Let us know if you need this method for any code you are porting and we'll look into implement it properly. 🫢

SbBool SoIndexedShape::areTexCoordsIndexed (SoAction * action) [static], [protected]

Returns whether texture coordinates should be indexed or not. 🧡

See also: SoTextureCoordinateBinding

SbBool SoIndexedShape::getVertexData (SoState * state, const SoCoordinateElement *& coords, const SbVec3f *& normals, const int32_t *& cindices, const int32_t *& nindices, const int32_t *& tindices, const int32_t *& mindices, int & numcindices, const SbBool needNormals, SbBool & normalCacheUsed) [protected]

A convenience method that will fetch the data needed for rendering or generating primitives. It takes care of the normal cache too, so you don't gotta. ✨

This method was not part of the original SGI Open Inventor API β€” it's an extension specific for Coin. πŸͺ™


πŸ“ Member Data Documentation πŸ“

  • SoMFInt32 SoIndexedShape::coordIndex β€” Coordinate indices. πŸ“
  • SoMFInt32 SoIndexedShape::materialIndex β€” Material indices. 🎨
  • SoMFInt32 SoIndexedShape::normalIndex β€” Normal indices. 🧭
  • SoMFInt32 SoIndexedShape::textureCoordIndex β€” Texture coordinate indices. 🧡

πŸ‘‘ Author πŸ‘‘

Generated automatically by Doxygen for Coin from the source code. πŸ€–


and that's a wrap on SoIndexedShape(3), bestie β€” this lil doc came straight from Coin, Version 3.1.3, and it's dated the same as that version, so go forth and index your vertices, you absolute icon πŸ’–βœ¨πŸŽ€

πŸ“¦ where this page comes from