-
Notifications
You must be signed in to change notification settings - Fork 69
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
[BUG] SKLottieView Not Displaying In Android Release Mode #228
Comments
having the same issue, all good in debug mode (.NET 8) |
Maui or Forms? I think it works well with Xamarin Forms, Android release. |
The MAUI one |
No workaround? |
The animations work for me in MAUI, if I drop them in the Resources/Raw folder (they'll have the MauiAsset type). |
I have already followed the site. |
Strange. I've just rebuilt in Release mode and animations are working for me. So either my Release mode is not properly configured (although looking at the building steps it should be), or there's a problem on your end :/ |
Just got some new findings. public class SKLottieImageSourceConverter : IValueConverter
{
public object Convert(object value, Type targetType, object parameter, CultureInfo culture)
{
if (value == null)
return null;
return SKLottieImageSource.FromFile(value.ToString()) as SKLottieImageSource;
}
public object ConvertBack(object value, Type targetType, object parameter, CultureInfo culture)
{
return null;
}
} <skia:SKLottieView Source="{Binding AnimationPath, Converter={StaticResource lottieImageConverter}}"
RepeatMode="Restart"
RepeatCount="-1"
IsAnimationEnabled="True"
HeightRequest="{Binding AnimationHeight}"
WidthRequest="{Binding AnimationWidth}" />
|
Indeed, I can confirm this, I was always using such a converter, that's why it always worked for me (in Release as well) |
@ThumbGen can you show me you xaml file so that I can understand how to apply this for mine? Source="{Binding AnimationPath, Converter={StaticResource lottieImageConverter}} |
I use exactly the code you see in the post above. A converter loading the image from file, and that converter used when defining the Source.
|
@ThumbGen could you tell me where I should put this line? <converters:LottieImageSourceConverter x:Key="LottieImageSourceConverter"/> |
SKLottieView Not Displaying In Android Release Mode
The text was updated successfully, but these errors were encountered: