Wired character encoding

  • rrr

    rrr - 2008-01-28

    I have some MP3 files with Cyrillic labels and the following lines in the config file:

    <import hidden-files="no">


    All files are processed without any complains but when I browse them they are printed quite differently under the "PC Directory" and the "Audio" directories.
    The files under "PC Directory" are rendered with the proper names and labels.
    The same files under "Audio" are totally unreadable (something like ".09:> .J;30@89>"). When opened in the editor all the fields including the filename are unreadable and so are the corresponding records in the MySQL DB (they seemed to me like utf-16 encoded).

    Does anybody have an idea what is going one and what should I correct in my config file?

    Thanks in advance,

    • Jin

      Jin - 2008-01-28

      The problem is that your id3 tags are not encoded in UTF-8 (that's what you specified as the <metadata-charset>, it is common for id3tags to be encoded in ISO-8859-1, so you may want to try that.

      Otherwise find out what encoding your tags are in. PC Directory titles are derived from the filenames, and your filenames are obviously encoded in UTF-8, that's why the titles in PC Directory are displayed correctly.

      Another solution might be trying to switch to taglib, it seems to handle id3 encodings better (but you'd have to recompile MediaTomb with taglib support)

      Kind regards,

    • rrr

      rrr - 2008-01-31

      Thanks Jin,

      I'm almost certain that the tags are UTF-8 encoded since their chars are two bytes long and MP3::Info reads them correctly when used with use_mp3_utf8. Unfortunately for some reason, unknown to me, id3lib did not recognize them properly.

      Once I switched to taglib, everything was properly recognized!

      BW even though the binary I've compiled was build with mysql only, mediatomb was complaining about missing /server/storage/database-file. I have to add it in the config.xml, which makes no sense whatsoever, in order to start it...

      Thanks for the advice,

    • Jin

      Jin - 2008-01-31

      Regarding the database file error - it's a known bug that is fixed in the current SVN code.

      Kind regards,


Log in to post a comment.

Get latest updates about Open Source Projects, Conferences and News.

Sign up for the SourceForge newsletter:

JavaScript is required for this form.

No, thanks