Open soxunyi opened 3 years ago
Any update on this? I can't figure out how to render lotties with a transparent background
@soxunyi , lottie2gif is just an example app to quickly test the rendering without any UI framework. not sure whats the usecase. there maybe better tools in lottiefiles to a gif. @hermet , I think you have added the background color support to lottie2gif. is it possible to support transparent background ?
Any updates here?
Hi, basically gif doesn't support the alpha channel. gif89a format might support transparent but current gif builder in lottie2gif doesn't support it. Sorry for that.
Is there an option for getting transparent pngs for every frame? Thanks for your reply :-)
@IdanRot I think your requirement can be done by slightly modifying https://github.com/XieJiSS/rlottie/commit/6f2d8b7519f63db1458dbcc06d88ac7f4624df42, and the glitched output caused by frame composing could be fixed by ImageMagick convert -set dispose previous input.gif output.gif
.
Run
lottie2gif example.json 500x500 0x00ffffff
in ternimal, and the background of example.json.gif is white, and the fully transparent is not work. The bgColor is not supported alpha value?