AnsweredAssumed Answered

VPU framerate iMX53

Question asked by flto on Mar 16, 2015
Latest reply on Dec 19, 2017 by flto



I work on an quite old project made with iMX53.

It uses linux-2.6-imx-rel_imx_2.6.35_11.09.01 kernel from Freescale.

I have a problem with frame rate in VPU.

[Full context]

Basically, this program captures a video stream on CSI0 video input, add some annotations (texts, images...) and the result is both displayed in live and saved in a file thanks to VPU encoding.

The internals use cairo library (for texts and images), vpu library (for video encoding) and ioctl calls to IPU driver (for color space changes / merging memories / display).


In essence, the programs loops over these operations:

  • Waiting for a new frame at input
  • Merging an overlay (prepared in another thread, and merged with IPU)
  • Sending frame to VPU (and waiting for VPU to be ready again)
  • Displaying

Since stream is small and manipulated with pointers passed to IPU or VPU accordingly, the operations are very quick.


The recorded videos are "sped up", that is when we record 10 seconds, the replay on PC lasts between 6 et 7 seconds with all images displayed less time than expected. (Hope I am sufficiently clear)

Thus I would like to change the frame rate recorded by the VPU.


When I change frameRateInfo parameter from EncOpenParam struct sent to  vpu_EncOpen, there is no change.

Whether I set 25 (current), 10 or 100, the saved video has the same speed. (6 or 7 seconds for 10 seconds recording ; ~20s for ~30s recording)


Is there other parameters to set in order to change frame rate ?


I attached what is set in EncOpenParam struct, when passed to vpu_EncOpen.

Original Attachment has been moved to: