Animating Series
- 2 minutes to read
This topic provides information on how to animate a series in 2D chart types.
#Overview
There are two approaches to providing an animation effect for a series:
- all series can be animated simultaneously using the built-in animation effect;
- the animation effect can be specified for each series individually.
When using the second approach, you can select your custom animation from the list of all animations for a given series.
To obtain the list of all animations, use the Series.GetPredefinedSeriesAnimationKinds and Series.GetPredefinedPointAnimationKinds methods.
For example, the following animation effects for the AreaSeries2D view type are available:
- Area2DDropFromFarAnimation
- Area2DDropFromNearAnimation
- Area2DGrowUpAnimation
- Area2DStretchFromFarAnimation
- Area2DStretchFromNearAnimation
- Area2DStretchOutAnimation
- Area2DUnwindAnimation
The image below shows the Area2DDropFromFarAnimation effect in action.
#Animation Customization
To animate series and/or series points within a chart (depending on the series type) using the built-in animation effect, set its ChartControl.EnableAnimation property to true.
To animate a specific series using a custom effect, assign an animation to its SeriesAnimation property (e.g., AreaSeries2D.SeriesAnimation).
Example
For a real-world example on how to animate a chart series, see the following tutorial.
The table below shows properties that can be used to customize the animation effect.
Member | Description |
---|---|
Series. |
Specifies the automatic start mode for the animation. This is a dependency property. |
Animation |
Specifies the time when the animation is started. This is a dependency property. |
Animation |
Specifies the duration of the animation. This is a dependency property. |
Animation |
Specifies the easing function for the animation. This is a dependency property. |