looping video and callbacks
Posted: Tue Nov 22, 2011 11:56 am
Hi,
I want to play a video in a player, and have it play forwards, then backwards, then forwards...
and before you ask, the video would be a rotation of an object, where I set up just a section of the video to play.
This would give the effect of the object slowly spinning backs and forwards, but not a complete rotation.
I'm trying to do this with callbacks.
First time round, I set up a callback so that when the player gets to x, the callback is invoked, which sets the play speed to the negative of the play speed. I then set up a new call back to be triggered when it gets back to the first frame, which of course sets the play speed back to positive.
This works first time round, the end is reached, the callback invoked, the speed set to negative, and the movie plays backwards. The property inspector shows a new callback is in place to be invoked when the movie gets back to the first frame.
However, the new callback is never invoked.
It seems that once a callback is set up, the player can be given a new callback, which it merely ignores.
Starting and stopping the player makes no difference - subsequent callbacks are ignored.
Any suggestions please ?
I want to play a video in a player, and have it play forwards, then backwards, then forwards...
and before you ask, the video would be a rotation of an object, where I set up just a section of the video to play.
This would give the effect of the object slowly spinning backs and forwards, but not a complete rotation.
I'm trying to do this with callbacks.
First time round, I set up a callback so that when the player gets to x, the callback is invoked, which sets the play speed to the negative of the play speed. I then set up a new call back to be triggered when it gets back to the first frame, which of course sets the play speed back to positive.
This works first time round, the end is reached, the callback invoked, the speed set to negative, and the movie plays backwards. The property inspector shows a new callback is in place to be invoked when the movie gets back to the first frame.
However, the new callback is never invoked.
It seems that once a callback is set up, the player can be given a new callback, which it merely ignores.
Starting and stopping the player makes no difference - subsequent callbacks are ignored.
Any suggestions please ?