keyFrames

@JvmName(name = "keyFramesSingle")
fun <T> keyFrames(converter: SingleDataConverter<T>, duration: Measure<Time>, frames: KeyFrameBlock<T>.() -> Unit): FiniteNumericAnimationPlan<T, Double>(source)

Creates an animation that manipulates values of type T that are convertable to a Double.

keyFrames(converter, duration) {
value1 at duration * 0 then easeInElastic
value2 at duration * 1/3 then linear
value3 at duration * 2/3 then easeOutBack
}

Parameters

converter

that maps T to and from Array<Double>

duration

of the animation

frames

defining the animation key points


@JvmName(name = "keyFramesMulti")
fun <T> keyFrames(converter: MultiDataConverter<T>, duration: Measure<Time>, frames: KeyFrameBlock<T>.() -> Unit): FiniteNumericAnimationPlan<T, Array<Double>>(source)

Creates an animation that manipulates values of type T that are convertable to an array of Double. Each dimension of T will be animated using the definitions within frames.

Parameters

converter

that maps T to and from Array<Double>

duration

of the animation

frames

defining the animation key points

See also


@JvmName(name = "keyFramesSingle")
fun <T> keyFrames(converter: SingleDataConverter<T>, duration: Measure<Time>, delay: Measure<Time>, frames: KeyFrameBlock<T>.() -> Unit): FiniteNumericAnimationPlan<T, Double>(source)

Deprecated

use after method instead to add delays

Replace with

after(delay, keyFrames(converter, duration, frames))

Creates an animation that manipulates values of type T that are convertable to a Double.

keyFrames(converter, duration) {
value1 at duration * 0 then easeInElastic
value2 at duration * 1/3 then linear
value3 at duration * 2/3 then easeOutBack
}

Parameters

converter

that maps T to and from Array<Double>

duration

of the animation

delay

to apply before the animation begins

frames

defining the animation key points

See also


@JvmName(name = "keyFramesMulti")
fun <T> keyFrames(converter: MultiDataConverter<T>, duration: Measure<Time>, delay: Measure<Time>, frames: KeyFrameBlock<T>.() -> Unit): FiniteNumericAnimationPlan<T, Array<Double>>(source)

Deprecated

use after method instead to add delays

Replace with

after(delay, keyFrames(converter, duration, frames))

Creates an animation that manipulates values of type T that are convertable to an array of Double. Each dimension of T will be animated using the definitions within frames.

Parameters

converter

that maps T to and from Array<Double>

duration

of the animation

delay

to apply before the animation begins

frames

defining the animation key points

See also