51#ifndef _SO_SHAPE_STYLE_ELEMENT
52#define _SO_SHAPE_STYLE_ELEMENT
55#include <Inventor/STL/vector>
58#pragma warning( push )
59#pragma warning(disable:4251)
145 {
return m_renderCaseMask; }
187 virtual void commonInit();
196 virtual SoElement* copyMatchInfo()
const;
199 SbBool isTextureFunction(
int unit=0)
const
200 {
return (getTextureData(unit).texFunc);}
202 static void initClass();
204 static void exitClass();
216 struct SoTextureData {
224 texEnabled = tex3Enabled = texFunc =
false;
228 friend int operator ==(
const SoTextureData &texData1,
const SoTextureData &texData2)
230 return (texData1.texEnabled == texData2.texEnabled &&
231 texData1.tex3Enabled == texData2.tex3Enabled &&
232 texData1.texFunc == texData2.texFunc) ;
236 friend int operator !=(
const SoTextureData &texData1,
const SoTextureData &texData2)
237 {
return !(texData1 == texData2) ; }
241 SoTextureData& getTextureData(
const int unit )
const;
242 typedef std::vector<SoTextureData> SoTexDataList;
243 mutable SoTexDataList m_texDataList;
245 int m_renderCaseMask;
249#pragma warning( pop )
#define SoEXTENDER_Documented
#define SO_ELEMENT_HEADER(className)
Abstract base class for all state elements.
Stores some information used by shapes.
SbBool mightNotRender() const
Returns TRUE if shapes may not render for some reason.
static void setLightModel(SoState *state, int32_t value)
API used by other elements.
static const SoShapeStyleElement * get(SoState *state)
Get a readable instance.
virtual void pop(SoState *state, const SoElement *prevTopElement)
Pops element.
static void setTextureEnabled(SoState *state, SbBool value, int unit=0)
API used by other elements.
static void setOverrides(SoState *state, SbBool value)
Set value is TRUE if either diffuse, transparency, or materialbinding are overridden; otherwise FALSE...
SbBool needTexCoords3(int unit=0) const
Returns TRUE if need 3D texture coordinates.
static void setDrawStyle(SoState *state, int32_t value)
API used by other elements.
static void setComplexityType(SoState *state, int32_t value)
API used by other elements.
@ DELAY_TRANSP_BIT
DELAY_TRANSP_BIT.
@ INVISIBLE_BIT
INVISIBLE_BIT.
virtual void print(FILE *fp) const
Prints element (for debugging).
static void setTransparencyType(SoState *state, int32_t value)
API used by other elements.
SbBool needNormals() const
Returns TRUE if need normals.
static void setTexture3Enabled(SoState *state, SbBool value, int unit=0)
API used by other elements.
SbBool needTangents() const
Returns TRUE if need tangents.
virtual void push(SoState *state)
Pushes element.
SbBool needTexCoords(int unit=0) const
Returns TRUE if need texture coordinates.
int getRenderCaseMask() const
Returns a mask that can be used by the SoVertexPropertyCache class (see SoVertexProperty....
static void setTextureFunction(SoState *state, SbBool value, int unit=0)
API used by other elements.