PDA

View Full Version : UTF-8 Subtitle in Linux/Mac OS


dukevn
2009-01-11, 18:08
Hi all,

I have problem of displaying correctly the UTF-8 saved subtitle. No matter how I altered the settings, fonts etc, it always shows garbage characters. I read the forum and found the only way to show subtitle correctly is to use notepad in Windows and save it as ANSI file. My questions:

1. What is that ANSI file??? How can I do the same thing in Linux?

2. Why isnt there an option in Configuration - Video - Subtitle - Charset for UTF-8? Usually when I use other player (SMPlayer, VLC etc) I can set the charset of subtitle to UTF-8 to display correctly. Can I modify anywhere to have UTF-8 option shown up?

Thanks,

D.

dukevn
2009-01-13, 23:26
Anybody?

I read somewhere in the net, that ANSI uses ASCII which has just 256 characters, while unicode has 65,536 characters. That means if I re-encode a subtitle file, which was encoded in UTF-8 before, in ANSI, then there are certainly some missing characters.

Is there any solution for this?

Thanks,

D.

jmarshall
2009-01-13, 23:56
It should already detect that it's utf8 anyway. If it doesn't, please supply an example file, ideally by posting it on trac with details to reproduce.

dukevn
2009-01-14, 07:03
Sorry, I am not familiar with the Trac system, just created one but it does not look very nice :no:

http://xbmc.org/trac/ticket/5682

The attached log in the bug report was created when I tried to run Ocean 12 with a subtitle file of extension srt and was encoded in UTF-8 with TextMate in Mac OS. The text showed, but just like garbage no matter how I changed the settings, font or charset. The movie file is too big to attach, but with the subtitle file, one can reproduce error simply by using another movie, change the name of that movie to be exact like the subtitle file and run XBMC.

PS: I wanted to attach my log and srt files here as well, but can not find anywhere an option to attach. Am I missing something?

jmarshall
2009-01-14, 07:16
Thanks for the report.