external player and loops
#1
Hello.
I've a strange problem with external players.
I've an autoexec.py which load a playlist, and then play it infinitly.
If i use the stand player, everything is ok.
I changed the machine to a sooooooo bad cedarview one ( gma 3650), and to play films with a decent framerate, i've to use mplayer with -vo vaapi.
so i created playercorefactory.xml to handle video with mplayer.

Everything works fine, bu the loop in playlist don't work anymore.

What's wrong in my config ? any idea ?

many thanks, and please excuse my poor english!

autoexec.py:
Code:
# Autoplay videodirectory
import os, xbmc
xbmc.log( "starting autoexec")
# set path to dir you want to play
path="/home/xbmc/Videos"

dirList=os.listdir(path)

videoList = xbmc.PlayList(xbmc.PLAYLIST_VIDEO)
videoList.clear()

for fname in dirList:
    videoList.add(path + "/" + fname)

# shuffle playlist
videoList.shuffle()

# put playlist on repeat
xbmc.executebuiltin("xbmc.playercontrol(RepeatAll)")
xbmc.executebuiltin("xbmc.setvolume(00)")
# play playlist
xbmc.log( "autoexec: playing list")
xbmc.Player().play(videoList)
xbmc.executebuiltin("xbmc.PlayerControl(RepeatAll)")

the playercorefactory.xml

Code:
<playercorefactory>
<players>
   <player name="mplayer" type="ExternalPlayer" audio="false" video="true">
     <filename>/etc/mplay.sh</filename>
     <args>"{1}"</args>
     <hidexbmc>true</hidexbmc>
     <hideconsole>true</hideconsole>
     <warpcursor>topleft</warpcursor>
   </player>
</players>
<rules action="prepend">
   <rule filetypes="mkv" player="mplayer"/>
   <rule filetypes="avi" player="mplayer"/>
   <rule filetypes="mov" player="mplayer"/>
</rules>
</playercorefactory>

and the mplay.sh:

Code:
#!/bin/sh
#hide mouse
unclutter -idle 0.01 -root &

#play video with mplayer through vaapi with no sound
/usr/bin/mplayer "$1" -fs -vo vaapi -va vaapi -ao null

killall unclutter




Reply

Logout Mark Read Team Forum Stats Members Help
external player and loops0