Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Use the new Skottie animation builder #277

Merged
merged 3 commits into from
Apr 16, 2024
Merged

Use the new Skottie animation builder #277

merged 3 commits into from
Apr 16, 2024

Conversation

mattleibow
Copy link
Contributor

@mattleibow mattleibow commented Apr 16, 2024

Description of Change

The new builder supports loading embedded images as well as caching any images or files if they are re-used.

Fixes mono/SkiaSharp#2173

The new builder supports loading embedded images as well as caching any
images or files if they are re-used.
Base automatically changed from dev/skia-v3 to main April 16, 2024 20:22
@mattleibow mattleibow merged commit 7d14149 into main Apr 16, 2024
6 checks passed
@mattleibow mattleibow deleted the dev/lottie branch April 16, 2024 21:06
@Jasbirbhinder
Copy link

@mattleibow I am reposting detail in this post as the other post closed and refered to this. Im adding screenshots and JSON file in this comment, that i am using in my Maui project. embedded image is not loading!!

this is Maui code.
xmlns:skia="clr-namespace:SkiaSharp.Extended.UI.Controls;assembly=SkiaSharp.Extended.UI"

<skia:SKLottieView
BackgroundColor="Red"
HeightRequest="100"
RepeatCount="-1"
Source="https://lottie.host/e6ca851f-5408-44f3-8874-637caebbf0d5/SlgPlLNWlZ.json"
WidthRequest="100" />

1

this it is loading without embedded image
2

this it suppose to load
3

attached json file
blizzard.json

@Glomby
Copy link

Glomby commented Jun 30, 2024

Embedded images work for me with the latest preview updated, so this has definitly improved the usabilty alot. However, I do have some very severe performance issues with my animations that use embedded images. On my android test device the screen renderning goes from 60 Hz (under Xamarin.Forms with lottie) down to 7-12 Hz (with the same lottie animations but under maui).

I testet a few things and removing some other elements gets the fps up to 20 but not 60. I created a small sample project with this issue to test. Maybe the way images are handled causes these performance problems. Here ist the issue, with a link to a sample project. Just press the button to get to the problematic animations:
#283

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Skottie cannot draw animations that have embedded images
3 participants