mirror of
https://github.com/FFmpeg/FFmpeg.git
synced 2024-12-23 12:43:46 +02:00
avcodec/opusenc_psy: use av_clip_uintp2()
Fixes fate-source. Signed-off-by: James Almer <jamrial@gmail.com>
This commit is contained in:
parent
b8eaecbf39
commit
e4fd7b1fea
@ -299,7 +299,7 @@ static void celt_gauge_psy_weight(OpusPsyContext *s, OpusPsyStep **start,
|
|||||||
}
|
}
|
||||||
|
|
||||||
tonal /= 1333136.0f;
|
tonal /= 1333136.0f;
|
||||||
f_out->spread = av_clip(lrintf(tonal), 0, 3);
|
f_out->spread = av_clip_uintp2(lrintf(tonal), 2);
|
||||||
|
|
||||||
rate = ((float)s->avctx->bit_rate) + frame_bits*frame_size*16;
|
rate = ((float)s->avctx->bit_rate) + frame_bits*frame_size*16;
|
||||||
rate *= s->lambda;
|
rate *= s->lambda;
|
||||||
|
Loading…
Reference in New Issue
Block a user