AnimationClipState.generated.cs 1.5 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647
  1. using System;
  2. using System.Runtime.CompilerServices;
  3. using System.Runtime.InteropServices;
  4. namespace BansheeEngine
  5. {
  6. /** @addtogroup Animation
  7. * @{
  8. */
  9. /// <summary>Contains information about a currently playing animation clip.</summary>
  10. [StructLayout(LayoutKind.Sequential), SerializeObject]
  11. public partial struct AnimationClipState
  12. {
  13. /// <summary>Initializes the struct with default values.</summary>
  14. public static AnimationClipState Default()
  15. {
  16. AnimationClipState value = new AnimationClipState();
  17. value.layer = 0;
  18. value.time = 0f;
  19. value.speed = 1f;
  20. value.weight = 1f;
  21. value.wrapMode = AnimWrapMode.Loop;
  22. value.stopped = false;
  23. return value;
  24. }
  25. /// <summary>Layer the clip is playing on. Multiple clips can be played simulatenously on different layers.</summary>
  26. public uint layer;
  27. /// <summary>Current time the animation is playing from.</summary>
  28. public float time;
  29. /// <summary>Speed at which the animation is playing.</summary>
  30. public float speed;
  31. /// <summary>Determines how much of an influence does the clip have on the final pose.</summary>
  32. public float weight;
  33. /// <summary>Determines what happens to other animation clips when a new clip starts playing.</summary>
  34. public AnimWrapMode wrapMode;
  35. /// <summary>
  36. /// Determines should the time be advanced automatically. Certain type of animation clips don't involve playback (e.g.
  37. /// for blending where animation weight controls the animation).
  38. /// </summary>
  39. public bool stopped;
  40. }
  41. /** @} */
  42. }