-api-id | -api-type |
---|---|
T:Windows.UI.Composition.LinearEasingFunction |
winrt class |
Represents a linear function for interpolating between animation key frames.
The linear function of another supported easing function that can be used with KeyFrame Animations. When used, the animating property will change in between two KeyFrames linearly over time.
To create a new instance of LinearEasingFunction
, call CompositionEasingFunction.CreateLinearEasingFunction.md or Compositor.CreateLinearEasingFunction.
// Construct the linear function
LinearEasingFunction linear = _compositor.CreateLinearEasingFunction();
ScalarKeyFrameAnimation animation = _compositor.CreateScalarKeyFrameAnimation();
// Apply the cubic-bezier to a KeyFrame
animation.InsertKeyFrame(0.0f, 1.0f);
animation.InsertKeyFrame(1.0f, 0.0f, linear);
Composition Animations Overview, CompositionEasingFunction, IClosable