6

I want to live stream from one source(ffmpeg) to multiple clients for which I'm using mkvserver. I'm able to live stream a webcam from ffmpeg(client) to mkvserver(server) as follows:

On Server :

nc -l <port-number> | ./server 

On Client :

ffmpeg -f avfoundation -framerate 30 -i 0 -b 900k -f matroska -r 20 tcp://<ip-address>:<port-number> 

To view the genereted steam on server, I used the ffplay as:

ffplay tcp://<ip-address>:<port> 

but I got the Connection timed out error. Please suggest a way to view the generated stream on the server via ffplay. Thanks!

1 Answer 1

4
+50

Let me recap for clarification.

You are streaming from the client with ffmpeg

ffmpeg -f avfoundation -framerate 30 -i 0 -b 900k -f matroska -r 20 tcp://<ip-address>:<port-number> 

to the server which listen with NetCat in some port over TCP.

nc -l <port-number> 

You are piping the NetCat outPut (client steam) to Matroska Server Mk2 (./server) which serve the streaming in real-time over http on all interfaces on port 8080.

nc -l <port-number> | ./server 

So I think that ffplay should connect through http in port 8080 to view the output of Matroska Server Mk2 (./server).

ffplay http://ip-address:8080 
Sign up to request clarification or add additional context in comments.

1 Comment

This is perfectly working. I got tcp confused for http when it should be http on the receiving end. Thanks~

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.