Read frames from GStreamer pipeline in opencv (cv::Mat)

Tim Müller tim at
Wed May 31 11:01:44 UTC 2017

On Tue, 2017-05-30 at 10:08 -0700, pchaurasia wrote:


> I expect map_info.size to give me frame size as per - 
>  filtercaps = gst_caps_from_string("video/x-raw(memory:NVMM),
> width=(int)1920, height=(int)1080, format=(string)I420,
> framerate=(fraction)30/1 ")
> Thus, I am expecting size to be 1920*1080*1.5 (420 format). However,
> the value of map_info.size, that I am printing/reading is about 776
> bytes. 

Ah, that's a bit odd, looks like a bug or oversight in the way nvidia
have implemented this.

Have you tried using an 'nvvidconv' element after your source, I
believe that should convert it?


Tim Müller, Centricular Ltd -

More information about the gstreamer-devel mailing list