cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 
nishiuser
Visitor
Visitor
272 Views
Registered: ‎07-20-2021

Delay in omxh265enc in 4K encoding

Working in Zynq UltraScale+ MPSoC

The output of following pipeline have frame skipping. When the same pipeline runs with h264 encoder, the output is smooth.

gst-launch-1.0 v4l2src device=/dev/video0 io-mode=4 ! video/x-raw, format=NV12, width=3840, height=2160, framerate=60/1 ! queue ! omxh265enc qp-mode=auto gop-mode=basic gop-length=60 b-frames=0 target-bitrate=10000 num-slices=8 control-rate=constant prefetch-buffer=true low-bandwidth=false filler-data=true cpb-size=1000 initial-delay=500 ! video/x-h265,profile=main ! queue ! h265parse ! matroskamux ! queue ! filesink location= test.mkv

By further debugging, I found that the time taken to encode one frame by the encoder is

h264 : 16ms

h265 : 95 to 100ms

The delay comes from some frame handling at the output port of encoder.

Any suggestions on how to resolve this ?

 

0 Kudos
2 Replies
kvasantr
Moderator
Moderator
188 Views
Registered: ‎04-12-2017

Hello @nishiuser 

what is the version of SW you are using to run the above pipeline?

are you using TRD designs to test? if yes which one?

 

-------------------------------------------------------------------------
Don’t forget to reply, kudo, and accept as solution.
-------------------------------------------------------------------------
0 Kudos
nishiuser
Visitor
Visitor
155 Views
Registered: ‎07-20-2021

Hi,

Gstreamer version :1.14.4

omx version : release-2019.2

I figured out the issue, but could not solve it.

gstomxvideoenc.c:2567:check_input_alignment:<omxh265enc-omxh265enc0> 

input buffer has wrong size/stride (12441600 expected: 12533760), can't use dynamic allocation

h265 encoder expects buffer to be 32 bit aligned. So the input should be 3840x2176

But how can I achieve this ?

 

0 Kudos