Grasshopper API
Node3dTNearestItems Method (Double, Double, Double, Int32, Double, Double) |
Find the N nearest items.
Namespace: Grasshopper.Kernel.Geometry.SpatialTrees
Assembly: Grasshopper (in Grasshopper.dll)
public List<Index3d<T>> NearestItems( double x, double y, double z, int groupSize, double minimumDistance, double maximumDistance )
Public Function NearestItems ( x As Double, y As Double, z As Double, groupSize As Integer, minimumDistance As Double, maximumDistance As Double ) As List(Of Index3d(Of T))
Parameters
- x
- Type: SystemDouble
x coordinate to search from. - y
- Type: SystemDouble
y coordinate to search from. - z
- Type: SystemDouble
z coordinate to search from. - groupSize
- Type: SystemInt32
Number of nearest items to return. - minimumDistance
- Type: SystemDouble
Minimum distance for nearest items. Items closer than minimumDistance will be ignored. - maximumDistance
- Type: SystemDouble
Maximum distance for nearest items. Items further than maximumDistance will be ignored.
Return Value
Type: ListIndex3dTA list of nearest items, sorted from nearest to furthest.