[Python-Dev] Expanding max chunk size to 4GB.
Erik de Castro Lopo
erikd at mega-nerd.com
Wed Jul 6 22:39:51 CEST 2005
Mark Rages wrote:
> The RIFF chunk size (used by the Python wave library) is 2GB, because
> the length is read as a signed 32-bit integer.
>
> The attached patch to chunk.py raises the limit to 4GB by using a
> signed integer.
>
> Is this correct?
The original Microsoft specification listed the chunk size fields
as unsigned 32 bit int, so what you are doing is correct.
However, be aware that many programs (particularly on windows) using
their own WAV file parsing code do not handle file bigger than 2Gig.
> Is there a more general solution to 32-bit addressing limitation in
> wave files?
No.
> Multiple chunks?
No.
Other file formats allow file sizes larger than 4Gig. I would suggest
you have a look at AU and W64.
Erik
--
+-----------------------------------------------------------+
Erik de Castro Lopo nospam at mega-nerd.com (Yes it's valid)
+-----------------------------------------------------------+
Fundamentalist : Someone who is colour blind and yet wants everyone
else to see the world with the same lack of colour.
More information about the Python-Dev
mailing list