vJSONClosePath
Closes or opens a path by adding or removing a repeated end point, with seam options.

vJSONClosePath takes an array of XYZ points that form a path. Operation closes it, opens it or toggles it, and Seam and Duplicate Endpoint control how the closing point is made.
Parameters
| Parameter | Type | Default | Description |
|---|---|---|---|
| Operation | Dropdown | Close Path | Close Path (default), Open Path or Toggle. |
| Seam | Dropdown | Keep Start | Keep Start (default), Keep End or Average. Which first point is used when closing. Hidden for Open Path. |
| Duplicate Endpoint | Integer | 1 | Adds a copy of the first point at the end of a closed path when on (default). Hidden for Open Path. |
| Points | DATATYPE | — | Point positions. |
Read the full description
A path counts as closed when its first and last points are equal. Open Path removes repeated last points until the path is no longer closed. Close Path removes an existing repeated end first, then applies Seam, then adds a copy of the first point at the end if Duplicate Endpoint is on (default). Toggle opens a closed path and closes an open one.
Seam Keep Start leaves the first point as it is. Keep End replaces the first point with a copy of the last. Average replaces it with the average of the first and the last. Seam and Duplicate Endpoint are hidden when Operation is Open Path.
Fewer than 2 points are returned unchanged. Each output point has X, Y and Z only.
Example Connections
- Close a path and draw it
- Resample a closed path
vJSONPointsOnArc.Output -> vJSONClosePath.Points
vJSONClosePath.Output -> vJSONCameraProjection.ArrayA
vJSONCameraProjection.Output -> vJSONShapeRender.ArrayPoint
Background.Output -> vJSONShapeRender.Input
vJSONPointsOnCircle.Output -> vJSONClosePath.Points
vJSONClosePath.Output -> vJSONResamplePath.Points