2019-08-18 22:29:26 +03:00
|
|
|
@file:JsModule("three")
|
|
|
|
@file:JsNonModule
|
|
|
|
|
2022-08-14 22:03:46 +03:00
|
|
|
package three.animation
|
2019-08-18 22:29:26 +03:00
|
|
|
|
|
|
|
import org.khronos.webgl.Float32Array
|
|
|
|
|
|
|
|
/**
|
|
|
|
* @param name the identifier for the KeyframeTrack.
|
|
|
|
* @param times an array of keyframe times, converted internally to a Float32Array.
|
|
|
|
* @param values an array with the values related to the times array, converted internally to a Float32Array.
|
|
|
|
* @param interpolation the type of interpolation to use. See Animation Constants for possible values. Default is InterpolateLinear.
|
|
|
|
*/
|
|
|
|
external class KeyFrameTrack(
|
|
|
|
name: String,
|
|
|
|
times: Array<Number>,
|
|
|
|
values: Array<Number>,
|
|
|
|
interpolation: Int
|
|
|
|
) {
|
|
|
|
|
|
|
|
companion object {
|
|
|
|
var DefaultInterpolation: Int
|
|
|
|
}
|
|
|
|
|
|
|
|
var name: String
|
|
|
|
var times: Float32Array
|
|
|
|
var values: Float32Array
|
|
|
|
|
|
|
|
/**
|
|
|
|
* Returns the interpolation type
|
|
|
|
*/
|
|
|
|
fun getInterpolation(): Int
|
|
|
|
|
|
|
|
|
|
|
|
}
|