-
Bmcc*81
FLV: Adding Controls - that work with text animation
Hi,
I have this video I made that has an flv with simple play, pause and stop. But I need to add replay.
The thing is that the buttons that I have already don't stop, and play the text animations.
How do I get this to stop and play the text animations as well as the video.
This is my listener for the FLV
Code:
var n = 0
var listenerObject:Object = new Object();
listenerObject.cuePoint = function(eventObject:Object):Void {
trace("Elapsed time in seconds: " + flv_mc2.my_FLVPlybk2.playheadTime);
n = n + 20
gotoAndPlay(n)
}
flv_mc2.my_FLVPlybk2.addEventListener("cuePoint", listenerObject);
and these are my controls:
Code:
this._parent.flv_mc2.my_FLVPlybk2.muteButton = mutebtn;
this._parent.flv_mc2.my_FLVPlybk2.playPauseButton = playpausebtn;
function raja()
{
klio();
trace("kliotech");
}
Can someone teach or tell me how to add REPLAY and to have my text animations stop and play in sync with the FLV?
Thanks,
BMCC81
-
Bmcc*81
Anyone know what I'm talking about? Or am I way off?
-
you sound like you need to nest your text animation in a movieclip.
then you can simply add some lines of code to the handler which deals with the "click on button" functionality, eg
Code:
mymovieclip.play();
mymovieclip.stop();
For the replay function, you need to test if the flv has reached the end of it's duration.
You can either test this with a timer and use the (i think) currentTime/Time property of the flvplayback, together with the overall duration property of the clip; or you can just listen for the VideoEvent.COMPLETE event that the flvplayback component dispatches when it has finished playing your FLV.
You don't even really need to do anything with the handler, just seek() to the start of the video, then make sure that the play button is still usable; or just make a replay button, make it seek() to the start of the video, then play().
Does that help?
Dan
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|