我必须有 FMS 才能从我的相机发布流吗?

发布于 2024-11-18 10:26:58 字数 1864 浏览 2 评论 0原文

我正在建立一个直播网站并且我正在使用 1- 飞行管理系统 2- Apache 网络服务器

我已经制作了订阅者并且运行良好。 但我需要建立发布者以允许用户从他们的相机广播他们的流。

我已经测试了一个使用actionscript构建的发布者,直到我在本地主机上安装了fms之后它才工作,但我需要一个任何用户都可以在他的网络浏览器中使用的发布者。

我的发布商:

   protected function application1_creationCompleteHandler(event:FlexEvent):void 
        { 
            connection = new NetConnection(); 
            connection.connect("rtmp:/live"); 
            connection.addEventListener(NetStatusEvent.NET_STATUS,onConnected); 

        } 
   private function setupVideo():void 
        { 
            //setting up outgoing devices 
            camera = Camera.getCamera(); 
            camera.setMode(640,480,30); 
            mic = Microphone.getMicrophone(); 

            //setting up outgoing Stream 
            outStream = new NetStream(connection); 
            outStream.attachCamera(camera); 
            outStream.attachAudio(mic); 
            outStream.publish("EraMaX-Live"); 

            //setting up outgoing video & attach outgoing devices 
            outVideo = new Video(); 
            outVideo.attachCamera(camera);  
            //setting up incomming Stream 
            inStream = new NetStream(connection); 
            inStream.play("EraMaX-Live"); 

            //setting up incomming video & attach incoming Stream 
            inVideo = new Video(); 
            inVideo.attachNetStream(inStream); 

            //wrap video object 
            outVideoWrapper = new UIComponent(); 
            outVideoWrapper.addChild(outVideo); 
            addElement(outVideoWrapper); 

            inVideoWrapper = new UIComponent(); 
            inVideoWrapper.addChild(inVideo); 
            addElement(inVideoWrapper); 
            inVideoWrapper.move(400,0); 
            //setting up incomming video 

        } 

所以我的问题是我必须有 FMS 才能将流从我的相机发布到我的网站吗?

i am building an live streaming website and i am use
1- FMS
2- Apache webserver

i have made the subcriber and i works well .
but i need to build the publisher to allow users to broadcast thier stream from thier cameras.

i have tested a publisher which was build using actionscript and it didn't work untill i have installed the fms on my localhost , but i need a publisher which any user can use in his web browser .

my publisher :

   protected function application1_creationCompleteHandler(event:FlexEvent):void 
        { 
            connection = new NetConnection(); 
            connection.connect("rtmp:/live"); 
            connection.addEventListener(NetStatusEvent.NET_STATUS,onConnected); 

        } 
   private function setupVideo():void 
        { 
            //setting up outgoing devices 
            camera = Camera.getCamera(); 
            camera.setMode(640,480,30); 
            mic = Microphone.getMicrophone(); 

            //setting up outgoing Stream 
            outStream = new NetStream(connection); 
            outStream.attachCamera(camera); 
            outStream.attachAudio(mic); 
            outStream.publish("EraMaX-Live"); 

            //setting up outgoing video & attach outgoing devices 
            outVideo = new Video(); 
            outVideo.attachCamera(camera);  
            //setting up incomming Stream 
            inStream = new NetStream(connection); 
            inStream.play("EraMaX-Live"); 

            //setting up incomming video & attach incoming Stream 
            inVideo = new Video(); 
            inVideo.attachNetStream(inStream); 

            //wrap video object 
            outVideoWrapper = new UIComponent(); 
            outVideoWrapper.addChild(outVideo); 
            addElement(outVideoWrapper); 

            inVideoWrapper = new UIComponent(); 
            inVideoWrapper.addChild(inVideo); 
            addElement(inVideoWrapper); 
            inVideoWrapper.move(400,0); 
            //setting up incomming video 

        } 

so my question must i have FMS to publish a stream from my camera to my website ?

如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

扫码二维码加入Web技术交流群

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。

评论(1

半步萧音过轻尘 2024-11-25 10:26:58

如果您想流式传输实时视频,则需要流媒体服务器。不一定是 FMS,您还可以使用 Red5、Wowza,甚至开源解决方案,例如 RTMPD 或 RTMPLite。

If you want to stream live video, you need a streaming server. Not definitely FMS, you also can use Red5, Wowza, or even open source solutions such as RTMPD or RTMPLite.

~没有更多了~
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文