Gstreamer: can't get rtpjpegpay to work with BGR source

I want to use gstreamer udpsink to stream video from opencv, but I can’t get a working pipeline using gst-launch1.0. The following convoluted pipeline mimics the pipeline sourcing appsink within my code with bits tacked on to complete the pipeline for the udpsink:

gst-launch-1.0 v4l2src device=/dev/video0 io-mode=2 ! image/jpeg,format=MJPG,width=640,height=480,framerate=61612/513 ! nvv4l2decoder mjpeg=1 ! nvvidconv ! video/x-raw,format=BGRx ! videoconvert ! video/x-raw,format=BGR ! jpegenc ! rtpjpegpay ! udpsink host=10.10.10.1 port=5000

This produces:

WARNING: from element /GstPipeline:pipeline0/GstRtpJPEGPay:rtpjpegpay0: Invalid component
Additional debug info:
gstrtpjpegpay.c(596): gst_rtp_jpeg_pay_read_sof (): /GstPipeline:pipeline0/GstRtpJPEGPay:rtpjpegpay0

gst-inspect1.0 tells me jpegenc sinks video/x-raw in BGR format, so what gives?

Thanks!

Hi,
Please break down the pipeline and see which plugin triggers issue. You may try like:

gst-launch-1.0 v4l2src device=/dev/video0 io-mode=2 ! image/jpeg,format=MJPG,width=640,height=480,framerate=61612/513 ! nvv4l2decoder mjpeg=1 ! nvvidconv ! video/x-raw,format=BGRx ! videoconvert ! video/x-raw,format=BGR ! jpegenc ! fakesink sync=0
gst-launch-1.0 v4l2src device=/dev/video0 io-mode=2 ! image/jpeg,format=MJPG,width=640,height=480,framerate=61612/513 ! nvv4l2decoder mjpeg=1 ! nvvidconv ! video/x-raw,format=BGRx ! videoconvert ! video/x-raw,format=BGR ! fakesink sync=0

This topic was automatically closed 14 days after the last reply. New replies are no longer allowed.