diff options
author | Andreas Rheinhardt <andreas.rheinhardt@gmail.com> | 2020-03-30 03:09:41 +0200 |
---|---|---|
committer | Andreas Rheinhardt <andreas.rheinhardt@gmail.com> | 2020-04-07 15:02:54 +0200 |
commit | 1719c7f5db233a7efb2b55d7299d30f32061499b (patch) | |
tree | e67155f70d1bf9218d8891fd19c4a318f9af52cb /libavformat | |
parent | cbea58b2b35c6409e062c929f0b2ab763b8661eb (diff) | |
download | ffmpeg-1719c7f5db233a7efb2b55d7299d30f32061499b.tar.gz |
avformat/webmdashenc: Use AVCodecDescriptors for codec names
Signed-off-by: Andreas Rheinhardt <andreas.rheinhardt@gmail.com>
Diffstat (limited to 'libavformat')
-rw-r--r-- | libavformat/webmdashenc.c | 12 |
1 files changed, 1 insertions, 11 deletions
diff --git a/libavformat/webmdashenc.c b/libavformat/webmdashenc.c index 016de8af6b..08fe976b15 100644 --- a/libavformat/webmdashenc.c +++ b/libavformat/webmdashenc.c @@ -61,17 +61,7 @@ typedef struct WebMDashMuxContext { static const char *get_codec_name(int codec_id) { - switch (codec_id) { - case AV_CODEC_ID_VP8: - return "vp8"; - case AV_CODEC_ID_VP9: - return "vp9"; - case AV_CODEC_ID_VORBIS: - return "vorbis"; - case AV_CODEC_ID_OPUS: - return "opus"; - } - return NULL; + return avcodec_descriptor_get(codec_id)->name; } static double get_duration(AVFormatContext *s) |