1
0
mirror of https://github.com/FFmpeg/FFmpeg.git synced 2024-12-23 12:43:46 +02:00

Write sample format description within avcodec_string()

Originally committed as revision 14485 to svn://svn.ffmpeg.org/ffmpeg/trunk
This commit is contained in:
Peter Ross 2008-07-31 12:56:56 +00:00
parent c2b28bb975
commit 9e82a113e5

View File

@ -31,6 +31,7 @@
#include "dsputil.h" #include "dsputil.h"
#include "opt.h" #include "opt.h"
#include "imgconvert.h" #include "imgconvert.h"
#include "audioconvert.h"
#include <stdarg.h> #include <stdarg.h>
#include <limits.h> #include <limits.h>
#include <float.h> #include <float.h>
@ -1148,6 +1149,10 @@ void avcodec_string(char *buf, int buf_size, AVCodecContext *enc, int encode)
enc->sample_rate, enc->sample_rate,
channels_str); channels_str);
} }
if (enc->sample_fmt != SAMPLE_FMT_NONE) {
snprintf(buf + strlen(buf), buf_size - strlen(buf),
", %s", avcodec_get_sample_fmt_name(enc->sample_fmt));
}
/* for PCM codecs, compute bitrate directly */ /* for PCM codecs, compute bitrate directly */
switch(enc->codec_id) { switch(enc->codec_id) {