aboutsummaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
authorDaniele Sluijters <info@daenney.net>2009-01-14 22:38:55 +0100
committerMax Kellermann <max@duempel.org>2009-01-14 22:38:55 +0100
commitca42f0142736d3d4e8145fd4e1abd7350604808e (patch)
tree0f9965b771737d47c9a4867f37e88aa207cd11f9 /src
parentae5517b0b3a01c4e3e678f77d85f30b7ac3f3273 (diff)
downloadmpd-ca42f0142736d3d4e8145fd4e1abd7350604808e.tar.gz
mpd-ca42f0142736d3d4e8145fd4e1abd7350604808e.tar.xz
mpd-ca42f0142736d3d4e8145fd4e1abd7350604808e.zip
tag_id3: added support for the "album artist" tag
Read the id3 tags "TPE2" and "TSO2" into the "album artist" tag.
Diffstat (limited to 'src')
-rw-r--r--src/tag_id3.c12
1 files changed, 12 insertions, 0 deletions
diff --git a/src/tag_id3.c b/src/tag_id3.c
index b98d8af57..3bcdd9e58 100644
--- a/src/tag_id3.c
+++ b/src/tag_id3.c
@@ -41,6 +41,14 @@
# define ID3_FRAME_DISC "TPOS"
# endif
+#ifndef ID3_FRAME_ALBUM_ARTIST_SORT
+#define ID3_FRAME_ALBUM_ARTIST_SORT "TSO2"
+#endif
+
+#ifndef ID3_FRAME_ALBUM_ARTIST
+#define ID3_FRAME_ALBUM_ARTIST "TPE2"
+#endif
+
/* This will try to convert a string to utf-8,
*/
static id3_utf8_t * processID3FieldString (int is_id3v1, const id3_ucs4_t *ucs4, int type)
@@ -210,6 +218,10 @@ struct tag *tag_id3_import(struct id3_tag * tag)
struct tag *ret = NULL;
ret = getID3Info(tag, ID3_FRAME_ARTIST, TAG_ITEM_ARTIST, ret);
+ ret = getID3Info(tag, ID3_FRAME_ALBUM_ARTIST,
+ TAG_ITEM_ALBUM_ARTIST, ret);
+ ret = getID3Info(tag, ID3_FRAME_ALBUM_ARTIST_SORT,
+ TAG_ITEM_ALBUM_ARTIST, ret);
ret = getID3Info(tag, ID3_FRAME_TITLE, TAG_ITEM_TITLE, ret);
ret = getID3Info(tag, ID3_FRAME_ALBUM, TAG_ITEM_ALBUM, ret);
ret = getID3Info(tag, ID3_FRAME_TRACK, TAG_ITEM_TRACK, ret);