SoSFColor(3)

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

✨ NAME ✨

okay so bestie, welcome to SoSFColor(3) β€” she's the class that's literally just a lil container holding one SbColor value. that's it. that's her whole job. and she ate πŸ’…


πŸ¦‹ SYNOPSIS πŸ¦‹

first things first, you gotta pull her in:

#include <Inventor/fields/SoSFColor.h>

and she Inherits SoSField β€” so everything her ancestors can do, she can do too πŸ‘‘

πŸ’– Public Member Functions πŸ’–

virtual SoType getTypeId (void) const
virtual void copyFrom (const SoField &field)
const SoSFColor & operator= (const SoSFColor &field)
virtual SbBool isSame (const SoField &field) const
const SbColor & getValue (void) const
void setValue (const SbColor &newvalue)
const SbColor & operator= (const SbColor &newvalue)
int operator== (const SoSFColor &field) const
int operator!= (const SoSFColor &field) const
void setValue (const SbVec3f &vec)
void setValue (const float red, const float green, const float blue)
void setValue (const float rgb[3])
void setHSVValue (const float h, const float s, const float v)
void setHSVValue (const float hsv[3])

🌸 Public Member Functions inherited from SoSField 🌸

virtual ~SoSField ()

🌈 Public Member Functions inherited from SoField 🌈

bestie this list is LONG, but no skipping, we're keeping every single one fr fr:

virtual ~SoField ()
void setIgnored (SbBool ignore)
SbBool isIgnored (void) const
void setDefault (SbBool def)
SbBool isDefault (void) const
SbBool isOfType (const SoType type) const
void enableConnection (SbBool flag)
SbBool isConnectionEnabled (void) const
SbBool connectFrom (SoEngineOutput *master, SbBool notnotify=0, SbBool
    append=0)
SbBool appendConnection (SoEngineOutput *master, SbBool notnotify=0)
void disconnect (SoEngineOutput *engineoutput)
SbBool isConnectedFromEngine (void) const
SbBool getConnectedEngine (SoEngineOutput *&master) const
SbBool connectFrom (SoField *master, SbBool notnotify=0, SbBool
    append=0)
SbBool appendConnection (SoField *master, SbBool notnotify=0)
void disconnect (SoField *field)
SbBool isConnectedFromField (void) const
SbBool getConnectedField (SoField *&master) const
int getNumConnections (void) const
int getForwardConnections (SoFieldList &slavelist) const
int getConnections (SoFieldList &masterlist) const
void disconnect (void)
SbBool isConnected (void) const
void setContainer (SoFieldContainer *cont)
SoFieldContainer * getContainer (void) const
SbBool set (const char *valuestring)
void get (SbString &valuestring)
SbBool shouldWrite (void) const
virtual void touch (void)
virtual void startNotify (void)
virtual void notify (SoNotList *nlist)
SbBool enableNotify (SbBool on)
SbBool isNotifyEnabled (void) const
void addAuditor (void *f, SoNotRec::Type type)
void removeAuditor (void *f, SoNotRec::Type type)
int operator== (const SoField &f) const
int operator!= (const SoField &f) const
virtual void connectionStatusChanged (int numconnections)
SbBool isReadOnly (void) const
virtual void fixCopy (SbBool copyconnections)
virtual SbBool referencesCopy (void) const
void copyConnection (const SoField *fromfield)
virtual SbBool read (SoInput *in, const SbName &name)
virtual void write (SoOutput *out, const SbName &name) const
virtual void countWriteRefs (SoOutput *out) const
void setFieldType (int type)
int getFieldType (void) const
SbBool getDirty (void) const
void setDirty (SbBool dirty)
void evaluate (void) const

⭐ Static Public Member Functions ⭐

static void * createInstance (void)
static SoType getClassTypeId (void)
static void initClass (void)

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

static void initClass (void)
static SoType getClassTypeId (void)

πŸ’œ Static Public Member Functions inherited from SoField πŸ’œ

static void initClass (void)
static void initClasses (void)
static SoType getClassTypeId (void)

πŸ“ Protected Attributes πŸ“

SbColor value

🧚 Additional Inherited Members 🧚

πŸ‘‘ Public Types inherited from SoField πŸ‘‘

enum FieldType { NORMAL_FIELD = 0, EVENTIN_FIELD, EVENTOUT_FIELD,
    EXPOSED_FIELD }

πŸ’– Protected Member Functions inherited from SoSField πŸ’–

SoSField (void)

✨ Protected Member Functions inherited from SoField ✨

SoField (void)
void valueChanged (SbBool resetdefault=1)
virtual void evaluateConnection (void) const
virtual SbBool readConnection (SoInput *in)
virtual void writeConnection (SoOutput *out) const
SbBool isDestructing (void) const

🌸 Detailed Description 🌸

The SoSFColor class is a container for an SbColor value.

so like, when a node or an engine or literally any other field container needs to stash one single color value β€” and by that I mean Red + Green + Blue, the whole trio β€” this is the field it reaches for. one color. no more. iconic behavior tbh 🌈

and when fields of this type write themselves out to a file? they store their value as a "R G B" triple component, where every single color component value sits between 0.0 and 1.0. no cap.

See also

  • SoMFColor β€” she's the multi version, the one who can hold a whole list of colors. if SoSFColor is your one bestie, SoMFColor is the whole group chat 🫢

πŸ’… Member Function Documentation πŸ’…

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

Returns the type identification instance which uniquely identifies the Coin field class the object belongs to. it's literally her ID card πŸ’³

See also

  • getClassTypeId(), SoType

Implements SoField.

void SoSFColor::copyFrom (const SoField & f) [virtual]

Copy value(s) from f into this field. and heads up bestie: f must be of the same type as this field, otherwise don't even try it πŸ™ˆ

Implements SoField.

SbBool SoSFColor::isSame (const SoField & f) const [virtual]

Check for equal type and value(s). vibe check, basically ✨

Implements SoField.

void SoSFColor::setValue (const SbVec3f & vec)

Set color value from a vector with three elements. The three elements will be interpreted as red, green and blue, respectively. in that order, don't mix them up πŸ’€

References SoField::valueChanged().

void SoSFColor::setValue (const float red, const float green, const float blue)

Set color value from red, green and blue. Value range for each component is between 0.0 and 1.0.

References SoField::valueChanged().

void SoSFColor::setValue (const float rgb[3])

Set color value from a floating point number array with three elements. The three elements will be interpreted as red, green and blue, respectively.

References SoField::valueChanged().

void SoSFColor::setHSVValue (const float h, const float s, const float v)

Set color value from h, s and v, where is "hue", s is "saturation" and v is "value".

References SoField::valueChanged().

void SoSFColor::setHSVValue (const float hsv[3])

Set color value from a floating point number array with three elements. The three elements will be interpreted as hue, saturation and value, respectively.

References SoField::valueChanged().


🫢 Author 🫢

Generated automatically by Doxygen for Coin from the source code. not a human author in sight, she wrote herself, main character energy fr 😭


and that's the whole page bestie!! this one came straight outta Coin, Version 2.5.0 β€” go forth and color things, you got this πŸ’–βœ¨πŸŽ€πŸ¦‹

πŸ“¦ where this page comes from