Hex garbage in comment field

The place for "I can't figure out how to..." questions.
Post Reply
THEMike
User
Posts: 3
Joined: Sun Mar 19, 2006 7:14 pm

Hex garbage in comment field

Post by THEMike » Sun Mar 19, 2006 7:17 pm

Hi,

I'm using getid3 to implement tag reading for a podcasting plugin to the geeklog cms.

Working fine on my MP3's ripped with Easy CD DA on windows, but a beta user who has files ripped with iTunes on the Mac gets a load of hex in the comment field.

000002F1 0000035B 0000414B 000042F2 0002B71A 00036B4E 00007A58 00007B37
000333CB 00029658
00000000 00000210 00000A5C 0000000000C87714 00000000 00000000 00000000
00000000 00000000 00000000 00000000 00000000
12+C725498D3545B59F3929FBAA25C186EE+453905
I'm using getid3_lib::CopyTagsToComments($fileinfo); to merge all the tags into one location.

Any suggestions?

Allan Hansen
getID3() v2 developer
Posts: 445
Joined: Sun May 04, 2003 2:22 pm
Location: Holmegaard, Denmark

Post by Allan Hansen » Sun Mar 19, 2006 7:45 pm

Send us a demo file.

THEMike
User
Posts: 3
Joined: Sun Mar 19, 2006 7:14 pm

Post by THEMike » Mon Mar 20, 2006 7:34 am

link to demo emailed.

Allan Hansen
getID3() v2 developer
Posts: 445
Joined: Sun May 04, 2003 2:22 pm
Location: Holmegaard, Denmark

Post by Allan Hansen » Mon Mar 20, 2006 8:39 am

There is nothing wrong with the MP3 file and nothing wrong with the way getID3() parses it.

The files has the following three comment fields:

000002F1 0000035B 0000414B 000042F2 0002B71A 00036B4E 00007A58 00007B37 000333CB 00029658

00000000 00000210 00000A5C 0000000000C87714 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000

12+C725498D3545B59F3929FBAA25C186EE+453905

It also has encodedby = "iTunes v6.0.2"

Opening the file in foobar2000 reveals that the three comments are:

iTunNORM
iTunSMPB
iTun_CDDB_IDs

Maybe a future version of getID3() will have better iTunes support.

THEMike
User
Posts: 3
Joined: Sun Mar 19, 2006 7:14 pm

Post by THEMike » Mon Mar 20, 2006 8:54 am

OK, thanks.

Those tags weren't displayed in winamp so I was somewhat confused.

Cheers,

Mike

sblowes
User
Posts: 2
Joined: Fri Feb 23, 2007 9:59 pm
Location: Destin, FL

Was this ever resolved?

Post by sblowes » Fri Feb 23, 2007 10:01 pm

Is there a work-around for this? Or do I have to stop using iTunes to rip CDs?

sblowes
User
Posts: 2
Joined: Fri Feb 23, 2007 9:59 pm
Location: Destin, FL

Fixed it!

Post by sblowes » Fri Feb 23, 2007 10:09 pm

This may be posted elsewhere, but I couldn't find it so I'm posting for future strugglers.

I was getting the weird hex garbage from the comments field, so I ran this:

echo "<pre>";
print_r($ThisFileInfo);

and got the following excerpt:

[comments] => Array
(
[0] => 0000027E 000002C4 000029FA 00003299 000008E0 000008E0 00007E83 0000808C 000030FA 000030FA
[1] => 00000000 00000210 00000804 00000000002389EC 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000
[2] => 42+E93BD3FB31E0179DF02B9E69B8860B42+4611758
[3] => This is just a test track from the movie Napoleon Dynamite.

I was using ['html_comments']['comments]['0']. I switched to ['html_comments']['comments']['3'] and it works just fine.

Allan Hansen
getID3() v2 developer
Posts: 445
Joined: Sun May 04, 2003 2:22 pm
Location: Holmegaard, Denmark

Post by Allan Hansen » Fri Feb 23, 2007 10:51 pm

I am going to repeat what I wrote earlier:

There is nothing wrong with the MP3 file and nothing wrong with the way getID3() parses it.

And no we haven't added special code to handle special iTunes ID3v2 tags. If anyone wishes to "fix" this, please submit a patch.

Post Reply