Putting together a complex gstreamer command line...
Robin A. Jensen
RAJensen at youmail.dk
Sun Apr 3 13:40:44 UTC 2016
Hello Nicko.
Don't know so much about G-Streamer, but i did have a little fight with
videomixer. (I won)
Now i've got trouble with a tcpclientsrc & Python....
But I think that your Pipeline is incomplete regarding to your mixer.
First of all: I'm quite sure that it needs that your src use
do-timestamp=true and some where down the pipeline, some Caps must be
provided and some queue might help on roll.
Also importent: Mixer needs to know where to put mixed sources on
display. Like sink_0::xpos=0 sink_0::ypos=0 and display size must match
your 2 x stream width.
Consider to use a videotestsrc as a background with the width,
height,format,framerate and feed it to mixer and then mix your sources.
And use videoconvert to your sources.
I have a Rpi with tcpserversink streaming to a Win7 tcpclientsrc and can
mix 2 streams.
I set Caps according to my video before streams go out and a
videotestsrc as background for the mixer
I've not used v4l2src but raspivid and fdsrc.
Best regards Robin.
Den 03-04-2016 kl. 14:30 skrev nicko:
> For the sake of completeness, here is the question - I would really
> appreciate help on this as I'm completely stuck:
>
> I have a Raspberry Pi Compute Module with 2 cameras. I'm trying to use
> gstreamer with v4l2src selecting /dev/video0 & /dev/video1 to continually
> run at about 20FPS and use videomixer to combine the images side-by-side
> then output H.264 over RTP to a UDP port (read by another host). Somewhere
> in the comand line, I'm going to need to include glshader to apply some
> distortion to each image before the merge...
>
> The default (current) RPi v4l2src driver does not support two cameras, but
> as of today a beta is available that does, however it requires the beta
> 4.4.6 kernel.
>
> The problem I'm having is in getting the mixer connected.
>
> #!/bin/bash -x
> #
> # Script to start RPi Compute Module streaming over RTP (RFC3984)
> # from both cameras
> #
> FPS=20 # Frames per second
> WIDTH=640 # Image width
> HEIGHT=480 # Image height
> UPLINK_HOST=192.168.1.73 # Receiving host
> PORT=5200 # UDP port
> #
> # TESTING WITH ONE CAMERA ONLY FOR THE MOMENT
> #
> function start_streaming
> {
> gst-launch-1.0 -ve videomixer name=mixer \
> ! x264enc \
> ! h264parse \
> ! rtph264pay config-interval=10 pt=96 \
> ! udpsink host=$UPLINK_HOST port=$PORT \
> v4l2src device=/dev/video0 \
> ! video/x-raw,format=AYUV,width=$WIDTH,height=$HEIGHT,framerate=$FPS/1 \
> ! mixer.
> }
>
> # Start streaming on both cameras simultaneously
> echo Image size: $WIDTH x $HEIGHT
> echo Frame rate: $FPS
> echo Starting cameras 0 and 1 streaming to $UPLINK_HOST:$PORT
> start_streaming
>
> # Wait until everything has finished
> wait
>
> exit 0
> # end
>
> What I'm getting is the rather useless (to me) message:
>
> WARNING: erroneous pipeline: could not link v4l2src0 to mixer
>
> I've fiddled about rather a lot and got nowhere - it's probably something
> trivial, but be blowed if I can see it !
>
> Many thanks
>
> Nick
>
>
>
>
> --
> View this message in context: http://gstreamer-devel.966125.n4.nabble.com/Putting-together-a-complex-gstreamer-command-line-tp4676713p4676714.html
> Sent from the GStreamer-devel mailing list archive at Nabble.com.
> _______________________________________________
> gstreamer-devel mailing list
> gstreamer-devel at lists.freedesktop.org
> https://lists.freedesktop.org/mailman/listinfo/gstreamer-devel
More information about the gstreamer-devel
mailing list