Python code for reading MPEG *headers*?
Tom Bridgman
bridgman at wyeth.gsfc.nasa.gov
Wed May 23 15:14:01 EDT 2001
We have some animations we've coded into MPEG-1 and MPEG-2 format and
we'd like a way to read some basic stats about the animation for
inclusion in a database - frame size, number of frames, color depth,
etc. from the file.
Currently, I've got a Python wrapper on the SGI utility dmconvert which
works okay for MPEG-1 files but doesn't like MPEG-2, especially in HDTV
resolution.
Does anyone have a code that can parse this information out of an MPEG-2
header? The MPEG-2 format docs I've examined are basically impenetrable
- speaking about searching for tag fields but not explaining what the
tag looks like.
Again, we just need to read the header info, not the full file so I
wouldn't think there'd be licensing issues.
Alternatively, if anyone knows of a *comprehensible* description of the
MPEG-2 headers?
Thanks,
Tom
--
Dr. William T."Tom" Bridgman Scientific Visualization Studio
Global Science & Technology, Inc. NASA/Goddard Space Flight Center
Email: bridgman at wyeth.gsfc.nasa.gov Code 935
Phone: 301-286-1346 Greenbelt, MD 20771
FAX: TBD http://svs.gsfc.nasa.gov/
More information about the Python-list
mailing list