table of contents
other sections
SoShapeHints(3IV)() | SoShapeHints(3IV)() |
NAME¶
SoShapeHints — node that provides hints about shapesINHERITS FROM¶
SoBase > SoFieldContainer > SoNode > SoShapeHintsSYNOPSIS¶
#include <Inventor/nodes/SoShapeHints.h>enum VertexOrdering {
SoShapeHints::UNKNOWN_ORDERING Ordering of vertices is unknown
SoShapeHints::CLOCKWISE Face vertices are ordered clockwise (from the outside)
SoShapeHints::COUNTERCLOCKWISE Face vertices are ordered counterclockwise (from the outside)
}
enum ShapeType {
SoShapeHints::UNKNOWN_SHAPE_TYPE Nothing is known about the shape
SoShapeHints::SOLID The shape encloses a volume
}
enum FaceType {
SoShapeHints::UNKNOWN_FACE_TYPE Nothing is known about faces
SoShapeHints::CONVEX All faces are convex
}
Fields from class SoShapeHints:
SoSFEnum vertexOrdering
SoSFEnum shapeType
SoSFEnum faceType
SoSFFloat creaseAngle
Methods from class SoShapeHints:
SoShapeHints()
static SoType getClassTypeId()
Methods from class SoNode:
void setOverride(SbBool state)
SbBool isOverride() const
SoNode * copy(SbBool copyConnections = FALSE) const
virtual SbBool affectsState() const
static SoNode * getByName(const SbName &name)
static int getByName(const SbName &name, SoNodeList &list)
Methods from class SoFieldContainer:
void setToDefaults()
SbBool hasDefaultValues() const
SbBool fieldsAreEqual(const SoFieldContainer *fc) const
void copyFieldValues(const SoFieldContainer *fc, SbBool copyConnections = FALSE)
SbBool set(const char *fieldDataString)
void get(SbString &fieldDataString)
virtual int getFields(SoFieldList &resultList) const
virtual SoField * getField(const SbName &fieldName) const
SbBool getFieldName(const SoField *field, SbName &fieldName) const
SbBool isNotifyEnabled() const
SbBool enableNotify(SbBool flag)
Methods from class SoBase:
void ref()
void unref() const
void unrefNoDelete() const
void touch()
virtual SoType getTypeId() const
SbBool isOfType(SoType type) const
virtual void setName(const SbName &name)
virtual SbName getName() const
DESCRIPTION¶
By default, Inventor assumes very little about the shapes it renders. You can use the SoShapeHints node to indicate that vertex-based shapes (those derived from SoVertexShape) are solid, contain ordered vertices, or contain convex faces. For fastest rendering, specify SOLID, COUNTERCLOCKWISE, CONVEX shapes.FIELDS¶
SoSFEnum vertexOrdering
Indicates how the vertices of faces are ordered. CLOCKWISE ordering means that the vertices of each face form a clockwise loop around the face, when viewed from the outside (the side toward which the normal points).
SoSFEnum shapeType
Indicates whether the shape is known to enclose a volume ( SOLID) or not. If the inside (the side away from the surface normal) of any part of the shape is visible, the shape is not solid.
SoSFEnum faceType
Indicates whether each face is convex. Because the penalty for non-convex faces is very steep (faces must be triangulated expensively), the default assumes all faces are convex. Therefore, shapes with concave faces may not be displayed correctly unless this hint is set to UNKNOWN_FACE_TYPE.
SoSFFloat creaseAngle
Indicates the minimum angle (in radians) between two adjacent face normals required to form a sharp crease at the edge when default normals are computed and used.
METHODS¶
SoShapeHints()
Creates a shape hints node with default settings.
static SoType getClassTypeId()
Returns type identifier for this class.
ACTION BEHAVIOR¶
SoGLRenderAction, SoCallbackAction, SoRayPickAction, SoGetBoundingBoxActionSets the state to contain the hints; sets up optimizations based on the hints.
FILE FORMAT/DEFAULTS¶
ShapeHints {
vertexOrdering UNKNOWN_ORDERING shapeType UNKNOWN_SHAPE_TYPE faceType CONVEX creaseAngle 0
}