Recording RTP Audio & Video Streams

Edip Demirbilek edip.demirbilek at gmail.com
Tue Dec 1 15:18:40 PST 2015


Hello Everyone,

 

I have generated RTP Audio and Video streams on the server using Gstreamer
and have tried to record them on the client using Gstreamer. On the client,
a file is being generated with expected size but I cannot play it either
with gstreamer or with other standard video players. The codes are as
follows:

 

Server side:

SRC=localhost

DEST=localhost

VCAPS="video/x-raw,width=352,height=288,framerate=15/1"

gst-launch-1.0 -ve rtpbin name=rtpbin \

           videotestsrc num-buffers=200 ! $VCAPS ! x264enc ! rtph264pay !
rtpbin.send_rtp_sink_0          \

                     rtpbin.send_rtp_src_0 ! udpsink host=$DEST port=5000
\

           audiotestsrc num-buffers=200 ! voamrwbenc ! rtpamrpay !
rtpbin.send_rtp_sink_1                 \

                             rtpbin.send_rtp_src_1 ! udpsink host=$DEST
port=5002

 

Client side:

SRC=localhost

DEST=localhost

VIDEO_CAPS="application/x-rtp,media=(string)video,clock-rate=(int)90000,enco
ding-name=(string)H264"

AUDIO_CAPS="application/x-rtp,media=(string)audio,clock-rate=(int)16000,enco
ding-name=(string)AMR-WB,encoding-params=(string)1,octet-align=(string)1"

LATENCY=400

VIDEO_STR=" rtph264depay ! avdec_h264 ! videoconvert ! x264enc ! qtmux
name=mux ! filesink location=<dir>/Captured.3gp"

AUDIO_STR=" rtpamrdepay ! avdec_amrwb ! audioconvert ! voamrwbenc ! mux."

 

gst-launch-1.0 -v rtpbin name=rtpbin latency=$LATENCY
\

           udpsrc caps=$VIDEO_CAPS address=$SRC port=5000 !
rtpbin.recv_rtp_sink_0                   \

                         rtpbin. ! $VIDEO_STR
\

                       udpsrc caps=$AUDIO_CAPS address=$SRC port=5002 !
rtpbin.recv_rtp_sink_1                   \

                         rtpbin. ! $AUDIO_STR

 

and when I play the file via GStreamer, I get the following error

 

gst-launch-1.0 playbin uri=file:///<dir>/Captured.3gp

Setting pipeline to PAUSED ...

Pipeline is PREROLLING ...

ERROR: from element
/GstPlayBin:playbin0/GstURIDecodeBin:uridecodebin0/GstDecodeBin:decodebin0/G
stQTDemux:qtdemux0: This file contains no playable streams.

Additional debug info:

qtdemux.c(640): gst_qtdemux_post_no_playable_stream_error ():
/GstPlayBin:playbin0/GstURIDecodeBin:uridecodebin0/GstDecodeBin:decodebin0/G
stQTDemux:qtdemux0:

no known streams found

ERROR: pipeline doesn't want to preroll.

Setting pipeline to NULL ...

Freeing pipeline ...

 

However for the same server side code, I can successfully play audio and
video streams on the client side using  autovideosink and autoaudiosink, and
I can record audio and video streams in different sessions on the client as
well. The problem is when I try to record the audio and video streams at the
same time to a 3gp file. What might be the problem?

 

Many thanks in advance

Edip

 

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.freedesktop.org/archives/gstreamer-devel/attachments/20151201/b9441250/attachment.html>


More information about the gstreamer-devel mailing list