[FFmpeg-devel] [PATCH 03/10] swresample/audioconvert: display error message if not conversion not supported
Peter Ross
pross at xvid.org
Tue May 6 14:38:04 CEST 2014
This happens when PCM to DSD conversion is requested.
Signed-off-by: Peter Ross <pross at xvid.org>
---
libswresample/audioconvert.c | 4 +++-
1 file changed, 3 insertions(+), 1 deletion(-)
diff --git a/libswresample/audioconvert.c b/libswresample/audioconvert.c
index 2df11f5..6132fe6 100644
--- a/libswresample/audioconvert.c
+++ b/libswresample/audioconvert.c
@@ -171,8 +171,10 @@ AudioConvert *swri_audio_convert_alloc(enum AVSampleFormat out_fmt,
AudioConvert *ctx;
conv_func_type *f = fmt_pair_to_conv_functions[av_get_packed_sample_fmt(out_fmt) + AV_SAMPLE_FMT_NB*av_get_packed_sample_fmt(in_fmt)];
- if (!f)
+ if (!f) {
+ av_log(0, AV_LOG_ERROR, "cannot convert %s to %s\n", av_get_sample_fmt_name(in_fmt), av_get_sample_fmt_name(out_fmt));
return NULL;
+ }
ctx = av_mallocz(sizeof(*ctx));
if (!ctx)
return NULL;
--
1.8.3.2
-- Peter
(A907 E02F A6E5 0CD2 34CD 20D2 6760 79C5 AC40 DD6B)
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 198 bytes
Desc: Digital signature
URL: <http://ffmpeg.org/pipermail/ffmpeg-devel/attachments/20140506/43850951/attachment.asc>
More information about the ffmpeg-devel
mailing list