[Live-devel] emulation bytes in a slice NALU
Ross Finlayson
finlayson at live555.com
Sat Aug 17 21:26:54 PDT 2013
> I am curious if someone could shed some light on the following assumption in the live555 code:
>
> liveMedia/H264VideoStreamFramer.cpp:524: // Note: We assume that there aren't any 'emulation prevention' bytes here to worry about...
What this means is that we 'hope' that there aren't any 'emulation prevention' bytes to worry about, because our code doesn't check for them in this case. (Our H.264 parsing code checks for/removes 'emulation prevention' bytes only when parsing SPS or PPS NAL units, because those are the only NAL units whose contents we really care about, and because doing so for other, much larger NAL units would be costly.)
As you noted, our "analyze_slice_header()" function doesn't check for/remove 'emulation prevention' bytes in VCL NAL units (the ones that have slice headers). That's probably OK, because we call "analyze_slice_header()" only in certain cases, to check the parameters of the 'current' and 'next' NAL units' slice headers to try to figure out whether the 'current' NAL unit ends an 'access unit' (basically, a 'frame'). Our code probably ends up doing the right thing even for your stream. But this turns out to be a moot point, because the "H264VideoStreamFramer" code will shortly be changed to make this 'end of access unit' check more accurate (and more efficient). As part of this, the "analyze_slice_header()" function will probably be removed entirely.
Ross Finlayson
Live Networks, Inc.
http://www.live555.com/
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.live555.com/pipermail/live-devel/attachments/20130817/9d388e5e/attachment-0001.html>
More information about the live-devel
mailing list