aboutsummaryrefslogtreecommitdiffstats
path: root/src/tag.c
diff options
context:
space:
mode:
authorWarren Dukes <warren.dukes@gmail.com>2005-03-05 22:24:10 +0000
committerWarren Dukes <warren.dukes@gmail.com>2005-03-05 22:24:10 +0000
commit3bdee5521711f338b9ce0701d51543bee24008fc (patch)
tree45e61023164f78259095f299e32a5d386a405bc3 /src/tag.c
parent4b016cafa1e44294605467dd95efb421b96574a5 (diff)
downloadmpd-3bdee5521711f338b9ce0701d51543bee24008fc.tar.gz
mpd-3bdee5521711f338b9ce0701d51543bee24008fc.tar.xz
mpd-3bdee5521711f338b9ce0701d51543bee24008fc.zip
added composer, performer, and comment metadata items
git-svn-id: https://svn.musicpd.org/mpd/trunk@3022 09075e82-0dd4-0310-85a5-a0d7c8717e4f
Diffstat (limited to 'src/tag.c')
-rw-r--r--src/tag.c14
1 files changed, 13 insertions, 1 deletions
diff --git a/src/tag.c b/src/tag.c
index ab32445f8..7b1b8e837 100644
--- a/src/tag.c
+++ b/src/tag.c
@@ -42,6 +42,12 @@
#include <FLAC/metadata.h>
#endif
+#ifdef HAVE_ID3TAG
+#ifndef ID3_FRAME_COMPOSER
+#define ID3_FRAME_COMPOSER "TCOM"
+#endif
+#endif
+
char * mpdTagItemKeys[TAG_NUM_OF_ITEM_TYPES] =
{
"Artist",
@@ -50,7 +56,10 @@ char * mpdTagItemKeys[TAG_NUM_OF_ITEM_TYPES] =
"Track",
"Name",
"Genre",
- "Date"
+ "Date",
+ "Composer",
+ "Performer",
+ "Comment"
};
static mpd_sint8 ignoreTagItems[TAG_NUM_OF_ITEM_TYPES];
@@ -70,6 +79,7 @@ void initTagConfig() {
/* parse the "metadata_to_use" config parameter below */
memset(ignoreTagItems, 0, TAG_NUM_OF_ITEM_TYPES);
+ ignoreTagItems[TAG_ITEM_COMMENT] = 1; /* ignore comments by default */
param = getConfigParam(CONF_METADATA_TO_USE);
@@ -174,6 +184,8 @@ MpdTag * parseId3Tag(struct id3_tag * tag) {
ret = getID3Info(tag, ID3_FRAME_TRACK, TAG_ITEM_TRACK, ret);
ret = getID3Info(tag, ID3_FRAME_YEAR, TAG_ITEM_DATE, ret);
ret = getID3Info(tag, ID3_FRAME_GENRE, TAG_ITEM_GENRE, ret);
+ ret = getID3Info(tag, ID3_FRAME_COMPOSER, TAG_ITEM_COMPOSER, ret);
+ ret = getID3Info(tag, ID3_FRAME_COMMENT, TAG_ITEM_COMMENT, ret);
return ret;
}