Gstreamer

From XPUB & Lens-Based wiki

http://gstreamer.freedesktop.org/

Amazing audio/video processing, from the commandline!

Streaming

Transmitter:

gst-launch-0.10 v4l2src ! 'video/x-raw-yuv,width=640,height=480,framerate=30/1' ! videoflip method=5 ! x264enc pass=qual quantizer=20 tune=zerolatency ! rtph264pay ! udpsink host=192.168.0.150 port=3333

Receiver:

gst-launch-0.10 udpsrc port=3333 ! "application/x-rtp, payload=127" ! rtph264depay ! ffdec_h264 ! xvimagesink sync=false

Take a still image

gst-launch v4l2src ! ffmpegcolorspace ! pngenc ! filesink location=test.png

Raw audio streaming

An example of streaming from a Rasberry PI, credits to Stéfan Piat, taken from his blog (http://rearwndw.wordpress.com/2013/05/17/raw-vorbis/)

SENDER:

gst-launch -v autoaudiosrc ! audioconvert ! audioresample ! vorbisenc ! udpsink host=192.168.2.102 port=5000

RECEIVER:

gst-launch -v udpsrc port=5000 ! vorbisdec ! audioconvert ! alsasink sync=false