[FFmpeg-devel] [PATCH 3/3] aacenc: Remove energy 'normalization' modification from the 3GPP psymodel

Alex Converse alex.converse
Wed Oct 27 08:26:16 CEST 2010


On Mon, Oct 25, 2010 at 4:30 PM, Nathan Caldwell <saintdev at gmail.com> wrote:
> This greatly improves bitrate handling. You will now get within a few
> kbps of your requested bitrate instead of 20-40kbps higher.
>
> There is absolutely no analog to this line in the 3GPP spec, that I
> can find.
> ---
> ?libavcodec/aacpsy.c | ? ?1 -
> ?1 files changed, 0 insertions(+), 1 deletions(-)
>
> diff --git a/libavcodec/aacpsy.c b/libavcodec/aacpsy.c
> index 16528d6..7259d4c 100644
> --- a/libavcodec/aacpsy.c
> +++ b/libavcodec/aacpsy.c
> @@ -404,7 +404,6 @@ static void psy_3gpp_analyze(FFPsyContext *ctx, int channel,
> ? ? ? ? ? ? band->energy = 0.0f;
> ? ? ? ? ? ? for (i = 0; i < band_sizes[g]; i++)
> ? ? ? ? ? ? ? ? band->energy += coefs[start+i] * coefs[start+i];
> - ? ? ? ? ? ?band->energy *= 1.0f / (512*512);
> ? ? ? ? ? ? band->thr ? ? = band->energy * 0.001258925f;
> ? ? ? ? ? ? start ? ? ? ?+= band_sizes[g];
>
> --
> 1.7.3.2
>

Ok to commit, though I'd still like to know where it came from.



More information about the ffmpeg-devel mailing list