SoVRMLSphere(3)

πŸ“¦
version 4.0.10 Β· 4 versions
, in fedora 43, fedora 44

✨ NAME ✨

SoVRMLSphere β€” the class that's literally a spherical 3D object, bestie. No cap, she's giving geometry realness. πŸ’–


✨ SYNOPSIS ✨

Okay so first things first, you gotta include her:

#include <Inventor/VRMLnodes/SoVRMLSphere.h>

And she inherits from SoVRMLGeometry. Slay.

πŸ’… Public Member Functions πŸ’…

  • virtual SoType getTypeId (void) const β€” the type ID getter, she's iconic.
  • SoVRMLSphere (void) β€” the constructor, welcome to the sphere era.
  • virtual void GLRender (SoGLRenderAction *action) β€” renders with OpenGL, periodt.
  • virtual void rayPick (SoRayPickAction *action) β€” does the ray picking thing.
  • virtual void getPrimitiveCount (SoGetPrimitiveCountAction *action) β€” counts primitives, fr fr.

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

  • virtual void search (SoSearchAction *action) β€” search action vibes.
  • virtual void copyContents (const SoFieldContainer *from, SbBool copyConn) β€” copies contents, bestie.

🌸 Public Member Functions inherited from SoShape 🌸

  • virtual SbBool affectsState (void) const β€” does it affect state? mystery.
  • virtual void getBoundingBox (SoGetBoundingBoxAction *action) β€” gets the bounding box, iconic.
  • virtual void callback (SoCallbackAction *action) β€” callback action, she's here.
  • const SoBoundingBoxCache * getBoundingBoxCache (void) const β€” returns the bounding box cache, no cap.

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

  • void setOverride (const SbBool state) β€” sets override state.
  • SbBool isOverride (void) const β€” is it override? maybe.
  • void setNodeType (const NodeType type) β€” sets the node type.
  • NodeType getNodeType (void) const β€” gets the node type.
  • virtual SoNode * copy (SbBool copyconnections=FALSE) const β€” copies the node, default copyconnections=FALSE.
  • virtual void doAction (SoAction *action) β€” does the action.
  • virtual void GLRenderBelowPath (SoGLRenderAction *action) β€” GL render below path.
  • virtual void GLRenderInPath (SoGLRenderAction *action) β€” GL render in path.
  • virtual void GLRenderOffPath (SoGLRenderAction *action) β€” GL render off path.
  • virtual void getMatrix (SoGetMatrixAction *action) β€” gets the matrix.
  • virtual void handleEvent (SoHandleEventAction *action) β€” handles events.
  • virtual void pick (SoPickAction *action) β€” picks.
  • virtual void write (SoWriteAction *action) β€” writes.
  • virtual void audioRender (SoAudioRenderAction *action) β€” audio render.
  • virtual void grabEventsSetup (void) β€” grab events setup.
  • virtual void grabEventsCleanup (void) β€” grab events cleanup.
  • virtual void startNotify (void) β€” start notify.
  • SbUniqueId getNodeId (void) const β€” gets the node ID.
  • virtual void writeInstance (SoOutput *out) β€” write instance.
  • virtual SoNode * addToCopyDict (void) const β€” adds to copy dict.
  • virtual SoFieldContainer * copyThroughConnection (void) const β€” copy through connection.

πŸ’œ Public Member Functions inherited from SoFieldContainer πŸ’œ

  • void setToDefaults (void) β€” sets to defaults.
  • SbBool hasDefaultValues (void) const β€” has default values?.
  • SbBool fieldsAreEqual (const SoFieldContainer *container) const β€” checks if fields are equal.
  • void copyFieldValues (const SoFieldContainer *container, SbBool copyconnections=FALSE) β€” copies field values, default copyconnections=FALSE.
  • SbBool set (const char *const fielddata) β€” sets from fielddata.
  • void get (SbString &fielddata) β€” gets fielddata.
  • virtual int getFields (SoFieldList &l) const β€” gets fields.
  • virtual int getAllFields (SoFieldList &l) const β€” gets all fields.
  • virtual SoField * getField (const SbName &name) const β€” gets a field by name.
  • virtual SoField * getEventIn (const SbName &name) const β€” gets an event in.
  • virtual SoField * getEventOut (const SbName &name) const β€” gets an event out.
  • SbBool getFieldName (const SoField *const field, SbName &name) const β€” gets field name.
  • SbBool enableNotify (const SbBool flag) β€” enables notify.
  • SbBool isNotifyEnabled (void) const β€” is notify enabled?.
  • SbBool set (const char *fielddata, SoInput *input) β€” sets with input.
  • void get (SbString &fielddata, SoOutput *out) β€” gets with output.
  • virtual SbBool validateNewFieldValue (SoField *field, void *newval) β€” validates new field value.
  • virtual void addWriteReference (SoOutput *out, SbBool isfromfield=FALSE) β€” adds write reference, default isfromfield=FALSE.
  • SbBool getIsBuiltIn (void) const β€” gets is built in.
  • virtual void getFieldsMemorySize (size_t &managed, size_t &unmanaged) const β€” gets fields memory size.
  • void setUserData (void *userdata) const β€” sets user data.
  • void * getUserData (void) const β€” gets user data.

🌈 Public Member Functions inherited from SoBase 🌈

  • void ref (void) const β€” refs the object.
  • void unref (void) const β€” unrefs.
  • void unrefNoDelete (void) const β€” unrefs without deleting.
  • int32_t getRefCount (void) const β€” gets ref count.
  • void touch (void) β€” touch it.
  • SbBool isOfType (SoType type) const β€” Returns TRUE if the type of this object is either of the same type or inherited from type. iykyk.
  • virtual SbName getName (void) const β€” gets the name.
  • virtual void setName (const SbName &newname) β€” sets the name.
  • void addAuditor (void *const auditor, const SoNotRec::Type type) β€” adds an auditor.
  • void removeAuditor (void *const auditor, const SoNotRec::Type type) β€” removes an auditor.
  • const SoAuditorList & getAuditors (void) const β€” gets the auditors.
  • SbBool shouldWrite (void) β€” should write?.
  • void assertAlive (void) const β€” asserts alive.

✨ Static Public Member Functions ✨

  • static SoType getClassTypeId (void) β€” gets the class type ID.
  • static void initClass (void) β€” initializes the class.

🫢 Static Public Member Functions inherited from SoVRMLGeometry 🫢

  • static SoType getClassTypeId (void) β€” gets the class type ID.
  • static void initClass (void) β€” initializes the class.

πŸŽ€ Static Public Member Functions inherited from SoShape πŸŽ€

  • static SoType getClassTypeId (void) β€” gets the class type ID.
  • static void initClass (void) β€” Sets up initialization for data common to all instances of this class, like submitting necessary information to the Coin type system. slay.
  • static void getScreenSize (SoState *const state, const SbBox3f &boundingbox, SbVec2s &rectsize) β€” gets the screen size.
  • static float getDecimatedComplexity (SoState *state, float complexity) β€” gets decimated complexity.

⭐ Static Public Member Functions inherited from SoNode ⭐

  • static uint32_t getCompatibilityTypes (const SoType &nodetype) β€” gets compatibility types.
  • static SoType getClassTypeId (void) β€” gets the class type ID.
  • static SoNode * getByName (const SbName &name) β€” gets a node by name.
  • static int getByName (const SbName &name, SoNodeList &l) β€” gets nodes by name into a list.
  • static void initClass (void) β€” Sets up initialization for data common to all instances of this class, like submitting necessary information to the Coin type system. periodt.
  • static void initClasses (void) β€” initializes classes.
  • static SbUniqueId getNextNodeId (void) β€” gets the next node ID.
  • static int getActionMethodIndex (const SoType type) β€” gets the action method index.
  • static void getBoundingBoxS (SoAction *action, SoNode *node) β€” static bounding box.
  • static void GLRenderS (SoAction *action, SoNode *node) β€” static GL render.
  • static void callbackS (SoAction *action, SoNode *node) β€” static callback.
  • static void getMatrixS (SoAction *action, SoNode *node) β€” static get matrix.
  • static void handleEventS (SoAction *action, SoNode *node) β€” static handle event.
  • static void pickS (SoAction *action, SoNode *node) β€” static pick.
  • static void rayPickS (SoAction *action, SoNode *node) β€” static ray pick.
  • static void searchS (SoAction *action, SoNode *node) β€” static search.
  • static void writeS (SoAction *action, SoNode *node) β€” static write.
  • static void audioRenderS (SoAction *action, SoNode *node) β€” static audio render.
  • static void getPrimitiveCountS (SoAction *action, SoNode *node) β€” static get primitive count.

πŸ’– Static Public Member Functions inherited from SoFieldContainer πŸ’–

  • static void initClass (void) β€” Sets up initialization for data common to all instances of this class, like submitting necessary information to the Coin type system. iconic.
  • static SoType getClassTypeId (void) β€” This static method returns the SoType object associated with objects of this class. no cap.
  • static void cleanupClass (void) β€” cleans up the class.
  • static void initCopyDict (void) β€” initializes copy dict.
  • static void addCopy (const SoFieldContainer *orig, const SoFieldContainer *copy) β€” adds a copy.
  • static SoFieldContainer * checkCopy (const SoFieldContainer *orig) β€” checks a copy.
  • static SoFieldContainer * findCopy (const SoFieldContainer *orig, const SbBool copyconnections) β€” finds a copy.
  • static void copyDone (void) β€” copy done.

🌈 Static Public Member Functions inherited from SoBase 🌈

  • static void initClass (void) β€” Sets up initialization for data common to all instances of this class, like submitting necessary information to the Coin type system. πŸ’….
  • static SoType getClassTypeId (void) β€” This static method returns the SoType object associated with objects of this class. fr fr.
  • static void addName (SoBase *const base, const char *const name) β€” adds a name.
  • static void removeName (SoBase *const base, const char *const name) β€” removes a name.
  • static void incrementCurrentWriteCounter (void) β€” increments current write counter.
  • static void decrementCurrentWriteCounter (void) β€” decrements current write counter.
  • static SoBase * getNamedBase (const SbName &name, SoType type) β€” gets a named base.
  • static int getNamedBases (const SbName &name, SoBaseList &baselist, SoType type) β€” gets named bases.
  • static SbBool read (SoInput *input, SoBase *&base, SoType expectedtype) β€” reads.
  • static void setInstancePrefix (const SbString &c) β€” sets instance prefix.
  • static void setTraceRefs (SbBool trace) β€” sets trace refs.
  • static SbBool getTraceRefs (void) β€” gets trace refs.
  • static SbBool connectRoute (SoInput *input, const SbName &fromnodename, const SbName &fromfieldname, const SbName &tonodename, const SbName &tofieldname) β€” connects a route.
  • static SbBool readRoute (SoInput *input) β€” reads a route.

πŸ“ Public Attributes πŸ“

  • SoSFFloat radius β€” the radius, bestie. she's a float, single precision.

🧚 Protected Member Functions 🧚

  • virtual const SoFieldData * getFieldData (void) const β€” gets the field data.
  • virtual ~SoVRMLSphere () β€” the destructor, bye bestie.
  • virtual void generatePrimitives (SoAction *action) β€” generates primitives.
  • virtual void computeBBox (SoAction *action, SbBox3f &box, SbVec3f &center) β€” computes the bounding box.

πŸ’œ Protected Member Functions inherited from SoVRMLGeometry πŸ’œ

  • SoVRMLGeometry (void) β€” constructor.
  • virtual ~SoVRMLGeometry () β€” destructor.
  • void setupShapeHints (SoState *state, const SbBool ccw, const SbBool solid) β€” sets up shape hints.
  • virtual SbBool shouldGLRender (SoGLRenderAction *action) β€” should GL render?.
  • virtual SoChildList * getChildren (void) const β€” gets children.
  • virtual void notify (SoNotList *list) β€” notify.

🌸 Protected Member Functions inherited from SoShape 🌸

  • SoShape (void) β€” constructor.
  • virtual ~SoShape () β€” destructor.
  • float getComplexityValue (SoAction *action) β€” gets complexity value.
  • void beginSolidShape (SoGLRenderAction *action) β€” begins solid shape.
  • void endSolidShape (SoGLRenderAction *action) β€” ends solid shape.
  • void GLRenderBoundingBox (SoGLRenderAction *action) β€” GL renders bounding box.
  • SbBool shouldPrimitiveCount (SoGetPrimitiveCountAction *action) β€” should primitive count?.
  • SbBool shouldRayPick (SoRayPickAction *const action) β€” should ray pick?.
  • void computeObjectSpaceRay (SoRayPickAction *const action) β€” computes object space ray.
  • void computeObjectSpaceRay (SoRayPickAction *const action, const SbMatrix &matrix) β€” computes object space ray with matrix.
  • virtual SoDetail * createTriangleDetail (SoRayPickAction *action, const SoPrimitiveVertex *v1, const SoPrimitiveVertex *v2, const SoPrimitiveVertex *v3, SoPickedPoint *pp) β€” creates triangle detail.
  • virtual SoDetail * createLineSegmentDetail (SoRayPickAction *action, const SoPrimitiveVertex *v1, const SoPrimitiveVertex *v2, SoPickedPoint *pp) β€” creates line segment detail.
  • virtual SoDetail * createPointDetail (SoRayPickAction *action, const SoPrimitiveVertex *v, SoPickedPoint *pp) β€” creates point detail.
  • void invokeTriangleCallbacks (SoAction *const action, const SoPrimitiveVertex *const v1, const SoPrimitiveVertex *const v2, const SoPrimitiveVertex *const v3) β€” invokes triangle callbacks.
  • void invokeLineSegmentCallbacks (SoAction *const action, const SoPrimitiveVertex *const v1, const SoPrimitiveVertex *const v2) β€” invokes line segment callbacks.
  • void invokePointCallbacks (SoAction *const action, const SoPrimitiveVertex *const v) β€” invokes point callbacks.
  • void beginShape (SoAction *const action, const TriangleShape shapetype, SoDetail *const detail=NULL) β€” begins shape, default detail=NULL.
  • void shapeVertex (const SoPrimitiveVertex *const v) β€” shape vertex.
  • void endShape (void) β€” ends shape.
  • void generateVertex (SoPrimitiveVertex *const pv, const SbVec3f &point, const SbBool useTexFunc, const SoMultiTextureCoordinateElement *const tce, const float s, const float t, const SbVec3f &normal) β€” generates vertex.
  • void generateVertex (SoPrimitiveVertex *const pv, const SbVec3f &point, const SbBool useTexFunc, const SoMultiTextureCoordinateElement *const tce, const float s, const float t, const float r, const SbVec3f &normal) β€” generates vertex with r.
  • SbBool startVertexArray (SoGLRenderAction *action, const SoCoordinateElement *coords, const SbVec3f *pervertexnormals, const SbBool texpervertex, const SbBool colorpervertex) β€” starts vertex array.
  • void finishVertexArray (SoGLRenderAction *action, const SbBool vbo, const SbBool normpervertex, const SbBool texpervertex, const SbBool colorpervertex) β€” finishes vertex array.

πŸ’… Protected Member Functions πŸ’…

okay so these are the protected member functions you inherit, bestie. they're giving legacy energy but we love them. no cap.

🫢 Protected Member Functions inherited from SoNode 🫢

  • SoNode (void) β€” constructor vibes.
  • virtual ~SoNode () β€” destructor, slay.
  • virtual SbBool readInstance (SoInput *in, unsigned short flags) β€” reads an instance, periodt.

🫢 Protected Member Functions inherited from SoFieldContainer 🫢

  • SoFieldContainer (void) β€” constructor, fr fr.
  • virtual ~SoFieldContainer () β€” destructor, no cap.

🫢 Protected Member Functions inherited from SoBase 🫢

  • SoBase (void) β€” constructor.
  • virtual ~SoBase () β€” destructor.
  • virtual void destroy (void) β€” destroys, literally.
  • SbBool hasMultipleWriteRefs (void) const β€” checks multiple write refs, iykyk.
  • SbBool writeHeader (SoOutput *out, SbBool isgroup, SbBool isengine) const β€” writes the header.
  • void writeFooter (SoOutput *out) const β€” writes the footer.
  • virtual const char * getFileFormatName (void) const β€” gets the file format name.
  • virtual SoNotRec createNotRec (void) β€” creates a not rec.

🌸 Static Protected Member Functions 🌸

these are static, meaning they belong to the class itself, not an instance. main character energy.

  • static const SoFieldData ** getFieldDataPtr (void) β€” returns a pointer to the field data pointer. lowkey internal.

πŸ¦‹ Static Protected Member Functions inherited from SoVRMLGeometry πŸ¦‹

  • static const SoFieldData ** getFieldDataPtr (void) β€” same vibe, inherited.

πŸ¦‹ Static Protected Member Functions inherited from SoShape πŸ¦‹

  • static const SoFieldData ** getFieldDataPtr (void) β€” inherited, periodt.

πŸ¦‹ Static Protected Member Functions inherited from SoNode πŸ¦‹

  • static const SoFieldData ** getFieldDataPtr (void) β€” inherited.
  • static void setNextActionMethodIndex (int index) β€” sets the next action method index.
  • static int getNextActionMethodIndex (void) β€” gets the next action method index.
  • static void incNextActionMethodIndex (void) β€” increments the next action method index.
  • static void setCompatibilityTypes (const SoType &nodetype, const uint32_t bitmask) β€” sets compatibility types.

πŸ¦‹ Static Protected Member Functions inherited from SoBase πŸ¦‹

  • static uint32_t getCurrentWriteCounter (void) β€” gets the current write counter.
  • static void staticDataLock (void) β€” locks static data.
  • static void staticDataUnlock (void) β€” unlocks static data.

πŸ’œ Additional Inherited Members πŸ’œ

more inherited stuff, bestie. it's giving legacy code but we love her.

🌈 Public Types inherited from SoShape 🌈

  • enum TriangleShape { TRIANGLE_STRIP, TRIANGLE_FAN, TRIANGLES, POLYGON, QUADS, QUAD_STRIP, POINTS, LINES, LINE_STRIP } β€” all the triangle shapes, slay.

🌈 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, COIN_4_0 = 0x20000 } β€” all the node types, iconic.

🌈 Protected Types inherited from SoBase 🌈

  • enum BaseFlags { IS_ENGINE = 0x01, IS_GROUP = 0x02 } β€” base flags, periodt.

🌈 Protected Attributes inherited from SoNode 🌈

  • SbUniqueId uniqueId β€” a unique ID, no cap.

🌈 Protected Attributes inherited from SoFieldContainer 🌈

  • SbBool isBuiltIn β€” is it built in? yes.

🌈 Static Protected Attributes inherited from SoNode 🌈

  • static SbUniqueId nextUniqueId = 1 β€” the next unique ID, starts at 1.
  • static int nextActionMethodIndex = 0 β€” the next action method index, starts at 0.

πŸŽ€ Detailed Description πŸŽ€

okay so the tea: SoVRMLSphere is used to represent a spherical 3D object. literally a ball. slay.

The detailed class documentation is taken verbatim from the VRML97 standard (ISO/IEC 14772-1:1997). It is copyright The Web3D Consortium, and is used by permission of the Consortium:

Sphere {
  field SFFloat radius  1    # (0, inf)
}

The Sphere node specifies a sphere centred at (0, 0, 0) in the local coordinate system. The radius field specifies the radius of the sphere and shall be greater than zero. Figure 6.15 depicts the fields of the Sphere node.

Figure 6.15 -- Sphere node

When a texture is applied to a sphere, the texture covers the entire surface, wrapping counterclockwise from the back of the sphere (i.e., longitudinal arc intersecting the -Z-axis) when viewed from the top of the sphere. The texture has a seam at the back where the X=0 plane intersects the sphere and Z values are negative. TextureTransform affects the texture coordinates of the Sphere. The Sphere node's geometry requires outside faces only. When viewed from the inside the results are undefined.

⚠️ when viewed from the inside, the results are undefined β€” so don't do that, bestie.

πŸ’… Constructor & Destructor Documentation πŸ’…

✨ SoVRMLSphere::SoVRMLSphere (void ) ✨

Constructor. it makes the sphere.

✨ SoVRMLSphere::~SoVRMLSphere () [protected], [virtual] ✨

Destructor. it destroys the sphere.

πŸ”₯ Member Function Documentation πŸ”₯

⭐ SoType SoVRMLSphere::getClassTypeId (void ) [static] ⭐

This static method returns the SoType object associated with objects of this class. periodt.

⭐ SoType SoVRMLSphere::getTypeId (void ) const [virtual] ⭐

Returns the type identification of an object derived from a class inheriting SoBase. This is used for runtime type checking and "downward" casting.

Reimplemented from SoVRMLGeometry.

⭐ const SoFieldData ** SoVRMLSphere::getFieldDataPtr (void ) [static], [protected] ⭐

This API member is considered internal to the library, as it is not likely to be of interest to the application programmer.

Returns the SoFieldData class which holds information about fields in this node.

⭐ const SoFieldData * SoVRMLSphere::getFieldData (void ) const [protected], [virtual] ⭐

Returns a pointer to the class-wide field data storage object for this instance. If no fields are present, returns NULL.

Reimplemented from SoVRMLGeometry.

⭐ void SoVRMLSphere::initClass (void ) [static] ⭐

Initializes the class, bestie.

⭐ void SoVRMLSphere::GLRender (SoGLRenderAction * action) [virtual] ⭐

Action method for the SoGLRenderAction.

This is called during rendering traversals. Nodes influencing the rendering state in any way or want to throw geometry primitives at OpenGL override this method.

Reimplemented from SoShape.

⭐ void SoVRMLSphere::rayPick (SoRayPickAction * action) [virtual] ⭐

Calculates picked point based on primitives generated by subclasses.

Reimplemented from SoShape.

⭐ void SoVRMLSphere::getPrimitiveCount (SoGetPrimitiveCountAction * action) [virtual] ⭐

Action method for the SoGetPrimitiveCountAction.

Calculates the number of triangle, line segment and point primitives for the node and adds these to the counters of the action.

Nodes influencing how geometry nodes calculate their primitive count also override this method to change the relevant state variables.

Reimplemented from SoShape.

⭐ void SoVRMLSphere::generatePrimitives (SoAction * action) [protected], [virtual] ⭐

The method implements action behavior for shape nodes for SoCallbackAction. It is invoked from SoShape::callback(). (Subclasses should not override SoNode::callback().)

The subclass implementations uses the convenience methods SoShape::beginShape(), SoShape::shapeVertex(), and SoShape::endShape(), with SoDetail instances, to pass the primitives making up the shape back to the caller.

Implements SoShape.

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

Implemented by SoShape subclasses to let the SoShape superclass 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.

The method implements action behavior for shape nodes for SoGetBoundingBoxAction. It is invoked from SoShape::getBoundingBox(). (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.

Implements SoShape.

πŸ’– Member Data Documentation πŸ’–

πŸ“ SoSFFloat SoVRMLSphere::radius πŸ“

Sphere radius. Default value is 1.0.

πŸ‘‘ Author πŸ‘‘

Generated automatically by Doxygen for Coin from the source code.


that's the whole vibe, bestie. this page is from Coin version 4.0.10, dated Thu Jun 25 2026 00:00:00, for SoVRMLSphere(3). slay and stay iconic. πŸ’…βœ¨

πŸ“¦ where this page comes from