WIP Conditional Visibility based on Player.(Remaining)Time
#1
Question 
Is it possible in a skin to do something like the following, and if so how?

<visible>( VideoPlayer.Content(musicvideos) + Player.Time > 0:05:00 + Player.Time < 0:10:00 ) || ( VideoPlayer.Content(musicvideos) + Player.RemainingTime > 0:05:00 + Player.RemainingTime < 0:10:00 ) )</visible>

Basically between 5 seconds and 10 seconds into a music video (and between 10 and 5 seconds remaining) it should pop the artist, album artwork and song title up on screen just like it does on the Music TV channels.

Already have the info box sorted but can only get it on screen for the duration of the video currently.
Reply
#2
Actually, a bit of a bodge which seams to work

<visible>VideoPlayer.Content(musicvideos) + [ StringCompare(Player.Time,00:05) | StringCompare(Player.Time,00:06) | StringCompare(Player.Time,00:07) | StringCompare(Player.Time,00:08) | StringCompare(Player.Time,00:09) | StringCompare(Player.Time,00:10) | StringCompare(Player.TimeRemaining,00:05) | StringCompare(Player.TimeRemaining,00:06) | StringCompare(Player.TimeRemaining,00:07) | StringCompare(Player.TimeRemaining,00:08) | StringCompare(Player.TimeRemaining,00:09) | StringCompare(Player.TimeRemaining,00:10) ] </visible>

unless there is a better way?
Reply
#3
Note that stringcompare is really taxing on the system Smile
If you have problems please read this before posting

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

"Well Im gonna download the code and look at it a bit but I'm certainly not a really good C/C++ programer but I'd help as much as I can, I mostly write in C#."
Reply
#4
After a bit of playing around I realised that a ten second display from about 10 - 19 seconds produced a better results (and also has the nifty side effect of hiding some of the TV channels ones Big Grin) so

<visible>
[ VideoPlayer.Content(musicvideos) +
[ SubString(Player.Time,00:1,Left)
| SubString(Player.TimeRemaining,00:1,Left)
]
] + !Player.ShowInfo
</visible>

achieves the effect I was after, not sure how taxing this is on the system....

Image

Currently only for my personal PVR-Eden (I know!) skin.

Really must start using Github if only to make my own media centres stay in sync with one another Big Grin, although slightly annoyingly now I have that looking nice I'll need to amend the rest of my customised skin to match now as it looks more dated (well considering I ripped the colours of my 10 year old DVB-T PVR what do I expect) - damn! Nod
Reply

Logout Mark Read Team Forum Stats Members Help
Conditional Visibility based on Player.(Remaining)Time0