Skip to main content
Inspiring
November 27, 2007
Question

FLVPlayback Component and FMS

  • November 27, 2007
  • 2 replies
  • 412 views
Hi all,

I've been trying to get my FMS server to stream to a FLVPlayback component and have had no luck. I have seen numerous posts on this subject in this forum and others, but a lot of it seems related to the older FCS and Flash 8/Actionscript 2.0 so maybe I'm not doing something right for Flash CS3/AS3.0.

Here's what I've got, using the examples from http://livedocs.adobe.com/flash/9.0/ActionScriptLangRefV3/fl/video/FLVPlayback.html#includeExamplesSummary.

I have a file named FLVPlaybackExample.fla, on the stage is a FLVPlayback component instance named "player". The Document class is set to "FLVPlaybackExample". There is a file named FLVPlayback.as in the same directory with the following code:

package
{
import fl.video.FLVPlayback;
import flash.display.Sprite;

public class FLVPlaybackExample extends Sprite {

// private var videoPath:String = " http://www-app6.wa.gov/disit/dev/flash/1.flv";

private var videoPath:String = "rtmp://flash.wa.gov/FLVPlaybackExample/1";

public function FLVPlaybackExample() {
player.autoPlay = true;
player.isLive = false;
player.source = videoPath;
}
}
}

You can see in the code I have 2 versions of the declaration of the videoPath String. One is streaming from my FMS, the other is progressive downloaded from a web server. Progressive download works great. Streaming I get the colored "buffering" affect on the scrub bar but nothing past that. I'm using the same video clips in both places. The video clip is placed properly on the FMS (at /applications/FMSPlaybackExample/streams/_definst_). I have used this clip to stream for other tests I've run using the standard Video object (not FMSPlayback) and it worked fine then. I don't have any sort of main.asc, which I've seen referred to in other posts, but the references say to search for it in the Flash 8 samples and tutorials directory, which does not exist on version CS3. If anyone could point out what I'm missing here I'd greatly appreciate it.

thanks!
    This topic has been closed for replies.

    2 replies

    Inspiring
    November 29, 2007
    Hmm... for starters, it looks like you have your AS file improperly named. It should be FLVPlaybackExample.as, not FLVPlayback.as. (The class named should always be used, followed by .as)

    Try that, and then let me know what happens.
    Inspiring
    November 29, 2007
    Anyone?