AnimationClip Class
Namespace: Stride.AnimationsAssembly: Stride.Engine.dll
An aggregation of AnimationCurve with their channel names.
[DataContract]
[ContentSerializer(typeof(DataContentSerializer<AnimationClip>))]
[DataSerializerGlobal(typeof(ReferenceSerializer<AnimationClip>), null, DataSerializerGenericMode.None, false, false, Profile = "Content")]
public sealed class AnimationClip
Name | Description | |
---|---|---|
Fields | ||
Channels | Gets the channels of this clip. |
|
Curves | ||
OptimizedAnimationDatas | ||
ShouldRescanChannels | Set this flag to true when the channel information of the clip have changed and need to be rescan by engine. |
|
Properties | ||
Duration | Gets or sets the duration of this clip. |
|
RepeatMode | Gets or sets the repeat mode of the AnimationClip. |
|
Methods | ||
AddCurve(String, AnimationCurve, Boolean) | Adds a named curve. |
|
GetCurve(String) | ||
Optimize() | Optimizes data from multiple curves to a single linear data stream. |
Fields
Channels
Gets the channels of this clip.
public Dictionary<string, AnimationClip.Channel> Channels
Field Value
Type | Description |
---|---|
System.Collections.Generic.Dictionary<System.String, AnimationClip.Channel> | The channels of this clip. |
Curves
public List<AnimationCurve> Curves
Field Value
Type | Description |
---|---|
System.Collections.Generic.List<AnimationCurve> |
OptimizedAnimationDatas
public AnimationData[] OptimizedAnimationDatas
Field Value
Type | Description |
---|---|
AnimationData[] |
ShouldRescanChannels
Set this flag to true when the channel information of the clip have changed and need to be rescan by engine.
public bool ShouldRescanChannels
Field Value
Type | Description |
---|---|
System.Boolean |
Properties
Duration
Gets or sets the duration of this clip.
public TimeSpan Duration { get; set; }
Property Value
Type | Description |
---|---|
System.TimeSpan | The duration of this clip. |
RepeatMode
Gets or sets the repeat mode of the AnimationClip.
public AnimationRepeatMode RepeatMode { get; set; }
Property Value
Type | Description |
---|---|
AnimationRepeatMode |
Methods
AddCurve(String, AnimationCurve, Boolean)
Adds a named curve.
public void AddCurve(string propertyName, AnimationCurve curve, bool isUserCustomProperty = false)
Parameters
Type | Name | Description |
---|---|---|
System.String | propertyName | Name of the property. |
AnimationCurve | curve | The curve. |
System.Boolean | isUserCustomProperty |
GetCurve(String)
public AnimationCurve GetCurve(string propertyName)
Parameters
Type | Name | Description |
---|---|---|
System.String | propertyName |
Returns
Type | Description |
---|---|
AnimationCurve |
Optimize()
Optimizes data from multiple curves to a single linear data stream.
public void Optimize()