Scanning a file
Lasse Vågsæther Karlsen
lasse at vkarlsen.no
Mon Oct 31 03:41:02 EST 2005
David Rasmussen wrote:
<snip>
> If you must know, the above one-liner actually counts the number of
> frames in an MPEG2 file. I want to know this number for a number of
> files for various reasons. I don't want it to take forever.
<snip>
Don't you risk getting more "frames" than the file actually have? What
if the encoded data happens to have the magic byte values for something
else?
--
Lasse Vågsæther Karlsen
http://usinglvkblog.blogspot.com/
mailto:lasse at vkarlsen.no
PGP KeyID: 0x2A42A1C2
More information about the Python-list
mailing list