diff options
author | Michael Niedermayer <michael@niedermayer.cc> | 2021-06-01 11:07:05 +0300 |
---|---|---|
committer | Michael Niedermayer <michael@niedermayer.cc> | 2021-10-06 14:54:16 +0300 |
commit | 92b047755ec9fad17e5865bf8a0a148596c3b407 (patch) | |
tree | 9f6dbc02ab0fd8ec251f6ba4de920cbc5f26ffb0 | |
parent | 7cc32a537b1003395bac7cb27fd7e72e130386c3 (diff) |
avcodec/aacenc: Use FLT_EPSILON for lambda minimum
(cherry picked from commit 4b89cf7aa49191c7f8a5ae6e9cf6cfc79ff4ee5e)
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
-rw-r--r-- | libavcodec/aacenc.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/libavcodec/aacenc.c b/libavcodec/aacenc.c index fb6229930f..179791bd2a 100644 --- a/libavcodec/aacenc.c +++ b/libavcodec/aacenc.c @@ -856,7 +856,7 @@ static int aac_encode_frame(AVCodecContext *avctx, AVPacket *avpkt, /* Not so fast though */ ratio = sqrtf(ratio); } - s->lambda = av_clipf(s->lambda * ratio, FLT_MIN, 65536.f); + s->lambda = av_clipf(s->lambda * ratio, FLT_EPSILON, 65536.f); /* Keep iterating if we must reduce and lambda is in the sky */ if (ratio > 0.9f && ratio < 1.1f) { |