Class YAHOO.util.Bezier
| Package: | YAHOO.util |
| Class: | Bezier |
| Extends: | Object |
| Defined In: | animation.js |
Used to calculate Bezier splines for any number of control points.
Public Properties
This class has no public properties.
Public Methods
| |
getPosition(Array points, Number t) : Array |
Bezier |
| Get the current position of the animated element based on t.
Each point is an array of "x" and "y" values (0 = x, 1 =... |
Public Events
This class has no public events.
Method Details
getPosition
public function getPosition(Array points, Number t)
Get the current position of the animated element based on t.
Each point is an array of "x" and "y" values (0 = x, 1 = y)
At least 2 points are required (start and end).
First point is start. Last point is end.
Additional control points are optional.
This method is defined by Bezier.