Skip to content

Commit cad940d

Browse files
author
exawon
authored
Update README.md
1 parent c017c6c commit cad940d

File tree

1 file changed

+6
-3
lines changed

1 file changed

+6
-3
lines changed

README.md

Lines changed: 6 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -25,7 +25,8 @@ public class PlayControl : AnimatorBehaviour
2525
IEnumerator Intro(int layer, int nameHash)
2626
{
2727
//OnStateEnter
28-
28+
29+
2930
while (StateCondition)
3031
{
3132
//OnStateUpdate
@@ -76,8 +77,10 @@ Tools to generate a bitmap font:
7677

7778
## Spline
7879

79-
[Spline](https://github.com/exawon/UnityScriptAccessories/tree/master/Spline) folder contains `SplineEditor`, `SplineData`, `SplineFollower`.
80+
[Spline](https://github.com/exawon/UnityScriptAccessories/tree/master/Spline) folder contains `SplineEditor`, `SplineData`, `SplineFollower`.
81+
82+
Linear curve is `B(t) = (1 - t) P0 + t P1`. The quadratic curve is `B(t) = (1 - t) ((1 - t) P0 + t P1) + t ((1 - t) P1 + t P2)`. It's `B(t) = (1 - t)^2 P0 + 2 (1 - t) t P1 + t^2 P2` compactly. And for the direction, the first derivative is `B'(t) = 2 (1 - t) (P1 - P0) + 2 t (P2 - P1)`.
8083

81-
Linear curve is `B(t) = (1 - t) P0 + t P1`. The quadratic curve is `B(t) = (1 - t) ((1 - t) P0 + t P1) + t ((1 - t) P1 + t P2)`. It's `B(t) = (1 - t)^2 P0 + 2 (1 - t) t P1 + t^2 P2` compactly. And for the direction, the first derivative is `B'(t) = 2 (1 - t) (P1 - P0) + 2 t (P2 - P1)`.
84+
`Spline` has been implemented as cubic curve. Each point has incomming handle and outgoing handle.
8285

8386
![](https://github.com/exawon/UnityScriptAccessories/blob/master/Images/spline-editor-01.jpg)

0 commit comments

Comments
 (0)