MusicBrainz Tag

From MusicBrainz Wiki
Revision as of 04:03, 28 October 2005 by Shepard (talk | contribs) (moving table to bottom (Imported from MoinMoin))
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)
Jump to navigationJump to search

MusicBrainz Metadata Tags (ID3 and Vorbis/FLAC Comment)

Status: Alert.png The information on this page is complete as of tunepimp CVS snapshot 2005-10-28.

Applications that read or write metadata tags from music files should follow one consistent specification for what MusicBrainz information is stored where and in what tag. That way all the work of the various tagger applications will contribute to a well connected and clean body of metadata. Any application that deals with music should be able to read the MusicBrainzIdentifiers from a music file in order to communicate unambiguously about the music it's working with.

ID3v2 Tag specifications

See ID3v2Tags for a list of proposed frames tagger applications could write. The following descriptions are summerized in a table below, for more information on how to use ID3v2 tags in your own applications read the specifications on http://www.id3.org/.

Note: for each text frame (TXXX) the encoding of the value strings can be defined in the frame header. ID3v2.3 supports UTF-16 and ISO-8859-1 encoded strings; ID3v2.4 has addional support for UTF-8 and UTF-16BE. MusicBrainz Identifiers must be encoded as ISO-8859-1 strings.

ID3v2 frames can be stored in any order in the MP3 file.

General Frames

The following frames are used for the regular information from the database: TPE1 for the main artist name, TALB for the album name, TIT2 for the track title, TRCK for the track number on the album.

TCMP is a nonstandard tag that defines a track as being part of a compilation (VA album) if set to 1 or part of a single artist album if set to 0. It is used by the iTunes music player software.

Artist Sortname

The artist sortname is stored in the TSOP frame for ID3v2.4 and in the experimental XSOP frame for ID3v2.3.

Release Date

ID3v2.3 is missing a standard frame for a detailed date. Therefore the experimental XDOR frame is used and the additional TORY that stores the year of release as a 4 digit number only is used.

In ID3v2.4 only the TDRL frame is used to store the complete release date in yyyy-MM-dd format.

Music Brainz Identifier

To store the MusicBrainzIdentifiers in an ID3v2 tag, you will need to use a UFID frame for the Track Id, and some user defined TXXX text frames for the artist, album, album artist and trm identifiers as well as the album status and type. Please note that for ease of use these ID3 frames are specified to use ISO 8859-1. However, the types of characters used to express these tags are the same in ISO 8895-1 and UTF-8, since UTF-8 is backward compatible with 7-bit ASCII.

MusicBrainz Track Identifier:

The MusicBrainz Track Id is the internal unique ID MusicBrainz defines for every object in its database. It is stored in the special UFID frame, that contains two parts: The Owner Identifier selects the namespace where the identifies is unique. For MusicBrainz it is be guaranteed that this ID is unique on the server; therefore the default owner identifier is http://musicbrainz.org. The second part is the UUID for the track as stored in the MusicBrainz database.

MusicBrainz Artist Identifier:

The MusicBrainz Artist Id is stored in a user defined TXXX text information frame, encoded as a 0x00 terminated ISO-8859-1 string. Its value is the artist UUID as stored in the MusicBrainz database.

MusicBrainz Album Identifier:

The MusicBrainz Album Id is stored in a user defined TXXX text information frame, encoded as a 0x00 terminated ISO-8859-1 string. Its value is the album UUID as stored in the MusicBrainz database.

MusicBrainz Album Artist Identifier:

The MusicBrainz Album Id is used to store an artist identifier for the album the track is on. At the moment, this is only used for Various Artists albums where the tracks have multiple different artists and the album itself is by the special artist Various Artists with UUID 89ad4ac3-39f7-470e-963a-56509c546377.

It is stored in a user defined TXXX text information frame, encoded as a 0x00 terminated ISO-8859-1 string. Its value is the artist UUID as stored in the MusicBrainz database.

MusicBrainz Album Status

This stores the status of the album the track is from, encoded as a 0x00 terminated ISO-8859-1 string. At the moment the possible values are: official, promotional, bootleg.

MusicBrainz Album Type

This type the status of the album the track is from, encoded as a 0x00 terminated ISO-8859-1 string. Possible values are: album, single, live e.a.

MusicBrainz TRM Identifier:

The MusicBrainz TRM Id is stored in a user defined TXXX text information frame, encoded as a 0x00 terminated ISO-8859-1 string. Its value is the track's TRM UUID as stored in the MusicBrainz database.

Vorbis/FLAC comment specifications

In contrast to the various possibilities of ID3 tagging, Vorbis and FLAC tags are stored in a unified way. All strings are encoded as UTF-8, tagged data is stored in the so called comment header, each key value pair is specified as a tripplet of the form: [length in bytes][key]=[value]. Strings are not terminated. For additional information see recommendations.

The different comment names and their equivalent ID3v3 frames can be found in the table below.

Overview

ID3v2.3 frame ID3v2.4 frame Value Description (TXXX only) Vorbis/FLAC comments
TPE1 TPE1 [artist name] ARTIST
TALB TALB [album title] ALBUM
TIT2 TIT2 [track title] TITLE
TRCK TRCK [track number] TRACKNUMBER
XSOP TSOP [artist sortname] MUSICBRAINZ_SORTNAME
TORY --- [release year] ---
XDOR TDRL [release date] DATE
TXXX TXXX [artist UUID] MusicBrainz Artist Id MUSICBRAINZ_ARTISTID
TXXX TXXX [album UUID] MusicBrainz Album Id MUSICBRAINZ_ALBUMID
TXXX TXXX [album artist UUID] MusicBrainz Album Artist Id MUSICBRAINZ_ALBUMARTISTID
TXXX TXXX [album status] MusicBrainz Album Status MUSICBRAINZ_ALBUMSTATUS
TXXX TXXX [album type] MusicBrainz Album Type MUSICBRAINZ_ALBUMTYPE
TXXX TXXX [TRM UUID] MusicBrainz TRM Id MUSICBRAINZ_TRMID
UFID UFID [track UUID] (OwnerID is: http://musicbrainz.org) MUSICBRAINZ_TRACKID
TCMP TCMP if VA then 1 else 0 ---
RELEASECOUNTRY

Authors: DonRedman, Shepard, FuchsOriginalVersion