/* copy the position */
rbsp->nal = *nal;
- rbsp->escaped = 0;
-
/* search for the end of the NAL unit */
while (vl_vlc_search_byte(nal, num_bits, 0x00)) {
if (vl_vlc_peekbits(nal, 24) == 0x000001 ||
i += 8;
}
}
+
+ valid = vl_vlc_valid_bits(&rbsp->nal);
+
+ rbsp->escaped = (valid >= 16) ? 16 : ((valid >= 8) ? 8 : 0);
}
/**