DM81xx GStreamer Pipelines - SDK 2011Q2

From RidgeRun Developer Connection

Revision as of 22:00, 5 September 2011 by Mmontero (Talk | contribs)
(diff) ← Older revision | Current revision (diff) | Newer revision → (diff)
Jump to:navigation, search

The following examples show the usage of GStreamer with the RR DM81xx SDK 2011Q2.


Video streaming

These instructions show how to do video streaming over the network, a video will be played on the board and viewed on the host.

  1. Stream H.264 video test pattern over RTP
CLIENT_IP=10.251.101.58

gst-launch videotestsrc ! omx_h264enc ! queue ! H264parse !  gstperf ! rtph264pay ! udpsink host=$CLIENT_IP -v

This pipeline is going to print the capabilities of each element's pad thanks to the -v option. The pipeline should print something similar to this output:

.
.
.
/GstPipeline:pipeline0/GstUDPSink:udpsink0.GstPad:sink: caps = application/x-rtp, media=(string)video, clock-rate=(int)90000, 
encoding-name=(string)H264, sprop-parameter-sets=(string)J0KAKouVAoPy, payload=(int)96, ssrc=(uint)951364645, 
clock-base=(uint)2084568768, seqnum-base=(uint)10992                                              
Pipeline is PREROLLED ...
Setting pipeline to PLAYING ...
/GstPipeline:pipeline0/GstRtpH264Pay:rtph264pay0.GstPad:src: caps = application/x-rtp, media=(string)video, clock-rate=(int)90000,
encoding-name=(string)H264, sprop-parameter-sets=(string)\"J0KAKouVAoPy\\,KN4BriA\\=\", payload=(int)96, ssrc=(uint)951364645, 
clock-base=(uint)2084568768, seqnum-base=(uint)10992                        
New clock: GstSystemClock
/GstPipeline:pipeline0/GstUDPSink:udpsink0.GstPad:sink: caps = application/x-rtp, media=(string)video, clock-rate=(int)90000, 
encoding-name=(string)H264, sprop-parameter-sets=(string)\"J0KAKouVAoPy\\,KN4BriA\\=\", payload=(int)96, ssrc=(uint)951364645, 
clock-base=(uint)2084568768, seqnum-base=(uint)10992                             
frames: 68      current: 67.90   average: 67.90 arm-load: 0   
.
.
.                                                                       

You need the udpsink:sink capabilities for the client pipeline.

Copy the udpsink caps given by the server pipeline, erase the spaces and the (uint) cast.

CAPS=application/x-rtp,media=(string)video,clock-rate=(int)90000,encoding-name=(string)H264,\
sprop-parameter-sets=(string)\"J0KAKouVAoPy\\,KN4BriA\\=\",payload=(int)96,ssrc=951364645,\
clock-base=2084568768,seqnum-base=10992

PORT=4951

gst-launch udpsrc $PORT ! $CAPS ! rtph264depay byte-stream=true ! queue ! ffdec_h264 ! xvimagesink sync=false -v
  1. Stream H.264 encoded video file over RTP

Stream over RTSP

Navigation
Toolbox