Utility class for working with animations.

Constructors

Methods

  • Assigns animations from a GLTF file to the objects in the scene.
    This method will look for objects in the scene that have animations and assign them to the correct objects.

    Parameters

    • file: Pick<GLTF, "animations" | "scene">

      The GLTF file to assign the animations from

    • Optionalopts: {
          createAnimationComponent(obj: Object3D<Object3DEventMap>, animation: AnimationClip): IAnimationComponent;
      }
      • createAnimationComponent:function
        • Parameters

          Returns IAnimationComponent

    Returns void

  • Tries to get the animation actions from an animation mixer.

    Parameters

    Returns null | AnimationAction[]

    The actions or null if the mixer is invalid