1

我有一个在我的 Android 应用程序上运行的动画,它显示在模拟器 API 22 上,但没有显示在我的手机上(LG3 API 21)

爪哇:

    LottieAnimationView lottieAnimationView = (LottieAnimationView) findViewById(R.id.animation_view);
    lottieAnimationView.setImageAssetsFolder("images/");
    lottieAnimationView.setAnimation("GM_part_1.json");
    lottieAnimationView.loop(false);
    lottieAnimationView.useExperimentalHardwareAcceleration(true);
    lottieAnimationView.enableMergePathsForKitKatAndAbove(true);
    lottieAnimationView.playAnimation();

布局:

<com.airbnb.lottie.LottieAnimationView
    app:lottie_imageAssetsFolder="images"
    android:scaleType="centerCrop"
    android:id="@+id/animation_view"
    android:layout_width="match_parent"
    android:layout_height="match_parent" />

任何想法为什么会发生这种情况?我该如何解决?

4

0 回答 0