c# - Xamarin 洛蒂动画

标签 c# xamarin.forms lottie

我正在尝试使用 Lottie 来显示动画,但是当我为 Android 调试它时遇到了问题:

LottieAnimationView not displayed because it is too large to fit into a software layer (or drawing cache), needs 9072000 bytes, only 8294400 available

我的 XAML 代码:

<ContentPage.Content>
<StackLayout VerticalOptions="FillAndExpand" HorizontalOptions="FillAndExpand">
    <forms:AnimationView
        x:Name="AnimationView"
        Animation="data.json"
        AutoPlay="True" Loop="true"
        VerticalOptions="FillAndExpand"
        HorizontalOptions="FillAndExpand"
        Scale="0.2"/>
</StackLayout>

谁能帮我解决这个问题?

最佳答案

您需要在 After Effects 中更改动画的导出设置,以适应软件层限制

enter image description here

关于c# - Xamarin 洛蒂动画,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/53366331/

相关文章:

ios - 带 Lottie 的动态按钮

c# - MasterDetail 汉堡包菜单在按下后退按钮时消失

android - 洛蒂 + Jetpack 组合

c# - WCF 保护级别

c# - 将 Html.Partial 添加到 Javascript

c# - C# 中修饰符 static 对于此项错误无效

xaml - 新的 OnPlatform/OnIdiom XAML 扩展 - 边距厚度的用法

xcode - react native 构建失败 - xcodebuild : error: The workspace named "foo" does not contain a scheme named "foo"

c# - 将 IEnumerable 添加到 RouteValueDictionary - 这可能吗?

c# - 如何在 C# 中使用 EWS 从 Exchange 获取 HTML 和文本格式的电子邮件正文?