GSP
Quick Navigator

Search Site

Unix VPS
A - Starter
B - Basic
C - Preferred
D - Commercial
MPS - Dedicated
Previous VPSs
* Sign Up! *

Support
Contact Us
Online Help
Handbooks
Domain Status
Man Pages

FAQ
Virtual Servers
Pricing
Billing
Technical

Network
Facilities
Connectivity
Topology Map

Miscellaneous
Server Agreement
Year 2038
Credits
 

USA Flag

 

 

Man Pages


Manual Reference Pages  -  MP3ID (1)

.ds Aq ’

NAME

mp3id - displays/edits id3 metadata (id3v1 and id3v2) in mp3 files

CONTENTS

SYNOPSIS

<B>mp3idB> <file.mp3>...

<B>mp3idB> <B>-B>[<B>12qtvxXhB>] <B>-cB>[<B>12bcCB>] <B>--B> <file.mp3>...

<B>mp3idB> <B>-AB> <artist> <B>-LB> <album> <B>-TB> <track> <B>-NB> <tracknum> <file.mp3>...

<B>mp3idB> <B>-GB> <genre> <B>-YB> <year> <B>-C <comment>B> <file.mp3>...

<B>mp3idB> <B>-apB> <file.jpg> <B>-rpB> <file.gif> <file.mp3>...

<B>mp3idB> <B>-pB>[<B>aNALTGYCpPfFB>] <B>-B>[<B>iIB>] <file.id3> <file.mp3>...

<B>mp3idB> <B>-dB>[<B>axbpzNALTGYCB>] <B>-dfB> <frame> <file.mp3>...

<B>mp3idB> <B>-eB>[<B>abpB>] <B>-efB> <frame> <file.mp3>...

<B>mp3idB> <B>-afB> <frame=data> <file.mp3>...

<B>mp3idB> <B>-afB> <frame:key1=val:key2=:key3=file(file.dat)> <file.mp3>...

<B>mp3idB> <B>-rfB> <frame=data> <file.mp3>...

<B>mp3idB> <B>-rfB> <frame:key1=val:key2=:key3=file(file.dat)> <file.mp3>...

<B>mp3idB> <B>-B>[<B>FfB>]

DESCRIPTION

mp3id is a command-line viewer and editor for id3 metadata in mp3 files. ID3v1 and ID3v2 are both supported, including access to extended ID3v2 metadata (pictures, lyrics, etc).

OPTIONS

Options are processed in order, so you could do eg:



 mp3id -v -A Artist -L Album -N 1 -T Foo foo.mp3 -N 2 -T Bar bar.mp3



Any options involving <B>NB>, <B>AB>, <B>LB>, <B>TB>, <B>GB>, <B>YB> or <B>CB> refer to track<B>NB>umber, <B>AB>rtist, a<B>LB>bum, <B>TB>itle, <B>GB>enre, <B>YB>ear or <B>CB>omment, respectively.

    General Options

<B>-1B>, <B>-2B> Show/modify ID3v1/ID3v2 tags only. By default it does both v1 and v2 tags.
<B>-qB> Quiet (no output). This is the default if any changes are being made.
<B>-tB> Terse output.
<B>-vB> Verbose output. This is the default if no options are supplied.
<B>-xB>, <B>-XB> View extended ID3v2 frames. <B>-XB> shows all ID3v2 frames as extended frames, including the basic ones (artist, album, etc).

If terse output (<B>-tB>) is selected, an attempt to summarise the extended frames as tersely as possible is made.

Extended frames are separated by <B>:B>. Simple extended frames are of the form framename=value.

Complex frames have a leading frame name, then a <B>:B>. The elements of the frame are enclosed in angle brackets (<B><>B>), separated by <B>:B>, and are displayed in the form elementname=value. The contents of binary frames (eg <B>_DataB>) is displayed as <data>

For instance, one simple and one complex frame would be displayed as eg:



 filename:ext:TSIZ=2000:APIC:<Picture Type=Other:_Data=<data>:MIME type=image/gif:
 filename:ext:Description=file.gif>



<B>-fB> Summarise available ID3v2 frame types.
<B>-FB> Show a detailed listing of available ID3v2 frame types.. This is several pages long, so you may wish to pipe it to a pager such as more(1).
<B>-hB> Shows a summary of command line options.
<B>--B> Treat remaining command line arguments as files to operate on, not options.

    Options to set basic metadata (artist, album, etc)

<B>-AB> artist Set Artist
<B>-LB> album Set aLbum
<B>-TB> track Set Trackname (song title)
<B>-NB> num Set trackNumber
<B>-GB> genre Set Genre
<B>-YB> year Set Year
<B>-CB> comment Set Comment

    Options to add/replace extended frames

To find out about available frame formats, see MP3::Tag::ID3v2-Data(1).

For a quick reference, use <B>mp3id -fB>.
<B>-apB> picfile Add picture.
<B>-rpB> picfile Replace picture. This will only replace the first APIC frame. If there is more than one APIC frame in the file, you will need to use the <B>-rfB> option, below.
<B>-afB> ’frame=data’ Add a simple frame. The data field can be empty.

If necessary, you should enclose the frame spec in single quotes (<B>’B>), especially if there are spaces or other characters that will be interpreted by the shell.

<B>-afB> ’frame:key1=value:key2=:key3=file(file.dat)’ Add a complex frame. The format is the <B>framenameB>, then a colon, then a list of <B>fieldname=valueB>, separated by colons. Field values can be left blank.

If you want the contents of a file included in the field (useful for binary <B>_DataB> fields), surround the filename with <B>B>file()<B>B>, e.g. _Data=file(picture.gif).

If necessary, you should enclose the frame spec in single quotes (<B>’B>), especially if there are spaces or other characters that will be interpreted by the shell.

If all this is too much hassle, try <B>-pfB> to enter frame details interactively, with prompting.

<B>-rfB> ’frame=data’ Replace a simple frame. The data field can be empty.
<B>-rfB> ’frame:key1=value:key2=:key3=file(file.dat)’ Replace or merge a complex frame.

The frame format is the same for adding frames (<B>-afB>, above).

If you omit any fields and the frame already exists, they will be taken from the existing version of the frame, otherwise it is an error.

    Importing and Exporting data

When writing files containing pictures or binary frame data, the filename is created from the basename of the file (ie with the extension (eg .mp3) lopped off), then a 2 digit number to distinguish multiple frames from the same file, then a guessed extension. If the frame contains a <B>MIME typeB> field, the extension will be guessed from the MIME type, if not it will default to .bin.

For instance, the contents of the _Data field of the first APIC frame with MIME type image/jpeg in foo.mp3 will be written to foo.01.jpg.
<B>-iB> file.id3, <B>-IB> file.id3 Import data dumped with the <B>-eaB> option (see below) from from file.id3.

<B>-IB> deletes the files you have imported, <B>includingB> any files included using the <B>B>file()<B>B> syntax.

The format for the <B>.id3B> export file is essentially the same as that displayed by <B>mp3id -vxB>, except that instead of using <B><data>B> as a placeholder for binary frame data (<B>_DataB> etc), it uses the <B>B>file()<B>B> notation to include data from a file. See the <B>-afB> option above for more details on the <B>B>file()<B>B> notation.

Not all fields need to be present in the import file, it will only alter those mentioned in it.

<B>-eaB> Dump (export) all id3 tag data to a file. The file will be have the same basename as the input file, but with an extension of .id3. For example, mp3id -ea foo.mp3 creates the file foo.id3.

This file can be edited then imported using the <B>-iB> option (see above).

<B>-ebB> Extract all binary data stored in frames.

Some frames (eg APIC, the frame for storing pictures) have elements that begin with <B>_B>, usually _Data. These elements are used for storing binary data (eg picture data). This extracts the content of the binary data element for each frame that contains one.

<B>-epB> Extract all pictures from file.
<B>-efB> frame Extract named ID3v2 frame.

    Deleting data

<B>-dfB> frames Delete named frame
<B>-daB> Delete id3 tags.
<B>-dxB> Delete extended frames.
<B>-dbB> Delete binary frames (frames containing elements starting with <B>_B>, eg <B>_DataB>, which contain binary data).
<B>-dpB> Delete pictures. This will delete all APIC ID3v2 frames. If you only want to delete the first picture, use:



 mp3id -df APIC file.mp3



<B>-dzB> Delete id3 tags that contain no data.
<B>-dNB> Delete trackNumber.
<B>-dAB> Delete Artist.
<B>-dLB> Delete aLbum
<B>-dTB> Delete Track name (song title).
<B>-dGB> Delete Genre.
<B>-dYB> Delete Year.
<B>-dCB> Delete Comment.

    Prompting

<B>-paB> Prompt for all items.
<B>-pNB> Prompt for track Number.
<B>-pAB> Prompt for Artist.
<B>-pLB> Prompt for aLbum.
<B>-pTB> Prompt for Track name (song title).
<B>-pGB> Prompt for Genre.
<B>-pYB> Prompt for Year.
<B>-pCB> Prompt for Comment.
<B>-ppB> Prompt for a picture to add.
<B>-pfB> Prompt for an arbitrary frame to add (simple or complex).

    Copying and Comparing frames

<B>-c1B> Copy data from ID3v1 tag to ID3v2 tag.
<B>-c2B> Copy data from ID3v2 tag to ID3v1 tag.
<B>-cbB> Copy data from best source. If an ID3v2 frame is set and non-empty, sets the ID3v1 tag data to the same value, otherwise attempts to do the reverse.
<B>-ccB>, <B>-cCB> Compares ID3v1 and ID3v2 data.

If <B>-ccB> is used, it allows for truncation caused by limited-length ID3v1 tags, and only compares up to the length of the ID3v1 tag data.

<B>-cCB> is stricter, and complains if there is any difference between the tags.

EXAMPLES

<B>mp3id file.mp3B> Display id3 tags in file.mp3 (same as <B>mp3id -v file.mp3B>).
<B>mp3id -vx file.mp3B> Display id3 tags in file.mp3, including extended id3v2 tags.
<B>mp3id -2 -da *.mp3B> Delete all id3v2 tags in all mp3 files in current directory.
<B>mp3id -A artist -T album -pN -pT *.mp3B> In all files in the current directory, set the artist to <B>artistB>, the album to <B>albumB>, then for each file prompt for the tracknumber and track title.
<B>mp3id -c2 file.mp3B> Copy id3v2 tag to id3v1 tag. Some data may be truncated due to limitations of the id3v1 format. See MP3::Tag::ID3v1(3) for details on the lengths of id3v1 tag data.
<B>mp3id -cc file.mp3B> Compare id3v1 and id3v2 tags and complain if they don’t match.
<B>mp3id -ea file.mp3B> Extract all tag data from file.mp3 and write it in human-readable/editable format to file.id3
<B>mp3id -i file.id3 file.mp3B> Import the tag data from file.id3 to file.mp3
<B>mp3id -af ’COMM:Language=ENG:short=:Text=Hello World’ file.mp3B> This is the long-winded way of adding a comment. This is equivalent to <B>mp3id -C Hello World file.mp3B>.
<B>mp3id -ap pic.jpg file.mp3B> Adds the picture pic.jpg to file.mp3. If there is already an APIC (picture) frame present, this will be added as (eg) APIC01.
<B>mp3id -af ’APIC:MIME type=image/jpeg:Picture type=Other:Description=A picture:_Data=file(pic.jpg)’ file.mp3B> This is the long-winded way of adding a picture. It is equivalent to the <B>-apB> example above (except that <B>-apB> sets the Description field to the filename of the picture).

Note the use of <B>B>file()<B>B> to import the picture data from pic.jpg.

<B>mp3id — -filename.mp3B> Views the tags in -filename. The <B>--B> option stops mp3id from treating <B>-filenameB> as an option.
<B>mp3id -fB> View a summary of available ID3v2 tags and their associated data elements.
<B>mp3id -F | lessB> View a detailed list of available ID3v2 tags and their associated data elements, piping through less(1) to show a page at a time.

ACKNOWLEDGEMENTS

This program makes heavy use of the perl module MP3::Tag(3), by Thomas Geffert.

BUGS

None known. Please report any found to ianb@nessie.mcc.ac.uk

SEE ALSO

mp3-archive-tools(1), MP3::Tag(3), MP3::Tag::ID3v2-Data(1), mp3lint(1)

AUTHOR

Ian Beckwith <ianb@nessie.mcc.ac.uk>

AVAILABILITY

mp3id is part of the mp3-archive-tools package.

The latest version can be found at:

http://nessie.mcc.ac.uk/~ianb/projects/mp3-archive-tools/

COPYRIGHT

Copyright 2003 Ian Beckwith <ianb@nessie.mcc.ac.uk>

This program is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation; either version 2 of the License, or (at your option) any later version.

This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details.

You should have received a copy of the GNU General Public License along with this program; if not, write to the Free Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.

Search for    or go to Top of page |  Section 1 |  Main Index


perl v5.20.3 MP3ID (1) 2003-12-12

Powered by GSP Visit the GSP FreeBSD Man Page Interface.
Output converted with manServer 1.07.