Constructor
new Vec2Gradient(values, smooth)
Create a new Vec2 gradient.
Parameters:
Name | Type | Default | Description |
---|---|---|---|
values | Object.<number, (number|Vec2)> | Values at time intervals | |
smooth | boolean | false | Whether the track should start and end smoothly/gradually |
Methods
get(progress) → {Vec2}
Get the vector a specified point.
Parameters:
Name | Type | Description |
---|---|---|
progress | number | Overall animation progress (0 - 1) |
Returns:
Vector at current point
- Type:
- Vec2