Lottie动画未按预期工作

4
我正在使用Lottie文件进行动画处理。但是它的加载效果不如预期。应该像这样:http://www.lottiefiles.com/48-progress-bar 当前状态:https://www.dropbox.com/s/xgvj9pss2cauv37/device-2017-04-03-113913.mp4?dl=0
<RelativeLayout xmlns:android="http://schemas.android.com/apk/res/android"
    xmlns:app="http://schemas.android.com/apk/res-auto"
    xmlns:tools="http://schemas.android.com/tools"
    android:layout_width="match_parent"
    android:layout_height="match_parent"
    tools:context="com.icici.iciciappathon.checkout.PaymentSucessActivity"
    android:background="@color/sky_blue">

    <com.airbnb.lottie.LottieAnimationView
        android:id="@+id/animation_view"
        android:layout_width="wrap_content"
        android:layout_height="wrap_content"
        app:lottie_fileName="progress_bar.json"
        app:lottie_loop="true"
        app:lottie_autoPlay="true"
        android:layout_centerInParent="true"/>

</RelativeLayout>

你知道我做错了什么吗?

2个回答

3

你所做的事情没有问题。Lottie相当简单易用。不幸的是,progress_bar.json存在问题。

尝试与设计师联系,也许他可以解决这个问题。


-1

只是更改依赖项对我有效

implementation 'com.airbnb.android:lottie:2.8.0'

implementation 'com.airbnb.android:lottie:3.0.7'

网页内容由stack overflow 提供, 点击上面的
可以查看英文原文,
原文链接