all groups > macromedia flash flashcom > may 2007 >
You're in the

macromedia flash flashcom

group:

progressive download -> stop buffering at X sec.


progressive download -> stop buffering at X sec. dfm_
5/20/2007 5:31:25 PM
macromedia flash flashcom:
Hello,
I have custom made flash video player, witch pays (.flv)s. I want to make
something like trial of flash video clip. I have flash video clip (.flv) with
time length of 30 sec. I want to buffer only to 10 sec. and whe 10th sec. is
reatch to stop. So in my buffer memory will have only 1/3 of this (.flv). Is it
possible to make? How?

P.S. sorry for my English isn't very good.
Re: progressive download -> stop buffering at X sec. B_Shack
5/21/2007 12:00:00 AM
DFM,
An easy way to implement your timer is to use the playheadUpdate method of the
FLVPlayback component like this...

var listenerObject:Object = new Object();
listenerObject.playheadUpdate = function(eventObject:Object):Void {
// insert event-handling code here
};
my_FLVplybk.addEventListener("playheadUpdate", listenerObject);

Another way would be to use NetStream.time on the publishing stream something
liek this...

my_ns.attachVideo(active_cam);
my_ns.publish("SomeData", "live");
//After 10 seconds, my_ns.time = 10.

//You then stop publishing the stream.
my_ns.publish(false);

//10 seconds later, you publish on the same stream.
my_ns.publish("SomeData", "live");
//my_ns.time resets to 0.

Regards,
Shack

Re: progressive download -> stop buffering at X sec. dfm_
5/21/2007 12:00:00 AM
hello, 10x for RQ

Re: progressive download -> stop buffering at X sec. B_Shack
5/21/2007 12:00:00 AM
DFM,
Here ya go...

AddThis Social Bookmark Button