Audio/video stream recording forums (http://stream-recorder.com/forum/index.php)
-   Tagging and renaming media files (http://stream-recorder.com/forum/forumdisplay.php?f=20)
-   -  

Correcting GBK,Big5,CP1251,... ID3v1 and ID3v2 tags by converting them to UTF (linux)

(http://stream-recorder.com/forum/showthread.php?t=5598)

Stream Recorder 01-26-2010 07:14 AM

Correcting GBK,Big5,CP1251,... ID3v1 and ID3v2 tags by converting them to UTF (linux)


 
ID3v1 or v2 don't really supports multi-byte encodings such as GBK or Big5.

Most existing files falsely pretend they are ISO-8859-1 encoded. This means the softwares handle 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.

Converting ID3 tags to Unicode is important not only for Linux players, but also for most portable players.



How to correct ID3v1 and ID3v2 tags with python-mutagen (mid3iconv) by converting them to Unicode

In the Terminal:

Install python-mutagen:
Code:

apt-get install python-mutagen
Go to your music folder
Code:

cd ~/Music/
Correcting Chinese ID3 tags
Correct Chinese Traditional BIG5 ID3v2 tags by converting them to Unicode and remove ID3v1 tags:
Code:

find -iname '*.mp3' -print0 | xargs -0 mid3iconv -e GBK --remove-v1
Correct Chinese Simpliefied GBK ID3v2 tags by converting them to Unicode and remove ID3v1 tags:
Code:

find -iname '*.mp3' -print0 | xargs -0 mid3iconv -e GBK --remove-v1

Correct Chinese Simpliefied GB2312 ID3v2 tags by converting them to Unicode and remove ID3v1 tags:
Code:

find -iname '*.mp3' -print0 | xargs -0 mid3iconv -e GB2312 --remove-v1
Correcting Russian ID3 tags
Correct ID3v2 Windows1251 tags by converting them to Unicode and remove ID3v1 tags:
Code:

find -iname '*.mp3' -print0 | xargs -0 mid3iconv -e CP1251 --remove-v1
Correct ID3v2 KOI8-R tags by converting them to Unicode and remove ID3v1 tags:
Code:

find -iname '*.mp3' -print0 | xargs -0 mid3iconv -e KOI8-R --remove-v1
Correcting Cyrrilic/Ukranian KOI8-U ID3 tags
Code:

find -iname '*.mp3' -print0 | xargs -0 mid3iconv -e KOI8-U --remove-v1
Correcting Korean EUC-KR ID3 tags
Code:

find -iname '*.mp3' -print0 | xargs -0 mid3iconv -e EUC-KR --remove-v1
Correcting Japanese EUC-JP ID3 tags
Code:

find -iname '*.mp3' -print0 | xargs -0 mid3iconv -e EUC-JP --remove-v1
Correcting Hebrew ID3 tags
Code:

find -iname '*.mp3' -print0 | xargs -0 mid3iconv -e CP1255 --remove-v1
Correcting Arabic ID3 tags
Code:

find -iname '*.mp3' -print0 | xargs -0 mid3iconv -e CP1256 --remove-v1
Correcting Greek ID3 tags
Code:

find -iname '*.mp3' -print0 | xargs -0 mid3iconv -e CP1253 --remove-v1
Correcting Turkish ID3 tags
Code:

find -iname '*.mp3' -print0 | xargs -0 mid3iconv -e CP1254 --remove-v1

Note: If you don't want to remove ID3v1 tags, do not use the "--remove-v1" parameter.

Stream Recorder 01-26-2010 07:33 AM

Re: Correcting GBK,Big5,CP1251,... ID3v1 and ID3v2 tags by converting them to UTF (li


 
How to correct ID3v1 and ID3v2 tags with EasyTag by converting them to Unicode
  1. Install EasyTag
    Code:

    apt-get install easytag
  2. Run EasyTag:
  3. Go to Applications -> Sound & Video -> EasyTag
  4. Select "Settings" -> "Preferences"
  5. Select the "ID3 Settings tab"
  6. Check "Automatically convert old ID3v2 versions"
  7. Write "ID3v2-tag" version: ID3v2.4, Charset: Unicode
  8. Write "ID3v1-tag", Charset: Unicode, Additional settings for iconv: "//Translit"
  9. Check the "Non-standard" and select your encoding (Chinese Traditional BIG5, Chinese Simpliefied GB2312, Japanese EUC-JP, Cyrrilic Windows 1251, Hebrew Windows 1255, Arabic Windows 1256, Greek Windows 1253, Cyrrilic/Ukranian KOI8-U, Korean EUC-KR, Turkish Windows 1254 ...)
  10. Hit the OK button to apply the changes.
  11. Open your music folder with EasyTag.
  12. Click "Save file(s)" to save changes.

Solving the "Operation not supported" problem
EasyTag wasn't able to save many tags for me showing the following error in its log:
Code:

Operation not supported
I was able to fix the problem by changing ID3v2.4 onto ID3v2.3 on step 7.


All times are GMT -6. The time now is 09:02 PM.