The emulation bytes need to be removed as bytes, not bit. This fixes
decoding issues with files that have emulation bytes with the Cedrus
driver.
Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-bad/-/merge_requests/2471>
static guint
get_slice_header_bit_size (GstH264Slice * slice)
{
- return 8 * slice->nalu.header_bytes
- + slice->header.header_size - slice->header.n_emulation_prevention_bytes;
+ return 8 * slice->nalu.header_bytes + slice->header.header_size
+ - 8 * slice->header.n_emulation_prevention_bytes;
}
static void