AnsweredAssumed Answered

gstreamer video at 720p and 25/30 fps

Question asked by Philippe Balleydier on Oct 22, 2014
Latest reply on Oct 24, 2014 by igorpadykov

Hi everyone

 

i'm trying to stream over the network a USB webcam. I previously manage to do so at 1280x720 with 10 fps but couldn't get to 25 or 30 fps because the camera wasn't powerful enough. So i bought a new USB camera (Logitech C920) wich is able to do 720p at 30fps (as the documentation says)

The problem is that it is still not working for 25 or 30fps

Here are the gstreamer commands i'm using:

Sender:

gst-launch v4l2src device=/dev/video0 ! video/x-raw-yuv,width=1280,height=720,framerate=10/1 ! ffmpegcolorspace ! vpuenc codec=6 ! rtph264pay ! udpsink host=192.168.20.27 port=5000 

Receiver:

gst-launch udpsrc port=5000 caps="application/x-rtp, media=(string)video, clock-rate=(int)90000, payload=(int)96, encoding-name=(string)H264" ! rtph264depay ! ffdec_h264 ! xvimagesink 

So this is working at 10fps. When i try to change to more fps, it fails with the following error:

Setting pipeline to PAUSED ...

[INFO] Product Info: i.MX6Q/D/S

vpuenc versions

plugin: 3.0.11

wrapper: 1.0.46(VPUWRAPPER_ARM_LINUX Build on Sep 29 2014 16:56:55)

vpulib: 5.4.23

firmware: 3.1.1.46056

ERROR: Pipeline doesn't want to pause.

ERROR: from element /GstPipeline:pipeline0/GstV4l2Src:v4l2src0: Could not negotiate format

Additional debug info:

/media/philippe/data/fsl-release-bsp/build-x11/tmp/work/cortexa9hf-vfp-neon-poky-linux-gnueabi/gstreamer/0.10.36-r3/gstreamer-0.10.36/libs/gst/base/gstbasesrc.c(2830): gst_base_src_start (): /GstPipeline:pipeline0/GstV4l2Src:v4l2src0:

Check your filtered caps, if any

Setting pipeline to NULL ...

Freeing pipeline ...

 

If i delete the width parameter, i get up to 15fps but not more. As the error states, it could not negotiate format. So i believe i have to change/add/remove the "video/x-raw-yuv,width=1280,height=720,framerate=10/1" parameter. But what should i change to make it works?

PS: if i plug my USB webcam to my computer, i manage to record 720@25fps with VLC without any problems

PS2: When i add the plugin videorate to my gstreamer command, it gets really laggy (less than a frame per second), but it seems it is not due to CPU usage, since it remains the same

Any pointers would be of great help

Thanks

Outcomes