Click or drag to resize
DigitalRuneAnimationControllerUpdateAndApply Method
Immediately evaluates the animation and applies the new animation values.

Namespace: DigitalRune.Animation
Assembly: DigitalRune.Animation (in DigitalRune.Animation.dll) Version: 1.4.0.0 (1.4.1.14427)
Syntax
public void UpdateAndApply()
Exceptions
ExceptionCondition
AnimationException Cannot update and apply animation. The animation instance associated with the current animation controller is already running or has already been recycled and the animation controller is no longer valid.
Remarks

When an animation is started or stopped, the values of the animated properties do not change immediately. The new animation values will be computed and set when the animation system is updated. See Update(TimeSpan) and ApplyAnimations.

But in certain cases when an animation is started or stopped the animated properties should be updated immediately. In these case the method UpdateAndApply needs to be called after the animation is started or stopped. This method immediately evaluates the animation and applies the new animation values to the properties that are being animated.

The method can also be called if an animation is modified (e.g. key frames are added or removed) and the changes should take effect immediately.

In most cases it is not necessary to call this method because the animation service updates and applies animations automatically.

Note that UpdateAndApply does not advance the time of the animation. The animation is evaluated at the current time.

See Also