|
AR + GPS Location
3.0.0
|
A (open-ended) catmull-rom spline, which interpolates a set points by joining catmull-rom curves together. More...
Public Member Functions | |
| CatmullRomSpline (Vector3[] points, int n, float alpha) | |
| Creates a new Catmull-rom spline. More... | |
| sealed override void | CalculateSegments (int n) |
| Calculate the catmull-rom segments. Also estimates the curve's length. More... | |
Public Member Functions inherited from ARLocation.Spline | |
| Vector3 | GetPointAtArcLength (float s) |
| Returns the point of the spline at a given arc-length. More... | |
| CurvePointData | GetPointAndTangentAtArcLength (float s) |
| Returns a CurvePointData whith the point and tangent of the spline at a given arc-length. More... | |
| void | DrawCurveWithLineRenderer (LineRenderer renderer, System.Func< Vector3, Vector3 > func, int n=100) |
| Draws the curve using a given LineRenderer, with points being processed by a given function beforehand. More... | |
| Vector3[] | SamplePoints (int n, System.Func< Vector3, Vector3 > func) |
| Calculates a sample of (N+2) equidistant points along the spline. More... | |
| Vector3[] | SamplePoints (int n) |
| Calculates a sample of (N+2) equidistant points along the spline. More... | |
| void | DrawGizmos () |
| Draw the curve and sample point using Gizmos. More... | |
Properties | |
| float | Alpha [get, set] |
| The alpha/tension parameter of the spline. More... | |
Properties inherited from ARLocation.Spline | |
| Vector3[] | Points [get, protected set] |
| The points interpolated of the spline. More... | |
| float | Length [get, protected set] |
| The full (estimated) length of the spline. More... | |
Additional Inherited Members | |
Protected Attributes inherited from ARLocation.Spline | |
| Curve[] | segments |
| The CatmullRom curve-segments of the spline. More... | |
| int | segmentCount = 0 |
| The number of segments that make up the spline. More... | |
| float[] | lengths |
A (open-ended) catmull-rom spline, which interpolates a set points by joining catmull-rom curves together.
Definition at line 10 of file CatmullRomSpline.cs.
| ARLocation.CatmullRomSpline.CatmullRomSpline | ( | Vector3[] | points, |
| int | n, | ||
| float | alpha | ||
| ) |
Creates a new Catmull-rom spline.
| points | The interpolated points. |
| n | The number of samples used in each segment of the spline. |
| alpha |
Definition at line 48 of file CatmullRomSpline.cs.
|
virtual |
Calculate the catmull-rom segments. Also estimates the curve's length.
| n | The number sample points used to estimate each segment's length. |
Implements ARLocation.Spline.
Definition at line 60 of file CatmullRomSpline.cs.
|
getset |
The alpha/tension parameter of the spline.
Definition at line 26 of file CatmullRomSpline.cs.