import { VEC3_ZERO , VEC3_ONE , QUAT_DEFAULT } from '../../../common/gl-matrix-addon' ; import MdlxTextureAnimation from '../../../parsers/mdlx/textureanimation' ; import AnimatedObject from './animatedobject' ; import MdxModel from './model' ; /**
 * An MDX texture animation.
 */ export default class TextureAnimation extends AnimatedObject { constructor ( model , textureAnimation ) { super ( model , textureAnimation ) ; this . addVariants ( 'KTAT' , 'translation' ) ; this . addVariants ( 'KTAR' , 'rotation' ) ; this . addVariants ( 'KTAS' , 'scale' ) ; } getTranslation ( out , sequence , frame , counter ) { return this . getVectorValue ( out , 'KTAT' , sequence , frame , counter , < Float32Array > VEC3_ZERO ) ; } getRotation ( out , sequence , frame , counter ) { return this . getQuatValue ( out , 'KTAR' , sequence , frame , counter , < Float32Array > QUAT_DEFAULT ) ; } getScale ( out , sequence , frame , counter ) { return this . getVectorValue ( out , 'KTAS' , sequence , frame , counter , < Float32Array > VEC3_ONE ) ; } }