mirror of
https://gitlab.freedesktop.org/gstreamer/gstreamer.git
synced 2024-12-24 17:20:36 +00:00
x264enc: fix up avcC header construction
Fix off-by-one introduced by commit 35dd89951d
for BUILD_X264 < 76.
Also fixes #610089.
This commit is contained in:
parent
5fd1796fda
commit
61643c7d89
1 changed files with 5 additions and 3 deletions
|
@ -756,12 +756,14 @@ gst_x264_enc_header_buf (GstX264Enc * encoder)
|
|||
sps = nal[SPS_NI].p_payload;
|
||||
#else
|
||||
sps = nal[SPS_NI].p_payload + 4;
|
||||
/* skip NAL unit type */
|
||||
sps++;
|
||||
#endif
|
||||
|
||||
buffer[0] = 1; /* AVC Decoder Configuration Record ver. 1 */
|
||||
buffer[1] = sps[1]; /* profile_idc */
|
||||
buffer[2] = sps[2]; /* profile_compability */
|
||||
buffer[3] = sps[3]; /* level_idc */
|
||||
buffer[1] = sps[0]; /* profile_idc */
|
||||
buffer[2] = sps[1]; /* profile_compability */
|
||||
buffer[3] = sps[2]; /* level_idc */
|
||||
buffer[4] = 0xfc | (4 - 1); /* nal_length_size_minus1 */
|
||||
|
||||
i_size = 5;
|
||||
|
|
Loading…
Reference in a new issue