MergePoints
Introduction
vtkMergePoints merge exactly coincident points.
vtkMergePoints is a locator object to quickly locate points in 3D.
Methods
extend
Method used to decorate a given object (publicAPI+model) with vtkMergePoints characteristics.
| Argument | Type | Required | Description |
|---|---|---|---|
publicAPI | Yes | object on which methods will be bounds (public) | |
model | Yes | object on which data structure will be bounds (protected) | |
initialValues | IMergePointsInitialValues | No | (default: {}) |
insertUniquePoint
Insert a point into the merge points structure. If the point is already present, it returns the existing ID. Otherwise, it inserts the point and returns a new ID.
| Argument | Type | Required | Description |
|---|---|---|---|
x | Vector3 | Yes | The point to insert as an array of 3 numbers. |
Returns
| Type | Description |
|---|---|
| IInsertPointResult | An object indicating if the point was inserted and its ID. |
isInsertedPoint
Check if a point is already inserted in the merge points structure.
| Argument | Type | Required | Description |
|---|---|---|---|
x | Vector3 | Yes | The point to check. |
Returns
| Type | Description |
|---|---|
| Number | The ID of the point if it exists, otherwise -1. |
newInstance
Method used to create a new instance of vtkMergePoints.
| Argument | Type | Required | Description |
|---|---|---|---|
initialValues | IMergePointsInitialValues | No | for pre-setting some of its content |