Stream an UDP stream to webpage

Discussion in 'Web Call Server 5' started by Corrado Steri, Mar 21, 2019.

  1. Corrado Steri

    Corrado Steri New Member

    I have a camera that outputs an udp stream to a certain port i can set. Would it be possible for the server to take this stream and publish it on a web page? (like it does with RTSP streams).

    Corrado
  2. Max

    Max Administrator Staff Member

    Hello.
    WCS can:
    1. Pull RTSP stream from camera as described here.
    2. Capture RTMP stream from RTMP encoder as described here.
    3. Pull RTMP stream as client from another RTMP server as described here.
    So your camera should act as RTSP source, RTMP encoder or RTMP server.
    Also, if your camera act as a browser and can establish WebRTC connection, you can try to use raw Websocket API to publish stream, but it is probably a more complex way.
  3. Corrado Steri

    Corrado Steri New Member

    I'll try with RTMP.
    Only one prob, i see gstreamer can do RTMP and is what i'll use, but it doesn't have a key stream.

    Any hint on how a gstreamer pipe could look to work, seting a raspicam as source?
  4. Max

    Max Administrator Staff Member

    We have not tested Gstreamer yet. We plan to test it, but it may take a time.
    If you can establish RTMP connection with WCS and start streaming, but WCS breaks the connection or does not play the stream, please hrepare a report as described here, including traffic dump, and send to support@flashphoner.com. We will check.
  5. Max

    Max Administrator Staff Member

    Good day.
    We have tested RTMP translation from Gstreamer to WCS. The stream is published successfully with the following command
    Code:
    gst-launch-1.0 -e videotestsrc ! queue ! videoconvert ! x264enc ! flvmux streamable=true ! queue ! rtmpsink location='rtmp://WCS_IP:1935/live/myStream'
  6. Corrado Steri

    Corrado Steri New Member

    Hello thank you. My problem is that i need to stream to an udp sink and to WCS at the same time, would you be so kind to test a gstreamer command that does that?
  7. Max

    Max Administrator Staff Member

    You can use two Gstreamer pipelines simultaneously as supposed here. If it does not work for the same source device, it looks like Gstreamer limit.
  8. Corrado Steri

    Corrado Steri New Member

    I think the tee command has to be used in gstreamer but i really can't figure out how to use it. Basicly should be possible tom get one stream and divide it into 2 streams directed to different queues. In theory doesn't seem so difficult but i scratched my head over it for weeks without any acceptable results.
  9. Max

    Max Administrator Staff Member

    You can stream RTMP with Gstreamer to WCS then pull it from WCS with WebRTC, RTSP or RTMP.

Share This Page