UltraStar-Deluxe / USDX

The free and open source karaoke singing game UltraStar Deluxe, inspired by Sony SingStar™
https://usdx.eu
GNU General Public License v2.0
836 stars 160 forks source link

Playlist Problems by Songs with ä ö ü #152

Closed chimaira666 closed 1 year ago

chimaira666 commented 7 years ago

Hi! First: Thx for working at USDX 1.3. Its great and we love it! But i have one Problem: If i create a Playlist with Ultra Star Manager or Playlist Editor 1.3 there are 273 Songs in it, but when i start the game and select the Playlist there are only 243 Songs. I searched for the Problem and realize that every Song with "ä" "ö" "ü" or an ' (She ' s got.....) doesnt works. When I play Ultrastar without an Playlist, every Song works....also the Songs with "ä" "ü" "ö" and `. If I changed the "ä" to an "ae" there are no Problems. But it is very exhausting to change it all.

Sorry for my bad english!

redflash13 commented 6 years ago

I have the same issue and came as well to the point that song names containing special characters like german umlauts cause the issue.

The playlist is then automatically reduced by the tracks containing umlauts. That happens when I play team game based on playlist as well as when I load a playlist within the jukebox.

The playlist contains items like: Benjamin Blümchen : Intro Song Disney’s Die Eiskönigin : Lass jetzt los

which is to my understanding exactly representing the txt file name (e.G. "Disney’s Die Eiskönigin - Lass jetzt los.txt")

The log is saying that: ERROR: Could not find Song in Playlist: listen.upl, Benjamin Bl��en : Intro Song ERROR: Could not find Song in Playlist: listen.upl, Michel Tel󠺠Ai Se Eu Te Pego ERROR: Could not find Song in Playlist: listen.upl, Andreas Gabalier : I Sing A Liad F��i ERROR: Could not find Song in Playlist: listen.upl, B�� Onkelz : Wir ham'n noch lange nicht genug ERROR: Could not find Song in Playlist: listen.upl, Cheb Khaled : Aनa ERROR: Could not find Song in Playlist: listen.upl, Christina St��r : Millionen Lichter ERROR: Could not find Song in Playlist: listen.upl, Depeche Mode : Just Canմ Get Enough ERROR: Could not find Song in Playlist: listen.upl, Die Prinzen : Million岊ERROR: Could not find Song in Playlist: listen.upl, Die Ųzte : Zu Sp崊ERROR: Could not find Song in Playlist: listen.upl, Disneyӳ Die Eisk��in : Lass jetzt los ERROR: Could not find Song in Playlist: listen.upl, Echt : Du Tr娳t Keine Liebe In Dir ERROR: Could not find Song in Playlist: listen.upl, Elvis Presley : (YouӲe The) Devil in Disguise ERROR: Could not find Song in Playlist: listen.upl, Extrabreit : Flieger, Gr��Mir Die Sonne ERROR: Could not find Song in Playlist: listen.upl, Gummib峥nbande : Theme ERROR: Could not find Song in Playlist: listen.upl, Herbert Gr��eyer : Bochum (Live) ERROR: Could not find Song in Playlist: listen.upl, H��r : Viva Colonia (Da Simmer Dabei, Dat Is Prima!) ERROR: Could not find Song in Playlist: listen.upl, Jason Mraz : Iխ Yours ERROR: Could not find Song in Playlist: listen.upl, Joris : Herz �� Kopf ERROR: Could not find Song in Playlist: listen.upl, Kelly Family : I canմ help myself (Duett) ERROR: Could not find Song in Playlist: listen.upl, Lucilectric : M奣hen ERROR: Could not find Song in Playlist: listen.upl, Marius M��r Westernhagen : Willenlos ERROR: Could not find Song in Playlist: listen.upl, Mark Forster : Ch��ERROR: Could not find Song in Playlist: listen.upl, Mؠ: Final Song ERROR: Could not find Song in Playlist: listen.upl, M��ener Freiheit : Solang man Tr嶭e noch leben kann ERROR: Could not find Song in Playlist: listen.upl, Nickerbocker & Biene : Hallo Klaus (I w��r zruck) ERROR: Could not find Song in Playlist: listen.upl, Peter Maffay : ݢer sieben Br��n mu࠴ Du gehn ERROR: Could not find Song in Playlist: listen.upl, Phil Collins : You Canմ Hurry Love ERROR: Could not find Song in Playlist: listen.upl, Puff Daddy ft. Faith Evans : Iլl be missing you (Duett) ERROR: Could not find Song in Playlist: listen.upl, Rio Reiser : K�� Von Deutschland ERROR: Could not find Song in Playlist: listen.upl, R��nn's (Sch)erben : Ein Freund, Ein Guter Freund ERROR: Could not find Song in Playlist: listen.upl, STS : F��enfeld ERROR: Could not find Song in Playlist: listen.upl, Vater Abraham : Das Lied Der Schl��e (Duett)

so, very likely an encoding (iso/utf8) thing, I guess.

I'm on 9d190774c3bfe8da9615212fc514b241c22728f1 with Ubuntu 17.10

bohning commented 6 years ago

Hmm... unfortunately I cannot reproduce this on my Mac. I added several songs with Umlauts to a playlist and used it both for jukebox and party mode, both seems to be working correctly...

bildschirmfoto 2018-02-18 um 18 15 42 bildschirmfoto 2018-02-18 um 18 18 51
redflash13 commented 6 years ago

Ok, I see. I assume, you created the playlist using USDX itself. I just checked and if I'm doing it like that, it works too. The playlist I used (that had the umlauts issue) was created by Ultrastar Manager. I compared the resulting files of both ways and found out that the charset is different. Ultrastar Manager creates the file with ANSI/ISO encoding. USDX creates it as UTF8 file. I just did a quick check on windows: If I convert the Playlist File from Ultrastar Manager into UTF8 charset and use it within USDX, it works as well and all tracks are finally listed. So, I think USDX needs the playlist file in UTF8. For me it's ok to do that workaround for the files I created via Ultrastar Manager. I think a finding workaround for this in USDX is maybe not worth spending more energie in.

bohning commented 6 years ago

Ah, I see. Then UltraStar Manager seems to be needing a fix...

bohning commented 6 years ago

@redflash13, could you try with the latest commit e0ee66b3ddf1da8e2358ea8f390a040725b0b2a4? Remember to set the output encoding in 'Options' to UTF8.

redflash13 commented 6 years ago

Didn't recognized so far that there is an encoding option which I can set to utf-8 . But yes, it's there. Unfortunately I had no success in compiling Ultrastar Manager on Ubuntu and so used only the prepared build on my Win10 system. I try to compile again these days and will report. I suppose your fix is about taking in account the encoding setting for the playlist creation?!

bohning commented 6 years ago

Yes, encodings kinda are a difficult, especially since older version of UltraStar cannot handle UTF8 encoded files. Therefore, UltraStar Manager offers a default input encoding when reading files (current default is CP1252) and a default output encoding when writing files (also default CP1252). However, if CP1252 is not sufficient to encode the UltraStar text file (i.e. a special character not available in CP1252 is used), it uses UTF8 anyway. This maximizes backwards compatibility towards older version of UltraStar in that UTF8 is only used when necessary (and not by default). However, this default output encoding option was not used when writing the playlist files, it was hardcoded in Qt's toLocal8bit(). That's why you experienced issues with playlists by UltraStar Manager. Now with the latest commit, the selected default output encoding is also considered when writing the playlist files (however, without checking if the selected output encoding, in case of CP1252, is sufficient to encode all song artists and titles).

It used to compile on Ubuntu, but haven't checked in quite a while. Let me know how it went.

redflash13 commented 6 years ago

I managed to build Ultrastar Manager on Ubuntu finally (I left some updated instructions in the corresponding issue resport). Thanks a lot! The encoding stuff is solved. Works!

One very minor issue - don't know if it existed before... If I create a playlist with only one song (what makes not that much sense indeed) and try to use it in USDX Jukebox, the playlist doesn't load. In the error log it says, that the list is empty. As soon I add a second track, the list loads and both tracks are displayed. Encoding doesn't seem to play a role here.

bohning commented 6 years ago

Thanks for the feedback and happy to hear that the problem is solved. I will try to adjust the compilation instructions accordingly.

Regarding the problem with one song playlists, you could try the following: create the same playlist as well in USDX and compare the two resulting playlists to find out where they differ.

redflash13 commented 6 years ago

I checked and I can say it doesn't matter if I create the one-track playlist from Ultrastar Manager or within USDX directly. If it only contains one song, it is treated as empty and do not open up at all in USDX. But as I said, I don't think that this is really relevant - at least not for myself. I just came to this issue when checking the encoding stuff, as I simply added one track with umlauts and was a little frustrated, why it was not opening - and finally found out that I need to add at least two songs to make the playlist work.