4

I have the following setup:

Raspberry Pi with raspicam (CSI camera) sends an RTP stream to a Server in the same local network with gstreamer1.0.

I´m using the following pipeline: raspivid -t 0 -h 720 -w 1080 -fps 25 -hf -b 2000000 -o - | gst-launch-1.0 -v fdsrc ! h264parse ! rtph264pay config-interval=1 pt=96 ! gdppay ! tcpserversink host="RPI-IP" port=5000

I can receive the stream on my Ubuntu 14.04 server with this pipline: gst-launch-1.0 -v tcpclientsrc host="RPI-IP" port=5000 ! gdpdepay ! rtph264depay ! avdec_h264 ! videoconvert ! autovideosink sync=false

I installed kurento on the server following this instructions

Can someone point me to a document or tutorial on how to setup the server to get the RTP Stream out into the web, using WebRTC broadcast or HTTP streaming, so I can include the stream in a website without any plugins ?

I read in the documentation that there is an RTP-Endpoint and an WebRTC-Endpoint. So In my understanding I can connect both and would like to have this setup:

RPI -> GStramer --> RTP -> Server -> RTP-Endpoint (kurento Media Server) -> WebRTC-Endpoint (kurento Media Server) -> Browser(Client)

Is this even the right way to go? Other suggestions are welcome too.

igracia
  • 3,543
  • 1
  • 18
  • 23
d00d
  • 514
  • 10
  • 20
  • Did you try to ask this question directly on kurento forum: https://groups.google.com/forum/#!forum/kurento ? – Footniko Nov 30 '14 at 20:19
  • actually I didn´t, because of missing google account. Did you find a solution for your problem? – d00d Dec 04 '14 at 03:51
  • 1
    Unfortunately, not yet. I asked similar question in Kurento forum two days ago, but still no attention:( – Footniko Dec 04 '14 at 08:46
  • @D.Hot It would be easier if you could provide an RTSP feed, as you wouldn't need the SDP negotiation of the RTP endpoint. In any case, you can still do that with Kurento through RTP. – igracia Aug 27 '15 at 13:26

2 Answers2

2

Indeed you can create that setup using Kurento Media Server. However, there are a couple of issues you neeed to consider:

  • Kurento Media Server will be transparently transcoding for you when you connect the H.264 based RtpEndpoint to the VP8 based WebRtcEndpoint. This transcoding is expensive in terms of CPU and you will pay it with less scalability in the broadcasting.
  • If you don't want to use an application server (so that all the logic is at the client app at the RPI), you will need to create a client capable of "speaking" with Kurento Media Server. For this, you need to implement the Kurento Protocol. Otherwise, you could use one of the built-in Kurento Clients through some kind of app server, but currently only Java and JavaScript are available.
lulop
  • 917
  • 8
  • 7
  • 2
    Thanks, **lulop** for response. I have similar problem and now i have exploring **KMS** to resolve it. Can u pls provide for us some example how to capture h264 stream with KMS as RtpEndpoint? And is KMS automatically transcode h264 to vp8? – Footniko Dec 01 '14 at 16:38
  • 1
    KMS does not provide any feature for "capture" RTP streams. KMS is a media server, so it mediates among different client applications connecting to it. If I'm not wrong, what you want is to create a RTP client application. For that, KMS cannot help you. You can create a RTP client application using different software stacks such as GStreamer and ffmpeg, but it requires some plumbing a development. Unfortunately I don't have any source code example of such an application. However, there are many commercial vendors providing RTP soft-phones off-the-self – lulop Dec 08 '14 at 16:36
1

Your question does not seem to be specific to Kurento. To broadcast audio and video you can use UV4L & Jitsi Meet instead:

Thanks to a new, special module for UV4L, it is now possible to join a room of any Jitsi Meet Web Conference anywhere (including those on the free, public meet.jit.si service) and broadcast live video and audio from your camera and microphone to all the participants or viewers in the room without the need of any browser installed on the Raspberry Pi!

strumps
  • 46
  • 2