I'm trying using the xmbc library to my code on python, exactly y need the method xmbc.getCondVisibility('Player.HasMedia') to know that kodi is treaming a file.I write their imports but when I run the file, this say:
ImportError: No module named xbmc
The code:
the source:
https://forum.kodi.tv/showthread.php?tid=244430
http://kodi.wiki/view/List_of_boolean_conditions
If I edit line xbmc for kodi, I get this error:
I run this program in autoexec.py in userdata folder
ImportError: No module named xbmc
The code:
python:import os
import time
import signal
import sys
sys.path.append('/storage/.kodi/addons/virtual.rpi-tools/lib')
import subprocess
import socket
import xbmc
import xbmcgui
while True:
if xbmc.getCondVisibility('Player.HasMedia'):
setMovieScene()
sleep(3)
the source:
https://forum.kodi.tv/showthread.php?tid=244430
http://kodi.wiki/view/List_of_boolean_conditions
If I edit line xbmc for kodi, I get this error:
ERROR: AttributeError: 'module' object has no attribute 'getCondVisibility'python:
--import xbmc
--import xbmcgui
++ import kodi
I run this program in autoexec.py in userdata folder