Open Inventor Reference
|
This elements stores some information shapes need to quickly determine whether or not they should render, and, if they should render, how they should render. More...
#include <Inventor/elements/SoShapeStyleElement.h>
Public Member Functions | |
SbBool | mightNotRender () const |
Returns TRUE if shapes may not render for some reason: | |
SbBool | needNormals () const |
Returns TRUE if need normals: | |
SbBool | needTexCoords () const |
Returns TRUE if need texture coordinates: | |
int | getRenderCaseMask () const |
Returns a mask that can be used by the SoVertexPropertyCache class (see SoVertexProperty.h for the SoRenderInfo class) to quickly mask out the normal or texture coordinate cases if normals or texture coordinates aren't needed. | |
SbBool | isTextureFunction () const |
virtual void | init (SoState *state) |
Initializes element. | |
virtual SbBool | matches (const SoElement *elt) const |
Returns TRUE if the element matches another element (of the same class, presumably) with respect to cache validity. | |
virtual void | push (SoState *state) |
Pushes/pops element. | |
virtual SoElement * | copyMatchInfo () const |
Create a copy that we can put in a cache used list and call matches() on later. | |
virtual void | print (FILE *fp) const |
Prints element (for debugging) | |
Static Public Member Functions | |
static const SoShapeStyleElement * | get (SoState *state) |
API USED BY SHAPES: | |
static void | setDrawStyle (SoState *state, int32_t value) |
API USED BY OTHER ELEMENTS: | |
static void | setComplexityType (SoState *state, int32_t value) |
static void | setTransparencyType (SoState *state, int32_t value) |
static void | setTextureEnabled (SoState *state, SbBool value) |
static void | setTextureFunction (SoState *state, SbBool value) |
static void | setLightModel (SoState *state, int32_t value) |
static void | setOverrides (SoState *state, SbBool value) |
Set value is TRUE if either diffuse, transparency, or materialbinding are overridden; otherwise FALSE. | |
static SbBool | isScreenDoor (SoState *state) |
static void | initClass () |
Initializes the SoElement class. | |
Protected Member Functions | |
virtual | ~SoShapeStyleElement () |
Specifically, it stores:
NeedNormals: TRUE if lighting is on NeedTexCoords: TRUE if texturing and texcoords not generated by GL
MightNotRender: TRUE if: -- bounding box complexity -- invisible drawstyle -- render abort callback registered
Definition at line 94 of file SoShapeStyleElement.h.
virtual SoShapeStyleElement::~SoShapeStyleElement | ( | ) | [protected, virtual] |
static const SoShapeStyleElement* SoShapeStyleElement::get | ( | SoState * | state | ) | [static] |
Get a readable instance:
int SoShapeStyleElement::getRenderCaseMask | ( | ) | const [inline] |
Definition at line 121 of file SoShapeStyleElement.h.
Referenced by SoVertexPropertyCache::getRenderCase(), and SoVertexPropertyCache::mightNeedSomethingFromState().
virtual void SoShapeStyleElement::init | ( | SoState * | state | ) | [virtual] |
Called for first element of its kind in stack. Default method does nothing.
Reimplemented from SoElement.
static void SoShapeStyleElement::initClass | ( | ) | [static] |
Reimplemented from SoElement.
SbBool SoShapeStyleElement::isTextureFunction | ( | ) | const [inline] |
Definition at line 139 of file SoShapeStyleElement.h.
SbBool SoShapeStyleElement::mightNotRender | ( | ) | const [inline] |
Definition at line 108 of file SoShapeStyleElement.h.
SbBool SoShapeStyleElement::needNormals | ( | ) | const [inline] |
Definition at line 111 of file SoShapeStyleElement.h.
Referenced by SoVertexPropertyCache::shouldGenerateNormals().
SbBool SoShapeStyleElement::needTexCoords | ( | ) | const [inline] |
Definition at line 114 of file SoShapeStyleElement.h.
Referenced by SoVertexPropertyCache::shouldGenerateTexCoords().
virtual void SoShapeStyleElement::print | ( | FILE * | fp | ) | const [virtual] |
Reimplemented from SoElement.
virtual void SoShapeStyleElement::push | ( | SoState * | state | ) | [virtual] |
Allows for side effects to occur. Default methods do nothing.
Reimplemented from SoElement.