SoLevelOfDetail Class Reference
[Groups]

Level-of-detail switching group node. More...

#include <Inventor/nodes/SoLevelOfDetail.h>

Inheritance diagram for SoLevelOfDetail:
SoGroup SoNode SoFieldContainer SoBase SoRefCounter SoTypedObject

List of all members.

Public Member Functions

virtual SoType getTypeId () const
 SoLevelOfDetail ()
 SoLevelOfDetail (int nChildren)

Static Public Member Functions

static SoType getClassTypeId ()

Public Attributes

SoMFFloat screenArea

Detailed Description

Level-of-detail switching group node.

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.

FILE FORMAT/DEFAULT

ACTION BEHAVIOR

SEE ALSO

SoLOD, SoComplexity, SoSwitch, SoGroup


Constructor & Destructor Documentation

SoLevelOfDetail::SoLevelOfDetail (  ) 

Creates a level-of-detail node with default settings.

SoLevelOfDetail::SoLevelOfDetail ( int  nChildren  ) 

Constructor that takes approximate number of children.


Member Function Documentation

static SoType SoLevelOfDetail::getClassTypeId (  )  [static]

Returns the type identifier for this class.

Reimplemented from SoGroup.

virtual SoType SoLevelOfDetail::getTypeId (  )  const [virtual]

Returns the type identifier for this specific instance.

Reimplemented from SoGroup.


Member Data Documentation

Areas to use for comparison.


The documentation for this class was generated from the following file:

Open Inventor Toolkit reference manual, generated on 15 Mar 2023
Copyright © Thermo Fisher Scientific All rights reserved.
http://www.openinventor.com/