player.py
import xbmc import xbmcgui import subprocess import osclass MyPlayer(xbmc.Player): def init (self): xbmc.Player.init(self)
def onPlayBackStarted(self): if xbmc.Player().isPlayingVideo(): os.system("~/.xbmc/scripts/scanset.sh &")
player=MyPlayer() VIDEO = 0
while(1): if xbmc.Player().isPlaying(): if xbmc.Player().isPlayingVideo(): VIDEO = 1 else: VIDEO = 0 xbmc.sleep(1000)
Place in ~/.xbmc/scripts/
. This also relies on scanset.sh
script down below.
#!/bin/bash sleep 3 echo "running aticonfig underscan-fix" aticonfig --set-dispattrib=dfp1,positionX:0 >/dev/null aticonfig --set-dispattrib=dfp1,positionY:0 >/dev/null aticonfig --set-dispattrib=dfp1,sizeX:1920 >/dev/null aticonfig --set-dispattrib=dfp1,sizeY:1080 >/dev/null sleep 1
Lämna en kommentar