Redundant code cleanup.
Optimized dither generation.
Minor optimization in bit allocation.
Comments.
Originally committed as revision 9669 to svn://svn.ffmpeg.org/ffmpeg/trunk
Fix the bugs:
1. The quality of output because of incorrect windowing coefficients.
New code for window generation.
2. Dynrng values were reset where dynrng value is present in the first block,
but not in the subsequent block.
Originally committed as revision 9667 to svn://svn.ffmpeg.org/ffmpeg/trunk
Remove more unnecessary headers.
Codec initialization changed to use name => argument notation.
Originally committed as revision 9663 to svn://svn.ffmpeg.org/ffmpeg/trunk
Converted the window from double to float.
Now sound produced is as good as sound produced by liba52.
Originally committed as revision 9661 to svn://svn.ffmpeg.org/ffmpeg/trunk
Reset the blksw and dithflag to 0 at the begining of each block.
Otherwise blockswitching propagates over multiple frames even if
block switching is not enabled for that frame.
Also reuse rematflg.
Originally committed as revision 9660 to svn://svn.ffmpeg.org/ffmpeg/trunk
I realized that the bug was not in the imdct routine but in the
get_transform_coeffs.
Fixed it.
Code now uses the ffmpeg's imdct routines.
All the mplayer's ac3 samples are decoded
successfully.
Also improved downmixing.
Now all the downmixing coeffcients for channels
are normalized such that the sum of coefficients
used to construct the output for single channel
never exceeds 1.0.
Originally committed as revision 9659 to svn://svn.ffmpeg.org/ffmpeg/trunk
More code cleanup.
Window is now runtime generated.
Fixed the bugs in rematrixing routine and
in Decoding AC3 Bitstreams when coupling is in use.
Still struggling to find out what affects the quality of
the produced sound. Can anybody have a look at the
imdct routines do_imdct_256 and do_imdct_512 and tell me
whether it is the correctly implemented as described in
standard.
Originally committed as revision 9658 to svn://svn.ffmpeg.org/ffmpeg/trunk
major code cleanup.
correct implementation of imdct.
implemented imdct for block switching also.
when coupling is not in use all the
ac3 streams are decoded correctly.
but when coupling is in use there is a bug.
i am currently finding the root of the bug.
if anybody can help.
Originally committed as revision 9657 to svn://svn.ffmpeg.org/ffmpeg/trunk
working decoder
imdct for block switching is to be implemented
various other things to do
Originally committed as revision 9656 to svn://svn.ffmpeg.org/ffmpeg/trunk
Latest commit.
There is no error in parsing and or recovering transform coefficients.
Double checked with ac3dec.
Getting consistent results with the bit allocation routine and transform
coefficients.
The code is able to parse valid ac3 bitstreams without error from start
to end.
I have also implemented the imdct when block switching is not enabled.
However, can anybody provide an insight into how to convert float samples to
int16_t ? lrint is of no help cuz it produces output -1, 0 or 1 whereas the
output should be between -32768 to 32767.
Originally committed as revision 9654 to svn://svn.ffmpeg.org/ffmpeg/trunk
Removed _ from names
Removed temporary storage for the exponents
Removed ctx->samples
Now each transform coefficients are stored in audio block as an array of transform coefficients for each channel
added ctx->delay (output of later half of previous block)
added audio_block->block_output(output of this block)
I am still not able to produce the output.
I checked the code twice completely. I am not missing anything in
parsing or in bit allocation. Yet it throws error in getting transform
coefficients sometimes. Can anyone review a code of get_transform_coeffs and
help me debug it further. I think the error is in do_bit_allocation routine cuz
get_transform_coeffs is dependent on the bit allocation parameters table.
I have checked the bit allocation algorithm thoroughly and it is as defined in the
standard. Tried everything and got stuck where to go further.
Please help me.
Originally committed as revision 9653 to svn://svn.ffmpeg.org/ffmpeg/trunk