Share via


Reuse interpolation values on other keyframes (Windows Phone)

In Blend for Visual Studio 2012, you can convert an existing key spline interpolation value to a resource, and then reuse the interpolation value by applying it to other keyframes. This is helpful if you create an interpolation effect that would be difficult to reproduce by hand on other keyframes.

Note

If you modify a keyframe that uses a key spline resource, or add a keyframe to a timeline that has keyframes that use a key spline resource, the keyframes will be converted to local values. If this happens, a notification appears at the top of the artboard.

To convert an interpolation value to a resource

  1. Create a key spline interpolation value on a keyframe using the "To change keyframe interpolation by using the key spline editor" procedure under Change animation interpolation between keyframes (Windows Phone).

  2. In the Objects and Timeline panel, select the keyframe  that uses the interpolation value that you want to reuse.

  3. In the Properties panel, under Easing, click Advanced options  next to the EasingFunction property, and then select Convert to New Resource from the pop-up menu.

    The Create EasingFunctionBase Resource dialog box appears.

  4. Under Name (Key), type a name for your key spline resource. This is the name by which other objects can reference the resource, thereby applying the resource to themselves.

  5. Under Define in, select the option where you want the key spline brush resource to be defined:

    • To make the resource available to any document in your application, select Application.

    • To make the resource available only to the current document, select This document (Page: <no name>).

    • To make the resource available only to the object from which you created the resource or its child objects, select This document (object).

    • To define the resource in a resource dictionary file that you can reuse in other projects, select an existing Resource dictionary.

  6. Click OK to close the dialog box and create the resource. A color-coded frame appears around the EasingFunction property in the Properties panel indicating that the property is now using a resource:

To apply an interpolation resource to another keyframe

  1. With a storyboard open in Blend, select a keyframe  in the Objects and Timeline panel.

  2. In the Properties panel, under Easing, click Advanced options  next to the EasingFunction property, click Local Resource, and then select the name of the resource that you want to apply to this keyframe.

To modify an interpolation resource

  1. In the Resources panel, expand the node where you defined your resource. For example, if you defined the resource in This document (Page: <no name>), expand the Page node in the Resources panel.

  2. Locate the resource by name, for example, “EasingFunctionBase1” and then click the modify resource button  next to the resource name. An EasingFunction editor appears:

    After you finish modifying the key spline resource, click anywhere outside the EasingFunction editor to close the editor. All of the keyframes that use this resource are automatically updated to use the new value.

See Also

Tasks

Change animation interpolation between keyframes (Windows Phone)