mirror of
https://gitlab.freedesktop.org/gstreamer/gstreamer.git
synced 2024-12-29 19:50:40 +00:00
codecparser: h265: skip byte alignment bits while parsing slice header
Skip the byte alignment bits as per the logic of byte_alignment() provided in hevc specification. This will fix the calculation of slice header size. https://bugzilla.gnome.org/show_bug.cgi?id=747613
This commit is contained in:
parent
b17a026eb7
commit
a86e7c1c1f
1 changed files with 8 additions and 0 deletions
|
@ -2185,6 +2185,14 @@ gst_h265_parser_parse_slice_hdr (GstH265Parser * parser,
|
|||
goto error;
|
||||
}
|
||||
|
||||
/* Skip the byte alignment bits */
|
||||
if (!nal_reader_skip (&nr, 1))
|
||||
goto error;
|
||||
while (!nal_reader_is_byte_aligned (&nr)) {
|
||||
if (!nal_reader_skip (&nr, 1))
|
||||
goto error;
|
||||
}
|
||||
|
||||
slice->header_size = nal_reader_get_pos (&nr);
|
||||
slice->n_emulation_prevention_bytes = nal_reader_get_epb_count (&nr);
|
||||
|
||||
|
|
Loading…
Reference in a new issue