Neighbors0D (Geometry0D)
Description
Returns an Array of indices (Integers) of the 0D neighborhood of a given 0D component within a given distance (see Geometry0D.Neighborhood0D) ->a given safe array of given 0D components within a given distance.
Parameters
|
Parameter |
Type |
Description |
|
compIdx / compIdxArray |
Index of the component or Array of component indices Possible Values: • 0 <= compIdx < Number of 0D Component: The compIdx must be valid • 0 <= compIdxArray[i] < Nb of 0D Component: The compIdxArray[i] must be valid |
|
|
siNeighborType |
siNeighborType |
Type of neighboring |
|
distance |
Distance to take into account |
Examples
VBScript Example
'See the Neighborhood0D for the use with a simple index argument
set oCube = Application.ActiveProject.ActiveScene.Root.AddGeometry("Cube", "MeshSurface")
set oGeometry = oCube.obj
set o0DGeometry = oGeometry.Geometry0D
'Get the array of indices from that item
set oSubComponent = getvalue(oCube.FullName & ".pnt[6]")
aIndices = oSubComponent.SubElements
a0DNeighbors = o0DGeometry.Neighbors0D( aIndices, siAdjacent, 1 )
for j = LBound( a0DNeighbors, 1 ) to UBound( a0DNeighbors, 1 )
LogMessage "Component [" & j & "] 0D neighbor : " & a0DNeighbors(j)
next
See Also
|
|
|
|
SOFTIMAGE|XSI v6.01