Skip to content

API > AnimationClip


AnimationClip⚓︎

AnimationClip inherits from Motion

Stores keyframe based animations.

Members⚓︎

Properties⚓︎

Name Description
AnimationClip.emptyProperty Returns true if the animation clip has no curves and no events.
AnimationClip.eventsProperty Animation Events for this animation clip.
AnimationClip.frameRateProperty Frame rate at which keyframes are sampled. (Read Only)
AnimationClip.hasGenericRootTransformProperty Returns true if the Animation has animation on the root transform.
AnimationClip.hasMotionCurvesProperty Returns true if the AnimationClip has root motion curves.
AnimationClip.humanMotionProperty Returns true if the animation contains curve that drives a humanoid rig.
AnimationClip.legacyProperty Set to true if the AnimationClip will be used with the Legacy Animation component ( instead of the Animator ).
AnimationClip.lengthProperty Animation length in seconds. (Read Only)
AnimationClip.localBoundsProperty AABB of this Animation Clip in local space of Animation component that it is attached too.
AnimationClip.wrapModeProperty Sets the default wrap mode used in the animation state.

Constructor⚓︎

Name Description
AnimationClip()Constructor Creates a new animation clip.

Methods⚓︎

Name Description
AnimationClip.AddEvent(evt) Method Adds an animation event to the clip.
AnimationClip.ClearCurves() Method Clears all curves from the clip.
AnimationClip.EnsureQuaternionContinuity() Method Realigns quaternion keys to ensure shortest interpolation paths.
AnimationClip.SampleAnimation(go, time) Method Samples an animation at a given time for any animated properties.
AnimationClip.SetCurve(relativePath, type, propertyName, curve) Method Assigns the curve to animate a specific property.

Inherited Members⚓︎

Inherited Properties⚓︎

Name Description
AnimationClip.hideFlagsProperty Should the object be hidden, saved with the Scene or modifiable by the user?
AnimationClip.nameProperty The name of the object.

Inherited Methods⚓︎

Name Description
AnimationClip.GetInstanceID()Method Returns the instance id of the object.

Extra Detail⚓︎

AnimationClip is used by Animation to play back animations. Unity AnimationClip