madsleejensen / react-native-image-sequence

native implementation for creating frame based image animations
MIT License
107 stars 67 forks source link

Add pause at end of animation and start/end callbacks #5

Open tomchambers2 opened 7 years ago

tomchambers2 commented 7 years ago

I'd like to be able to have the animation pause. So the animation will play all its frames and then pause for a defined period of time. Would also be useful to have a callback in order to sync something else happening in the application, in my case playing a sound synchronised with the animation.

Not great with Obj C, but happy to have a go with a few pointers as to how this could be achieved.

rad182 commented 7 years ago

+1

dfc747 commented 7 years ago

I'm not sure if this helps but you can edit RCTImageSequenceView.java , and change animationDrawable.setOneShot(false) to true and it will play one time.

tijsluitse commented 6 years ago

Is there already a solution to play and pause the animation? Or did you find a fix @tomchambers2 ?

skyliwq commented 6 years ago

+1

aiynmm commented 6 years ago

+1

vpsantos commented 5 years ago

Hello, is there any way to play/stop the animation via code?

nester999 commented 1 year ago

+1 to this as well

sleep9 commented 4 months ago

+1