es碼流結(jié)構(gòu)
在其他參考文獻(xiàn)中 宏塊是最小的單位 不能再被分割 個人比較認(rèn)同這種說法 故認(rèn)為es碼流應(yīng)為5層結(jié)構(gòu)
個人理解在H.264中:
SPS信息用于描述圖像序列層的信息.
PPS信息用于描述圖像的信息.
圖像序列 & SPS
通過SPS可獲取序列的信息, 比如:
可獲取H264的Profile和Level等信息.
解碼器獲取Profile和Level信息后, 可明白需要準(zhǔn)備那些內(nèi)容來進(jìn)行解碼.獲取序列中圖像的寬和高.
可通過pic_width_in_mbs_minus1
和pic_height_in_map_units_minus1
來計算圖像的寬和高.獲取序列中圖像的幀率.
如果包含vui信息, 還可計算出圖像的幀率.
GOP
In video coding, a group of pictures, or GOP structure, specifies the order in which intra- and inter-frames are arranged.
The GOP is a group of successive pictures within a coded video stream.
Each coded video stream consists of successive GOPs.
From the pictures contained in it, the visible frames are generated.
Encountering(遇到) a new GOP in a compressed video stream ensures the decoder that no previous frame will be needed to decode the next ones, and is what allows fast seeking through the video.
GOP由一組連續(xù)的視頻編碼圖像.
每個視頻流有很多連續(xù)的GOP組成.
- GOP Structure
The GOP structure is often referred by two numbers, for example, M=3, N=12. The first number tells the distance between two anchor frames (I or P).
The second one tells the distance between two full images (I-frames): it is the GOP size.[2]
For the example M=3, N=12, the GOP structure is IBBPBBPBBPBBI. Instead of the M parameter the maximal count of B-frames between two consecutive anchor frames can be used.
For example, in a sequence with pattern IBBBBPBBBBPBBBBI, the GOP size is equal to 15 (length between two I frames) and distance between two anchor frames (M value) is 5 (length between I and P frames or length between two consecutive P Frames).
GOP的size指的是兩個相鄰I幀的距離.
Slice & MB
Slices
- 一幅圖像被分割成1個或多個片.
- 每個片有很多宏塊組成.
Macroblocks
- 基本的處理單元.
- 每個宏塊包括一個16*16的亮度采樣和兩個8*8的色度采樣.
- 宏塊不能再被分割.
Reference:
新一代視頻壓縮編碼標(biāo)準(zhǔn) ——H.264/AVC 畢厚杰主編
https://en.wikipedia.org/wiki/Group_of_pictures
https://en.wikipedia.org/wiki/H.264/MPEG-4_AVC
http://iphome.hhi.de/wiegand/assets/pdfs/DIC_H264_07.pdf