3DTV Support - Play "3D" Movies in XBMC plus have GUI / OSD and subtitles just work?

  Thread Rating:
  • 4 Votes - 5 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Post Reply
giaur Offline
Fan
Posts: 466
Joined: Nov 2011
Reputation: 1
Post: #226
Any chance to add font scale support?

Subtitles are displayed as 50% stretched in 3d mode. They need to be squeezed by xbmc (best solution) or squeezed font sholud be used - I'm still looking for such squeezed font but without any success.
(This post was last modified: 2012-04-12 12:25 by giaur.)
find quote
bigbadrabbit Offline
Senior Member
Posts: 162
Joined: Sep 2008
Reputation: 0
Location: Austria
Post: #227
(2012-04-09 19:04)noeikujoo Wrote:  Hi!

I have used this 3D patch in XBMC 10.1 Dharma to get subtitles show corretcly in 3D -> https://gist.github.com/244af9c006c12e0a8664.

I just got this patch to work with XBMC 11.0 Eden. I also added 3D parallax adjustment for subtitles. The new patch can be downloaded from here.

Can someone please explain, how to apply this patch on a Mac? Thanks!

XBMC Gotham
OS X 10.9.3
Mac mini (late 2012) | i5 | 8GB RAM | SSD
find quote
giaur Offline
Fan
Posts: 466
Joined: Nov 2011
Reputation: 1
Post: #228
http://forum.xbmc.org/showthread.php?tid...pid1064285

I suspect you use binary packages for Mac, so you are unable to apply this patch. You need to compile xbmc from source.
find quote
noeikujoo Offline
Member
Posts: 51
Joined: Mar 2009
Reputation: 0
Location: Finland
Post: #229
(2012-04-12 12:23)giaur Wrote:  Any chance to add font scale support?

Subtitles are displayed as 50% stretched in 3d mode. They need to be squeezed by xbmc (best solution) or squeezed font sholud be used - I'm still looking for such squeezed font but without any success.
I just added some kind subtitle scaling support in 3d mode. Now subtitles are displayed 1.5 x times smaller in 3D. The patch link: 3D SUBTITLE PATCH. The patch is released ‘as is’ without warranty or guarantee of any kind.
find quote
giaur Offline
Fan
Posts: 466
Joined: Nov 2011
Reputation: 1
Post: #230
But what dimension is 1.5 x times smaller? It should be half x dimension and untouched y dimension in case side by side 3d mode, or untouched x dimension and half y dimension in case top-bottom 3d mode. Proportional scalling does not have much sense.
(This post was last modified: 2012-04-14 00:36 by giaur.)
find quote
noeikujoo Offline
Member
Posts: 51
Joined: Mar 2009
Reputation: 0
Location: Finland
Post: #231
(2012-04-14 00:34)giaur Wrote:  It should be half x dimension and untouched y dimension in case side by side 3d mode, or untouched x dimension and half y dimension in case top-bottom 3d mode.
I already tried to do this patch this way, but it seems that subtitles aspect ratio can't be changed. If y dimension is changed, subtitles font size changed. Changing x dimension doesn't affect subtitles font size:
Code:
float xx=720;
        float yy=576;
        if (g_settings.m_currentVideoSettings.m_Subtitle3DMode!=0)
    {  
           xx*=1.5f;
           yy*=1.5f;
        }
        RESOLUTION_INFO pal((int)xx, (int)yy, 0);
        CGUIFont *subFont = g_fontManager.LoadTTF("__subtitle__", fontPath, color[g_guiSettings.GetInt("subtitles.color")], 0, g_guiSettings.GetInt("subtitles.height"), g_guiSettings.GetInt("subtitles.style"), false, 1.0f, 1.0f, &pal, true);
        CGUIFont *borderFont = g_fontManager.LoadTTF("__subtitleborder__", fontPath, 0xFF000000, 0, g_guiSettings.GetInt("subtitles.height"), g_guiSettings.GetInt("subtitles.style"), true, 1.0f, 1.0f, &pal, true);
        if (!subFont || !borderFont)

I don't know how to scale subtitles font half x dimension and untouched y dimension or untouched x dimension and half y dimension.
(This post was last modified: 2012-04-14 08:54 by noeikujoo.)
find quote
giaur Offline
Fan
Posts: 466
Joined: Nov 2011
Reputation: 1
Post: #232
I think you should rather look into libfreetype api and maybe you can find something about non proportional scalling. Or, simply generate bitmap from text and try to scale bitmap.

But I think the problem is that xbmc handles fonts some other way (I didn't look into source code, so I don't know much about this, I believe this sholud be LoadTTF method and CGUIFont class) and you are forced to use this api instead of making some low-level font functions. So, it seems there is need to make changes in xbmc font rendering engine and this can be not so easy.
(This post was last modified: 2012-04-14 11:43 by giaur.)
find quote
Dam0 Offline
Fan
Posts: 440
Joined: Jun 2008
Reputation: 0
Post: #233
im hoping someone can help pls...

i have generated a playercorefactory.xml to select stereoscopic player as external player for SBS and half OU

i can varify that <rule filename=.*SBS.* etc works

and that

<rule filename=".*HalfOU.*" works.

however, for some reason i cant work out how to have both search criteria parsed?

Code:
<playercorefactory>
<players>
   <player name="SideBySide" type="ExternalPlayer" audio="false" video="true">
     <filename>C:\Program Files (x86)\Stereoscopic Player\StereoPlayer.exe</filename>
     <args>{1} -il:SideBySideLF -ihw -ol:OptAnaRC -fss -fp -nl -termend</args>
     <hidexbmc>false</hidexbmc>
     <hideconsole>false</hideconsole>
     <warpcursor>none</warpcursor>
   </player>
   <player name="OverUnder" type="ExternalPlayer" audio="false" video="true">
     <filename>C:\Program Files (x86)\Stereoscopic Player\StereoPlayer.exe</filename>
     <args>{1} -il:OverUnderLT -ihh -ol:OptAnaRC -fss -fp -nl -termend</args>
     <hidexbmc>false</hidexbmc>
     <hideconsole>false</hideconsole>
     <warpcursor>none</warpcursor>
   </player>
</players>
<rules action="prepend">
   <rule video="true" player="dvdplayer">
        <rule filename=".*HalfOU.*" player="OverUnder"/>
</rule>
</rules>
</playercorefactory>

this copy will use stereoscopic for UO, and internal for all other videos. as soon as i add <rule for SBS, only UO is set as default

running magro pvr full eden build

thanks in advance,
Dam0
find quote
febox-pootz Offline
Junior Member
Posts: 44
Joined: Sep 2008
Reputation: 0
Post: #234
noeikujoo, can you host your patch on another server or send it to me please? I'm getting "server not found" over here.

Thanks
find quote
noeikujoo Offline
Member
Posts: 51
Joined: Mar 2009
Reputation: 0
Location: Finland
Post: #235
(2012-04-14 18:09)febox-pootz Wrote:  noeikujoo, can you host your patch on another server or send it to me please? I'm getting "server not found" over here.

Thanks
Please try this link. And the same patch copied to another server.
(This post was last modified: 2012-04-14 22:43 by noeikujoo.)
find quote
febox-pootz Offline
Junior Member
Posts: 44
Joined: Sep 2008
Reputation: 0
Post: #236
It didn't work either.
find quote
noeikujoo Offline
Member
Posts: 51
Joined: Mar 2009
Reputation: 0
Location: Finland
Post: #237
Try another server? Just added new link to last post.
find quote
Dam0 Offline
Fan
Posts: 440
Joined: Jun 2008
Reputation: 0
Post: #238
Code:
<playercorefactory>
<players>
   <player name="SideBySide" type="ExternalPlayer" audio="false" video="true">
     <filename>C:\Program Files (x86)\Stereoscopic Player\StereoPlayer.exe</filename>
     <args>{1} -il:SideBySideLF -ihw -ol:OptAnaRC -fss -fp -nl -termend</args>
     <hidexbmc>false</hidexbmc>
     <hideconsole>false</hideconsole>
     <warpcursor>none</warpcursor>
   </player>
   <player name="OverUnder" type="ExternalPlayer" audio="false" video="true">
     <filename>C:\Program Files (x86)\Stereoscopic Player\StereoPlayer.exe</filename>
     <args>{1} -il:OverUnderLT -ihh -ol:OptAnaRC -fss -fp -nl -termend</args>
     <hidexbmc>false</hidexbmc>
     <hideconsole>false</hideconsole>
     <warpcursor>none</warpcursor>
   </player>
</players>
<rules action="prepend">
   <! SideBySide and OverUnder Selection !>
   <rule filename=".*HalfOU.*" player="OverUnder"/>
   <rule filename=".*SBS.*" player="SideBySide"/>
</rules>
</playercorefactory>

working code for sbs and OU using stereoscopic player

Dam0
find quote
noeikujoo Offline
Member
Posts: 51
Joined: Mar 2009
Reputation: 0
Location: Finland
Post: #239
(2012-04-14 11:26)giaur Wrote:  I think you should rather look into libfreetype api and maybe you can find something about non proportional scalling. Or, simply generate bitmap from text and try to scale bitmap.

But I think the problem is that xbmc handles fonts some other way (I didn't look into source code, so I don't know much about this, I believe this sholud be LoadTTF method and CGUIFont class) and you are forced to use this api instead of making some low-level font functions. So, it seems there is need to make changes in xbmc font rendering engine and this can be not so easy.
If non-proportional scaling is not easy thing to do then maybe we can use different and smaller fonts 3D subtitles? For example narrow font in "Side-by-Side" mode and wide font in "Top-Bottom" mode.

I am not so picky about the correct font scaling, and I'm already happy that I can see the subtitles in 3D. Maybe sometime in the future I find a solution how the font should be scaled correctly..
(This post was last modified: 2012-04-16 08:44 by noeikujoo.)
find quote
giaur Offline
Fan
Posts: 466
Joined: Nov 2011
Reputation: 1
Post: #240
Quote:If non-proportional scaling is not easy thing to do then maybe we can use different and smaller fonts 3D subtitles?
If you can find font with required aspect ratio....

I think bes solution is use .idx/sub for 3d subtitles. This is not ideal, because each displayed text is .png graphic and programs like 3d sutitler are able to set correct aspect ratio. But, of course built in 3d support for any font in xbmc will be very nice also. I belive this is possible to set aspect ratio for displayed text, but it needs some love level api.
find quote
Post Reply