I帧和IDR帧的区别

视频编码中,经常提到I帧。I帧只使用帧内压缩,不能除去帧间冗余度。P帧做帧间编码,根据当前帧与前面最近的I帧或P帧的差别来编码。

另外一个比较少提到的概念是IDR帧。IDR属于I帧,但是I帧不一定是IDR帧。只有IDR帧,才有SPS和PPS。解码器收到IDR帧时,将reference buffer清空;而收到I帧不会清空reference buffer。也就是说,对某个IDR帧之后的帧,解码器不会参考这个IDR帧之前的任何帧做解码。对某个I帧之后的帧,解码器可能会参考这个I帧之前的帧做解码。还可以参考文档https://malleshamdasari.wordpress.com/2013/07/31/difference-between-i-frame-and-idr-frame/。
在Xilinx VCU GStreamer里,使用参数periodicity-idr指定IDR帧的间隔。在Xilinx VCU Ctrl-SW里,使用参数Gop.FreqIDR指定IDR帧的间隔。PG252里的说明如下:

IDR picture frequency 
periodicity-idr 
Specifies the number of frames between consecutive
instantaneous decoder refresh (IDR) pictures. The periodicity-
idr property was formerly called gop-freq-idr.
Allowed values: <Positive value> or -1 to disable IDR insertion
Default value: 0 (first frame is IDR)
Gop.FreqIDR Specifies the minimum number of frames between two IDR pictures (AVC and HEVC). IDR
insertion depends on the position of the GOP boundary.
Allowed values: positive integer or -1 to disable IDR region.
Default value: -1
posted @ 2020-11-13 11:51  HankFu  阅读(1576)  评论(0编辑  收藏  举报