transitive-bullshit / puppeteer-lottie

Renders Lottie animations via Puppeteer to image, GIF, or MP4.
362 stars 71 forks source link

Option for getting output of specific frames #44

Open affankhan43 opened 3 years ago

affankhan43 commented 3 years ago

Just need to use to options for rendering specific frame images

amiantos commented 3 years ago

How would you use this to get a single frame of animation? I'm confused by the -1 you're doing to the endFrame value. If you want frame 0 of the animation, how would you get it in this context? startFrame = 0, endFrame = 1? I dunno if that makes sense to me.

Can you add some tests? Full disclosure, I tried out this solution on my own and it didn't appear to work.