Rising CPU usage when decoding interlaced H.264 using VPU

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

Rising CPU usage when decoding interlaced H.264 using VPU

738 Views
jasson_rodriguez
Contributor II

Hi,

We need to perform decoding of an interlaced H.264 stream using the VPU of the iMX8 Quad Max. Doing it using the v4l2h264dec GStreamer plugin the CPU usage keeps rising over time. For example, the following is the CPU usage of the gst-launch process measured using top:

Time 0: 3% CPU
1 min: 6.6% CPU
2 min: 14% CPU
3 min: 20.2% CPU

The same behaviour was observed on a iMX8M Plus using vpudec.

Is interlaced video decoding supported by the Amphion VPU (or any other VPU)? Or is there another issue with decoding interlaced video?

To reproduce the issue I recorded a file from the stream which can be played using the following GStreamer pipeline:
gst-launch-1.0 filesrc location=interlaced.h264 ! h264parse ! v4l2h264dec output-io-mode=dmabuf ! fakesink sync=true

Problematic video:

https://drive.google.com/file/d/1YPnvKthPSfGqi5q_Ua_oUKjZ_ACMeOqv/view?usp=sharing

0 Kudos
3 Replies

708 Views
jasson_rodriguez
Contributor II

Hello Bio,

I had to upload a shorter video due to the attachment size constraint. While the original pipeline still shows some increase in the CPU usage, it is better shown by the following pipeline:

gst-launch-1.0 multifilesrc location=interlaced-small.h264 loop=true ! h264parse ! v4l2h264dec output-io-mode=dmabuf ! fakesink sync=true

Regards

0 Kudos

714 Views
Bio_TICFSL
NXP TechSupport
NXP TechSupport

Hello jasson,

The h264 file can't be accessed. Could you share the h264 video?

Regards

0 Kudos

679 Views
jasson_rodriguez
Contributor II

Hello @Bio_TICFSL,

I'm sorry, I didn't notice I wasn't replying to you directly. I uploaded a smaller file in another reply to my post.

I tried to update the board's BSP to use Yocto Hardknott and it got even worse. This time seeing the issue with a progressive stream. Do you have any suggestions?

0 Kudos