Class SplineDataHandles
Provides default handles to SplineData.
Call Data
Inherited Members
Namespace: UnityEditor .Splines
Assembly: Unity.Splines.Editor.dll
Syntax
public static class SplineDataHandles
Methods
DataPointHandles<TSpline, TData>(TSpline, SplineData<TData>, bool)
Creates manipulation handles in the SceneView to add, move, and remove SplineData's DataPoints along a spline. DataPoints of the targeted SplineData along a Spline. Left click on an empty location on the spline adds a new DataPoint in the SplineData. Left click on an existing DataPoint allows to move this point along the Spline while a right click on it allows to delete that DataPoint.
Declaration
public static void DataPointHandles<TSpline, TData>(this TSpline spline, SplineData<TData> splineData, bool useDefaultValueOnAdd = false) where TSpline : ISpline
Parameters
Type | Name | Description |
---|---|---|
TSpline | spline | The Spline to use to interprete the SplineData. |
Spline |
splineData | The SplineData for which the handles are drawn. |
bool | useDefaultValueOnAdd | Either to use default value or closer DataPoint value when adding new DataPoint. |
Type Parameters
Name | Description |
---|---|
TSpline | The Spline type. |
TData | The type of data this data point stores. |
Remarks
Left-click an empty location on the spline to add a new DataPoint to the SplineData. Left-click on a DataPoint to move the point along the Spline. Right-click a DataPoint to delete it.
DataPointHandles<TSpline, TData>(TSpline, SplineData<TData>, bool, int)
Creates manipulation handles in the Scene view that can be used to add, move, and remove SplineData's DataPoints along a spline.
Declaration
public static void DataPointHandles<TSpline, TData>(this TSpline spline, SplineData<TData> splineData, bool useDefaultValueOnAdd, int splineID = 0) where TSpline : ISpline
Parameters
Type | Name | Description |
---|---|---|
TSpline | spline | The spline to use to interprete the SplineData. |
Spline |
splineData | The SplineData for which the handles are drawn. |
bool | useDefaultValueOnAdd | Whether to use the default value or a closer DataPoint value when adding new DataPoint. |
int | splineID | The ID for the spline. |
Type Parameters
Name | Description |
---|---|
TSpline | The spline type. |
TData | The type of data this data point stores. |
Remarks
Left-click an empty location on the spline to add a new DataPoint to the SplineData. Left-click and drag a DataPoint to move the point along the spline. Right-click a DataPoint to delete it.