xvrh / lottie-flutter

Render After Effects animations natively on Flutter. This package is a pure Dart implementation of a Lottie player.
https://pub.dev/packages/lottie
MIT License
1.16k stars 196 forks source link

Large memory problem #232

Open WQDev2013 opened 2 years ago

WQDev2013 commented 2 years ago

When it loads 300 images with an average size of 2KB, my app increases memory by more than 300M.

AMAL-KVS commented 3 months ago

i have also this problem !

xvrh commented 3 months ago

@AMAL-KVS can you produce a reproducible example?

AMAL-KVS commented 3 months ago

`` @xvrh Am using LottieBuilder.network , In the perfeomece testing we got high Rss Value ' 1.9 GB ' , how can i reduce the rss value or how can i optimize the Lotti Builder ?

My code : `Align( alignment: Alignment.bottomCenter, child: LottieBuilder.network( myUrl, controller: widget.lottieController, fit: BoxFit.fitWidth, filterQuality: FilterQuality.none, frameRate: FrameRate.max, onLoaded: (LottieComposition composition) { widget.lottieController ..duration = composition.duration ..value = widget.page.value / 4; }, errorBuilder: (, , ) { return const SizedBox();

            },
          ),
        )`