nvvidconv plugin problem with higher Gstreamer version than 1.2.4

I am using R23.2 on TX1.
Default gstreamer-1.0 version in R23.2 is 1.2.4. I am getting overlay flickering issue using below pipeline.

gst-launch-1.0 videotestsrc \
! textoverlay text="Recording..." halignment=0 valignment=1 \
! 'video/x-raw, width=1920, height=1080, format=UYVY, framerate=60/1' \
! nvvidconv ! 'video/x-raw(memory:NVMM), width=1920, height=1080, format=I420, framerate=60/1' \
! nvoverlaysink sync=false

“Recording…” text overlay flickers while preview renders smoothly.
This is creating issue with “v4l2src”. I have created camera driver which gives 1080p60 UYVY data.
But with new gstreamer version like 1.8.3 or 1.10.2 the above command display overlay smoothly with videotestsrc. But with v4l2src it gives below error

Setting pipeline to PAUSED ...
Inside NvxLiteH264DecoderLowLatencyInitNvxLiteH264DecoderLowLatencyInit set DPB and MjstreamingInside NvxLiteH265DecoderLowLatencyInitNvxLiteH265DecoderLowLatencyInit set DPB and MjstreamingPipeline is live and does not need PREROLL ...
Setting pipeline to PLAYING ...
New clock: GstSystemClock
ERROR: from element /GstPipeline:pipeline0/GstV4l2Src:v4l2src0: Internal data stream error.
Additional debug info:
gstbasesrc.c(2950): gst_base_src_loop (): /GstPipeline:pipeline0/GstV4l2Src:v4l2src0:
streaming stopped, reason error (-5)
Execution ended after 0:00:00.077374264
Setting pipeline to PAUSED ...
Setting pipeline to READY ...
Setting pipeline to NULL ...
Freeing pipeline ...

But if replaced nvvidconv with videoconvert preview appears but it lags a lot but with no overlay flickering.

gst-launch-1.0 v4l2src \
! textoverlay text="Recording..." halignment=0 valignment=1 \
! 'video/x-raw, width=1920, height=1080, format=UYVY, framerate=60/1' \
! nvvidconv ! 'video/x-raw, width=1920, height=1080, format=I420, framerate=60/1' \
! nvoverlaysink sync=false

But if i use xvimagesink instead of nvvidconv and nvoverlaysink video plays smoothely and with no overlay flickering.

gst-launch-1.0 v4l2src device=/dev/video0 ! 'video/x-raw, width=1920, height=1080, format=UYVY, framerate=60/1' ! textoverlay text="Recording..." halignment=0 valignment=1 ! xvimagesink

So i think there’s some problem with v4l2src and nvvidconv using gstreamer 1.10.2.
I think i need to build nvvidconv with new gstreamer. But source code of nvvidconv is proprietary, Right? So what else i can do?

L4T R24.2 supports Gstreamer 1.8.2 by default. So as nvvidconv is compatible with new version.
But my problem is R24.2 deprecated SOC_CAMERA framework and replaced by MEDIA_CONTROLLER. and MEDIA_CONTROLLER doesn’t support YUV sensor for now. And my camera sensor outputs UYVY.
My forum post regarding this issue.
https://devtalk.nvidia.com/default/topic/946840/soc_camera-driver-in-l4t-r24-1/#5038234

And My application requires rich overlay on preview with recording and streaming.

I have tries QT with qt-gstreamer but there’s also some color conversion problem in UYVY to I420 conversion problem in QML videosink element so i am getting Reddish Preview with no flickering in overlay
https://devtalk.nvidia.com/default/topic/965626/qt-gstreamer-videosink-in-qt-qml/

So can i get libgstnvvidconv.so with latest gstreamer for 32-bit user space so i can use on R23.2 which can solve my problem until there’s some solution for UYVY camera support in R24.2.

Or any other workaround in R23.2 which can solve overlay flickering issue?

Hi RiteshPanchal,
On r23,2 I tried to upgrade to gstreamer 1.8.3 but could not get ‘textoverlay’ plugins.

ubuntu@tegra-ubuntu:~/gst-1.8.3/lib/arm-linux-gnueabihf$ gst-inspect-1.0 --version
gst-inspect-1.0 version 1.2.4
GStreamer 1.8.3
https://launchpad.net/distros/ubuntu/+source/gstreamer1.0
ubuntu@tegra-ubuntu:~/gst-1.8.3/lib/arm-linux-gnueabihf$ gst-inspect-1.0 textoverlay
No such element or plugin 'textoverlay'

Could you share how you do the upgrade? You should run it successfully per your comment:
‘But with new gstreamer version like 1.8.3 or 1.10.2 the above command display overlay smoothly with videotestsrc.’

I have installed new gstreamer by following command

gst-install --prefix=/usr/ --version=1.8.3

And this command will remove 1.2.4 and install 1.8.3. so there will be no conflicting.

Hi RiteshPanchal,
Please try the attached libgstnvvidconv.so on r23.2. I have run the following command with gstreamer 1.8.3
ubuntu@tegra-ubuntu:~$ gst-launch-1.0 v4l2src device=/dev/v4l/by-id/usb-046d_HD_Pro_Webcam_C920_C42A6E9F-video-index0 ! textoverlay text=“Recording…” halignment=0 valignment=1 ! ‘video/x-raw, width=1280, height=720, format=I420, framerate=30/1’ ! nvvidconv ! ‘video/x-raw(memory:NVMM), width=1280, height=720, format=NV12, framerate=30/1’ ! nvoverlaysink display-id=1 sync=false

I don’t have UYVY input but tested it without error via USBCAM with I420. Please try your case.
libgstnvvidconv.so.txt (93.9 KB)

Hi Dane,

Your attached libgstnvvidconv.so is working perfectly on R23.2 with gstreamer 1.10.2 and with UYVY v4l2src. As i already having 1.10.2, so i have tested with this version and its working like a charm.

Thanks for your great help…!!

Merry Christmas…!!!