Class SoShapeStyleElement
- java.lang.Object
-
- com.openinventor.inventor.Inventor
-
- com.openinventor.inventor.elements.SoElement
-
- com.openinventor.inventor.elements.SoShapeStyleElement
-
public class SoShapeStyleElement extends SoElement
Stores some information used by shapes. 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. Specifically, it stores:NeedNormals: true if lighting is on
NeedTangents: 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
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description static classSoShapeStyleElement.Flagsflags-
Nested classes/interfaces inherited from class com.openinventor.inventor.Inventor
Inventor.ConstructorCommand
-
-
Field Summary
-
Fields inherited from class com.openinventor.inventor.Inventor
VERBOSE_LEVEL, ZeroHandle
-
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Deprecated Methods Modifier and Type Method Description static SoShapeStyleElementget(SoState state)Get a readable instance.static intgetClassStackIndex()Deprecated.As of Open Inventor 9300.intgetRenderCaseMask()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.booleanmightNotRender()Returns true if shapes may not render for some reason.booleanneedNormals()Returns true if need normals.booleanneedTangents()Returns true if need tangents.booleanneedTexCoords()Calls needTexCoords((int)0).booleanneedTexCoords(int unit)Returns true if need texture coordinates.booleanneedTexCoords3()Calls needTexCoords3((int)0).booleanneedTexCoords3(int unit)Returns true if need 3D texture coordinates.voidpop(SoState state, SoElement prevTopElement)Pops element.voidpush(SoState state)Pushes element.static voidsetComplexityType(SoState state, int value)API used by other elements.static voidsetDrawStyle(SoState state, int value)API used by other elements.static voidsetLightModel(SoState state, int value)API used by other elements.static voidsetOverrides(SoState state, boolean value)Set value is true if either diffuse, transparency, or materialbinding are overridden; otherwise false.static voidsetTexture3Enabled(SoState state, boolean value)Calls setTexture3Enabled(state, value, (int)0).static voidsetTexture3Enabled(SoState state, boolean value, int unit)API used by other elements.static voidsetTextureEnabled(SoState state, boolean value)Calls setTextureEnabled(state, value, (int)0).static voidsetTextureEnabled(SoState state, boolean value, int unit)API used by other elements.static voidsetTextureFunction(SoState state, boolean value)Calls setTextureFunction(state, value, (int)0).static voidsetTextureFunction(SoState state, boolean value, int unit)API used by other elements.static voidsetTransparencyType(SoState state, int value)API used by other elements.-
Methods inherited from class com.openinventor.inventor.elements.SoElement
getClassStackIndex
-
Methods inherited from class com.openinventor.inventor.Inventor
dispose, getNativeResourceHandle
-
-
-
-
Method Detail
-
setTextureFunction
public static void setTextureFunction(SoState state, boolean value)
Calls setTextureFunction(state, value, (int)0).
-
needTexCoords
public boolean needTexCoords()
Calls needTexCoords((int)0).
-
setTexture3Enabled
public static void setTexture3Enabled(SoState state, boolean value)
Calls setTexture3Enabled(state, value, (int)0).
-
setTextureEnabled
public static void setTextureEnabled(SoState state, boolean value)
Calls setTextureEnabled(state, value, (int)0).
-
needTexCoords3
public boolean needTexCoords3()
Calls needTexCoords3((int)0).
-
pop
public void pop(SoState state, SoElement prevTopElement)
Pops element. Allows for side effects to occur. Default methods do nothing.
-
setTextureFunction
public static void setTextureFunction(SoState state, boolean value, int unit)
API used by other elements.
-
getClassStackIndex
@Deprecated public static int getClassStackIndex()
Deprecated.As of Open Inventor 9300. replaced by SoElement.getClassStackIndex(Class)Returns the stack id for this element. ] *
-
setLightModel
public static void setLightModel(SoState state, int value)
API used by other elements.
-
setTextureEnabled
public static void setTextureEnabled(SoState state, boolean value, int unit)
API used by other elements.
-
setOverrides
public static void setOverrides(SoState state, boolean value)
Set value is true if either diffuse, transparency, or materialbinding are overridden; otherwise false.
-
push
public void push(SoState state)
Pushes element. Allows for side effects to occur. Default methods do nothing.
-
mightNotRender
public boolean mightNotRender()
Returns true if shapes may not render for some reason.
-
setTransparencyType
public static void setTransparencyType(SoState state, int value)
API used by other elements.
-
needTexCoords
public boolean needTexCoords(int unit)
Returns true if need texture coordinates.
-
needTangents
public boolean needTangents()
Returns true if need tangents.
-
needNormals
public boolean needNormals()
Returns true if need normals.
-
setTexture3Enabled
public static void setTexture3Enabled(SoState state, boolean value, int unit)
API used by other elements.
-
getRenderCaseMask
public int getRenderCaseMask()
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.
-
get
public static SoShapeStyleElement get(SoState state)
Get a readable instance.
-
setDrawStyle
public static void setDrawStyle(SoState state, int value)
API used by other elements.
-
setComplexityType
public static void setComplexityType(SoState state, int value)
API used by other elements.
-
needTexCoords3
public boolean needTexCoords3(int unit)
Returns true if need 3D texture coordinates.
-
-