Exemplo n.º 1
0
        public static AnimatedLottie file(string path, Key key = null, Curve curve = null, TimeSpan?duration = null,
                                          float frame          = 0)
        {
            var skottie = new Skottie(Path.Combine(Application.streamingAssetsPath, path));

            duration = duration ?? TimeSpan.FromSeconds(skottie.duration());
            return(new AnimatedLottie(skottie, key, curve, duration, frame));
        }
Exemplo n.º 2
0
 public Lottie(string path, float frame = 0, Size size = null, int round = -1)
 {
     D.assert(path != null);
     _skottie  = new Skottie(Path.Combine(Application.streamingAssetsPath, path));
     _duration = _skottie.duration();
     _round    = round;
     _frame    = frame * _duration;
     _size     = size;
 }
Exemplo n.º 3
0
 public RenderLottie(
     Skottie skottie,
     float?width  = null,
     float?height = null,
     float scale  = 1.0f,
     float frame  = 0
     )
 {
     _width    = width;
     _height   = height;
     _scale    = scale;
     _skottie  = skottie;
     _frame    = frame;
     _duration = skottie.duration();
 }
Exemplo n.º 4
0
 public LottieRenderObjectWidget(Skottie anime, float frame)
 {
     _anime    = anime;
     _frame    = frame;
     _duration = anime.duration();
 }