Solved how to playing media rmtp ? xbmcswift
#1
i'm using xbmcswift and i use this to play media
Code:
@plugin.route('/videos/')
def show_videos():
    items = [
        {'label': 'Calculus: Derivatives 1',
         'path': 'http://s3.amazonaws.com/KA-youtube-converted/ANyVpMS3HL4.mp4/ANyVpMS3HL4.mp4',
         'is_playable': True,
         }
    ]
    return plugin.finish(items)

but if I want to play youtube video or
Google Video url like
Code:
http://redirector.googlevideo.com/videoplayback?id=ab8a7eded4167aa30&itag=22&source=picasa&cmo=sensitive_content%3Dyes&ip=0.0.0.0&ipbits=0&expire=1386697391&sparams=id,itag,source,ip,ipbits,expire&signature=DD02AFD0018610D632FCCE94ECEE6C75A1DD42D7.5AF5D41DDB6ED8C24CA23D75B30AFCB9653A69AE&key=lh1

or rmtp media, how can I code it ?


AND I have an error when I try to use my add-on on rasPi My LOG file.
Code:
Error Type:
Error Contents: No module named xbmcswift2
Traceback (most recent call last):
File "/home/pi/.xbmc/addons/plugin.video.play/addon.py", line 22, in
from xbmcswift2 import Plugin, xbmcgui, xbmcaddon, xbmc
ImportError: No module named xbmcswift2

how can I fix it.

Thank you very much.
Reply
#2
help me please.
Reply
#3
Code:
from xbmcswift2 import Plugin, xbmcgui, xbmcaddon, xbmc
ImportError: No module named xbmcswift2

Given that you have imported XBMCSwift into your file and you are still getting a 'no module' found error, I would say that the problem you are having is that XBMCSwift has not been downloaded as a plugin on the XBMC client that you are using on your Rasberry Pi.

Make sure that you add a dependency to xbmcswift in your addon.xml file of your plugin like so:

Code:
<requires>
    ...
    <import addon="script.module.xbmcswift2" version="1.1.1" />
</requires>
Reply
#4
(2013-11-18, 03:38)hadynz Wrote:
Code:
from xbmcswift2 import Plugin, xbmcgui, xbmcaddon, xbmc
ImportError: No module named xbmcswift2

Given that you have imported XBMCSwift into your file and you are still getting a 'no module' found error, I would say that the problem you are having is that XBMCSwift has not been downloaded as a plugin on the XBMC client that you are using on your Rasberry Pi.

Make sure that you add a dependency to xbmcswift in your addon.xml file of your plugin like so:

Code:
<requires>
    ...
    <import addon="script.module.xbmcswift2" version="1.1.1" />
</requires>

I import this and still error
Code:
<import addon="script.module.xbmcswift2" version="2.4.0"/>
it error only on Rasberry Pi.

Thank you for help.
Reply

Logout Mark Read Team Forum Stats Members Help
how to playing media rmtp ? xbmcswift0