diff options
author | Vitor Sessak <vitor1001@gmail.com> | 2008-07-27 22:22:51 +0000 |
---|---|---|
committer | Vitor Sessak <vitor1001@gmail.com> | 2008-07-27 22:22:51 +0000 |
commit | b26d3205835c3d66f655247d00044658d5e58e51 (patch) | |
tree | b54d2381a0e5d8d658be2de107591c61111ab8e0 /libavcodec/ra288.c | |
parent | 854ce441c352a54673c20bf46513edfdd6535c08 (diff) | |
download | ffmpeg-b26d3205835c3d66f655247d00044658d5e58e51.tar.gz |
Add a few comments pointing to the G.728 specification
Originally committed as revision 14444 to svn://svn.ffmpeg.org/ffmpeg/trunk
Diffstat (limited to 'libavcodec/ra288.c')
-rw-r--r-- | libavcodec/ra288.c | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/libavcodec/ra288.c b/libavcodec/ra288.c index 10f5ca715d..36d0b6097c 100644 --- a/libavcodec/ra288.c +++ b/libavcodec/ra288.c @@ -74,11 +74,13 @@ static void decode(RA288Context *ractx, float gain, int cb_coef) ractx->sb[x] = -scalar_product_float(ractx->sb + x + 1, ractx->sp_lpc, 36); - /* convert log and do rms */ + /* block 46 of G.728 spec */ sum = 32. - scalar_product_float(ractx->gain_lpc, ractx->lhist, 10); + /* block 47 of G.728 spec */ sum = av_clipf(sum, 0, 60); + /* block 48 of G.728 spec */ sumsum = exp(sum * 0.1151292546497) * gain; /* pow(10.0,sum/20)*f */ for (x=0; x < 5; x++) |