[英]Custom animation in splash screen | Flutter
I want to make a custom animated splash screen for a project in flutter.我想为 flutter 中的项目制作自定义动画闪屏。 The output I want is like the one in this video , but I am almost new to animating in flutter and have no idea how to progress on this.我想要的 output 就像这个视频中的那个,但我对 flutter 中的动画几乎是新手,不知道如何在这方面取得进展。 Could someone help me?有人可以帮助我吗?
I would suggest checking the official documentation about animations at first.我建议首先查看有关动画的官方文档。 Also to achieve your desired output, I think lottie provides a good solution which you try out.为了实现您想要的 output,我认为lottie提供了一个很好的解决方案,您可以尝试一下。
Just turn you video .mp4
to .gif
or .json
Use online converters such as Lottie or many others.只需将您的视频.mp4
转换为.gif
或.json
使用Lottie或其他许多在线转换器。 Then Do this;然后这样做;
Image.asset(
"assets/your_animation.gif",
height: 200,
),
..
import 'package:lottie/lottie.dart';
..
Lottie.asset(
"assets/your_animation.json",
height: 200,
),
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.