hello.
in my first plugin i learned how to write a picture plugin, in my second plugin (my own personal transmission mod) i vastly improved xpath.
in my third plugin i wanna learn how to write a video plugin. it will be for Euronews: http://www.euronews.net
people who know euronews heard probably of their famous “no comment” reports.
my plugin will have a Live Stream of the tv channel, which is (here)
and one will be able to browse the recent No Comment videos.
first i wanna learn how to play the live stream. as you can see it’s a swf file, and plex gives me a “compressed swf not supported” when i try and play it in the plugin.
the code:
# PMS plugin framework<br />
import re, string, datetime<br />
from PMS import *<br />
<br />
PLUGIN_PREFIX = "/video/euronews"<br />
<br />
RSS_FEED = "http://feeds.feedburner.com/Euronews-NoComment"<br />
EUROLIVE = "http://www.euronews.net/media/player_live_1_7.swf"<br />
eurothumb = "icon-default.png"<br />
NAMESPACES = {'itunes':"http://www.itunes.com/DTDs/Podcast-1.0.dtd", 'media':"http://search.yahoo.com/mrss/", 'feedburner':"http://rssnamespace.org/feedburner/ext/1.0"}<br />
ART = 'art-default.png'<br />
ICON = 'icon-default.png'<br />
####################################################################################################<br />
<br />
def Start():<br />
Plugin.AddPrefixHandler(PLUGIN_PREFIX, MainMenu, "euronews", "icon-default.jpg", "art-default.jpg")<br />
Plugin.AddViewGroup("InfoList", viewMode="InfoList", mediaType="videos")<br />
<br />
MediaContainer.art =R(ART)<br />
DirectoryItem.thumb =R(ICON)<br />
<br />
<br />
####################################################################################################<br />
def MainMenu():<br />
dir = MediaContainer()<br />
url= EUROLIVE<br />
dir.Append(Function(WebVideoItem(VideoPlayer, title="Watch Euronews live", subtitle=None, thumb=None), url=url))<br />
return dir<br />
#########################################<br />
def VideoPlayer(sender, url):<br />
dir = MediaContainer()<br />
Log(url)<br />
return Redirect(url)<br />
ignore the rssfeed & the namespaces for now, they are for the no comment bits later.
as i said, i get a "compressed SWF not supported" error. what should i do? the stream url is under EUROLIVE ([here](http://www.euronews.net/media/player_live_1_7.swf)).
thanks!!
