SoLevelOfDetail(3IV)
SoLevelOfDetail (SoLvlOfDtl) - level-of-detail switching group node
As shipped in IRIX 6.5.22. Added in IRIX 6.5.22.
NAME SoLevelOfDetail (SoLvlOfDtl) - level-of-detail switching group node INHERITS FROM SoBase > SoFieldContainer > SoNode > SoGroup > SoLevelOfDetail SYNOPSIS #include <Inventor_c/nodes/SoLevelOfDetail.h> typedef SoLevelOfDetail SoLvlOfDtl Fields from class SoLevelOfDetail: SoMFFloat screenArea Functions from class SoLevelOfDetail: SoLevelOfDetail * SoLvlOfDtlCreate() SoType SoLvlOfDtlGetClassTypeId() Functions from class SoGroup: void SoLvlOfDtlAddChild(SoLvlOfDtl *this, SoNode *child) void SoLvlOfDtlInsertChild(SoLvlOfDtl *this, SoNode *child, int newChildIndex) SoNode * SoLvlOfDtlGetChild(const SoLvlOfDtl *this, int index) int SoLvlOfDtlFindChild(const SoLvlOfDtl *this, const SoNode *child) int SoLvlOfDtlGetNumChildren(const SoLvlOfDtl *this) void SoLvlOfDtlRemoveChild(SoLvlOfDtl *this, int index) void SoLvlOfDtlRemoveChildNode(SoLvlOfDtl *this, SoNode *child) void SoLvlOfDtlRemoveAllChildren(SoLvlOfDtl *this) void SoLvlOfDtlReplaceChild(SoLvlOfDtl *this, int index, SoNode *newChild) void SoLvlOfDtlReplaceChildNode(SoLvlOfDtl *this, SoNode *oldChild, SoNode *newChild) Functions from class SoNode: void SoLvlOfDtlSetOverride(SoLvlOfDtl *this, SbBool state) SbBool SoLvlOfDtlIsOverride(const SoLvlOfDtl *this) SoNode * SoLvlOfDtlCopy(const SoLvlOfDtl *this, SbBool copyConnections = FALSE) SbBool SoLvlOfDtlAffectsState(const SoLvlOfDtl *this) SoNode * SoLvlOfDtlGetByName(const char *name) int SoLvlOfDtlGetByNameList(const char *name, SoNodeList *list) Functions from class SoFieldContainer: void SoLvlOfDtlSetToDflts(SoLvlOfDtl *this) SbBool SoLvlOfDtlHasDfltVals(const SoLvlOfDtl *this) SbBool SoLvlOfDtlFldsAreEq(const SoLvlOfDtl *this, const SoFieldContainer *fc) void SoLvlOfDtlCopyFieldVals(SoLvlOfDtl *this, const SoFieldContainer *fc, SbBool copyConnections = FALSE) SbBool SoLvlOfDtlSet(SoLvlOfDtl *this, const char *fieldDataString) void SoLvlOfDtlGet(SoLvlOfDtl *this, SbString *fieldDataString) int SoLvlOfDtlGetFields(const SoLvlOfDtl *this, SoFieldList *resultList) SoField * SoLvlOfDtlGetField(const SoLvlOfDtl *this, const char *fieldName) SbBool SoLvlOfDtlGetFieldName(const SoLvlOfDtl *this, const SoField *field, SbName *fieldName) SbBool SoLvlOfDtlIsNotifyEnabled(const SoLvlOfDtl *this) SbBool SoLvlOfDtlEnableNotify(SoLvlOfDtl *this, SbBool flag) Functions from class SoBase: void SoLvlOfDtlRef(SoLvlOfDtl *this) void SoLvlOfDtlUnref(const SoLvlOfDtl *this) void SoLvlOfDtlUnrefNoDelete(const SoLvlOfDtl *this) void SoLvlOfDtlTouch(SoLvlOfDtl *this) SoType SoLvlOfDtlGetTypeId(const SoLvlOfDtl *this) SbBool SoLvlOfDtlIsOfType(const SoLvlOfDtl *this, SoType type) void SoLvlOfDtlSetName(SoLvlOfDtl *this, const char *name) SbName SoLvlOfDtlGetName(const SoLvlOfDtl *this) DESCRIPTION The children of this node typically represent the same object or objects at varying levels of detail, from highest detail to lowest. The size of the objects when projected into the viewport is used to determine which version to use (i.e., which child to traverse). The size is computed as the area of the screen rectangle enclosing the projection of the 3D bounding box that encloses all of the children. When rendering, this size is compared to the values in the screenArea field. If the size is greater than the first value, child 0 is traversed. If it is smaller than the first, but greater than the second, child 1 is traversed, and so on. If there are fewer children than are required by this rule, the last child is traversed. The screenArea field contains just 0 by default, so the first child is always traversed. The size calculation takes the current complexity into account. If the complexity is 0 or is of type BOUNDING_BOX, the last child is always traversed. If the complexity is less than .5, the computed size is scaled down appropriately to use (possibly) a less detailed representation. If the complexity is greater than .5, the size is scaled up. At complexity 1, the first child is always used. Note that the SoLOD node is similar to SoLevelOfDetail, except the switching between levels in the SoLOD node is based on distance from the camera, which is faster than using screen area. FIELDS SoMFFloat screenArea Areas to use for comparison FUNCTIONS SoLevelOfDetail * SoLvlOfDtlCreate() Creates a level-of-detail node with default settings. SoType SoLvlOfDtlGetClassTypeId() Returns type identifier for this class. ACTION BEHAVIOR SoGLRenderAction, SoRayPickAction, SoCallbackAction Only the child with the appropriate level of detail is traversed. SoGetBoundingBoxAction The box that encloses all children is computed. (This is the box that is needed to compute the projected size.) others All implemented as for SoGroup. FILE FORMAT/DEFAULTS LevelOfDetail { screenArea 0 } SEE ALSO SoLOD, SoComplexity, SoSwitch, SoGroup