.ass subtitles don't display the right way

macOS specific usage questions
spiderben25
New Cone
New Cone
Posts: 2
Joined: 05 Jul 2012 12:51
VLC version: 2.0.2
Operating System: OS X 10.8
Location: France

.ass subtitles don't display the right way

Postby spiderben25 » 05 Jul 2012 13:04

Hi,
I registered to this forum to ask for some help regarding .ass subtitles. I'm using VLC 2.0.2 on OS X 10.8 DP4, however, the problem showed up too when I was using VLC 1.x.x on Mac OS X 10.7.x.
This problem affects ONLY .ass subtitles. .srt subtitles are displayed just fine, without changing any settings !

So, here's a picture to show you what's happening :
Image

And here's a picture of the same video, same subtitle file, played by the latest version of MPlayerX, on the same computer :
Image

You can download the subtitle file here : http://www.datafilehost.com/download-511aae37.html

I also noticed that, on some others .ass files, instead of the weird boxes, when the subtitle line contains characters like é, ù or à, the font isn't the same compared to the subtitles lines who don't contain those characters. It's like an italic font, and there are blanks instead of the é,è,à.

Please, what can I do to play these files the right way ? I don't want to use .srt files because the position tags don't work, and I don't want to use MPlayerX because of your awesome subtitle scaling to the resolution of the screen and not the resolution of the video file.

nkoriyama
Cone that earned his stripes
Cone that earned his stripes
Posts: 338
Joined: 01 Sep 2011 20:50
VLC version: git
Operating System: Windows / Mac OS X
Location: Japan

Re: .ass subtitles don't display the right way

Postby nkoriyama » 06 Jul 2012 06:04

VLC uses freetype renderer module when playing SubRip(srt), and uses libass module when playing SSA/ASS.
Both module use fontconfig library. To be exact, from 2.0.2, freetype renderer module doesn't use fontconfig.

This issue happens because fontconfig library installaiton on VLC for Mac.
fontconfig library is used for choosing font from system, and by default on Mac, it searches from only /System/Library/Fonts.
I fixed this behavior (add font search path /Library/Fonts and ~/Library/Fonts) only for freetype but not for libass.

At the moment, you can do:
- Use the fonts in the /System/Library/Fonts.
- Copy the fonts to /System/Library/Fonts.
- Wait for fixing this issue:-)
How To Ask Questions The Smart Way http://www.catb.org/~esr/faqs/smart-questions.html
My hack for ISDB-T http://sdrv.ms/126weue

spiderben25
New Cone
New Cone
Posts: 2
Joined: 05 Jul 2012 12:51
VLC version: 2.0.2
Operating System: OS X 10.8
Location: France

Re: .ass subtitles don't display the right way

Postby spiderben25 » 06 Jul 2012 09:24

I opened my .ass file to know which font is used (it was Arial), so I made a copy of my Arial font (which was in my Library folder) to /System/Library/Fonts, like you said, and activated it using the fontbook.
And it works ! Thanks, you're a genius :-)

Jean-Baptiste Kempf
Site Administrator
Site Administrator
Posts: 37523
Joined: 22 Jul 2005 15:29
VLC version: 4.0.0-git
Operating System: Linux, Windows, Mac
Location: Cone, France
Contact:

Re: .ass subtitles don't display the right way

Postby Jean-Baptiste Kempf » 17 Jul 2012 19:18

He is :)
Jean-Baptiste Kempf
http://www.jbkempf.com/ - http://www.jbkempf.com/blog/category/Videolan
VLC media player developer, VideoLAN President and Sites administrator
If you want an answer to your question, just be specific and precise. Don't use Private Messages.

sikachu
New Cone
New Cone
Posts: 5
Joined: 20 Jul 2012 03:18

Re: .ass subtitles don't display the right way

Postby sikachu » 20 Jul 2012 04:13

I'm trying to fix this issue (not sure if you guys already have a ticket in trac or not) and seems like I found the fix for freetype here: http://git.videolan.org/?p=vlc.git;a=co ... h=b8fd5718

Now, I think I'm hitting a huge wall here because looking at `contrib/src/ass/rules.mak` and `contrib/src/fontconfig/rules.mak` and I'm not sure where I should fix it. If you can give me some guidance that'd be great.

Thank you.

sikachu
New Cone
New Cone
Posts: 5
Joined: 20 Jul 2012 03:18

Re: .ass subtitles don't display the right way

Postby sikachu » 20 Jul 2012 04:25

Never mind, that was the wrong commit. I found the right changes in http://git.videolan.org/?p=vlc.git;a=co ... h=b698c1c3 and I think I'll need to fix `modules/codec/libass.c`. Doing it now ...

sikachu
New Cone
New Cone
Posts: 5
Joined: 20 Jul 2012 03:18

Re: .ass subtitles don't display the right way

Postby sikachu » 20 Jul 2012 05:40

I can't get it to work after patching & recompile VLC. I think I'll give up for now. Can you tell me if I'm doing it right?

https://gist.github.com/3148494

fkuehne
Developer
Developer
Posts: 7266
Joined: 16 Mar 2004 19:37
VLC version: 0.4.6 - present
Operating System: Darwin
Location: Germany
Contact:

Re: .ass subtitles don't display the right way

Postby fkuehne » 20 Jul 2012 11:39

Hello thanks for your interest. Regrettably, this is approach is wrong. You're not supposed to use fontconfig anymore. Please have a look at my recent changes to the freetype module. It includes an automatic font look up mechanism which doesn't rely on libfontconfig. This is a cleaner approach since a cache is no longer needed.

Please tell me if you're interested in implementing this feature. If not it's no problem and I will see what I can do.
VideoLAN
Felix Paul Kühne
Medic. VLC developer for appleOS since before you were born.
Blog: https://www.feepk.net

sikachu
New Cone
New Cone
Posts: 5
Joined: 20 Jul 2012 03:18

Re: .ass subtitles don't display the right way

Postby sikachu » 20 Jul 2012 14:13

Please tell me if you're interested in implementing this feature. If not it's no problem and I will see what I can do.
Sure thing. Let me get a crack at it and see if I can port your changes from freetype somehow. >_>

nkoriyama
Cone that earned his stripes
Cone that earned his stripes
Posts: 338
Joined: 01 Sep 2011 20:50
VLC version: git
Operating System: Windows / Mac OS X
Location: Japan

Re: .ass subtitles don't display the right way

Postby nkoriyama » 20 Jul 2012 17:53

If we don't use fontconfig, we have to modify libass itself.
How To Ask Questions The Smart Way http://www.catb.org/~esr/faqs/smart-questions.html
My hack for ISDB-T http://sdrv.ms/126weue

sikachu
New Cone
New Cone
Posts: 5
Joined: 20 Jul 2012 03:18

Re: .ass subtitles don't display the right way

Postby sikachu » 20 Jul 2012 18:13

Yeah, I just realized that the hard way with @feepk on the IRC. We will try to figure out the best way to tackle this, as it's not as straightforward as I'd expect.

AlexSurin
New Cone
New Cone
Posts: 1
Joined: 13 Sep 2017 18:43

Re: .ass subtitles don't display the right way

Postby AlexSurin » 13 Sep 2017 18:50

At the moment, you can do:
- Use the fonts in the /System/Library/Fonts.
- Copy the fonts to /System/Library/Fonts.
- Wait for fixing this issue:-)
Hello! It's not easy anymore to put anything into /System/Library/Fonts as of 10.11 El Capitan (unless you turn off "System Intregrity Protection"). Looks like it's time to fix this thing. Or is there another way to use custom fonts with .ass subtitles?


Return to “VLC media player for macOS Troubleshooting”

Who is online

Users browsing this forum: No registered users and 43 guests