[Matroska-devel] Re: CodecPrivate for MPEG-1 and MPEG-2 video

John Cannon spyder at matroska.org
Tue Nov 16 18:57:45 CET 2004


Moritz Bunkus wrote:

> I don't think that the sequence header has such a big impact on
> overhead. And yes, they may occur more than once. If we decide to throw
> them all out then we have to start using CodecState, too, for the places
> where the sequence header changes. I don't even know the exact layout /
> size of a sequence header. That's why I'd like some input from spyder
> here.


Very little impact, It's only like 88 bytes for most MPEG-2 clips I 
have, less for MPEG-1 IIRC.  It's usually repeated at every GOP so you 
may as well consider it part of the I frame.  I'm OK with not putting it 
in the codec private data but we decided to put a copy there because of 
DirectShow's retardedness as Haali stated.  Sane decoders don't need the 
header beforehand (see libmpeg2).  IMO removing the headers entirely 
from the stream is a bad idea.  It makes the whole process much more 
complex and you're separating the codec stream.  It just has to be 
reinterleaved on playback anyway so it's silly.

John




More information about the Matroska-devel mailing list