update README
parent
55585138da
commit
b5f5627db4
17
README.md
17
README.md
|
@ -1,9 +1,9 @@
|
||||||
# MoonTools.Curve
|
# MoonTools.Curve
|
||||||
|
|
||||||
[](https://www.nuget.org/packages/MoonTools.Curve/)
|
[](https://www.nuget.org/packages/MoonTools.Curve/)
|
||||||
[](https://circleci.com/gh/MoonsideGames/MoonTools.Curve)
|
[](https://drone.moonside.games/MoonsideGames/MoonTools.Curve)
|
||||||
|
|
||||||
Implements quadratic and cubic Bezier curves in 2D and 3D.
|
Efficiently implements quadratic and cubic Bezier curves in 2D and 3D using immutable structs.
|
||||||
|
|
||||||
## Example
|
## Example
|
||||||
|
|
||||||
|
@ -16,7 +16,16 @@ Implements quadratic and cubic Bezier curves in 2D and 3D.
|
||||||
);
|
);
|
||||||
|
|
||||||
myCurve.Point(0.5f); // => Vector3(0, 0, 0.75f)
|
myCurve.Point(0.5f); // => Vector3(0, 0, 0.75f)
|
||||||
myCurve.Point(3, 2, 4); // => Vector3(0, 0, 0.75f);
|
myCurve.Point(3, 2, 4); // => Vector3(0, 0, 0.75f)
|
||||||
myCurve.Velocity(0.5f); // => Vector3(9, 0, 4.5f)
|
myCurve.Velocity(0.5f); // => Vector3(9, 0, 4.5f)
|
||||||
myCurve.Velocity(3, 2, 4); // => Vector3(9, 0, 4.5f);
|
myCurve.Velocity(3, 2, 4); // => Vector3(9, 0, 4.5f)
|
||||||
|
|
||||||
|
// curve values can be calculated statically as well
|
||||||
|
CubicBezierCurve3D.Point(
|
||||||
|
new Vector3(-4, -4, -3),
|
||||||
|
new Vector3(-2, 4, 0),
|
||||||
|
new Vector3(2, -4, 3),
|
||||||
|
new Vector3(4, 4, 0),
|
||||||
|
0.5f
|
||||||
|
); // => Vector3(0, 0, 0.75f)
|
||||||
```
|
```
|
||||||
|
|
Loading…
Reference in New Issue