-
Notifications
You must be signed in to change notification settings - Fork 0
DiGi.Geometry.Core
public static class CreateInheritance System.Object → Create
Performs density-based spatial clustering on the provided collection of points.
public static DiGi.Geometry.Core.Classes.DensityBasedSpatialClusteringResult<T>? DensityBasedSpatialClusteringResult<T>(this System.Collections.Generic.IEnumerable<T>? points, double tolerance, int pointCount)
where T : DiGi.Geometry.Core.Interfaces.IPoint<T>;T
The type of point, which must implement DiGi.Geometry.Core.Interfaces.IPoint<>.
points System.Collections.Generic.IEnumerable<T>
The System.Collections.Generic.IEnumerable<> collection of points to be clustered.
tolerance System.Double
The System.Double distance threshold used to determine if two points are neighbors.
pointCount System.Int32
The minimum System.Int32 number of points required to form a dense region.
DiGi.Geometry.Core.Classes.DensityBasedSpatialClusteringResult<T>
A DensityBasedSpatialClusteringResult<T>(this IEnumerable<T>, double, int) containing the clustering results, or null if the points collection is null.
public static class QueryInheritance System.Object → Query
Creates an adjacency dictionary from a collection of indexes.
public static System.Collections.Generic.Dictionary<int,System.Collections.Generic.List<int[]>>? AdjacencyIndexes(this System.Collections.Generic.IEnumerable<int[]>? indexes);indexes System.Collections.Generic.IEnumerable<System.Int32[]>
The System.Collections.Generic.IEnumerable<> of int[] representing the indexes to process.
System.Collections.Generic.Dictionary<System.Int32,System.Collections.Generic.List<System.Int32[]>>
A System.Collections.Generic.Dictionary<> mapping each node index to a System.Collections.Generic.List<> of its adjacent int[] edges, or null if the input is null.
Computes the auxiliary indexes based on the provided collection of index arrays.
public static System.Collections.Generic.List<int[]>? AuxiliaryIndexes(this System.Collections.Generic.IEnumerable<int[]>? indexes);indexes System.Collections.Generic.IEnumerable<System.Int32[]>
The System.Collections.Generic.IEnumerable<> of int[] containing the original indexes.
System.Collections.Generic.List<System.Int32[]>
A System.Collections.Generic.List<> of int[] representing the auxiliary indexes, or null if the input is null.
Identifies and returns the boundary indexes from the provided collection of integer arrays.
public static System.Collections.Generic.List<int[]>? BoundaryIndexes(this System.Collections.Generic.IEnumerable<int[]>? indexes);indexes System.Collections.Generic.IEnumerable<System.Int32[]>
The System.Collections.Generic.IEnumerable<> of int[] representing the indexes to evaluate.
System.Collections.Generic.List<System.Int32[]>
A System.Collections.Generic.List<> of int[] containing the boundary indexes, or null if the input collection is null.
Identifies the boundary indexes from a collection of indexes and extracts auxiliary indexes.
public static System.Collections.Generic.List<int[]>? BoundaryIndexes(this System.Collections.Generic.IEnumerable<int[]>? indexes, out System.Collections.Generic.List<int[]>? auxiliaryIndexes);indexes System.Collections.Generic.IEnumerable<System.Int32[]>
The System.Collections.Generic.IEnumerable<> of int[] representing the input indexes.
auxiliaryIndexes System.Collections.Generic.List<System.Int32[]>
When this method returns, contains a System.Collections.Generic.List<> of int[] representing the auxiliary indexes, or null if none were identified.
System.Collections.Generic.List<System.Int32[]>
A System.Collections.Generic.List<> of int[] containing the boundary indexes, or null if the input System.Collections.Generic.IEnumerable<> is null.
Determines whether the provided collection of indices represents a non-manifold mesh.
public static bool IsNonManifold(this System.Collections.Generic.IEnumerable<int[]>? indexes);indexes System.Collections.Generic.IEnumerable<System.Int32[]>
The System.Collections.Generic.IEnumerable<> of int[] containing the vertex indices for each face.
System.Boolean
A System.Boolean value indicating true if the mesh is non-manifold; otherwise, false.
the Isoperimetric Ratio (IR) (also called Isoperimetric Quotient, Circular Compactness, or Shape Factor) is a classic geometric measure that describes how close a shape is to a perfect circle.
public static double IsoperimetricRatio(double area, double perimeter);area System.Double
Area of the shape
perimeter System.Double
Perimeter (or boundary length)
System.Double
Isoperimetric ratio
Returns the opposite Alignment value.
public static DiGi.Geometry.Core.Enums.Alignment Opposite(this DiGi.Geometry.Core.Enums.Alignment alignment);alignment Alignment
The Alignment value to invert.
Alignment
The opposite Alignment value, or Undefined if no opposite is defined.
Returns the opposite of the specified Orientation.
public static DiGi.Geometry.Core.Enums.Orientation Opposite(this DiGi.Geometry.Core.Enums.Orientation orientation);orientation Orientation
The Orientation value to invert.
Orientation
The opposite Orientation value, or Undefined if the input is undefined or collinear.
Filters a collection of points to find those within a specified distance from a given point.
public static System.Collections.Generic.List<T>? PointsByDistance<T>(this System.Collections.Generic.IEnumerable<T>? points, T? point, double tolerance=1E-06)
where T : DiGi.Geometry.Core.Interfaces.IPoint<T>;T
The type of point, which must implement DiGi.Geometry.Core.Interfaces.IPoint<>.
points System.Collections.Generic.IEnumerable<T>
An System.Collections.Generic.IEnumerable<> containing the points to evaluate.
point T
The reference point used for distance comparison.
tolerance System.Double
A System.Double representing the maximum allowable distance between points.
System.Collections.Generic.List<T>
A System.Collections.Generic.List<> of points within the specified tolerance, or null if either the source collection or the reference point is null.
The Rectangular Thinness Ratio (RTR) — also sometimes called the Rectangular Compactness Ratio or Rectangular Shape Factor — is a geometric shape descriptor that measures how elongated or “thin” a shape is compared to a rectangle that perfectly fits around it (its minimum bounding rectangle).
public static double RectangularThinnessRatio(double area, double rectangleArea);area System.Double
shape area
rectangleArea System.Double
Minimal rectangle area
System.Double
Rectangular thinness ratio
Returns the sorted boundary indexes derived from the provided collection of int[].
public static System.Collections.Generic.List<System.Collections.Generic.List<int>>? SortedBoundaryIndexes(this System.Collections.Generic.IEnumerable<int[]>? indexes);indexes System.Collections.Generic.IEnumerable<System.Int32[]>
The System.Collections.Generic.IEnumerable<> of int[] representing the input indexes.
System.Collections.Generic.List<System.Collections.Generic.List<System.Int32>>
A System.Collections.Generic.List<> containing System.Collections.Generic.List<> of System.Int32 if successful; otherwise, null.
Sorts the boundary indexes into continuous loops of vertex indices.
public static System.Collections.Generic.List<System.Collections.Generic.List<int>>? SortedBoundaryIndexes(this System.Collections.Generic.IEnumerable<int[]>? indexes, out System.Collections.Generic.List<int[]>? auxiliaryIndexes);indexes System.Collections.Generic.IEnumerable<System.Int32[]>
The IEnumerable<int[]> containing the mesh index arrays.
auxiliaryIndexes System.Collections.Generic.List<System.Int32[]>
When this method returns, contains a List<int[]> of auxiliary indexes used during boundary detection.
System.Collections.Generic.List<System.Collections.Generic.List<System.Int32>>
A List<List<int>> where each inner list represents a sorted loop of boundary vertex indices; returns null if the input IEnumerable<int[]> is null.
The Square Thinness Ratio (STR) — also sometimes called the Square Compactness Ratio or Square Shape Factor — is a geometric shape descriptor that measures how elongated or “thin” a shape is compared to a square that perfectly fits around it (its minimum bounding square).
public static double SquareThinnessRatio(double area, double squareArea);area System.Double
shape area
squareArea System.Double
square area
System.Double
Square thinness ratio
Calculates the thinness ratio of a shape based on its area and perimeter.
public static double ThinnessRatio(double area, double perimeter);area System.Double
The double value representing the area of the shape.
perimeter System.Double
The double value representing the perimeter of the shape.
System.Double
A double value representing the thinness ratio, or System.Double.NaN if either input is System.Double.NaN or if the perimeter is zero.