Show / Hide Table of Contents

Class PointCloudOctant

Used in PointCloudOctree. This octant does not contain actual point data.

Inheritance
System.Object
PointCloudOctant
Implements
IPointCloudOctant
IEmptyOctant<double3, System.Double>
IBucket<double3, System.Double>
Inherited Members
System.Object.Equals(System.Object)
System.Object.Equals(System.Object, System.Object)
System.Object.GetHashCode()
System.Object.GetType()
System.Object.MemberwiseClone()
System.Object.ReferenceEquals(System.Object, System.Object)
System.Object.ToString()
Namespace: Fusee.PointCloud.Core
Assembly: Fusee.PointCloud.Core.dll
Syntax
public class PointCloudOctant : IPointCloudOctant, IEmptyOctant<double3, double>, IBucket<double3, double>

Constructors

PointCloudOctant(double3, Double, OctantId, PointCloudOctant[])

Creates a new instance of type PointCloudOctant.

Declaration
public PointCloudOctant(double3 center, double size, OctantId octId, PointCloudOctant[] children = null)
Parameters
Type Name Description
double3 center

The center of this octant.

System.Double size

The size (in all three dimensions) of this octant.

OctantId octId
PointCloudOctant[] children

The octants child octants.

Properties

Center

Center of this Bucket in world space coordinates.

Declaration
public double3 Center { get; set; }
Property Value
Type Description
double3

Children

List of child octants.

Declaration
public IEmptyOctant<double3, double>[] Children { get; }
Property Value
Type Description
IEmptyOctant<double3, System.Double>[]

IsLeaf

If true this octant does not have any children.

Declaration
public bool IsLeaf { get; set; }
Property Value
Type Description
System.Boolean

IsVisible

True if octant is currently visible.

Declaration
public bool IsVisible { get; set; }
Property Value
Type Description
System.Boolean

Level

Level/ depth of this octant in the octree.

Declaration
public int Level { get; }
Property Value
Type Description
System.Int32

Max

The maximum of octants bounding box.

Declaration
public double3 Max { get; }
Property Value
Type Description
double3

Min

The minimum of octants bounding box.

Declaration
public double3 Min { get; }
Property Value
Type Description
double3

NumberOfPointsInNode

Number of point cloud points, this node holds.

Declaration
public int NumberOfPointsInNode { get; set; }
Property Value
Type Description
System.Int32

OctId

The globally unique identifier for this octant.

Declaration
public OctantId OctId { get; set; }
Property Value
Type Description
OctantId

PosInParent

Position in the parent octant/cube.

Declaration
public int PosInParent { get; }
Property Value
Type Description
System.Int32

ProjectedScreenSize

The size, projected into screen space. Set with ComputeScreenProjectedSize(double3, Int32, Single, float3, float3).

Declaration
public double ProjectedScreenSize { get; }
Property Value
Type Description
System.Double

Size

Length, width and height of this Octant.

Declaration
public double Size { get; set; }
Property Value
Type Description
System.Double

Methods

ComputeScreenProjectedSize(double3, Int32, Single, float3, float3)

Calculates the size, projected into screen space.

Declaration
public void ComputeScreenProjectedSize(double3 camPos, int screenHeight, float fov, float3 translation, float3 scale)
Parameters
Type Name Description
double3 camPos

Position of the camera.

System.Int32 screenHeight

Hight of the canvas.

System.Single fov

Field of view.

float3 translation
float3 scale

CreateChild(Int32)

Instantiates a child octant at the given position.

Declaration
public IEmptyOctant<double3, double> CreateChild(int atPosInParent)
Parameters
Type Name Description
System.Int32 atPosInParent

The PosInParent the new child has.

Returns
Type Description
IEmptyOctant<double3, System.Double>

InsideOrIntersectingFrustum(FrustumF)

Checks if this Octant lies within or intersects a Frustum. Returns true if one of the Frustum planes is intersecting this octant.

Declaration
public bool InsideOrIntersectingFrustum(FrustumF frustum)
Parameters
Type Name Description
FrustumF frustum

The frustum to test against.

Returns
Type Description
System.Boolean

false if fully outside, true if inside or intersecting.

InsideOrIntersectingFrustum(FrustumF, float3, float3)

Checks if this Octant lies within or intersects a Frustum. Returns true if one of the Frustum planes is intersecting this octant.

Declaration
public bool InsideOrIntersectingFrustum(FrustumF frustum, float3 translation, float3 scale)
Parameters
Type Name Description
FrustumF frustum

The frustum to test against.

float3 translation
float3 scale
Returns
Type Description
System.Boolean

false if fully outside, true if inside or intersecting.

IntersectRay(RayD)

Checks if a given ray originates in, or intersects octant.

Declaration
public bool IntersectRay(RayD ray)
Parameters
Type Name Description
RayD ray

The ray to test against.

Returns
Type Description
System.Boolean

Intersects(double3)

Check if point lies in this octant.

Declaration
public bool Intersects(double3 point)
Parameters
Type Name Description
double3 point
Returns
Type Description
System.Boolean

Implements

IPointCloudOctant
IEmptyOctant<T, K>
IBucket<T, K>
Generated by DocFX
GitHub Repo
Back to top