FORUMS: list search recent posts

pausing external swf with flv from main movie

COW Forums : Adobe Flash

<< PREVIOUS   •   FAQ   •   VIEW ALL   •   PRINT   •   NEXT >>
brian hoven
pausing external swf with flv from main movie
on Mar 10, 2010 at 10:24:09 pm

my main movie calls up 7 individual swf files. Each of those contains a streaming flv file.

I want to have the ability to pause all those flv files when rolling over a button on the main movie.

Is this possible?

Here is the code i use to bring in the swf files:



var swf1:MovieClip;
var loader1:Loader = new Loader();

var defaultSWF1:URLRequest = new URLRequest("hatha.swf");
loader1.load(defaultSWF1);
addChildAt(loader1, 0);

loader1.x=0;
loader1.y=100;


var swf2:MovieClip;
var loader2:Loader = new Loader();

var defaultSWF2:URLRequest = new URLRequest("everyday.swf");
loader2.load(defaultSWF2);
addChildAt(loader2, 0);
loader2.x=140;
loader2.y=100;


var swf3:MovieClip;
var loader3:Loader = new Loader();

var defaultSWF3:URLRequest = new URLRequest("hstand.swf");
loader3.load(defaultSWF3);
addChildAt(loader3, 0);
loader3.x=280;
loader3.y=100;

and so on...

any help would be GREATLY appreciated.


Return to posts index

Brodd Nesset
Re: pausing external swf with flv from main movie
on Mar 11, 2010 at 1:24:19 pm

You can treat the loaded SWFs like any MovieClip, i.e. myLoadedSWF.stop(); and so on.

But how do the FLV play inside the SWFs? If you're using the Flash Video Playback Component, you need to give this an instance name like you would for a MovieClip. It is not required for simple playback (and user interaction), but it you need it for ActionScript control. If you name the Video Playback component instance "myVideo", then you can stop the loaded SWF playing its video like this:

myLoadedSWF.myVideo.stop();



Not everything that can be counted counts, and not everything that counts can be counted.



Return to posts index

brian hoven
Re: pausing external swf with flv from main movie
on Mar 11, 2010 at 5:52:03 pm

Thanks so much for your response.

The issue i'm having is that those swfs being called are playing flv files streaming from my server.

can i still have it stop/pause? i'm not sure where/what to give an instance name.

thanks!


Return to posts index


brian hoven
Re: pausing external swf with flv from main movie
on Mar 11, 2010 at 6:17:35 pm

and if you are looking at this code in the main mc:

var swf1:MovieClip;
var loader1:Loader = new Loader();

var defaultSWF1:URLRequest = new URLRequest("hatha.swf");
loader1.load(defaultSWF1);
addChildAt(loader1, 0);

loader1.x=0;
loader1.y=100;


what is the name of the 'instance' of the loaded swf? which one of these do i use to communicate to it? thanks!


Return to posts index

brian hoven
Re: pausing external swf with flv from main movie
on Mar 11, 2010 at 8:59:36 pm

scratch that! i got it thanks.



Return to posts index

Brodd Nesset
Re: pausing external swf with flv from main movie
on Mar 12, 2010 at 11:35:50 am

Note that Adobe recommends myVid.togglePause(); for stopping a videostream, mid stream so to speak.
You can issue togglePause(); again for resuming playback. Neat.
Stop() and Play() will work too.



Not everything that can be counted counts, and not everything that counts can be counted.



Return to posts index

<< PREVIOUS   •   VIEW ALL   •   PRINT   •   NEXT >>
© 2018 CreativeCOW.net All Rights Reserved
[TOP]