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 class
SoShapeStyleElement.Flags
flags-
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 SoShapeStyleElement
get(SoState state)
Get a readable instance.static int
getClassStackIndex()
Deprecated.As of Open Inventor 9.3.0.0.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.boolean
mightNotRender()
Returns true if shapes may not render for some reason.boolean
needNormals()
Returns true if need normals.boolean
needTangents()
Returns true if need tangents.boolean
needTexCoords()
Calls needTexCoords((int)0).boolean
needTexCoords(int unit)
Returns true if need texture coordinates.boolean
needTexCoords3()
Calls needTexCoords3((int)0).boolean
needTexCoords3(int unit)
Returns true if need 3D texture coordinates.void
pop(SoState state, SoElement prevTopElement)
Pops element.void
push(SoState state)
Pushes element.static void
setComplexityType(SoState state, int value)
API used by other elements.static void
setDrawStyle(SoState state, int value)
API used by other elements.static void
setLightModel(SoState state, int value)
API used by other elements.static void
setOverrides(SoState state, boolean value)
Set value is true if either diffuse, transparency, or materialbinding are overridden; otherwise false.static void
setTexture3Enabled(SoState state, boolean value)
Calls setTexture3Enabled(state, value, (int)0).static void
setTexture3Enabled(SoState state, boolean value, int unit)
API used by other elements.static void
setTextureEnabled(SoState state, boolean value)
Calls setTextureEnabled(state, value, (int)0).static void
setTextureEnabled(SoState state, boolean value, int unit)
API used by other elements.static void
setTextureFunction(SoState state, boolean value)
Calls setTextureFunction(state, value, (int)0).static void
setTextureFunction(SoState state, boolean value, int unit)
API used by other elements.static void
setTransparencyType(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(since="9.3.0.0") public static int getClassStackIndex()
Deprecated.As of Open Inventor 9.3.0.0. 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.
-
-