//------------------------------------------------------------------------------
// <auto-generated>
//     This code was generated by a tool.
//
//       LottieGen version:
//           8.1.240821.1+077322fa26
//       
//       Command:
//           LottieGen -Language CSharp -Public -WinUIVersion 3.0 -InputFile View.json
//       
//       Input file:
//           View.json (136242 bytes created 13:07+02:00 Nov 17 2024)
//       
//       LottieGen source:
//           http://aka.ms/Lottie
//
//     Changes to this file may cause incorrect behavior and will be lost if
//     the code is regenerated.
// </auto-generated>
//------------------------------------------------------------------------------
// ____________________________________
// |       Object stats       | Count |
// |__________________________|_______|
// | All CompositionObjects   |    74 |
// |--------------------------+-------|
// | Expression animators     |     1 |
// | KeyFrame animators       |     4 |
// | Reference parameters     |     1 |
// | Expression operations    |     0 |
// |--------------------------+-------|
// | Animated brushes         |     - |
// | Animated gradient stops  |     - |
// | ExpressionAnimations     |     1 |
// | PathKeyFrameAnimations   |     3 |
// |--------------------------+-------|
// | ContainerVisuals         |     1 |
// | ShapeVisuals             |     1 |
// |--------------------------+-------|
// | ContainerShapes          |     1 |
// | CompositionSpriteShapes  |     6 |
// |--------------------------+-------|
// | Brushes                  |     6 |
// | Gradient stops           |     9 |
// | CompositionVisualSurface |     - |
// ------------------------------------
using Microsoft.Graphics;
using Microsoft.Graphics.Canvas.Geometry;
using Microsoft.UI.Composition;
using System;
using System.Collections.Generic;
using System.Numerics;
using Windows.UI;

namespace AnimatedVisuals
{
    // Name:        tasks
    // Frame rate:  24 fps
    // Frame count: 28
    // Duration:    1166.7 mS
    // _____________________________________________________________________________________________
    // |           Marker           |           Constant           | Frame |   mS   |   Progress   |
    // |____________________________|______________________________|_______|________|______________|
    // | NormalToPressed_Start      | M_NormalToPressed_Start      |     0 |    0.0 | 0F           |
    // | NormalToPressed_End        | M_NormalToPressed_End        |     9 |  375.0 | 0.323214293F |
    // | PointerOverToPressed_Start | M_PointerOverToPressed_Start |     9 |  375.0 | 0.323214293F |
    // | PointerOverToPressed_End   | M_PointerOverToPressed_End   |    19 |  791.7 | 0.680357158F |
    // | PressedToNormal_Start      | M_PressedToNormal_Start      |    20 |  833.3 | 0.716071427F |
    // | PressedToNormal_End        | M_PressedToNormal_End        |    28 | 1166.7 | 1F           |
    // | PressedToPointerOver_Start | M_PressedToPointerOver_Start |    28 | 1166.7 | 1F           |
    // | PressedToPointerOver_End   | M_PressedToPointerOver_End   |    28 | 1166.7 | 1F           |
    // ---------------------------------------------------------------------------------------------
    sealed partial class View
        : Microsoft.UI.Xaml.Controls.IAnimatedVisualSource
        , Microsoft.UI.Xaml.Controls.IAnimatedVisualSource2
    {
        // Animation duration: 1.167 seconds.
        internal const long c_durationTicks = 11666666;

        // Marker: NormalToPressed_Start.
        internal const float M_NormalToPressed_Start = 0F;

        // Marker: NormalToPressed_End.
        internal const float M_NormalToPressed_End = 0.323214293F;

        // Marker: PointerOverToPressed_Start.
        internal const float M_PointerOverToPressed_Start = 0.323214293F;

        // Marker: PointerOverToPressed_End.
        internal const float M_PointerOverToPressed_End = 0.680357158F;

        // Marker: PressedToNormal_Start.
        internal const float M_PressedToNormal_Start = 0.716071427F;

        // Marker: PressedToNormal_End.
        internal const float M_PressedToNormal_End = 1F;

        // Marker: PressedToPointerOver_Start.
        internal const float M_PressedToPointerOver_Start = 1F;

        // Marker: PressedToPointerOver_End.
        internal const float M_PressedToPointerOver_End = 1F;

        public Microsoft.UI.Xaml.Controls.IAnimatedVisual TryCreateAnimatedVisual(Compositor compositor)
        {
            object ignored = null;
            return TryCreateAnimatedVisual(compositor, out ignored);
        }

        public Microsoft.UI.Xaml.Controls.IAnimatedVisual TryCreateAnimatedVisual(Compositor compositor, out object diagnostics)
        {
            diagnostics = null;

            var res =
                new View_AnimatedVisual(
                    compositor
                    );
            res.CreateAnimations();
            return res;
        }

        /// <summary>
        /// Gets the number of frames in the animation.
        /// </summary>
        public double FrameCount => 28d;

        /// <summary>
        /// Gets the frame rate of the animation.
        /// </summary>
        public double Framerate => 24d;

        /// <summary>
        /// Gets the duration of the animation.
        /// </summary>
        public TimeSpan Duration => TimeSpan.FromTicks(11666666);

        /// <summary>
        /// Converts a zero-based frame number to the corresponding progress value denoting the
        /// start of the frame.
        /// </summary>
        public double FrameToProgress(double frameNumber)
        {
            return frameNumber / 28d;
        }

        /// <summary>
        /// Returns a map from marker names to corresponding progress values.
        /// </summary>
        public IReadOnlyDictionary<string, double> Markers =>
            new Dictionary<string, double>
            {
                { "NormalToPressed_Start", 0d },
                { "NormalToPressed_End", 0.323214285714286 },
                { "PointerOverToPressed_Start", 0.323214285714286 },
                { "PointerOverToPressed_End", 0.680357142857143 },
                { "PressedToNormal_Start", 0.716071428571429 },
                { "PressedToNormal_End", 1d },
                { "PressedToPointerOver_Start", 1d },
                { "PressedToPointerOver_End", 1d },
            };

        /// <summary>
        /// Sets the color property with the given name, or does nothing if no such property
        /// exists.
        /// </summary>
        public void SetColorProperty(string propertyName, Color value)
        {
        }

        /// <summary>
        /// Sets the scalar property with the given name, or does nothing if no such property
        /// exists.
        /// </summary>
        public void SetScalarProperty(string propertyName, double value)
        {
        }

        sealed partial class View_AnimatedVisual
            : Microsoft.UI.Xaml.Controls.IAnimatedVisual
            , Microsoft.UI.Xaml.Controls.IAnimatedVisual2
        {
            const long c_durationTicks = 11666666;
            readonly Compositor _c;
            readonly ExpressionAnimation _reusableExpressionAnimation;
            AnimationController _animationController_0;
            CompositionColorGradientStop _gradientStop_0_AlmostMediumTurquoise_FF31BCEE;
            CompositionColorGradientStop _gradientStop_0p69_AlmostTeal_FF05509B;
            CompositionColorGradientStop _gradientStop_0p429_AlmostTeal_FF054E97;
            CompositionColorGradientStop _gradientStop_0p845_AlmostMidnightBlue_FF044689;
            CompositionColorGradientStop _gradientStop_1_AlmostMidnightBlue_FF033D78;
            CompositionContainerShape _containerShape;
            CompositionPath _path_0;
            CompositionPath _path_1;
            CompositionPath _path_2;
            CompositionPathGeometry _pathGeometry_0;
            CompositionPathGeometry _pathGeometry_1;
            CompositionPathGeometry _pathGeometry_2;
            CompositionPathGeometry _pathGeometry_3;
            ContainerVisual _root;
            CubicBezierEasingFunction _cubicBezierEasingFunction_0;
            StepEasingFunction _holdThenStepEasingFunction;
            StepEasingFunction _stepThenHoldEasingFunction;

            void BindProperty(
                CompositionObject target,
                string animatedPropertyName,
                string expression,
                string referenceParameterName,
                CompositionObject referencedObject)
            {
                _reusableExpressionAnimation.ClearAllParameters();
                _reusableExpressionAnimation.Expression = expression;
                _reusableExpressionAnimation.SetReferenceParameter(referenceParameterName, referencedObject);
                target.StartAnimation(animatedPropertyName, _reusableExpressionAnimation);
            }

            PathKeyFrameAnimation CreatePathKeyFrameAnimation(float initialProgress, CompositionPath initialValue, CompositionEasingFunction initialEasingFunction)
            {
                var result = _c.CreatePathKeyFrameAnimation();
                result.Duration = TimeSpan.FromTicks(c_durationTicks);
                result.InsertKeyFrame(initialProgress, initialValue, initialEasingFunction);
                return result;
            }

            Vector2KeyFrameAnimation CreateVector2KeyFrameAnimation(float initialProgress, Vector2 initialValue, CompositionEasingFunction initialEasingFunction)
            {
                var result = _c.CreateVector2KeyFrameAnimation();
                result.Duration = TimeSpan.FromTicks(c_durationTicks);
                result.InsertKeyFrame(initialProgress, initialValue, initialEasingFunction);
                return result;
            }

            CompositionSpriteShape CreateSpriteShape(CompositionGeometry geometry, Matrix3x2 transformMatrix, CompositionBrush fillBrush)
            {
                var result = _c.CreateSpriteShape(geometry);
                result.TransformMatrix = transformMatrix;
                result.FillBrush = fillBrush;
                return result;
            }

            AnimationController AnimationController_0()
            {
                if (_animationController_0 != null) { return _animationController_0; }
                var result = _animationController_0 = _c.CreateAnimationController();
                result.Pause();
                BindProperty(_animationController_0, "Progress", "_.Progress", "_", _root);
                return result;
            }

            CanvasGeometry Geometry_0()
            {
                CanvasGeometry result;
                using (var builder = new CanvasPathBuilder(null))
                {
                    builder.SetFilledRegionDetermination(CanvasFilledRegionDetermination.Winding);
                    builder.BeginFigure(new Vector2(-19F, 4F));
                    builder.AddLine(new Vector2(19F, 4F));
                    builder.AddCubicBezier(new Vector2(20.1000004F, 4F), new Vector2(21F, 3.0999999F), new Vector2(21F, 2F));
                    builder.AddLine(new Vector2(21F, -2F));
                    builder.AddCubicBezier(new Vector2(21F, -3.0999999F), new Vector2(20.1000004F, -4F), new Vector2(19F, -4F));
                    builder.AddLine(new Vector2(-19F, -4F));
                    builder.AddCubicBezier(new Vector2(-20.1000004F, -4F), new Vector2(-21F, -3.0999999F), new Vector2(-21F, -2F));
                    builder.AddLine(new Vector2(-21F, 2F));
                    builder.AddCubicBezier(new Vector2(-21F, 3.0999999F), new Vector2(-20.1000004F, 4F), new Vector2(-19F, 4F));
                    builder.EndFigure(CanvasFigureLoop.Closed);
                    result = CanvasGeometry.CreatePath(builder);
                }
                return result;
            }

            CanvasGeometry Geometry_1()
            {
                CanvasGeometry result;
                using (var builder = new CanvasPathBuilder(null))
                {
                    builder.SetFilledRegionDetermination(CanvasFilledRegionDetermination.Winding);
                    builder.BeginFigure(new Vector2(-10.5F, 4F));
                    builder.AddCubicBezier(new Vector2(-10.5F, 4F), new Vector2(10.5F, 4F), new Vector2(10.5F, 4F));
                    builder.AddCubicBezier(new Vector2(11.6000004F, 4F), new Vector2(12.5F, 3.0999999F), new Vector2(12.5F, 2F));
                    builder.AddCubicBezier(new Vector2(12.5F, 2F), new Vector2(12.5F, -2F), new Vector2(12.5F, -2F));
                    builder.AddCubicBezier(new Vector2(12.5F, -3.0999999F), new Vector2(11.6000004F, -4F), new Vector2(10.5F, -4F));
                    builder.AddCubicBezier(new Vector2(10.5F, -4F), new Vector2(-10.5F, -4F), new Vector2(-10.5F, -4F));
                    builder.AddCubicBezier(new Vector2(-11.6000004F, -4F), new Vector2(-12.5F, -3.0999999F), new Vector2(-12.5F, -2F));
                    builder.AddCubicBezier(new Vector2(-12.5F, -2F), new Vector2(-12.5F, 2F), new Vector2(-12.5F, 2F));
                    builder.AddCubicBezier(new Vector2(-12.5F, 3.0999999F), new Vector2(-11.6000004F, 4F), new Vector2(-10.5F, 4F));
                    builder.EndFigure(CanvasFigureLoop.Closed);
                    result = CanvasGeometry.CreatePath(builder);
                }
                return result;
            }

            // - - - - - Layer aggregator
            // - - - Transforms: task-3 Offset:<-8.5, 12>
            // - Path
            CanvasGeometry Geometry_2()
            {
                CanvasGeometry result;
                using (var builder = new CanvasPathBuilder(null))
                {
                    builder.SetFilledRegionDetermination(CanvasFilledRegionDetermination.Winding);
                    builder.BeginFigure(new Vector2(-10.5F, 4F));
                    builder.AddCubicBezier(new Vector2(-10.5F, 4F), new Vector2(17.5F, 4F), new Vector2(17.5F, 4F));
                    builder.AddCubicBezier(new Vector2(18.6000004F, 4F), new Vector2(19.5F, 3.0999999F), new Vector2(19.5F, 2F));
                    builder.AddCubicBezier(new Vector2(19.5F, 2F), new Vector2(19.5F, -2F), new Vector2(19.5F, -2F));
                    builder.AddCubicBezier(new Vector2(19.5F, -3.0999999F), new Vector2(18.6000004F, -4F), new Vector2(17.5F, -4F));
                    builder.AddCubicBezier(new Vector2(17.5F, -4F), new Vector2(-10.5F, -4F), new Vector2(-10.5F, -4F));
                    builder.AddCubicBezier(new Vector2(-11.6000004F, -4F), new Vector2(-12.5F, -3.0999999F), new Vector2(-12.5F, -2F));
                    builder.AddCubicBezier(new Vector2(-12.5F, -2F), new Vector2(-12.5F, 2F), new Vector2(-12.5F, 2F));
                    builder.AddCubicBezier(new Vector2(-12.5F, 3.0999999F), new Vector2(-11.6000004F, 4F), new Vector2(-10.5F, 4F));
                    builder.EndFigure(CanvasFigureLoop.Closed);
                    result = CanvasGeometry.CreatePath(builder);
                }
                return result;
            }

            // - - - - - Layer aggregator
            // - - - Transforms: task-3 Offset:<-8.5, 12>
            // - Path
            CanvasGeometry Geometry_3()
            {
                CanvasGeometry result;
                using (var builder = new CanvasPathBuilder(null))
                {
                    builder.SetFilledRegionDetermination(CanvasFilledRegionDetermination.Winding);
                    builder.BeginFigure(new Vector2(-10.5F, 4F));
                    builder.AddCubicBezier(new Vector2(-10.5F, 4F), new Vector2(5.5F, 4F), new Vector2(5.5F, 4F));
                    builder.AddCubicBezier(new Vector2(6.5999999F, 4F), new Vector2(7.5F, 3.0999999F), new Vector2(7.5F, 2F));
                    builder.AddCubicBezier(new Vector2(7.5F, 2F), new Vector2(7.5F, -2F), new Vector2(7.5F, -2F));
                    builder.AddCubicBezier(new Vector2(7.5F, -3.0999999F), new Vector2(6.5999999F, -4F), new Vector2(5.5F, -4F));
                    builder.AddCubicBezier(new Vector2(5.5F, -4F), new Vector2(-10.5F, -4F), new Vector2(-10.5F, -4F));
                    builder.AddCubicBezier(new Vector2(-11.6000004F, -4F), new Vector2(-12.5F, -3.0999999F), new Vector2(-12.5F, -2F));
                    builder.AddCubicBezier(new Vector2(-12.5F, -2F), new Vector2(-12.5F, 2F), new Vector2(-12.5F, 2F));
                    builder.AddCubicBezier(new Vector2(-12.5F, 3.0999999F), new Vector2(-11.6000004F, 4F), new Vector2(-10.5F, 4F));
                    builder.EndFigure(CanvasFigureLoop.Closed);
                    result = CanvasGeometry.CreatePath(builder);
                }
                return result;
            }

            CanvasGeometry Geometry_4()
            {
                CanvasGeometry result;
                using (var builder = new CanvasPathBuilder(null))
                {
                    builder.SetFilledRegionDetermination(CanvasFilledRegionDetermination.Winding);
                    builder.BeginFigure(new Vector2(-13F, 4F));
                    builder.AddCubicBezier(new Vector2(-13F, 4F), new Vector2(13F, 4F), new Vector2(13F, 4F));
                    builder.AddCubicBezier(new Vector2(14.1000004F, 4F), new Vector2(15F, 3.0999999F), new Vector2(15F, 2F));
                    builder.AddCubicBezier(new Vector2(15F, 2F), new Vector2(15F, -2F), new Vector2(15F, -2F));
                    builder.AddCubicBezier(new Vector2(15F, -3.0999999F), new Vector2(14.1000004F, -4F), new Vector2(13F, -4F));
                    builder.AddCubicBezier(new Vector2(13F, -4F), new Vector2(-13F, -4F), new Vector2(-13F, -4F));
                    builder.AddCubicBezier(new Vector2(-14.1000004F, -4F), new Vector2(-15F, -3.0999999F), new Vector2(-15F, -2F));
                    builder.AddCubicBezier(new Vector2(-15F, -2F), new Vector2(-15F, 2F), new Vector2(-15F, 2F));
                    builder.AddCubicBezier(new Vector2(-15F, 3.0999999F), new Vector2(-14.1000004F, 4F), new Vector2(-13F, 4F));
                    builder.EndFigure(CanvasFigureLoop.Closed);
                    result = CanvasGeometry.CreatePath(builder);
                }
                return result;
            }

            // - - - - - Layer aggregator
            // - - - Transforms: task-2 Offset:<-6, 0>
            // - Path
            CanvasGeometry Geometry_5()
            {
                CanvasGeometry result;
                using (var builder = new CanvasPathBuilder(null))
                {
                    builder.SetFilledRegionDetermination(CanvasFilledRegionDetermination.Winding);
                    builder.BeginFigure(new Vector2(-13F, 4F));
                    builder.AddCubicBezier(new Vector2(-13F, 4F), new Vector2(2F, 4F), new Vector2(2F, 4F));
                    builder.AddCubicBezier(new Vector2(3.0999999F, 4F), new Vector2(4F, 3.0999999F), new Vector2(4F, 2F));
                    builder.AddCubicBezier(new Vector2(4F, 2F), new Vector2(4F, -2F), new Vector2(4F, -2F));
                    builder.AddCubicBezier(new Vector2(4F, -3.0999999F), new Vector2(3.0999999F, -4F), new Vector2(2F, -4F));
                    builder.AddCubicBezier(new Vector2(2F, -4F), new Vector2(-13F, -4F), new Vector2(-13F, -4F));
                    builder.AddCubicBezier(new Vector2(-14.1000004F, -4F), new Vector2(-15F, -3.0999999F), new Vector2(-15F, -2F));
                    builder.AddCubicBezier(new Vector2(-15F, -2F), new Vector2(-15F, 2F), new Vector2(-15F, 2F));
                    builder.AddCubicBezier(new Vector2(-15F, 3.0999999F), new Vector2(-14.1000004F, 4F), new Vector2(-13F, 4F));
                    builder.EndFigure(CanvasFigureLoop.Closed);
                    result = CanvasGeometry.CreatePath(builder);
                }
                return result;
            }

            // - - - - - Layer aggregator
            // - - - Transforms: task-2 Offset:<-6, 0>
            // - Path
            CanvasGeometry Geometry_6()
            {
                CanvasGeometry result;
                using (var builder = new CanvasPathBuilder(null))
                {
                    builder.SetFilledRegionDetermination(CanvasFilledRegionDetermination.Winding);
                    builder.BeginFigure(new Vector2(-13F, 4F));
                    builder.AddCubicBezier(new Vector2(-13F, 4F), new Vector2(17.25F, 4F), new Vector2(17.25F, 4F));
                    builder.AddCubicBezier(new Vector2(18.3500004F, 4F), new Vector2(19.25F, 3.0999999F), new Vector2(19.25F, 2F));
                    builder.AddCubicBezier(new Vector2(19.25F, 2F), new Vector2(19.25F, -2F), new Vector2(19.25F, -2F));
                    builder.AddCubicBezier(new Vector2(19.25F, -3.0999999F), new Vector2(18.3500004F, -4F), new Vector2(17.25F, -4F));
                    builder.AddCubicBezier(new Vector2(17.25F, -4F), new Vector2(-13F, -4F), new Vector2(-13F, -4F));
                    builder.AddCubicBezier(new Vector2(-14.1000004F, -4F), new Vector2(-15F, -3.0999999F), new Vector2(-15F, -2F));
                    builder.AddCubicBezier(new Vector2(-15F, -2F), new Vector2(-15F, 2F), new Vector2(-15F, 2F));
                    builder.AddCubicBezier(new Vector2(-15F, 3.0999999F), new Vector2(-14.1000004F, 4F), new Vector2(-13F, 4F));
                    builder.EndFigure(CanvasFigureLoop.Closed);
                    result = CanvasGeometry.CreatePath(builder);
                }
                return result;
            }

            CanvasGeometry Geometry_7()
            {
                CanvasGeometry result;
                using (var builder = new CanvasPathBuilder(null))
                {
                    builder.SetFilledRegionDetermination(CanvasFilledRegionDetermination.Winding);
                    builder.BeginFigure(new Vector2(-3F, 4F));
                    builder.AddCubicBezier(new Vector2(-3F, 4F), new Vector2(3F, 4F), new Vector2(3F, 4F));
                    builder.AddCubicBezier(new Vector2(4.0999999F, 4F), new Vector2(5F, 3.0999999F), new Vector2(5F, 2F));
                    builder.AddCubicBezier(new Vector2(5F, 2F), new Vector2(5F, -2F), new Vector2(5F, -2F));
                    builder.AddCubicBezier(new Vector2(5F, -3.0999999F), new Vector2(4.0999999F, -4F), new Vector2(3F, -4F));
                    builder.AddCubicBezier(new Vector2(3F, -4F), new Vector2(-3F, -4F), new Vector2(-3F, -4F));
                    builder.AddCubicBezier(new Vector2(-4.0999999F, -4F), new Vector2(-5F, -3.0999999F), new Vector2(-5F, -2F));
                    builder.AddCubicBezier(new Vector2(-5F, -2F), new Vector2(-5F, 2F), new Vector2(-5F, 2F));
                    builder.AddCubicBezier(new Vector2(-5F, 3.0999999F), new Vector2(-4.0999999F, 4F), new Vector2(-3F, 4F));
                    builder.EndFigure(CanvasFigureLoop.Closed);
                    result = CanvasGeometry.CreatePath(builder);
                }
                return result;
            }

            // - - - - - Layer aggregator
            // - - - Transforms: task-1 Offset:<-16, -12>
            // - Path
            CanvasGeometry Geometry_8()
            {
                CanvasGeometry result;
                using (var builder = new CanvasPathBuilder(null))
                {
                    builder.SetFilledRegionDetermination(CanvasFilledRegionDetermination.Winding);
                    builder.BeginFigure(new Vector2(-3F, 4F));
                    builder.AddCubicBezier(new Vector2(-3F, 4F), new Vector2(22F, 4F), new Vector2(22F, 4F));
                    builder.AddCubicBezier(new Vector2(23.1000004F, 4F), new Vector2(24F, 3.0999999F), new Vector2(24F, 2F));
                    builder.AddCubicBezier(new Vector2(24F, 2F), new Vector2(24F, -2F), new Vector2(24F, -2F));
                    builder.AddCubicBezier(new Vector2(24F, -3.0999999F), new Vector2(23.1000004F, -4F), new Vector2(22F, -4F));
                    builder.AddCubicBezier(new Vector2(22F, -4F), new Vector2(-3F, -4F), new Vector2(-3F, -4F));
                    builder.AddCubicBezier(new Vector2(-4.0999999F, -4F), new Vector2(-5F, -3.0999999F), new Vector2(-5F, -2F));
                    builder.AddCubicBezier(new Vector2(-5F, -2F), new Vector2(-5F, 2F), new Vector2(-5F, 2F));
                    builder.AddCubicBezier(new Vector2(-5F, 3.0999999F), new Vector2(-4.0999999F, 4F), new Vector2(-3F, 4F));
                    builder.EndFigure(CanvasFigureLoop.Closed);
                    result = CanvasGeometry.CreatePath(builder);
                }
                return result;
            }

            // - - - - - Layer aggregator
            // - - - Transforms: task-1 Offset:<-16, -12>
            // - Path
            CanvasGeometry Geometry_9()
            {
                CanvasGeometry result;
                using (var builder = new CanvasPathBuilder(null))
                {
                    builder.SetFilledRegionDetermination(CanvasFilledRegionDetermination.Winding);
                    builder.BeginFigure(new Vector2(-3F, 4F));
                    builder.AddCubicBezier(new Vector2(-3F, 4F), new Vector2(0.375F, 4F), new Vector2(0.375F, 4F));
                    builder.AddCubicBezier(new Vector2(1.47500002F, 4F), new Vector2(2.375F, 3.0999999F), new Vector2(2.375F, 2F));
                    builder.AddCubicBezier(new Vector2(2.375F, 2F), new Vector2(2.375F, -2F), new Vector2(2.375F, -2F));
                    builder.AddCubicBezier(new Vector2(2.375F, -3.0999999F), new Vector2(1.47500002F, -4F), new Vector2(0.375F, -4F));
                    builder.AddCubicBezier(new Vector2(0.375F, -4F), new Vector2(-3F, -4F), new Vector2(-3F, -4F));
                    builder.AddCubicBezier(new Vector2(-4.0999999F, -4F), new Vector2(-5F, -3.0999999F), new Vector2(-5F, -2F));
                    builder.AddCubicBezier(new Vector2(-5F, -2F), new Vector2(-5F, 2F), new Vector2(-5F, 2F));
                    builder.AddCubicBezier(new Vector2(-5F, 3.0999999F), new Vector2(-4.0999999F, 4F), new Vector2(-3F, 4F));
                    builder.EndFigure(CanvasFigureLoop.Closed);
                    result = CanvasGeometry.CreatePath(builder);
                }
                return result;
            }

            // - - - Layer aggregator
            // - Transforms: task-2 Offset:<-6, 0>
            // Stop 0
            CompositionColorGradientStop GradientStop_0_AlmostDodgerBlue_FF1EA1E3()
            {
                return _c.CreateColorGradientStop(0F, Color.FromArgb(0xFF, 0x1E, 0xA1, 0xE3));
            }

            // Stop 0
            CompositionColorGradientStop GradientStop_0_AlmostMediumTurquoise_FF31BCEE()
            {
                return (_gradientStop_0_AlmostMediumTurquoise_FF31BCEE == null)
                    ? _gradientStop_0_AlmostMediumTurquoise_FF31BCEE = _c.CreateColorGradientStop(0F, Color.FromArgb(0xFF, 0x31, 0xBC, 0xEE))
                    : _gradientStop_0_AlmostMediumTurquoise_FF31BCEE;
            }

            // Stop 1
            CompositionColorGradientStop GradientStop_0p69_AlmostTeal_FF05509B()
            {
                return (_gradientStop_0p69_AlmostTeal_FF05509B == null)
                    ? _gradientStop_0p69_AlmostTeal_FF05509B = _c.CreateColorGradientStop(0.689999998F, Color.FromArgb(0xFF, 0x05, 0x50, 0x9B))
                    : _gradientStop_0p69_AlmostTeal_FF05509B;
            }

            // Stop 0
            CompositionColorGradientStop GradientStop_0p429_AlmostTeal_FF054E97()
            {
                return (_gradientStop_0p429_AlmostTeal_FF054E97 == null)
                    ? _gradientStop_0p429_AlmostTeal_FF054E97 = _c.CreateColorGradientStop(0.42899999F, Color.FromArgb(0xFF, 0x05, 0x4E, 0x97))
                    : _gradientStop_0p429_AlmostTeal_FF054E97;
            }

            // Stop 2
            CompositionColorGradientStop GradientStop_0p845_AlmostMidnightBlue_FF044689()
            {
                return (_gradientStop_0p845_AlmostMidnightBlue_FF044689 == null)
                    ? _gradientStop_0p845_AlmostMidnightBlue_FF044689 = _c.CreateColorGradientStop(0.845000029F, Color.FromArgb(0xFF, 0x04, 0x46, 0x89))
                    : _gradientStop_0p845_AlmostMidnightBlue_FF044689;
            }

            // - - - Layer aggregator
            // - Transforms: task-3 Offset:<-8.5, 12>
            // Stop 1
            CompositionColorGradientStop GradientStop_0p995_AlmostDodgerBlue_FF1EA1E3()
            {
                return _c.CreateColorGradientStop(0.995000005F, Color.FromArgb(0xFF, 0x1E, 0xA1, 0xE3));
            }

            // - - - Layer aggregator
            // - Transforms: task-1 Offset:<-16, -12>
            // Stop 1
            CompositionColorGradientStop GradientStop_1_AlmostDodgerBlue_FF1EA1E3()
            {
                return _c.CreateColorGradientStop(1F, Color.FromArgb(0xFF, 0x1E, 0xA1, 0xE3));
            }

            // - - - Layer aggregator
            // - Transforms: task-2 Offset:<-6, 0>
            // Stop 1
            CompositionColorGradientStop GradientStop_1_AlmostMediumTurquoise_FF31BCEE()
            {
                return _c.CreateColorGradientStop(1F, Color.FromArgb(0xFF, 0x31, 0xBC, 0xEE));
            }

            // Stop 3
            CompositionColorGradientStop GradientStop_1_AlmostMidnightBlue_FF033D78()
            {
                return (_gradientStop_1_AlmostMidnightBlue_FF033D78 == null)
                    ? _gradientStop_1_AlmostMidnightBlue_FF033D78 = _c.CreateColorGradientStop(1F, Color.FromArgb(0xFF, 0x03, 0x3D, 0x78))
                    : _gradientStop_1_AlmostMidnightBlue_FF033D78;
            }

            // Layer aggregator
            CompositionContainerShape ContainerShape()
            {
                if (_containerShape != null) { return _containerShape; }
                var result = _containerShape = _c.CreateContainerShape();
                result.Offset = new Vector2(24F, 24F);
                var shapes = result.Shapes;
                // Transforms: task-6 Offset:<0, 12>
                shapes.Add(SpriteShape_0());
                // ShapeGroup: Group 1
                shapes.Add(SpriteShape_1());
                // Transforms: task-4 Offset:<0, -12>
                shapes.Add(SpriteShape_2());
                // Transforms: task-3 Offset:<-8.5, 12>
                shapes.Add(SpriteShape_3());
                // Transforms: task-2 Offset:<-6, 0>
                shapes.Add(SpriteShape_4());
                // Transforms: task-1 Offset:<-16, -12>
                shapes.Add(SpriteShape_5());
                return result;
            }

            // - - Layer aggregator
            // Transforms: task-6 Offset:<0, 12>
            CompositionLinearGradientBrush LinearGradientBrush_0()
            {
                var result = _c.CreateLinearGradientBrush();
                var colorStops = result.ColorStops;
                colorStops.Add(GradientStop_0p429_AlmostTeal_FF054E97());
                colorStops.Add(GradientStop_0p69_AlmostTeal_FF05509B());
                colorStops.Add(GradientStop_0p845_AlmostMidnightBlue_FF044689());
                colorStops.Add(GradientStop_1_AlmostMidnightBlue_FF033D78());
                result.MappingMode = CompositionMappingMode.Absolute;
                result.StartPoint = new Vector2(10.125F, 2.81200004F);
                result.EndPoint = new Vector2(10.125F, -5.22300005F);
                return result;
            }

            // - - Layer aggregator
            // ShapeGroup: Group 1
            CompositionLinearGradientBrush LinearGradientBrush_1()
            {
                var result = _c.CreateLinearGradientBrush();
                var colorStops = result.ColorStops;
                colorStops.Add(GradientStop_0p429_AlmostTeal_FF054E97());
                colorStops.Add(GradientStop_0p69_AlmostTeal_FF05509B());
                colorStops.Add(GradientStop_0p845_AlmostMidnightBlue_FF044689());
                colorStops.Add(GradientStop_1_AlmostMidnightBlue_FF033D78());
                result.MappingMode = CompositionMappingMode.Absolute;
                result.StartPoint = new Vector2(3.875F, 2F);
                result.EndPoint = new Vector2(3.75F, -6.70200014F);
                return result;
            }

            // - - Layer aggregator
            // Transforms: task-4 Offset:<0, -12>
            CompositionLinearGradientBrush LinearGradientBrush_2()
            {
                var result = _c.CreateLinearGradientBrush();
                var colorStops = result.ColorStops;
                colorStops.Add(GradientStop_0p429_AlmostTeal_FF054E97());
                colorStops.Add(GradientStop_0p69_AlmostTeal_FF05509B());
                colorStops.Add(GradientStop_0p845_AlmostMidnightBlue_FF044689());
                colorStops.Add(GradientStop_1_AlmostMidnightBlue_FF033D78());
                result.MappingMode = CompositionMappingMode.Absolute;
                result.StartPoint = new Vector2(-0.5F, 3F);
                result.EndPoint = new Vector2(-0.5F, -5.65700006F);
                return result;
            }

            // - - Layer aggregator
            // Transforms: task-3 Offset:<-8.5, 12>
            CompositionLinearGradientBrush LinearGradientBrush_3()
            {
                var result = _c.CreateLinearGradientBrush();
                var colorStops = result.ColorStops;
                colorStops.Add(GradientStop_0_AlmostMediumTurquoise_FF31BCEE());
                colorStops.Add(GradientStop_0p995_AlmostDodgerBlue_FF1EA1E3());
                result.MappingMode = CompositionMappingMode.Absolute;
                result.StartPoint = new Vector2(0F, -3.125F);
                result.EndPoint = new Vector2(0.25F, 4.89599991F);
                return result;
            }

            // - - Layer aggregator
            // Transforms: task-2 Offset:<-6, 0>
            CompositionLinearGradientBrush LinearGradientBrush_4()
            {
                var result = _c.CreateLinearGradientBrush();
                var colorStops = result.ColorStops;
                colorStops.Add(GradientStop_0_AlmostDodgerBlue_FF1EA1E3());
                colorStops.Add(GradientStop_1_AlmostMediumTurquoise_FF31BCEE());
                result.MappingMode = CompositionMappingMode.Absolute;
                result.StartPoint = new Vector2(-0.061999999F, 4.375F);
                result.EndPoint = new Vector2(-0.125F, -3.68600011F);
                return result;
            }

            // - - Layer aggregator
            // Transforms: task-1 Offset:<-16, -12>
            CompositionLinearGradientBrush LinearGradientBrush_5()
            {
                var result = _c.CreateLinearGradientBrush();
                var colorStops = result.ColorStops;
                colorStops.Add(GradientStop_0_AlmostMediumTurquoise_FF31BCEE());
                colorStops.Add(GradientStop_1_AlmostDodgerBlue_FF1EA1E3());
                result.MappingMode = CompositionMappingMode.Absolute;
                result.StartPoint = new Vector2(-0.561999977F, -3.93799996F);
                result.EndPoint = new Vector2(-0.625F, 4.66300011F);
                return result;
            }

            CompositionPath Path_0()
            {
                if (_path_0 != null) { return _path_0; }
                var result = _path_0 = new CompositionPath(Geometry_1());
                return result;
            }

            CompositionPath Path_1()
            {
                if (_path_1 != null) { return _path_1; }
                var result = _path_1 = new CompositionPath(Geometry_4());
                return result;
            }

            CompositionPath Path_2()
            {
                if (_path_2 != null) { return _path_2; }
                var result = _path_2 = new CompositionPath(Geometry_7());
                return result;
            }

            CompositionPathGeometry PathGeometry_0()
            {
                return (_pathGeometry_0 == null)
                    ? _pathGeometry_0 = _c.CreatePathGeometry(new CompositionPath(Geometry_0()))
                    : _pathGeometry_0;
            }

            // - - Layer aggregator
            // Transforms: task-3 Offset:<-8.5, 12>
            CompositionPathGeometry PathGeometry_1()
            {
                if (_pathGeometry_1 != null) { return _pathGeometry_1; }
                var result = _pathGeometry_1 = _c.CreatePathGeometry();
                return result;
            }

            // - - Layer aggregator
            // Transforms: task-2 Offset:<-6, 0>
            CompositionPathGeometry PathGeometry_2()
            {
                if (_pathGeometry_2 != null) { return _pathGeometry_2; }
                var result = _pathGeometry_2 = _c.CreatePathGeometry();
                return result;
            }

            // - - Layer aggregator
            // Transforms: task-1 Offset:<-16, -12>
            CompositionPathGeometry PathGeometry_3()
            {
                if (_pathGeometry_3 != null) { return _pathGeometry_3; }
                var result = _pathGeometry_3 = _c.CreatePathGeometry();
                return result;
            }

            // - Layer aggregator
            // Path 1
            CompositionSpriteShape SpriteShape_0()
            {
                // Offset:<0, 12>
                var geometry = PathGeometry_0();
                var result = CreateSpriteShape(geometry, new Matrix3x2(1F, 0F, 0F, 1F, 0F, 12F), LinearGradientBrush_0()); ;
                return result;
            }

            // - Layer aggregator
            // Path 1
            CompositionSpriteShape SpriteShape_1()
            {
                var result = _c.CreateSpriteShape(PathGeometry_0());
                result.FillBrush = LinearGradientBrush_1();
                return result;
            }

            // - Layer aggregator
            // Path 1
            CompositionSpriteShape SpriteShape_2()
            {
                // Offset:<0, -12>
                var geometry = PathGeometry_0();
                var result = CreateSpriteShape(geometry, new Matrix3x2(1F, 0F, 0F, 1F, 0F, -12F), LinearGradientBrush_2()); ;
                return result;
            }

            // - Layer aggregator
            // Path 1
            CompositionSpriteShape SpriteShape_3()
            {
                // Offset:<-8.5, 12>
                var geometry = PathGeometry_1();
                var result = CreateSpriteShape(geometry, new Matrix3x2(1F, 0F, 0F, 1F, -8.5F, 12F), LinearGradientBrush_3()); ;
                return result;
            }

            // - Layer aggregator
            // Path 1
            CompositionSpriteShape SpriteShape_4()
            {
                // Offset:<-6, 0>
                var geometry = PathGeometry_2();
                var result = CreateSpriteShape(geometry, new Matrix3x2(1F, 0F, 0F, 1F, -6F, 0F), LinearGradientBrush_4()); ;
                return result;
            }

            // - Layer aggregator
            // Path 1
            CompositionSpriteShape SpriteShape_5()
            {
                // Offset:<-16, -12>
                var geometry = PathGeometry_3();
                var result = CreateSpriteShape(geometry, new Matrix3x2(1F, 0F, 0F, 1F, -16F, -12F), LinearGradientBrush_5()); ;
                return result;
            }

            // The root of the composition.
            ContainerVisual Root()
            {
                if (_root != null) { return _root; }
                var result = _root = _c.CreateContainerVisual();
                var propertySet = result.Properties;
                propertySet.InsertScalar("Progress", 0F);
                // Layer aggregator
                result.Children.InsertAtTop(ShapeVisual_0());
                return result;
            }

            CubicBezierEasingFunction CubicBezierEasingFunction_0()
            {
                return (_cubicBezierEasingFunction_0 == null)
                    ? _cubicBezierEasingFunction_0 = _c.CreateCubicBezierEasingFunction(new Vector2(0.333000004F, 0F), new Vector2(0.666999996F, 1F))
                    : _cubicBezierEasingFunction_0;
            }

            // - - - Layer aggregator
            // - Transforms: task-3 Offset:<-8.5, 12>
            // Path
            PathKeyFrameAnimation PathKeyFrameAnimation_0()
            {
                // Frame 0.
                var result = CreatePathKeyFrameAnimation(0F, Path_0(), StepThenHoldEasingFunction());
                // Frame 3.
                result.InsertKeyFrame(0.107142858F, Path_0(), HoldThenStepEasingFunction());
                // Frame 10.
                result.InsertKeyFrame(0.357142866F, new CompositionPath(Geometry_2()), CubicBezierEasingFunction_0());
                // Frame 18.
                result.InsertKeyFrame(0.642857134F, new CompositionPath(Geometry_3()), CubicBezierEasingFunction_0());
                // Frame 25.
                result.InsertKeyFrame(0.892857134F, Path_0(), CubicBezierEasingFunction_0());
                return result;
            }

            // - - - Layer aggregator
            // - Transforms: task-2 Offset:<-6, 0>
            // Path
            PathKeyFrameAnimation PathKeyFrameAnimation_1()
            {
                // Frame 0.
                var result = CreatePathKeyFrameAnimation(0F, Path_1(), StepThenHoldEasingFunction());
                // Frame 3.
                result.InsertKeyFrame(0.107142858F, Path_1(), HoldThenStepEasingFunction());
                // Frame 10.
                result.InsertKeyFrame(0.357142866F, new CompositionPath(Geometry_5()), CubicBezierEasingFunction_0());
                // Frame 18.
                result.InsertKeyFrame(0.642857134F, new CompositionPath(Geometry_6()), CubicBezierEasingFunction_0());
                // Frame 25.
                result.InsertKeyFrame(0.892857134F, Path_1(), CubicBezierEasingFunction_0());
                return result;
            }

            // - - - Layer aggregator
            // - Transforms: task-1 Offset:<-16, -12>
            // Path
            PathKeyFrameAnimation PathKeyFrameAnimation_2()
            {
                // Frame 0.
                var result = CreatePathKeyFrameAnimation(0F, Path_2(), StepThenHoldEasingFunction());
                // Frame 3.
                result.InsertKeyFrame(0.107142858F, Path_2(), HoldThenStepEasingFunction());
                // Frame 10.
                result.InsertKeyFrame(0.357142866F, new CompositionPath(Geometry_8()), CubicBezierEasingFunction_0());
                // Frame 18.
                result.InsertKeyFrame(0.642857134F, new CompositionPath(Geometry_9()), CubicBezierEasingFunction_0());
                // Frame 25.
                result.InsertKeyFrame(0.892857134F, Path_2(), CubicBezierEasingFunction_0());
                return result;
            }

            // Layer aggregator
            ShapeVisual ShapeVisual_0()
            {
                var result = _c.CreateShapeVisual();
                result.Size = new Vector2(48F, 48F);
                result.Shapes.Add(ContainerShape());
                return result;
            }

            StepEasingFunction HoldThenStepEasingFunction()
            {
                if (_holdThenStepEasingFunction != null) { return _holdThenStepEasingFunction; }
                var result = _holdThenStepEasingFunction = _c.CreateStepEasingFunction();
                result.IsFinalStepSingleFrame = true;
                return result;
            }

            StepEasingFunction StepThenHoldEasingFunction()
            {
                if (_stepThenHoldEasingFunction != null) { return _stepThenHoldEasingFunction; }
                var result = _stepThenHoldEasingFunction = _c.CreateStepEasingFunction();
                result.IsInitialStepSingleFrame = true;
                return result;
            }

            // - Layer aggregator
            // Scale
            Vector2KeyFrameAnimation ScaleVector2Animation()
            {
                // Frame 0.
                var result = CreateVector2KeyFrameAnimation(0F, new Vector2(1F, 1F), StepThenHoldEasingFunction());
                // Frame 3.
                result.InsertKeyFrame(0.107142858F, new Vector2(1F, 1F), HoldThenStepEasingFunction());
                // Frame 10.
                result.InsertKeyFrame(0.357142866F, new Vector2(0.949999988F, 0.949999988F), CubicBezierEasingFunction_0());
                // Frame 18.
                result.InsertKeyFrame(0.642857134F, new Vector2(1.04999995F, 1.04999995F), CubicBezierEasingFunction_0());
                // Frame 25.
                result.InsertKeyFrame(0.892857134F, new Vector2(1F, 1F), CubicBezierEasingFunction_0());
                return result;
            }

            internal View_AnimatedVisual(
                Compositor compositor
                )
            {
                _c = compositor;
                _reusableExpressionAnimation = compositor.CreateExpressionAnimation();
                Root();
            }

            public Visual RootVisual => _root;
            public TimeSpan Duration => TimeSpan.FromTicks(c_durationTicks);
            public Vector2 Size => new Vector2(48F, 48F);
            void IDisposable.Dispose() => _root?.Dispose();

            public void CreateAnimations()
            {
                _containerShape.StartAnimation("Scale", ScaleVector2Animation(), AnimationController_0());
                _pathGeometry_1.StartAnimation("Path", PathKeyFrameAnimation_0(), AnimationController_0());
                _pathGeometry_2.StartAnimation("Path", PathKeyFrameAnimation_1(), AnimationController_0());
                _pathGeometry_3.StartAnimation("Path", PathKeyFrameAnimation_2(), AnimationController_0());
            }

            public void DestroyAnimations()
            {
                _containerShape.StopAnimation("Scale");
                _pathGeometry_1.StopAnimation("Path");
                _pathGeometry_2.StopAnimation("Path");
                _pathGeometry_3.StopAnimation("Path");
            }

        }
    }
}
