On Sunday, March 31, 2002, at 06:40 AM, Dirk Nehring wrote:
You probably can't add a checksum easily if there isn't one already because it involves adding a 16-bit field to the audio data region, and you may not have enough room for it in every frame.
I haven't understand it fully: if I use a CRC check field, I loose 2 bytes from the data field. If this is true, I think it is impossible to add a CRC field afterward.
That was my point.
I developed the following lines:
One thing I noticed is that you make the assumption all your frames are Layer III.
Is it theoretically possible to add an CRC checksum to a frame without reencoding?
Theoretically I think it is possible, yes, as long as there are at least 16 bits of unused ancillary data in each frame, or (for Layer III only) there are at least 16 additional bits available from the bit reservoir. If you take bits from the latter, you'll have to update the main_data_begin pointer as appropriate.
-- Rob Leslie rob@mars.org