Would switching to conditional includes improve efficiency?
#1
If I switched from visibility conditions to conditional includes wherever possible, would it improve efficiency or performance? I'm not particularly up on how XBMC handles controls, but would this give it fewer controls to worry about at any one time?
Reply
#2
Apparently conditional includes only get read on window create
Reply
#3
So if a certain window - MyVideoNav, let's say - features both TV and Movie controls that display according to conditional visibility, would there be any benefit in splitting those using conditional includes? So when you load the Movie library rather than TV, you save on the TV-related resources?
Reply
#4
I doubt it because the window doesn't get reloaded when switching between the 2 unless you access it directly

But to be honest I'm vague on the whole conditional includes thing I didn't even know they existed until last month
Reply
#5
Maybe jm can shed some light on it. I'm even more in the dark than you are, obviously, though I understand Aeon does have a rather extreme number of controls on the go at once.
Reply
#6
Conditional includes only get included when the window is loaded, yes. So if you include only controls you need then obviously that reduces the number that XBMC has to iterate through.

If the user cannot get to their movies while in tvshows, then that'll work just fine. If they can, then strange things may happen (basically your nice movie views won't be available, unless the window is reloaded first).

Note that another problem is that the include conditions must be able to be evaluated at window load - i.e. some conditions may not be correctly returned if the rest of the window environment (such as which dir they're in, what the content type is and so on) has yet to be setup. I'm not sure exactly when some of these are valid, so it's something to be careful about.

Certainly skin options will be set at that point (and won't change while you're in that screen, one presumes) so they can be used to switch stuff off.

Cheers,
Jonathan
Always read the XBMC online-manual, FAQ and search the forum before posting.
Do not e-mail XBMC-Team members directly asking for support. Read/follow the forum rules.
For troubleshooting and bug reporting please make sure you read this first.


Image
Reply
#7
jmarshall Wrote:If the user cannot get to their movies while in tvshows, then that'll work just fine. If they can, then strange things may happen (basically your nice movie views won't be available, unless the window is reloaded first).

Which explains the problem when using remotes to jump straight from Movies to TV Shows bypassing the Home menu.
Reply
#8
That problem actually grew from a much earlier use of skin settings to differentiate the two libraries, which itself stemmed from trouble I was having controlling the uppermost windows - the genre, title, etc. ones. They didn't seem to fit in with the whole Container.Content system. I was probably missing something, though.

Anyway, the conditional includes thing has compounded the issue past the point of being rectified now, which is absolutely fine by me as I don't see the whole remote-jumping thing as essential. In fact, I'd be surprised if more than 1 per cent of XBMC users used it. If I could, I'd shut that functionality out of Aeon entirely to stop people running into problems.
Reply
#9
djh_ Wrote:They didn't seem to fit in with the whole Container.Content system.

They do now! kinda anyway, you can read all about it here:

trac

I never actually got round to trying it out myself though.
Reply
#10
jmarshall Wrote:some conditions may not be correctly returned if the rest of the window environment (such as which dir they're in, what the content type is and so on) has yet to be setup. I'm not sure exactly when some of these are valid, so it's something to be careful about.

Cheers,
Jonathan
Sorry to be a thread necromancer but is there a way, other than trial and error, to find what is valid at window load? Is there a section of source code I could browse through to find out?
Reply
#11
wannabegt4 Wrote:Sorry to be a thread necromancer but is there a way, other than trial and error, to find what is valid at window load? Is there a section of source code I could browse through to find out?

SkinHasSetting and WindowIsActive should be safe to use.
My skins:

Amber
Quartz

Reply

Logout Mark Read Team Forum Stats Members Help
Would switching to conditional includes improve efficiency?0