Kodi Community Forum
Popup Window with video stream - Printable Version

+- Kodi Community Forum (https://forum.kodi.tv)
+-- Forum: Support (https://forum.kodi.tv/forumdisplay.php?fid=33)
+--- Forum: Skins Support (https://forum.kodi.tv/forumdisplay.php?fid=67)
+---- Forum: Confluence (https://forum.kodi.tv/forumdisplay.php?fid=125)
+---- Thread: Popup Window with video stream (/showthread.php?tid=118847)



Popup Window with video stream - wphj1 - 2012-01-05

Hi there!

The guys from the windows forum "sent" me over with my problem
( http://forum.xbmc.org/showthread.php?tid=118714 )

I have a doorcamera, which delievers a rtsp stream.
I have managed to play it on xbmc via a *.strm file.

Target:
Push a button on my ps3 remote -> popup with camera stream appears
Push the button again -> popup goes away

Can someone help a noob with the right lines of code (and an idiotproof howto where to put it).

thanx in advance!


- mad-max - 2012-01-05

Create an addon with a default.py an insert the following code:

Code:
import xbmc
url = 'Hier kommt der Link zu deinem Stream'
xbmc.Player(xbmc.PLAYER_CORE_DVDPLAYER).play(url)

Then you can map a button to your remote that launches the addon...
Pressing Stop will stop the stream...

cheers,
mad-max


- wphj1 - 2012-01-05

Ok, i´ve created a new folder in my addon collection

http://www.phj.at/xbmc/folder.jpg

Then i made a new default file with the editor

http://www.phj.at/xbmc/default.jpg

Since i want the letter "N" (which i assigned to the "Playstation" Button) to start the stream i have edited the keymap in the main install directory

http://www.phj.at/xbmc/keymap.jpg

But NOTHING happens.

Do i have to activate the new addon somewhere?
(its not listed in the "addon" section of the system settings)


- mad-max - 2012-01-05

Because you did not create an Addon...
You simply copied the py file in there...
There is no Addon.xml...


- wphj1 - 2012-01-06

Now i created an addon.xml in the folder (adapted from another addon)

http://www.phj.at/xbmc/addon.jpg

Still nothing happens No


- mad-max - 2012-01-06

log-file?


- wphj1 - 2012-01-06

http://pastebin.com/U1j9W6sd


- mad-max - 2012-01-06

What about <p>RunScript(PathToDefault.py)</p>

Success?

mm


- wphj1 - 2012-01-06

http://pastebin.com/UGfc8xUU

If i push the playstation button theres an error message in the right bottom corner.
Then i realised i wrote "C:\\Users" instead of "c:\\benutzer", but when i change it, nothing happens.

I tried to change it to "RunAddon" with the path to the addon.xml -> nothing happens (not even the error message)