[FFmpeg-soc] [soc]: r4376 - in amr: amrnbfloatdata.h amrnbfloatdec.c

Robert Swain robert.swain at gmail.com
Tue Jun 2 15:04:10 CEST 2009


Colin McQuillan wrote:
> 2009/6/2 Robert Swain <robert.swain at gmail.com>:
>> cmcq wrote:
>>> Author: cmcq
>>> Date: Tue Jun  2 13:58:23 2009
>>> New Revision: 4376
>>>
>>> Log:
>>> Rescale AMR samples from 16-bit PCM values
>>> The samples /A-codecs/amr/{sample,sample2,whatireallywant}.amr now produce
>>> recognizable output. There is still significant distortion.
>> Great! :D
>>
>>> Modified:
>>>   amr/amrnbfloatdata.h
>>>   amr/amrnbfloatdec.c
>>>
>>> Modified: amr/amrnbfloatdata.h
>>>
>>> ==============================================================================
>>> --- amr/amrnbfloatdata.h        Mon Jun  1 19:34:02 2009        (r4375)
>>> +++ amr/amrnbfloatdata.h        Tue Jun  2 13:58:23 2009        (r4376)
>>> @@ -38,6 +38,9 @@
>>>  #define AMR_BLOCK_SIZE    160
>>>  #define AMR_SUBFRAME_SIZE  40
>>>  +// AMR is designed to produce 16-bit PCM samples (3GPP TS 26.090 4.2)
>>> +#define AMR_SAMPLE_SCALE 32768.0
>> Maybe have:
>>
>> #define AMR_SAMPLE_BOUND 32768.0
>> #define AMR_SAMPLE_SCALE 1.0/32768.0
>>
>> and edit the other code accordingly so that you can use * rather than /. We
>> may have some suitable dsputil function for this anyway so it's not
>> massively important. Michael would have a suggestion about it later I
>> expect.
> 
> Since most of the processes are linear, I should be able to scale the
> innovative vectors definitions in amrnbfloatdata.h. However, I need to
> investigate what other effects this will have.

OK.

> Do you have any scripts to help generate amrnbfloatdata.h except reformat.pl?

I'll have a look around but I think that's all I used and just edited it 
accordingly.

Regards,
Rob


More information about the FFmpeg-soc mailing list