Hello,
I am trying to use VPU API on IMX8MM board, but no matter what parameters I add to function VPU_DecLoad() I always get VPU_DEC_RET_INVALID_PARAM return code. What is interesting is that the same parameters, for some reason, work in GStreamer. For example, I hardcoded those parameters (copied from gststreamer debug output):
Solved! Go to Solution.
I hate replying to my own requests, but I will do it in case someone else have this problem later:
Be VERY sure that you zero VpuMemDesc structure before assigning size to it and passing to VPU_DecGetMem. It's not stated anywhere in documentation, but correct way to use it is:
VpuMemDesc mem_desc;
memset(&mem_desc, 0, sizeof(VpuMemDesc));
mem_desc.nSize = <memory size got from VPU_DecQueryMem + alignment taken from the same function>;
I hate replying to my own requests, but I will do it in case someone else have this problem later:
Be VERY sure that you zero VpuMemDesc structure before assigning size to it and passing to VPU_DecGetMem. It's not stated anywhere in documentation, but correct way to use it is:
VpuMemDesc mem_desc;
memset(&mem_desc, 0, sizeof(VpuMemDesc));
mem_desc.nSize = <memory size got from VPU_DecQueryMem + alignment taken from the same function>;
Found something, that might be related to the issue: