RE: [Flashcoders] Multiple FLVPlayback problem
That's great arron, I actually started looking into this metod yesterday myself after seeing the activePlayer index in the FLVPlayback component. I was thinking that extending the component would be best. Well, I will be very greatful for your help/class. Cheers Jim -Original Message- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] On Behalf Of aaron smith Sent: 16 May 2006 23:55 To: Flashcoders mailing list Subject: Re: [Flashcoders] Multiple FLVPlayback problem one other thing, you might want to split up your video even more.. like 6 - 10 clips. that way they're way smaller files.. seeking and loading wouldn't be a problem then. aaron smith wrote: I'm also working on a project that requires multiple flv's also. What I did was create a very basic multiple flv player. then with that you listen to whatever events you want to tap into. say for some video controls and what not. I will share it with you later tonight. I need to refactor it a bit and add a little more functionality.. but it works great! I need to build in seeking capabilities and cuepoint capabilities.. other than that. it all works great. I am using with 2 - 5 MB files. of about 2 or 3 files.. so total up those files and generally its about 10 - 15 megs.. as far as preloading the flvs. what you need to do is start playing the first one. then when you get a metadata event for that one. start playing the second one, once you get metadeta for that one. add it to total time and pause it.. it will still continue to download the flv though... so basically you need to wait till one has metadeta.. then start the next one. or you could come up with some other way of doing this. but thats how I had to do it without killing the player because of all the video loading. this way works great locally. over the net it also works great but my files are considerablly smaller. like I said. i'll share this with you later tonight.. I also am planning on releasing it for public use. I just need to get it ready for release. smith Jim Tann wrote: Originally posted on OSFlash.org list, sorry to double post, sent to wrong list. Hi all, I am working on several projects that have very large videos (1-2 hours) that need to be delivered on CD-Rom Intranet. After trying to use one large video file I realized there is a large problem when seeking to any point in the video in that It has to buffer itself up to the point you wish to play on these large videos that can take quite some time. This led me to chop the video up into 2 min chunks write a segmented video player so they play as one video. This is working great on most machines but on the occasional Windows 98 machine it is crashing when initially grabbing the flv's. I think the problem is that when initializing the component it is trying to load all the flv's at once. Does anyone have any insight into this? Is there another segmented video player about? Here is the class: /*** * @author - James Tann * * FILE:: SegmentedFLVPlayback.as * PACKAGE:: com.codesortium.video.SegmentedFLVPlayback * AUTHOR:: James Tann * AUTHOR SITE:: http://www.avtgroup.com * CREATED:: 10/04/2006 * DESCRIPTION:: / // ** AUTO-UI IMPORT STATEMENTS ** // ** END AUTO-UI IMPORT STATEMENTS ** import mx.video.FLVPlayback; import mx.utils.Delegate; import mx.events.EventDispatcher; class com.codesortium.video.SegmentedFLVPlayback extends MovieClip { // Constants: public static var CLASS_REF:Function= com.codesortium.video.SegmentedFLVPlayback; public static var LINKAGE_ID:String= SegmentedFLVPlayback; public static var SymbolLinked:Boolean= Object.registerClass(LINKAGE_ID, CLASS_REF); // Public Properties: public var addEventListener:Function; public var removeEventListener:Function; public var autoPlay:Boolean = false; public var bufferTime:Number = 0.1; public var playheadTime:Number = 0; public var playheadUpdateInterval:Number= 250; public var progressInterval:Number = 250; public var state:String = ; public var totalTime:Number = 0; public var stateResponsive:Boolean = false; public var buffering:Boolean = false; // Private Properties: private var dispatchEvent:Function; private var _arrFLVPlayback:Array; private var _activeFlvPlayback:FLVPlayback; private var _totalLength:Number = 0; private var _position:Number = 0; private var _volume:Number = 100; private var _arrCuePoints:Array; // UI Elements: // ** AUTO-UI ELEMENTS ** private var
RE: [Flashcoders] Multiple FLVPlayback problem
I finished a project with quite some FLVs myself this week (around 45 different 1 to 3 MB FLVs) and used the activeVideoPlayerIndex technique... I throw an array of videos in my VideoLoader class and it starts preloading the 1st one...when that is done loading it adds 1 to the activeVideoPlayerIndex and preloads the next one in the array...etc.etc. Works great! Curious to see your code Aaron! -Original Message- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] On Behalf Of jim Sent: Wednesday, May 17, 2006 1:30 PM To: 'Flashcoders mailing list' Subject: RE: [Flashcoders] Multiple FLVPlayback problem That's great arron, I actually started looking into this metod yesterday myself after seeing the activePlayer index in the FLVPlayback component. I was thinking that extending the component would be best. Well, I will be very greatful for your help/class. Cheers Jim -Original Message- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] On Behalf Of aaron smith Sent: 16 May 2006 23:55 To: Flashcoders mailing list Subject: Re: [Flashcoders] Multiple FLVPlayback problem one other thing, you might want to split up your video even more.. like 6 - 10 clips. that way they're way smaller files.. seeking and loading wouldn't be a problem then. aaron smith wrote: I'm also working on a project that requires multiple flv's also. What I did was create a very basic multiple flv player. then with that you listen to whatever events you want to tap into. say for some video controls and what not. I will share it with you later tonight. I need to refactor it a bit and add a little more functionality.. but it works great! I need to build in seeking capabilities and cuepoint capabilities.. other than that. it all works great. I am using with 2 - 5 MB files. of about 2 or 3 files.. so total up those files and generally its about 10 - 15 megs.. as far as preloading the flvs. what you need to do is start playing the first one. then when you get a metadata event for that one. start playing the second one, once you get metadeta for that one. add it to total time and pause it.. it will still continue to download the flv though... so basically you need to wait till one has metadeta.. then start the next one. or you could come up with some other way of doing this. but thats how I had to do it without killing the player because of all the video loading. this way works great locally. over the net it also works great but my files are considerablly smaller. like I said. i'll share this with you later tonight.. I also am planning on releasing it for public use. I just need to get it ready for release. smith Jim Tann wrote: Originally posted on OSFlash.org list, sorry to double post, sent to wrong list. Hi all, I am working on several projects that have very large videos (1-2 hours) that need to be delivered on CD-Rom Intranet. After trying to use one large video file I realized there is a large problem when seeking to any point in the video in that It has to buffer itself up to the point you wish to play on these large videos that can take quite some time. This led me to chop the video up into 2 min chunks write a segmented video player so they play as one video. This is working great on most machines but on the occasional Windows 98 machine it is crashing when initially grabbing the flv's. I think the problem is that when initializing the component it is trying to load all the flv's at once. Does anyone have any insight into this? Is there another segmented video player about? Here is the class: /*** * @author - James Tann * * FILE:: SegmentedFLVPlayback.as * PACKAGE:: com.codesortium.video.SegmentedFLVPlayback * AUTHOR:: James Tann * AUTHOR SITE:: http://www.avtgroup.com * CREATED:: 10/04/2006 * DESCRIPTION:: / // ** AUTO-UI IMPORT STATEMENTS ** // ** END AUTO-UI IMPORT STATEMENTS ** import mx.video.FLVPlayback; import mx.utils.Delegate; import mx.events.EventDispatcher; class com.codesortium.video.SegmentedFLVPlayback extends MovieClip { // Constants: public static var CLASS_REF:Function= com.codesortium.video.SegmentedFLVPlayback; public static var LINKAGE_ID:String= SegmentedFLVPlayback; public static var SymbolLinked:Boolean= Object.registerClass(LINKAGE_ID, CLASS_REF); // Public Properties: public var addEventListener:Function; public var removeEventListener:Function; public var autoPlay:Boolean = false; public var bufferTime:Number = 0.1; public var playheadTime:Number = 0; public var playheadUpdateInterval:Number= 250; public var progressInterval:Number = 250; public var state
Re: [Flashcoders] Multiple FLVPlayback problem
', target:this, streamIndex:_streamIndex } ); } //set this clips index public function set streamIndex( int:Number ):Void { this._streamIndex = int; } //get this clips index public function get streamIndex():Number { return _streamIndex; } public function get loopClip():Boolean { return _loopClip; } public function set loopClip( loop:Boolean ):Void { trace('setLoopClip true'); _loopClip = loop; } //get this netstream object public function getStream():NetStream { return _nstream; } } -- thats my code as of right now. the code isn't up to par. being in the middle of stuff. but once I get done with a deadline i'll update it and make it available. how you use it is create a new instance of MultipleFLVVide0Player() : ex:var mfvlp:MultipleFLVVideoPlayer = new MultipleFLVVideoPlayer( ['1.flv','2.flv'] , videoObject ); then you just tap into the events it dispatches.. use those for all of your controls and bars and what not.. like I said.. i need to update this majorly so I can realease. it.. but.. it works great. Also not if you try to use this. you can take out any StaticLogger references or any clib.* imports... Aaron Wouter Steidl wrote: I finished a project with quite some FLVs myself this week (around 45 different 1 to 3 MB FLVs) and used the activeVideoPlayerIndex technique... I throw an array of videos in my VideoLoader class and it starts preloading the 1st one...when that is done loading it adds 1 to the activeVideoPlayerIndex and preloads the next one in the array...etc.etc. Works great! Curious to see your code Aaron! -Original Message- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] On Behalf Of jim Sent: Wednesday, May 17, 2006 1:30 PM To: 'Flashcoders mailing list' Subject: RE: [Flashcoders] Multiple FLVPlayback problem That's great arron, I actually started looking into this metod yesterday myself after seeing the activePlayer index in the FLVPlayback component. I was thinking that extending the component would be best. Well, I will be very greatful for your help/class. Cheers Jim -Original Message- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] On Behalf Of aaron smith Sent: 16 May 2006 23:55 To: Flashcoders mailing list Subject: Re: [Flashcoders] Multiple FLVPlayback problem one other thing, you might want to split up your video even more.. like 6 - 10 clips. that way they're way smaller files.. seeking and loading wouldn't be a problem then. aaron smith wrote: I'm also working on a project that requires multiple flv's also. What I did was create a very basic multiple flv player. then with that you listen to whatever events you want to tap into. say for some video controls and what not. I will share it with you later tonight. I need to refactor it a bit and add a little more functionality.. but it works great! I need to build in seeking capabilities and cuepoint capabilities.. other than that. it all works great. I am using with 2 - 5 MB files. of about 2 or 3 files.. so total up those files and generally its about 10 - 15 megs.. as far as preloading the flvs. what you need to do is start playing the first one. then when you get a metadata event for that one. start playing the second one, once you get metadeta for that one. add it to total time and pause it.. it will still continue to download the flv though... so basically you need to wait till one has metadeta.. then start the next one. or you could come up with some other way of doing this. but thats how I had to do it without killing the player because of all the video loading. this way works great locally. over the net it also works great but my files are considerablly smaller. like I said. i'll share this with you later tonight.. I also am planning on releasing it for public use. I just need to get it ready for release. smith Jim Tann wrote: Originally posted on OSFlash.org list, sorry to double post, sent to wrong list. Hi all, I am working on several projects that have very large videos (1-2 hours) that need to be delivered on CD-Rom Intranet. After trying to use one large video file I realized there is a large problem when seeking to any point in the video in that It has to buffer itself up to the point you wish to play on these large videos that can take quite some time. This led me to chop the video up into 2 min chunks write a segmented video player so they play as one video. This is working great on most machines but on the occasional Windows 98 machine it is crashing when initially grabbing the flv's. I think the problem is that when initializing the component it is trying to load all the flv's at once. Does anyone have any insight into this? Is there another segmented video player about? Here is the class: /*** * @author - James Tann * * FILE
Re: [Flashcoders] Multiple FLVPlayback problem
one other thing, you might want to split up your video even more.. like 6 - 10 clips. that way they're way smaller files.. seeking and loading wouldn't be a problem then. aaron smith wrote: I'm also working on a project that requires multiple flv's also. What I did was create a very basic multiple flv player. then with that you listen to whatever events you want to tap into. say for some video controls and what not. I will share it with you later tonight. I need to refactor it a bit and add a little more functionality.. but it works great! I need to build in seeking capabilities and cuepoint capabilities.. other than that. it all works great. I am using with 2 - 5 MB files. of about 2 or 3 files.. so total up those files and generally its about 10 - 15 megs.. as far as preloading the flvs. what you need to do is start playing the first one. then when you get a metadata event for that one. start playing the second one, once you get metadeta for that one. add it to total time and pause it.. it will still continue to download the flv though... so basically you need to wait till one has metadeta.. then start the next one. or you could come up with some other way of doing this. but thats how I had to do it without killing the player because of all the video loading. this way works great locally. over the net it also works great but my files are considerablly smaller. like I said. i'll share this with you later tonight.. I also am planning on releasing it for public use. I just need to get it ready for release. smith Jim Tann wrote: Originally posted on OSFlash.org list, sorry to double post, sent to wrong list. Hi all, I am working on several projects that have very large videos (1-2 hours) that need to be delivered on CD-Rom Intranet. After trying to use one large video file I realized there is a large problem when seeking to any point in the video in that It has to buffer itself up to the point you wish to play on these large videos that can take quite some time. This led me to chop the video up into 2 min chunks write a segmented video player so they play as one video. This is working great on most machines but on the occasional Windows 98 machine it is crashing when initially grabbing the flv's. I think the problem is that when initializing the component it is trying to load all the flv's at once. Does anyone have any insight into this? Is there another segmented video player about? Here is the class: /*** * @author - James Tann * * FILE:: SegmentedFLVPlayback.as * PACKAGE:: com.codesortium.video.SegmentedFLVPlayback * AUTHOR:: James Tann * AUTHOR SITE:: http://www.avtgroup.com * CREATED:: 10/04/2006 * DESCRIPTION:: / // ** AUTO-UI IMPORT STATEMENTS ** // ** END AUTO-UI IMPORT STATEMENTS ** import mx.video.FLVPlayback; import mx.utils.Delegate; import mx.events.EventDispatcher; class com.codesortium.video.SegmentedFLVPlayback extends MovieClip { // Constants: public static var CLASS_REF:Function= com.codesortium.video.SegmentedFLVPlayback; public static var LINKAGE_ID:String= SegmentedFLVPlayback; public static var SymbolLinked:Boolean= Object.registerClass(LINKAGE_ID, CLASS_REF); // Public Properties: public var addEventListener:Function; public var removeEventListener:Function; public var autoPlay:Boolean = false; public var bufferTime:Number = 0.1; public var playheadTime:Number = 0; public var playheadUpdateInterval:Number= 250; public var progressInterval:Number = 250; public var state:String = ; public var totalTime:Number = 0; public var stateResponsive:Boolean = false; public var buffering:Boolean = false; // Private Properties: private var dispatchEvent:Function; private var _arrFLVPlayback:Array; private var _activeFlvPlayback:FLVPlayback; private var _totalLength:Number = 0; private var _position:Number = 0; private var _volume:Number = 100; private var _arrCuePoints:Array; // UI Elements: // ** AUTO-UI ELEMENTS ** private var mcBackground:MovieClip; // ** END AUTO-UI ELEMENTS ** // Initialization: private function SegmentedFLVPlayback() { EventDispatcher.initialize(this); _arrFLVPlayback= new Array(); _arrCuePoints= new Array(); } private function onLoad():Void { configUI(); } // Public Methods: public function toString() : String { return com.codesortium.video.SegmentedFLVPlayback; } public function get width():Number{ return _width; } public function set