RTMP.Client.Start C# (CSharp) Method

Start() public method

public Start ( ) : void
return void
        public void Start()
        {
            SendC0Handshake();
            SendC1Handshake();
        }

Usage Example

Exemplo n.º 1
0
        static void Main(string[] args)
        {
            FlvStreamer streamer = new FlvStreamer();

            var client = new Client();

            client.PublisherId = "live_YourStreamID";
            client.Connect("199.9.255.53");
            client.Start();

            var vclient = new VideoClient();
            vclient.GrabVideo("http://www.youtube.com/watch?v=at68PMbgyhw");
            vclient.AddedTag += delegate(FlvTag tag)
                                    {
                                        client.SendFlv(new FlvTag[1] {tag});
                                    };

            while(true)
            {
                client.Update();
                if(client.CurrentState == Client.ClientStates.Streaming)
                    vclient.Update();
            }
        }