Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Umlaut-Characters messed up #515

Closed
franco-bez opened this issue Jan 18, 2017 · 21 comments
Closed

Umlaut-Characters messed up #515

franco-bez opened this issue Jan 18, 2017 · 21 comments

Comments

@franco-bez
Copy link

I'm not sure when this bug got introduced, I just noticed it with the latest Version 1.0.47.

Having special Characters like Umlaut or accented Characters in the ID3 Tags gives me Chinese Glyphs on the display. See screenshot

Ciao,
Franco

screenshot_2017-01-18-20-25-12

@franco-bez
Copy link
Author

I forgot to mention some details
Android Version is 4.4
The Artists should read "Bläck Föss" and "Hans Söllner" and the last one is "Héroes Del Silencio"

@adrian-bl
Copy link
Member

This was most likely already the case in earlier versions: Android has a bad habit of guessing character encodings of MP3 files.

Could you send me one of these files to adrian@blinkenlights.ch ?

@franco-bez
Copy link
Author

franco-bez commented Jan 18, 2017 via email

@adrian-bl
Copy link
Member

Ok, thanks: i'll try to have a look at it in the next few days

@PanderMusubi
Copy link
Contributor

You could on a dekstop or laptop with e.g. Linux, copy the file to a new file and enter all the characters manually. Hopefully all will be Unicode UTF-8 and the problem will disappear in Vanilla Music.

@ghost
Copy link

ghost commented Jan 19, 2017

Some $(head -n1 $file | hexdump -C) for comparison:

Here's an UTF-8 example with everything displayed correctly in vanilla music...
music title: (Don’t Fear) The Reaper
vanilla music artist: Blue Öyster Cult

00000000  49 44 33 04 00 00 00 06  1f 76 54 49 54 32 00 00  |ID3......vTIT2..|
00000010  00 1b 00 00 03 28 44 6f  6e e2 80 99 74 20 46 65  |.....(Don...t Fe|
00000020  61 72 29 20 54 68 65 20  52 65 61 70 65 72 00 54  |ar) The Reaper.T|
00000030  50 45 31 00 00 00 13 00  00 03 42 6c 75 65 20 c3  |PE1.......Blue .|
00000040  96 79 73 74 65 72 20 43  75 6c 74 00 54 52 43 4b  |.yster Cult.TRCK|

Next, an UTF-16 example with working Umlauts / broken Apostroph...
vanilla music title: (Don’t Fear) The Reaper
vanilla music artist: Blue Öyster Cult

00000000  49 44 33 04 00 00 00 06  1f 76 54 49 54 32 00 00  |ID3......vTIT2..|
00000010  00 33 00 00 01 ff fe 28  00 44 00 6f 00 6e 00 19  |.3.....(.D.o.n..|
00000020  20 74 00 20 00 46 00 65  00 61 00 72 00 29 00 20  | t. .F.e.a.r.). |
00000030  00 54 00 68 00 65 00 20  00 52 00 65 00 61 00 70  |.T.h.e. .R.e.a.p|
00000040  00 65 00 72 00 00 00 54  50 45 31 00 00 00 25 00  |.e.r...TPE1...%.|
00000050  00 01 ff fe 42 00 6c 00  75 00 65 00 20 00 d6 00  |....B.l.u.e. ...|
00000060  79 00 73 00 74 00 65 00  72 00 20 00 43 00 75 00  |y.s.t.e.r. .C.u.|
00000070  6c 00 74 00 00 00 54 52  43 4b 00 00 00 05 00 00  |l.t...TRCK......|

And then there is ISO-8859-1...
vanilla music title: (Don?t Fear) The Reaper
vanilla music artist: Blue Öyster Cult

00000000  49 44 33 04 00 00 00 06  1f 76 54 49 54 32 00 00  |ID3......vTIT2..|
00000010  00 19 00 00 00 28 44 6f  6e 3f 74 20 46 65 61 72  |.....(Don?t Fear|
00000020  29 20 54 68 65 20 52 65  61 70 65 72 00 54 50 45  |) The Reaper.TPE|
00000030  31 00 00 00 12 00 00 00  42 6c 75 65 20 d6 79 73  |1.......Blue .ys|
00000040  74 65 72 20 43 75 6c 74  00 54 52 43 4b 00 00 00  |ter Cult.TRCK...|

@PanderMusubi
Copy link
Contributor

Off-topic but hilarious that you choose (Don’t Fear) The Reaper from Blue Öyster Cult 😆

@franco-bez
Copy link
Author

Hi Pander and yaymeh,
yes vanilla-music handles unicode correctly.

If I had the time to convert several thousand mp3 files I could actually work around the problem.

I tried the tool mid3iconv on an album and the resulting files are displayed correctly in vanilla-music.
Here's the howto:
http://ask.xmodulo.com/convert-mp3-id3-tag-encodings-linux.html

Ciao,
Franco

@adrian-bl
Copy link
Member

adrian-bl commented Jan 21, 2017

@franco-bez

Thanks for the sample file you sent my via e-mail: I tested it on 3 devices:

Nexus 5 with CM14: Works
Moto Defy, Stock Android 5: Works
HTC One X, AOSP 4.2 : Umlauts are 'okay' - but the album is padded with about 10 white spaces for some reason.

The fact that a newer Android version (4.4) works worse than 4.2 is pretty strange - are you running a stock version (if yes: which vendor) or a custom ROM?

Do the affected files show up correctly in some other (eg. stock) music player?

@franco-bez
Copy link
Author

It is an Acer Phone.
VLC shows the fules correctly.
See screenshots.
screenshot_2017-01-21-15-08-17
screenshot_2017-01-21-15-06-59
screenshot_2017-01-21-15-05-48

@adrian-bl
Copy link
Member

Vlc uses ffmpeg, we are using androids own library for mp3.

What does the stock music player show?

@franco-bez
Copy link
Author

You mean this Google Play Music?
Looks good.
screenshot_2017-01-21-23-22-05
screenshot_2017-01-21-23-21-53

@adrian-bl
Copy link
Member

adrian-bl commented Jan 29, 2017

Play music also does its own parsing. Try something like https://f-droid.org/wiki/page/org.gateshipone.odyssey

@franco-bez
Copy link
Author

franco-bez commented Jan 29, 2017 via email

@franco-bez
Copy link
Author

Now I tried Music "The Stock Audio Player"

https://f-droid.org/repository/browse/?fdfilter=music&fdid=com.android.music&fdpage=2

Looks good as well.

screenshot_2017-01-29-19-36-36
screenshot_2017-01-29-19-36-57

@adrian-bl
Copy link
Member

Thats very strange: It seems like your android release does some magic after reading the tags (but before putting them into the database).

I think the best way to fix this is to just not use androids own ID3v2 tag reader - and the latest nightly of Vanilla Music (See: http://vanillamusic.io/#nightly-builds - you can install it without uninstalling the normal release as the nightly is a 'different' app) has an option to do so:

Please try to enable Settings > Media Library > Always use builtin tagreader and wait until the rescan finished.

After this, your library should hopefully be OK.

@franco-bez
Copy link
Author

Hi Adrian,
I tried the nightly and it's party a success.
However with some of the files the situation remains unchanged.
screenshot_2017-02-04-13-59-18
screenshot_2017-02-04-13-59-37
screenshot_2017-02-04-14-00-10
screenshot_2017-02-04-14-00-58
screenshot_2017-02-04-14-01-28

This screenshot is "Music - The Stock Player"
screenshot_2017-02-04-14-11-41

@adrian-bl
Copy link
Member

ID3 encodings are a mess :-/

Can you send me the two shown files to adrian@blinkenlights.ch?

@adrian-bl
Copy link
Member

Thanks for the sample files: These files do not have ID3v2 tags: They are only tagged with ID3v1 which our internal tag reader does not support (So we fall back to Androids own, faulty tag reader)

I'd strongly recommend to simple re-tag these files with ID3v2 - ID3v1 should have died a long time ago.

But i opened a bug about the ID3v1 tags at https://github.com/adrian-bl/bastp/issues/4 (the repo of the tagreader) and going to close the bug here: Once the issue in 'Bastp' has been fixed, it will also automatically be fixed in Vanilla Music.

@franco-bez
Copy link
Author

I just tried the latest nightly build and indeed the bug is fixed :-)
I just had to enable "always use builtin tag reader".
Thanks a lot :-)
Ciao,
Franco

@adrian-bl
Copy link
Member

Great, thanks for the feedback!

Also note that 1.0.49 should show up on f-droid very soon

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants