Class TShapeTreeLOD
Unit
Declaration
type TShapeTreeLOD = class(TShapeTreeGroup)
Description
LOD (level of detail) alternative in the TShapeTree. At most one child (from it's children list) is active at a given time.
Corresponds to X3D (or VRML 2.0) TLodNode.
( Note for VRML 1.0: This doesn't correspond to VRML 1.0 LOD node in TLODNode_1, which is more difficult to handle, as it may affect also other nodes after LOD. )
The scene code must call UpdateLevel whenever the camera (in scene coordinates) potentially changed.
Hierarchy
- TObject
- TShapeTree
- TShapeTreeGroup
- TShapeTreeLOD
Overview
Methods
![]() |
function LODInverseTransform: PMatrix4; |
![]() |
function UpdateLevel(const CameraLocalPosition: TVector3; const ProcessEvents: Boolean): Boolean; |
![]() |
function DebugInfoWithoutChildren: String; override; |
Properties
![]() |
property LODNode: TLODNode read FLODNode write FLODNode; |
![]() |
property Level: Cardinal read FLevel default 0; |
Description
Methods
![]() |
function LODInverseTransform: PMatrix4; |
This item has no description. |
![]() |
function UpdateLevel(const CameraLocalPosition: TVector3; const ProcessEvents: Boolean): Boolean; |
Calculate and set new value for Level, thus changing which child is the active one. Also, if ProcessEvents, send X3D output event LODNode.EventLevel_Changed (whenever it should be send). Looks at LOD node in LODNode and transformation in LODInverseTransform to choose the current level. ReturnsWhether the level changed. |
![]() |
function DebugInfoWithoutChildren: String; override; |
This item has no description. Showing description inherited from TShapeTree.DebugInfoWithoutChildren. Describe this shape, not recursively. |
Properties
![]() |
property LODNode: TLODNode read FLODNode write FLODNode; |
This item has no description. |
![]() |
property Level: Cardinal read FLevel default 0; |
Current level, that is index of the active child of this LOD node. This is always < Children.Count, unless there are no children. In this case it's 0. Should be modified UpdateLevel. By default we use the first (highest-detail) LOD as active. |
Generated by PasDoc 0.16.0-snapshot.