vJSONLine
Generate evenly spaced points on a straight line between a start and an end position.

vJSONLine has no input and outputs an array of XYZ points between Start and End positions. Point Count sets how many points are written.
Parameters
| Parameter | Type | Default | Description |
|---|---|---|---|
| Start X | Float | -0.5 | X position of the first point. Default -0.5. |
| Start Y | Float | 0 | Y position of the first point. Default 0. |
| Start Z | Float | 0 | Z position of the first point. Default 0. |
| End X | Float | 0.5 | X position of the end of the line. Default 0.5. |
| End Y | Float | 0 | Y position of the end of the line. Default 0. |
+3 more parameters
| Parameter | Type | Default | Description |
|---|---|---|---|
| End Z | Float | 0 | Z position of the end of the line. Default 0. |
| Point Count | Integer | 10 | Number of points. Clamped to 2 or more, default 10. |
| Include End Point | Integer | 1.0 | When on, the last point lands on the end position. When off, the points stop one step before it. Default on. |
Read the full description
For point i of n, the node uses t = i / (n - 1) and writes Start + (End - Start) * t on each of the three axes. The first point is at the start position and, with Include End Point on, the last point is at the end position.
With the defaults (Start -0.5, 0, 0, End 0.5, 0, 0, 10 points, Include End Point on) the node outputs ten points on the X axis from -0.5 to 0.5, 0.111 apart.
With Include End Point off, t is divided by n instead of n - 1. The spacing is then (End - Start) / n and the last point stops one step before the end position.
Point Count is clamped to 2 or more. The start and end positions are not limited. The output contains points only, with no edges.
Example Connections
- Draw the line
- Animate the points with vArrayWave
vJSONLine.Output -> vJSONCameraProjection.ArrayA
vJSONCameraProjection.Output -> vJSONShapeRender.ArrayPoint
Background.Output -> vJSONShapeRender.Input
vJSONLine.Output -> vJSONWave.ArrayA
vJSONWave.Output -> vJSONCameraProjection.ArrayA