FLVPlayback with Live Cam and Custom Skin
Hello,
I am curretnly attempting to use Flash Media Server, Flash Media Encoder, and Flash CS3 to make a custom swf for the web that viewers can watch the live feed from and have basic play/stop controls. I have followed the helpful information found here, http://www.adobe.com/devnet/flashmediaserver/articles/beginner_live_fms3.html , and have a pretty good knowledge of CS2 so CS3 really isn't that big of an issue but I already have an error.
Error: TypeError: Error #1006: addListener is not a function. at live_fla::MainTimeline/frame1()
Code:
stop();
myVideo.isLive = true;
function playVid(e:MouseEvent):void {
myVideo.play();
}
function stopVid(e:MouseEvent):void {
myVideo.stop();
}
function fullScreen(e:MouseEvent):void {
myVideo.enterFullScreenDisplayState();
}
playBtn.addListener(MouseEvent.CLICK, playVid);
stopBtn.addListener(MouseEvent.CLICK, stopVid);
fullscreenBtn.addListener(MouseEvent.CLICK, fullScreen);
I have a FLVPlayback component labeled myVideo in one layer. Above that I have a controls layer that contains three buttons: playBtn, stopBtn, fullscreenBtn. All of these have the proper instance names but for some reason I am getting that error. Any input would be appreciated. Also the live feed is streaming properly for me, its just that I get the error and the buttons do not work.
Also, instead of setting the source of the FLVPlayback component in parameters wouldnt it be possible to do myVideo.source(); ?
Thanks in advance.
Frank
