flutter-image-sequence-animator icon indicating copy to clipboard operation
flutter-image-sequence-animator copied to clipboard

[Feature Request] Parameter for number of times to play the animation

Open uzumakinaruto123 opened this issue 2 years ago • 0 comments

Need configuration like sequence plays as boomerang but not in the loop and only once.

Planned to use callbacks onPlaying and onFinishPlaying to manually stop it after 1 iteration but does not seem to be a nice solution.

Also, the issue is these callbacks are fired for every frame/image. So, onPlaying is called 64 times when I have 60 images.

ImageSequenceAnimator(
                "assets/images/newScrollSprites", //folderName
                "", //fileName
                1, //suffixStart
                1, //suffixCount
                "png", //fileFormat
                60, //frameCount
                // fps: 60,
                isBoomerang: true,
                isLooping: false,
                isAutoPlay: false,
                onReadyToPlay: onOfflineReadyToPlay,
                onPlaying: onOfflinePlaying,
                onFinishPlaying: onFinishPlaying,
 )

Parameter like "animationIterations" which respects boomerang property would help.

uzumakinaruto123 avatar Jul 08 '21 08:07 uzumakinaruto123