Find proper resolution
#16
(pike @ may 11 2005,15:40 Wrote:you want python to be aware that xbmc is in widescreen mode (like skins are) ?
exactly! at least that is what i want. i have been asking for this before. i want to be able to write code like this:

Quote:if mode='16:9': something...

you suggest parsing settings.xml to get the info. that is exactly the idea i've been looking for (although i was hoping i could call xbmc.getaspectratio() or something). thanks!

btw (i know it has been said before in this thread): width and height is exactly the same in 16:9 and 4:3 (it is the pixel aspect ratio that is different). try calling .getwidth() and .getheight() and you'll see for yourself.
Reply
#17
which setting.xml would you look at, theres one in pal and pal16x9, does it get copied somewhere?

i you manage to code a working 'getratio()' would you mind posting it here for us to share ?

cheers
Reply
#18
i was refering to /e/tdata/0face008/settings.xml. i'm not sure if or what the entry is though.

edit: the following is the section you need, but if resolution is set to auto, it may not work like you want.

resolution set to auto:
- <lookandfeel>
<charset>iso-8859-1</charset>
<clock12hour>true</clock12hour>
<enablerssfeeds>true</enablerssfeeds>
<font>default</font>
<guicentering />
<language>english</language>
<resolution>10</resolution>
<skin>project mayhem iii</skin>
<soundskin>skindefault</soundskin>
<swapmonthandday>false</swapmonthandday>
</lookandfeel>

when resolution set to ntsc 4:3:
<resolution>4</resolution>
For python coding questions first see http://mirrors.xbmc.org/docs/python-docs/
Reply

Logout Mark Read Team Forum Stats Members Help
Find proper resolution0