diff options
author | Michael Niedermayer <michaelni@gmx.at> | 2011-06-18 21:54:11 +0200 |
---|---|---|
committer | Michael Niedermayer <michaelni@gmx.at> | 2011-06-19 03:54:15 +0200 |
commit | 035c13e307daeb2a250b86f0ddef3b783a6393e5 (patch) | |
tree | cff630b817ba9cba8787e455b56acf85c0780b4a /ffmpeg.c | |
parent | 7ba262527fa87b3e6556b905a1b3cb0ad6ac2043 (diff) | |
download | ffmpeg-035c13e307daeb2a250b86f0ddef3b783a6393e5.tar.gz |
ffmpeg: warn if samples need to be converted in a lossy way for lossless encoders.
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
Diffstat (limited to 'ffmpeg.c')
-rw-r--r-- | ffmpeg.c | 2 |
1 files changed, 2 insertions, 0 deletions
@@ -617,6 +617,8 @@ static void choose_sample_fmt(AVStream *st, AVCodec *codec) break; } if (*p == -1) { + if((codec->capabilities & CODEC_CAP_LOSSLESS) && av_get_sample_fmt_name(st->codec->sample_fmt) > av_get_sample_fmt_name(codec->sample_fmts[0])) + av_log(NULL, AV_LOG_ERROR, "Convertion will not be lossless'\n"); av_log(NULL, AV_LOG_WARNING, "Incompatible sample format '%s' for codec '%s', auto-selecting format '%s'\n", av_get_sample_fmt_name(st->codec->sample_fmt), |