[FFmpeg-devel] [PATCH] FLAC parser

Justin Ruggles justin.ruggles
Sun Mar 29 03:23:03 CEST 2009


Uoti Urpala wrote:
> On Sat, 2009-03-28 at 21:00 -0400, Justin Ruggles wrote:
>> How do you calculate how many bits are checked for 1 invalid value in a
>> 4-bit code? 2 invalid values in a 3-bit code? etc...
> 
> In this context you can use the base 2 logarithm of the probability of a
> mistake going undetected.
> For 1 invalid value in 4-bit code, -ln(15/16)/ln(2) = 0.093
> For 2 invalid values in a 3-bit code, -ln(6/8)/ln(2) = 0.415

Thank you. Then, yes, Michael is correct.

15       sync code
 0.093   blocksize code
 0.093   samplerate code
 0.415   channel code
 0.415   bps code
 1       reserved bit
 1       utf-8
 8       header crc-8
16       frame crc-16
------
2^42.016 ~ 4.48e12



More information about the ffmpeg-devel mailing list