Skip to content

[BUG] Lottie animations created from movie files do not properly display with Skia Lottie #3242

Open
@vchelaru

Description

@vchelaru

Description

Here is a lottie file:

BadLottie.json

Normally I can play Lottie files in SkiaSharp, but this particular file does not render.

The properties seem to load correctly:

Image

I suspect this has to do with the data coming from a movie file which is not supported by SkiaSharp?

Code

I am rendering the animation to a canvas, but nothing appears.

animation = SkiaSharp.Skottie.Animation.Create(sourceFileAbsolute);
...
animation.Render(surface.Canvas, new SKRect(0, 0, 100, 100));

Expected Behavior

I expect the animation to play. This animation can be previewed on a Lottie viewer such as:

https://www.lottielab.com/preview

Image

Actual Behavior

Nothing is rendered to the canvas - it's blank

Version of SkiaSharp

3.116.0 (Current)

Last Known Good Version of SkiaSharp

Other (Please indicate in the description)

IDE / Editor

Visual Studio (Windows)

Platform / Operating System

Windows

Platform / Operating System Version

  • Windows 11

Devices

Tested on multiple Windows machines.

Relevant Screenshots

No response

Relevant Log Output

Code of Conduct

  • I agree to follow this project's Code of Conduct

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    Status

    New

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions