diff options
author | Anton Khirnov <wyskas@gmail.com> | 2010-02-02 12:35:08 +0100 |
---|---|---|
committer | Max Kellermann <max@duempel.org> | 2010-06-30 23:18:45 +0200 |
commit | c3569814bda057142da3f02a8d0cccb35184e396 (patch) | |
tree | faca569c490f1af0dfee3b1213db70b71681db99 /src/decoder/ffmpeg_plugin.c | |
parent | 814daac5bae1e7e3a67cd7ed727bd1fe6b9a3889 (diff) | |
download | mpd-c3569814bda057142da3f02a8d0cccb35184e396.tar.gz mpd-c3569814bda057142da3f02a8d0cccb35184e396.tar.xz mpd-c3569814bda057142da3f02a8d0cccb35184e396.zip |
ffmpeg: read more metadata.
Diffstat (limited to '')
-rw-r--r-- | src/decoder/ffmpeg_plugin.c | 11 |
1 files changed, 10 insertions, 1 deletions
diff --git a/src/decoder/ffmpeg_plugin.c b/src/decoder/ffmpeg_plugin.c index 2e06c13f8..7f2207669 100644 --- a/src/decoder/ffmpeg_plugin.c +++ b/src/decoder/ffmpeg_plugin.c @@ -405,12 +405,21 @@ static bool ffmpeg_tag_internal(struct ffmpeg_context *ctx) av_metadata_conv(f, NULL, f->iformat->metadata_conv); ffmpeg_copy_metadata(tag, f->metadata, TAG_ITEM_TITLE, "title"); +#if LIBAVFORMAT_VERSION_INT >= ((52<<16)+(50<<8)) + ffmpeg_copy_metadata(tag, f->metadata, TAG_ITEM_ARTIST, "artist"); + ffmpeg_copy_metadata(tag, f->metadata, TAG_ITEM_DATE, "date"); +#else ffmpeg_copy_metadata(tag, f->metadata, TAG_ITEM_ARTIST, "author"); + ffmpeg_copy_metadata(tag, f->metadata, TAG_ITEM_DATE, "year"); +#endif ffmpeg_copy_metadata(tag, f->metadata, TAG_ITEM_ALBUM, "album"); ffmpeg_copy_metadata(tag, f->metadata, TAG_ITEM_COMMENT, "comment"); ffmpeg_copy_metadata(tag, f->metadata, TAG_ITEM_GENRE, "genre"); ffmpeg_copy_metadata(tag, f->metadata, TAG_ITEM_TRACK, "track"); - ffmpeg_copy_metadata(tag, f->metadata, TAG_ITEM_DATE, "year"); + ffmpeg_copy_metadata(tag, f->metadata, TAG_ITEM_ALBUM_ARTIST, "album_artist"); + ffmpeg_copy_metadata(tag, f->metadata, TAG_ITEM_COMPOSER, "composer"); + ffmpeg_copy_metadata(tag, f->metadata, TAG_ITEM_PERFORMER, "performer"); + ffmpeg_copy_metadata(tag, f->metadata, TAG_ITEM_DISC, "disc"); #else if (f->author[0]) tag_add_item(tag, TAG_ITEM_ARTIST, f->author); |