[FFmpeg-cvslog] avcodec/mlpenc: use FFMAX()
Paul B Mahol
git at videolan.org
Tue Apr 12 20:30:25 EEST 2022
ffmpeg | branch: master | Paul B Mahol <onemda at gmail.com> | Tue Apr 12 18:50:25 2022 +0200| [dc068a7265b432a6a919acef462b927e5c156646] | committer: Paul B Mahol
avcodec/mlpenc: use FFMAX()
> http://git.videolan.org/gitweb.cgi/ffmpeg.git/?a=commit;h=dc068a7265b432a6a919acef462b927e5c156646
---
libavcodec/mlpenc.c | 3 +--
1 file changed, 1 insertion(+), 2 deletions(-)
diff --git a/libavcodec/mlpenc.c b/libavcodec/mlpenc.c
index 25adf6f998..a55302ccc7 100644
--- a/libavcodec/mlpenc.c
+++ b/libavcodec/mlpenc.c
@@ -1187,8 +1187,7 @@ static void input_data_internal(MLPEncodeContext *ctx, const uint8_t *samples,
/* TODO Find out if number_sbits can be used for negative values. */
abs_sample = FFABS(sample);
- if (greatest < abs_sample)
- greatest = abs_sample;
+ greatest = FFMAX(greatest, abs_sample);
temp_lossless_check_data ^= (sample & 0x00ffffff) << channel;
*sample_buffer++ = sample;
More information about the ffmpeg-cvslog
mailing list