Class StaticInstancingModelOctree
- Namespace
- HelixToolkit.SharpDX.Utilities
- Assembly
- HelixToolkit.SharpDX.dll
public class StaticInstancingModelOctree : StaticOctree<KeyValuePair<int, BoundingBox>>, IOctreeBasic
- Inheritance
-
StaticInstancingModelOctree
- Implements
- Inherited Members
Constructors
StaticInstancingModelOctree(IList<Matrix4x4>, BoundingBox, OctreeBuildParameter)
Initializes a new instance of the StaticInstancingModelOctree class.
public StaticInstancingModelOctree(IList<Matrix4x4> instanceMatrix, BoundingBox geometryBound, OctreeBuildParameter parameter)
Parameters
instanceMatrixIList<Matrix4x4>The instance matrix.
geometryBoundBoundingBoxThe geometry bound.
parameterOctreeBuildParameterThe parameter.
Fields
GeometryBound
protected readonly BoundingBox GeometryBound
Field Value
InstanceMatrix
protected readonly IList<Matrix4x4> InstanceMatrix
Field Value
Methods
FindNearestPointBySphereExcludeChild(ref Octant, HitTestContext?, ref BoundingSphere, ref List<HitTestResult>, ref bool)
Finds the nearest point by sphere exclude child.
protected override bool FindNearestPointBySphereExcludeChild(ref StaticOctree<KeyValuePair<int, BoundingBox>>.Octant octant, HitTestContext? context, ref BoundingSphere sphere, ref List<HitTestResult> points, ref bool isIntersect)
Parameters
octantStaticOctree<KeyValuePair<int, BoundingBox>>.OctantThe octant.
contextHitTestContextThe context.
sphereBoundingSphereThe sphere.
pointsList<HitTestResult>The points.
isIntersectboolif set to
true[is intersect].
Returns
GetBoundingBoxFromItem(ref KeyValuePair<int, BoundingBox>)
Gets the bounding box from item.
protected override BoundingBox GetBoundingBoxFromItem(ref KeyValuePair<int, BoundingBox> item)
Parameters
itemKeyValuePair<int, BoundingBox>The item.
Returns
GetMaxBound()
Gets the maximum bound.
protected override BoundingBox GetMaxBound()
Returns
GetObjects()
Gets the objects.
protected override KeyValuePair<int, BoundingBox>[] GetObjects()
Returns
HitTestCurrentNodeExcludeChild(ref Octant, HitTestContext?, object?, Geometry3D?, Matrix4x4, ref Ray, bool, ref List<HitTestResult>, ref bool, float)
Hits the test current node exclude child.
protected override bool HitTestCurrentNodeExcludeChild(ref StaticOctree<KeyValuePair<int, BoundingBox>>.Octant octant, HitTestContext? context, object? model, Geometry3D? geometry, Matrix4x4 modelMatrix, ref Ray rayModel, bool returnMultiple, ref List<HitTestResult> hits, ref bool isIntersect, float hitThickness)
Parameters
octantStaticOctree<KeyValuePair<int, BoundingBox>>.OctantThe octant.
contextHitTestContextThe context.
modelobjectThe model.
geometryGeometry3DmodelMatrixMatrix4x4The model matrix.
rayModelRayThe ray model.
returnMultipleboolhitsList<HitTestResult>The hits.
isIntersectboolif set to
true[is intersect].hitThicknessfloatThe hit thickness.