aboutsummaryrefslogtreecommitdiffstats
path: root/src/cue
diff options
context:
space:
mode:
authorMax Kellermann <max@duempel.org>2012-08-25 09:56:14 +0200
committerMax Kellermann <max@duempel.org>2012-08-25 09:56:14 +0200
commitacaa725478ae5e6e4fff9e07cf8637d17d314c41 (patch)
tree234a20740568f8de4e5805724dc5ba2957c2c84b /src/cue
parentf351550534939478d7ddc791dc76aafd5f2a3503 (diff)
downloadmpd-acaa725478ae5e6e4fff9e07cf8637d17d314c41.tar.gz
mpd-acaa725478ae5e6e4fff9e07cf8637d17d314c41.tar.xz
mpd-acaa725478ae5e6e4fff9e07cf8637d17d314c41.zip
playlist/cue: map "PERFORMER" to "artist" or "album artist"
Implements Mantis ticket 0003549.
Diffstat (limited to 'src/cue')
-rw-r--r--src/cue/cue_parser.c12
1 files changed, 11 insertions, 1 deletions
diff --git a/src/cue/cue_parser.c b/src/cue/cue_parser.c
index 868aed094..2b0733f00 100644
--- a/src/cue/cue_parser.c
+++ b/src/cue/cue_parser.c
@@ -216,9 +216,19 @@ cue_parser_feed2(struct cue_parser *parser, char *p)
if (tag != NULL)
cue_parse_rem(p, tag);
} else if (strcmp(command, "PERFORMER") == 0) {
+ /* MPD knows a "performer" tag, but it is not a good
+ match for this CUE tag; from the Hydrogenaudio
+ Knowledgebase: "At top-level this will specify the
+ CD artist, while at track-level it specifies the
+ track artist." */
+
+ enum tag_type type = parser->state == TRACK
+ ? TAG_ARTIST
+ : TAG_ALBUM_ARTIST;
+
struct tag *tag = cue_current_tag(parser);
if (tag != NULL)
- cue_add_tag(tag, TAG_PERFORMER, p);
+ cue_add_tag(tag, type, p);
} else if (strcmp(command, "TITLE") == 0) {
if (parser->state == HEADER)
cue_add_tag(parser->tag, TAG_ALBUM, p);