A quick glance at Bink Audio

Since my attention was drawn to this format (and binary specification was provided as well) I’ve briefly looked at it—and a brief look should be enough.

From what I see it’s the same Bink Audio but in its own container instead of Bink. It has 24-byte header, a table of 16-bit audio block sizes and actual audio data (each frame may be prefixed with 0x99 0x99 but I’m not sure since I’ve not seen a single file in that format).

Frame header:

  • 1FCB magic;
  • one byte of version (version 2 groups audio frames together, previous one does not);
  • one byte with number of blocks per frame;
  • two-byte sampling rate;
  • four-byte variable, probably frame length in samples;
  • four-byte unknown variable, maybe suggested input buffer size?
  • four-byte unknown variable
  • four-byte variable, number of frames in seek table.

So as expected it’s nothing special.

4 Responses to “A quick glance at Bink Audio”

  1. Paul says:

    So is it DCT or RDFT variant or something else?

  2. Kostya says:

    I expect it to be DCT since RDFT variant was used only in very old Bink files.

  3. Paul says:

    I can confirm it is DCT, just that last 2 bytes in header of 24 bytes if not 0100 they signal something and makes my demuxer to not give good packets to decoder.

  4. Kostya says:

    IIRC that depends on version. For one version it’s 32-bit int, for the other it’s two 16-bit ints telling how many frames are clumped together and number of such blocks.

    But let those with audio samples figure it out 😉