Click or drag to resize
DigitalRuneLodCollection Class
Stores the levels of detail (LODs) of an object.
Inheritance Hierarchy
SystemObject
  DigitalRune.Graphics.SceneGraphLodCollection

Namespace: DigitalRune.Graphics.SceneGraph
Assembly: DigitalRune.Graphics (in DigitalRune.Graphics.dll) Version: 1.2.0.0 (1.2.1.14562)
Syntax
public class LodCollection : ICollection<LodEntry>, 
	IEnumerable<LodEntry>, IEnumerable

The LodCollection type exposes the following members.

Methods
  NameDescription
Public methodAdd
Adds a LOD to the LodCollection.
Public methodClear
Removes all LODs from the LodCollection.
Public methodEquals
Determines whether the specified Object is equal to the current Object.
(Inherited from Object.)
Protected methodFinalize
Allows an object to try to free resources and perform other cleanup operations before it is reclaimed by garbage collection.
(Inherited from Object.)
Public methodGetEnumerator
Returns an enumerator that iterates through the collection.
Public methodGetHashCode
Serves as a hash function for a particular type.
(Inherited from Object.)
Public methodGetType
Gets the Type of the current instance.
(Inherited from Object.)
Public methodIndexOf(Single)
Determines the index of the LOD at a specific distance in the LodCollection.
Public methodIndexOf(SceneNode)
Determines the index of a specific LOD in the LodCollection.
Protected methodMemberwiseClone
Creates a shallow copy of the current Object.
(Inherited from Object.)
Public methodRemove(Int32)
Removes the LOD at the specified index from the LodCollection.
Public methodRemove(Single)
Removes the LOD at a specific distance from the LodCollection.
Public methodRemove(SceneNode)
Removes the specified LOD node from the LodCollection.
Public methodToString
Returns a string that represents the current object.
(Inherited from Object.)
Top
Extension Methods
  NameDescription
Public Extension MethodAddRangeLodEntry (Defined by CollectionHelper.)
Public Extension MethodDoLodEntry(ActionLodEntry)Overloaded.
Performs the given action on each element in a sequence when it is enumerated.
(Defined by LinqHelper.)
Public Extension MethodDoLodEntry(ActionLodEntry, Int32)Overloaded.
Performs the given action on each element (incorporating its index) in a sequence when it is enumerated.
(Defined by LinqHelper.)
Public Extension MethodForEachLodEntry(ActionLodEntry)Overloaded.
Immediately performs the given action on each element in a sequence.
(Defined by LinqHelper.)
Public Extension MethodForEachLodEntry(ActionLodEntry, Int32)Overloaded.
Immediately performs the given action on each element (incorporating its index) in a sequence.
(Defined by LinqHelper.)
Public Extension MethodIndexOfLodEntry
Returns the index of the first element in a sequence that satisfies the specified condition.
(Defined by LinqHelper.)
Top
Properties
  NameDescription
Public propertyCount
Gets the number of LODs.
Public propertyItem
Gets the LOD at the specified index.
Top
Explicit Interface Implementations
  NameDescription
Explicit interface implementationPrivate methodICollectionLodEntryAdd
Explicit interface implementationPrivate methodICollectionLodEntryContains
Explicit interface implementationPrivate methodICollectionLodEntryCopyTo
Explicit interface implementationPrivate methodIEnumerableLodEntryGetEnumerator
Returns an enumerator that iterates through the collection.
Explicit interface implementationPrivate methodIEnumerableGetEnumerator
Returns an enumerator that iterates through the collection.
Explicit interface implementationPrivate propertyICollectionLodEntryIsReadOnly
Explicit interface implementationPrivate methodICollectionLodEntryRemove
Top
Remarks

The LodCollection is a list of scene nodes sorted by distance. Each scene node represents a level of detail (LOD).

LOD0, LOD1, ... LODn-1:
LODs can be accessed by index. The LOD with index i is called LODi. By definition, LOD0 is the highest level of detail and LODn-1 is the lowest level of detail.

LOD Distances:
LODs are selected based on the current camera and the distance to the camera. The LOD distances stored in the LodCollection are view-normalized distances, which means that distance values are corrected based on the camera's field-of-view. The resulting LOD distances are independent of the current field-of-view. See GetViewNormalizedDistance(Single, Matrix44F) for more information.

The camera that serves as reference for LOD distance computations needs to be stored in the render context (see property LodCameraNode).

See Also