Commit b0a3c614 authored by Rostislav Pehlivanov's avatar Rostislav Pehlivanov

aacenc_ltp: replace av_clip() with av_clip_uintp2()

Suggested by ubitux.
Convenient.
parent 780dba01
...@@ -101,7 +101,7 @@ void ff_aac_update_ltp(AACEncContext *s, SingleChannelElement *sce) ...@@ -101,7 +101,7 @@ void ff_aac_update_ltp(AACEncContext *s, SingleChannelElement *sce)
lag = i; lag = i;
} }
} }
lag = av_clip(lag, 0, 2047); /* 11 bits => 2^11 = 0->2047 */ lag = av_clip_uintp2(lag, 11); /* 11 bits => 2^11 = 0->2047 */
if (!lag) { if (!lag) {
sce->ics.ltp.lag = lag; sce->ics.ltp.lag = lag;
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment