Click or drag to resize

VisualFindAspectsT Method

Find all aspects that can be cast to the given type.

Namespace:  Demo3D.Visuals
Assembly:  Demo3D.Core (in Demo3D.Core.dll) Version: 15.0.2.11458
Syntax
C#
public virtual IEnumerable<T> FindAspects<T>()
where T : class

Type Parameters

T
The type of the aspect to find.

Return Value

Type: IEnumerableT
All aspects that can be cast as the given type.
Examples
C#
int CountRenderables(Visual visual) {
    // Count number of renderers on this Visual
    return visual.FindAspects<PhysicsGeometryAspect>().Count();
}
See Also