Compartilhar via


IXRColorKeyFrame (Compact 2013)

3/28/2014

This class provides a base class for defining an animation segment with a target color value that uses specific animation key-frame techniques.

Derived classes each provide a different key-frame interpolation for a color value that is provided for an IXRColorAnimationUsingKeyFrames animation.

Syntax

class IXRColorKeyFrame : public IXRDependencyObject

Inheritance Hierarchy

IXRDependencyObject

    IXRColorKeyFrame

        IXRDiscreteColorKeyFrame

        IXRLinearColorKeyFrame

        IXRSplineColorKeyFrame

Methods

Method

Description

IXRColorKeyFrame::GetKeyTime

Retrieves the time at which the target color value for this key frame is reached.

IXRColorKeyFrame::GetValue

Retrieves the target color value for this key frame.

IXRColorKeyFrame::SetKeyTime

Sets the time at which the target color value for this key frame is reached.

IXRColorKeyFrame::SetValue

Sets the target color value for this key frame.

Thread Safety

Members of this class are thread-safe if you previously called IXRApplication::CreateHostFromXaml and supplied it with an XRWindowCreateParams structure that has AllowsMultipleThreadAccess set to true.

Remarks

IXRColorKeyFrame is an abstract class for the child classes IXRDiscreteColorKeyFrame, IXRLinearColorKeyFrame, and IXRSplineColorKeyFrame, and provides methods for defining color key frames by using different techniques of key-frame animation.

To animate a color using key frames, define an IXRColorAnimationUsingKeyFrames animation and define key frames by populating its IXRColorKeyFrameCollection collection with one or more IXRDiscreteColorKeyFrame, IXRLinearColorKeyFrame, or IXRSplineColorKeyFrame objects.

You can retrieve or set the target color value for this key frame by calling IXRColorKeyFrame::GetValue or IXRColorKeyFrame::SetValue.

A collection of IXRColorKeyFrame objects belongs to an IXRColorKeyFrameCollection object.

When you create a class instance, use an IXRColorKeyFramePtr smart pointer instead of a raw interface pointer. For more information, see XRPtr<Interface>.

.NET Framework Equivalent

System.Windows.Media.Animation.ColorKeyFrame

Requirements

Header

XamlRuntime.h

sysgen

SYSGEN_XAML_RUNTIME

See Also

Reference

Classes for Animation Storyboards
Classes for Visual Appearance