Displaying 2 results from an estimated 2 matches for "111bbccd".
2008 Nov 06
2
libFLAC header checking
In stream_decoder.c function find_metadata_() checks whether a file is
valid or not. There are 4 cases it recognizes:
1) file begins with 'fLaC'
2) file begins with ID3 (skipped), followed by 'fLaC'
3) file may begin with 11111111 111110?? sync code (or 11111111111110,
depends on endianess i suppose). That is - a raw file with FLAC frames,
without header (right?).
4) file begins
2008 Dec 10
0
libFLAC header checking
...d-blocksize
1 - variable-blocksize
CCCC =
0000 - reserved
0001 - 192 samples
0010-0101 - 576 * (2^(n-2)) samples
0110 - get 8 bit (blocksize-1) from end of header
0111 - get 16 bit (blocksize-1) from end of header
1000-1111 - 256 * (2^(n-8)) samples
MP3:
11111111 111BBCCD and so on
BB =
00 - MPEG 2.5
01 - reserved
10 - MPEG 2
11 - MPEG 1
CC =
00 - reserved
01 - layer 3
10 - layer 2
11 - layer 1
D =
0 - with CRC
1 - without CRC
The best way to distinguish FLAC header from MP3 header is to look at
"0A" (FL...