【工程师分享】使用prealloc-args降低MPSoC VCU解码的初始延时

作者:付汉杰,hankf@xilinx.com,文章转载自:赛灵思中文社区论坛

刚启动MPSoC的VCU解码器时,解码器先分析码流,得到分辨率信息后再调用回调函数分配buffer。这会耗费时间,增加延迟。如果希望减少延迟,可以使用prealloc-args参数,提前指定视频分辨率信息,提前分配buffer。

prealloc-args参数的格式是“--prealloc-args max-widthxmax-height: video-mode:chroma-mode:bitdepth:profile-idc:level”。max-widthxmax-height指示分辨率,比如1920x1080。video-mode是,逐行用progr。chroma-mode只444、422、420等格式。bitdepth说明每个色彩像素使用多少bit。profile-idc指编码规范的Profile,可以参考https://en.wikipedia.org/wiki/Advanced_Video_Coding#Profiles。对于H.264,常用的Baseline Profile (BP)是66,Main Profile (MP)是77,High Profile (HiP)是100。level代表解码器最大支持的分辨率。对于常用的level 5.1,使用 51。对于YUV420 8-bit图像,可以使用参数“--prealloc-args 1920x1080:progr:420:8:100:51”。

最新文章

最新文章