Unicode Rewriter

Unicode Rewrite is a Java tool to convert ID3 tags in MP3 files from whatever machine encoding you have (GB2312/GBK for Chinese, etc) to Unicode. It converts both ID3v1 tags and ID3v2 tags to Unicode-encoded ID3v2 (v2.3 or v2.4)

Friday, August 04, 2006

Introduction

I have many MP3 files which were ripped under Traditional Chinese version of Windows. The ID3 tags are encoding using Big5. As I am also a Mac OS X user, I use iTunes to listen to the MP3 files. Unfortunately, iTunes is unable to understand Big5 encoding. It only accepts Unicode. After a little research in the Internet, I found that Chinese Rewriter can solve my problem. Chinese Rewriter can convert ID3 tags of every MP3 file from Big5 to Unicode. Only one at a time. There is no way to convert a batch of MP3 files with a few mouse clicks. As I do not have much knowledge in ID3 tags, I looked for other software to solve my problem, Incidentialy I found ID3iconv which works find for me. Since ID3iconv is a command line tool, it would make my life easier if there is a graphical user interface (GUI) for it. Unicode Rewriter is thus born.

Thursday, August 03, 2006

Features

Unicode Rewriter inherits features from ID3iconv. Below is adapted from the descriptions of ID3iconv.

Unicode Rewrite is a Java tool to convert ID3 tags in MP3 files from whatever machine encoding you have (GB2312/GBK for Chinese, etc) to Unicode. It converts both ID3v1 tags and ID3v2 tags to Unicode-encoded ID3v2 (v2.3 or v2.4). This is sometimes useful because,

  • ID3v1 or v2 don't really supports multi-byte encoding such as GBK or Big5. Most existing files falsely pretend they are ISO-8859-1 encoded. This means the software handles them in all kinds of weird ways.

  • Even if the user can force the encoding in some players, it is then impossible to display tags of several international languages at the same time if files are so encoded.

Caution

The tool updates MP3 files in place. So backup the files if you don't want to lose your precious music...

Unicode Rewriter takes all text fields of ID3 tags and assumes they are in a certain encoding. It then converts them to their Unicode equivalence as supported by ID3 v2.3. If originally the file has only v1 tag, a v2 tag will be added to the beginning of the file. If original the file has a non-Unicode v2 tag, it will be converted to Unicode format. The output encoding is Unicode little endian, which seems to be the most compatible.

Whatever the encoding is supported by the Java virtual machine, the encoding is supported. Please see Supported Encoding for the list of supported encoding.

After the conversion, the MP3 files can be handled by:

  • Rhythmbox 0.6.5. Gnome's default music player.

  • iTunes for Mac OS and Windows.

  • Windows explorer's file property dialog for MP3 files.



Wednesday, August 02, 2006

Installation

This software should work on any platforms which has a windowing system and Sun's Java 2 Runtime Environment Standard Edition, v. 1.4 or Java 2 Software Development Kit Standard Edition, v. 1.4. It may work with other Java environment besides Sun. You are welcome to report the version of the Java environment which works for you.

For Mac OS X and Windows users, double click "UnicodeRewriter-Installer.jar" will launch the installer. For Unix, this command will be useful:

java -jar UnicodeRewriter-Install.jar

Follow the instruction in the installer will lead to a successful installation of Unicode Rewriter.

Figure 1. Installation Screen

Installation Screen

Tuesday, August 01, 2006

Usage

There are a few methods to run this software. For Mac OS X and Windows users, simply double click the icon of UnicodeRewriter.jar to run the application. If this method does not work, you can edit UnicodeRewriter.sh (for Unix) or UnicodeRewriter .bat (for Windows) and run the scripts.

Unicode Rewrite can run in 2. The first is command line mode which behaves similarly to ID3iconv. The second is graphical mode.

Command Line Mode

If a parameter is passed to the application, Unicode Rewriter will run in command line mode. The syntax is:

UnicodeRewriter [-options] mp3-files


Options can be the following:



-e encoding Specify original tag encoding.
If not specified, system default encoding will be used.
-p Dry-run. Do not actually modify files
-v1 Force using v1 tag as source, even if v2 tag exists.
Default is using v2 tag.
-removev1 Remove v1 tag after processing the file
-q Quiet mode
-d Output debug info to stderr
-h Show this help information
-l Show the license information


Whatever the encoding is supported by the Java virtual machine, the encoding is supported. Please see Supported Encoding for the list of supported encoding.

MP3 files can be 1 or more MP3 files.

Graphical Mode

If there is no parameter is passed to the application, Unicode Rewriter will run in graphical mode. Please note that some information is shown at the console.

Figure 2. Graphical Mode

Graphical Mode

User must specify the MP3 files to convert. By pressing "Browse" button, user can choose MP3 files and add to the list. On the other hand, files can be dragged and dropped to the list. List can be removed by pressing "Remove" button. There is an option that folders can be handled recursively. By pressing "Convert" button, ID3 tags of MP3 files in the list are read using the encoding specified by the field "Source Encoding" and then converted to Unicode. When Unicode Rewriter is started, the system default encoding is used. However, additional encoding can be selected from "Encoding" menu. If the desired encoding cannot be found, user can type the encoding directly. Please see Supported Encoding for the list of supported encoding.