CurveTimeline
The base class for timelines that interpolate between frame values using stepped, linear, or a Bezier curve.
Static Members
Instance Members
Sets the specified frame to linear interpolation.
Name |
Type |
Description |
frame |
Int |
Between 0 and frameCount - 1 , inclusive. |
Sets the specified frame to stepped interpolation.
Name |
Type |
Description |
frame |
Int |
Between 0 and frameCount - 1 , inclusive. |
spine
getCurveType(frame: Int): Int
Returns the interpolation type for the specified frame.
Name |
Type |
Description |
frame |
Int |
Between 0 and frameCount - 1 , inclusive. |
Returns |
Description |
Int |
{ |
spine
shrink(bezierCount: Int): Void
Shrinks the storage for Bezier curves, for use when bezierCount
(specified in the constructor) was larger
than the actual number of Bezier curves.
Name |
Type |
bezierCount |
Int |
spine
setBezier(bezier: Int, frame: Int, value: Int, time1: Float, value1: Float, cx1: Float, cy1: Float, cx2: Float, cy2: Float, time2: Float, value2: Float): Void
Stores the segments for the specified Bezier curve. For timelines that modify multiple values, there may be more than
one curve per frame.
Name |
Type |
Description |
bezier |
Int |
The ordinal of this Bezier curve for this timeline, between 0 and bezierCount - 1 (specified in the constructor), inclusive. |
frame |
Int |
Between 0 and frameCount - 1 , inclusive. |
value |
Int |
The index of the value for the frame this curve is used for. |
time1 |
Float |
The time for the first key. |
value1 |
Float |
The value for the first key. |
cx1 |
Float |
The time for the first Bezier handle. |
cy1 |
Float |
The value for the first Bezier handle. |
cx2 |
Float |
The time of the second Bezier handle. |
cy2 |
Float |
The value for the second Bezier handle. |
time2 |
Float |
The time for the second key. |
value2 |
Float |
The value for the second key. |
Returns the Bezier interpolated value for the specified time.
Name |
Type |
Description |
time |
Float |
|
frameIndex |
Int |
The index into { |
valueOffset |
Int |
The offset from frameIndex to the value this curve is used for. |
i |
Int |
The index of the Bezier segments. See { |
Name |
Type |
Description |
frameCount |
Int |
|
bezierCount |
Int |
The maximum number of Bezier curves. See { |
propertyIds |
spine.support.utils.StringArray |
Unique identifiers for the properties the timeline modifies. |