viewing encoding of id3v2 tags

Posted by: pim

viewing encoding of id3v2 tags - 23/06/2005 21:52

Does anyone know of a (small) tool that shows id3 tags
and can tell what encoding is used? (latin1 vs utf-16 vs utf-8),

Im struggling with mp3's which are (i think) encoded as utf-8,
but using iso8859-1 encoding headers.

It would even be nicer if such a tool could detect these
errors and/or be able to fix them.

linux/command line/open source preferred, but a Windows
GUI tool would be fine too.

Thanks,
Pim
Posted by: Mataglap

Re: viewing encoding of id3v2 tags - 23/06/2005 23:47

Case's tag, which looks like has disappererd, but you can get it bundled with a gui frontend http://www.tagger.boereck.de/download.html

It won't do exactly what you want, but it will rewrite tags from one format to another, and you could use that to get the right data into an ape tag and then reload the id3 tags from the ap3 tags.
Posted by: Defiler

Re: viewing encoding of id3v2 tags - 24/06/2005 10:43

Also, there's a Foobar2000 component (Windows) called foo_codepage, that will let you convert the encoding of your tags between any two codepages. Very handy.
Posted by: mlord

Re: viewing encoding of id3v2 tags - 24/06/2005 13:17

My free mp3tool utility (Linux) does not do this, but could be modifed to do it without too much pain, if anyone were interested in doing so.

Cheers
Posted by: pim

Re: viewing encoding of id3v2 tags - 24/06/2005 15:03

Ohhhh, can someone else ask? I don't dare, I just got two hijack kernels ...
Posted by: Defiler

Re: viewing encoding of id3v2 tags - 24/06/2005 16:18

I'd add this to mp3tool, since I really like reading mlord's code (not kidding), but sadly I have no experience with the various codepage APIs that might be available on Linux.
If someone pointed me to some docs, I'd be happy to give it a shot.
Posted by: mlord

Re: viewing encoding of id3v2 tags - 24/06/2005 16:23

Heh heh.. masochist!

The part I meant as "easy" would be simply retagging the headers (if possible) to solve this issue:
Quote:

Im struggling with mp3's which are (i think) encoded as utf-8,
but using iso8859-1 encoding headers.

.
Which may or may not solve the real problem (?). But no fancy codepage stuff should be needed to just change the charset encoding (whereever that's kept).

Or maybe I'm wrong.
Posted by: Defiler

Re: viewing encoding of id3v2 tags - 24/06/2005 18:57

Aah, I see what you mean. I was thinking of a command-line tool equivalent to the various Foobar2000 plugins that can actually convert arbitrary codepages into UTF-8 tags.

I modded Hijack the other day to display the time-alignment menu in inches, rather than centimeters. That exposed me to your code for the first time. Very clean. I was impressed.
Posted by: mlord

Re: viewing encoding of id3v2 tags - 25/06/2005 00:11

I actually cannot remember if I wrote that particular piece, or if somebody else did. The UI code in hijack.c *looks* like I wrote it, though!

As you get into that stuff, one thing to remember is that everything had to be done from scratch for the Hijack UI. The kernel originally contained no means for displaying text/data/anything on the display. No fonts, no way to draw fonts, etc..

I might do a few things differently if redoing it from scratch now, but for the most part it does the job and does it well enough.

Cheers
Posted by: Shonky

Re: viewing encoding of id3v2 tags - 26/06/2005 01:17

Quote:
I actually cannot remember if I wrote that particular piece, or if somebody else did. The UI code in hijack.c *looks* like I wrote it, though!


Technically you didn't but in reality you did Mark. I wrote the display function but I'm certain I would have heavily based it off one of the others you'd already written
Posted by: pim

Re: viewing encoding of id3v2 tags - 26/06/2005 23:14

Ideally, the tool would do the following:

1) output tags raw, and show encoding used
2) output tags converted to current locale (utf-8 for me) from encoding specified in encoding header
3) output tags converted to current locale (utf-8 for me) from encoding specified on command line
4) change encoding header without changing tag itself

Pim