clockoverlay in gstreamer.

cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 

clockoverlay in gstreamer.

4,313 Views
jisjohn
Contributor I

Hello all,


I am trying to implement a clock overlay to a video source from an analogue camera attached to the e-CAMNT_MX53x decoder board. The video is streamed and recorded in mp4 format, I followed the below procedure.


1,Enabled pango in the board.

2,Passed the command

     gst-launch-0.10 -v mfw_v4lsrc device=/dev/video0 capture-width=720 capture-height=576 sensor-width=720 sensor-height=288 typefind=1 preview=1 preview-width=1024 preview-height=768 bg=1 fps-n=25 fps-d=1 ! clockoverlay halign=left valign=bottom xpad=20 ypad=20 time-format="%R %d-%b-%Y" font-desc="Sans 15" shaded-background=false ! tee name=t ! queue ! mfw_ipucsc ! mfw_vpuencoder codec-type=std_mpeg4 ! avimux ! filesink location=/mnt/floppy/capturetest.mp4 t. ! queue ! mfw_v4lsink &


the gstreamer halted by giving the following warning WARNING: erroneous pipeline: could not link mfwgstv4lsrc0 to clockoverlay0


the command works fine if the clock overlay part is removed (i.e recording and streaming are proper).


Regards,

Jis


0 Kudos
4 Replies

1,922 Views
jisjohn
Contributor I

I tried usb camera also then also the same error is observed i.e the gstreamer halted by giving the following "WARNING: erroneous pipeline: could not link mfwgstv4lsrc0 to clockoverlay0". i.e mfwgstv4lsrc and clockoverlay cannot be linked.


Regards,


Jis

0 Kudos

1,922 Views
jisjohn
Contributor I

Hello all,

My camera output is in the format NV12 where as the clock overlay will take only the formatts I420 and UYVY, i used the following command and got the clock overlay


gst-launch-0.10 -v mfw_v4lsrc device=/dev/video0 capture-width=720 capture-height=576 sensor-width=720 sensor-height=288 typefind=1 preview=1 preview-width=1024 preview-height=768 ! queue max-size-buffers=10 ! ffmpegcolorspace ! clockoverlay halign=left valign=bottom xpad=20 ypad=20 time-format="%R %d-%b-%Y" font-desc="Sans 15" shaded-background=false ! mfw_v4lsink &


The current observations are.

1, High CPU usage of 76%.

2, The video display is having lines on it till the clockoverlay is displayed (Image1)

Image1.jpg

3, Slower update of screen if camera is moved once the clock overlay appears on screen.

Regards,

Jis

0 Kudos

1,922 Views
LeonardoSandova
Specialist I

Jis, replace ffmpegcolorspace with mfw_ipucsc, this way the color space conversion is HW accelerated.

1,922 Views
jisjohn
Contributor I

Hello Leonardo,

I tried the same using the following command, gst-launch-0.10 -v mfw_v4lsrc device=/dev/video0 capture-width=720 capture-height=576 sensor-width=720 sensor-height=288 typefind=1 preview=1 preview-width=1024 preview-height=768 ! mfw_ipucsc ! clockoverlay time-format="%R %d-%b-%Y" ! mfw_v4lsink &

The clock overlay starts appearing after 30 seconds but the camera is freezed and a green frame was flashing on the screen as shown in the image also in the terminal the following error was displayed "mxc_ipu_hl_lib.c:956 ipu is busy"

Please find attached the image sequences

1,Screen till the clock overlay appears.

2 & 3, Screen with clock overlay.

The CPU usage is the concern here (around 76%) and I wanted to know whether something can be done in imx53 ipu module so that we will get the data from the camera in UYVY format itself and we don't have to do any further color space conversion.Image1.jpg

                                                        Image 1

Image2.jpg

                                                            Image 2

Image3.jpg

                                                                 Image3

Regards,

Jis

0 Kudos