diff options
author | Stefano Sabatini <stefano.sabatini-lala@poste.it> | 2010-06-02 10:54:50 +0000 |
---|---|---|
committer | Stefano Sabatini <stefano.sabatini-lala@poste.it> | 2010-06-02 10:54:50 +0000 |
commit | ab0b53786b5595fa833610cef6ea896596b2629b (patch) | |
tree | 617ebeadee740993bdeaf9c54f87789551963ead /libavcodec/utils.c | |
parent | 7e566bbe6ce367e880bf09e293a9e72e52c0988e (diff) | |
download | ffmpeg-ab0b53786b5595fa833610cef6ea896596b2629b.tar.gz |
Make avcodec_string() use av_get_codec_tag_string().
Originally committed as revision 23422 to svn://svn.ffmpeg.org/ffmpeg/trunk
Diffstat (limited to 'libavcodec/utils.c')
-rw-r--r-- | libavcodec/utils.c | 14 |
1 files changed, 3 insertions, 11 deletions
diff --git a/libavcodec/utils.c b/libavcodec/utils.c index 739e874ef8..008f9e9e81 100644 --- a/libavcodec/utils.c +++ b/libavcodec/utils.c @@ -840,17 +840,9 @@ void avcodec_string(char *buf, int buf_size, AVCodecContext *enc, int encode) codec_name = enc->codec_name; } else { /* output avi tags */ - if( isprint(enc->codec_tag&0xFF) && isprint((enc->codec_tag>>8)&0xFF) - && isprint((enc->codec_tag>>16)&0xFF) && isprint((enc->codec_tag>>24)&0xFF)){ - snprintf(buf1, sizeof(buf1), "%c%c%c%c / 0x%04X", - enc->codec_tag & 0xff, - (enc->codec_tag >> 8) & 0xff, - (enc->codec_tag >> 16) & 0xff, - (enc->codec_tag >> 24) & 0xff, - enc->codec_tag); - } else { - snprintf(buf1, sizeof(buf1), "0x%04x", enc->codec_tag); - } + char tag_buf[32]; + av_get_codec_tag_string(tag_buf, sizeof(tag_buf), enc->codec_tag); + snprintf(buf1, sizeof(buf1), "%s / 0x%04X", tag_buf, enc->codec_tag); codec_name = buf1; } |