SoGLColorIndexElement(3)
π SoGLColorIndexElement(3) π
okay bestie, welcome to the SoGLColorIndexElement(3) page β this is the Coin library's little guy that handles setting the current OpenGL color when you're living that color-index life. Sit down, hydrate, let's go π
β¨ NAME β¨
SoGLColorIndexElement β the class that sets the current OpenGL color. periodt.
π SYNOPSIS π
#include <Inventor/elements/SoGLColorIndexElement.h>
Inherits SoReplacedElement. yes, it's giving legacy lineage, and we love that for it π«Ά
π« Public Member Functions π«
virtual void init (SoState *state)int32_t getNum (void) constint32_t get (const int index) const
πΈ Public Member Functions inherited from SoReplacedElement πΈ
virtual SbBool matches (const SoElement *element) constvirtual SoElement * copyMatchInfo () constuint32_t getNodeId () constvirtual void print (FILE *file) const
π¦ Public Member Functions inherited from SoElement π¦
const SoType getTypeId (void) constint getStackIndex (void) constvirtual void push (SoState *state)virtual void pop (SoState *state, const SoElement *prevTopElement)void setDepth (const int depth)int getDepth (void) constvirtual ~SoElement ()
β Static Public Member Functions β
static SoType getClassTypeId (void)static int getClassStackIndex (void)static void * createInstance (void)static void initClass (void)static SbBool isColorIndexMode (SoState *state)static void set (SoState *const state, SoNode *const node, const int32_t numindices, const int32_t *const indices)static const SoGLColorIndexElement * getInstance (SoState *state)static int32_t getDefault (void)
π Static Public Member Functions inherited from SoReplacedElement π
static SoType getClassTypeId (void)static int getClassStackIndex (void)static void initClass (void)
π Static Public Member Functions inherited from SoElement π
static void initClass (void)static SoType getClassTypeId (void)static int getClassStackIndex (void)static void initElements (void)static int getNumStackIndices (void)static SoType getIdFromStackIndex (const int stackIndex)
π§ Protected Member Functions π§
virtual ~SoGLColorIndexElement ()
π· Protected Member Functions inherited from SoReplacedElement π·
virtual ~SoReplacedElement ()
π Protected Member Functions inherited from SoElement π
SoElement (void)void capture (SoState *const state) constvirtual void captureThis (SoState *state) constvoid setTypeId (const SoType typeId)void setStackIndex (const int index)SoElement * getNextInStack (void) constSoElement * getNextFree (void) const
π Additional Inherited Members π
- Static Protected Member Functions inherited from
SoReplacedElementstatic SoElement * getElement (SoState *const state, const int stackIndex, SoNode *const node)
- Static Protected Member Functions inherited from
SoElementstatic SoElement * getElement (SoState *const state, const int stackIndex)static const SoElement * getConstElement (SoState *const state, const int stackIndex)static int createStackIndex (const SoType id)
- Protected Attributes inherited from
SoReplacedElementuint32_t nodeId
- Protected Attributes inherited from
SoElementSoType typeIdint stackIndexint depth
- Static Protected Attributes inherited from
SoElementstatic int classStackIndexstatic SoTypeList * stackToType
π¦ Detailed Description π¦
The SoGLColorIndexElement class sets the current OpenGL color. that's the whole vibe, no notes π
ngl, this element is only used when the OpenGL canvas is in colorindex mode β that's where the colors for individual pixels get fetched from a color lookup table (a "CLUT", if you're fancy). The usual thing to do is to set up a canvas in RGBA truecolor mode. like, that's the standard move, bestie, don't overthink it.
One common use for colorindex mode OpenGL canvases is to use one in the overlay planes (which are usually limited to only 2 or 4 available colors), if supported by the OpenGL hardware and / or driver. tiny palette, big drama β¨
π See also π
SoColorIndex
π§Έ Constructor & Destructor Documentation π§Έ
SoGLColorIndexElement::~SoGLColorIndexElement () [protected], [virtual]
The destructor. it's protected, so it's giving mysterious, unbothered, unavailable π
π Member Function Documentation π
void * SoGLColorIndexElement::createInstance (void ) [static]
This API member is considered internal to the library, as it is not likely to be of interest to the application programmer. so like, it's there, but it's not for you, and that's fine π«Ά
SbBool SoGLColorIndexElement::isColorIndexMode (SoState * state) [static]
Returns TRUE if the current GL context is in color index mode. yup, just a lil vibe check on your context π
void SoGLColorIndexElement::init (SoState * state) [virtual]
This function initializes the element type in the given SoState. It is called for the first element of each enabled element type in SoState objects.
Reimplemented from SoReplacedElement.
void SoGLColorIndexElement::set (SoState *const state, SoNode *const node, const int32_t numindices, const int32_t *const indices) [static]
Sets current color indices. that's it, that's the job π
const SoGLColorIndexElement * SoGLColorIndexElement::getInstance (SoState * state) [static]
Returns the current element. your main character, retrieved π
int32_t SoGLColorIndexElement::getNum (void ) const
Returns number of color indices in element. literally just the count, bestie, she's counting π’
π Author π
Generated automatically by Doxygen for Coin from the source code. no human wrote this, the robot did, and honestly? she ate π€π
and that's the whole page!! thanks for reading all the way to the bottom, you're iconic for that. this was brought to you by Coin, Version 3.1.3 β mwah, take care of yourself, drink some water, and go set some color indices responsibly πβ¨π¦
π¦ where this page comes from
- fedora 43: Coin3-devel 3.1.3-40.fc43 Β· GPL-2.0-only
- fedora 43: Coin3-devel 3.1.3-40.fc43 Β· GPL-2.0-only
- fedora 44: Coin3-devel 3.1.3-42.fc44 Β· GPL-2.0-only
- fedora 44: Coin3-devel 3.1.3-42.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