3 <link rel="stylesheet" type="text/css" href="trial.css">
\r
4 <title>Wikipedia P2P Video Streaming Test</title>
\r
5 <meta http-equiv="Content-Type" content="text/html; charset=utf-8">
\r
6 <style type="text/css">
\r
9 background-color: #FFFFFF;
\r
15 .style7 {color: #666666; font-style: italic;}
\r
22 <td><a href="http://www.p2p-next.org/"><img src="images/p2p-next_logo.png" border=0></a></td>
\r
23 <td class="header">Wikipedia P2P Video Streaming Test</td>
\r
24 <td><a href="http://www.p2p-next.org/"><img src="images/p2p-next_logo.png" border=0></a></td>
\r
28 <table class="container">
\r
29 <tr><td valign="top">
\r
34 <script type="text/javascript">
\r
36 if (navigator.appName == "Netscape")
\r
38 document.write('<tr>');
\r
39 document.write(' <td class="nr"><img src="images/01_120px.png" height="120"></td>');
\r
40 document.write(' <td><span class="title">Install SwarmTransport for Firefox</span>');
\r
41 document.write(' <span class="text">');
\r
42 document.write(' <ol type="a">');
\r
43 document.write(' <li> Open the <a href="http://www.tribler.org/trac/wiki/WikimediaCooperation">XPI for your platform</a> with Firefox');
\r
44 document.write(' <li> Restart Firefox, and revisit this page.');
\r
45 document.write(' </ol>');
\r
46 document.write(' For IE, visit this page using IE, or look in PageSource');
\r
47 document.write(' </span>');
\r
48 document.write(' </td>');
\r
49 document.write('</tr>');
\r
53 document.write('<tr>');
\r
54 document.write(' <td class="nr"><img src="images/01_120px.png" height="120"></td>');
\r
55 document.write(' <td><span class="title">Install SwarmPlugin for Internet Explorer</span>');
\r
56 document.write(' <span class="text">');
\r
57 document.write(' <ol type="a">');
\r
58 document.write(' <li> Run the <a href="http://www.tribler.org/trac/wiki/WikimediaCooperation">SwarmPlugin-Ogg installer</a> for IE');
\r
59 document.write(' <li> Revisit this page.');
\r
60 document.write(' </ol>');
\r
61 document.write(' For Firefox, visit this page using Firefox, or look in PageSource');
\r
62 document.write(' </span>');
\r
63 document.write(' </td>');
\r
64 document.write('</tr>');
\r
71 <td class="nr"><img src="images/02_120px.png" height="120" align="baseline"></td>
\r
72 <td><span class="title">Watch these Wikipedia videos via P2P</span>
\r
73 <span class="text"> </a>
\r
78 <!-- NextShare Tstream Lookup Service -->
\r
79 <script src="http://wikipedia.p2p-next.org/tlookup.js"></script>
\r
82 <!-- NextShare Common Javascript Code -->
\r
85 // Code for video tag error reporting
\r
86 function failed(e) {
\r
87 // video playback failed - show a message saying why
\r
88 switch (e.target.error.code) {
\r
89 case e.target.error.MEDIA_ERR_ABORTED:
\r
90 alert('You aborted the video playback.');
\r
92 case e.target.error.MEDIA_ERR_NETWORK:
\r
93 alert('A network error caused the video download to fail part-way.');
\r
95 case e.target.error.MEDIA_ERR_DECODE:
\r
96 alert('The video playback was aborted due to a corruption problem or because the video used features your browser did not support.');
\r
98 case e.target.error.MEDIA_ERR_SRC_NOT_SUPPORTED:
\r
99 alert('The video could not be loaded, either because the server or network failed or because the format is not supported.');
\r
102 alert('An unknown error occurred, code:'+e.target.error.code);
\r
107 // Code for IE8 SwarmPlugin
\r
108 function debugonclick(vlcobj)
\r
110 newwindow2=window.open('','name','height=400,width=640,scrollbars=1,resizable=1');
\r
111 var tmp = newwindow2.document;
\r
112 tmp.write('<html><head><title>popup</title>');
\r
113 tmp.write('</head><body><p>SwarmPlugin Debugging Popup</p>');
\r
115 tmp.write("Number of log messages "+vlcobj.log.messages.count);
\r
117 var iter = vlcobj.log.messages.iterator();
\r
118 while(iter.hasNext)
\r
121 tmp.write(msg.message+"<br>");
\r
124 tmp.write('</body></html>');
\r
130 function seek(vlcobj,percentage)
\r
132 vlcobj.input.position = percentage
\r
136 function writeplugin(vlcid,url)
\r
138 // 1. Write plugin HTML
\r
139 writeobject(vlcid,url);
\r
141 // 2. Write statusline HTML
\r
142 writestatusline(vlcid);
\r
144 // 3. Write controls HTML
\r
145 document.write('<p class="center">');
\r
146 writecontrols(vlcid);
\r
147 document.write('</p>');
\r
149 // 4. Periodically retrieve p2pstatus from plugin and show on page
\r
150 setInterval(function() { updatestatusline(vlcid); },100);
\r
153 function writeobject(vlcid,url)
\r
155 document.write('<object classid="clsid:1800B8AF-4E33-43C0-AFC7-894433C13538" ');
\r
156 //document.write('codebase="http://trial.p2p-next.org/download/SwarmPlugin_IE_1.0.5.cab"');
\r
157 document.write('width="320" height="240" id="'+vlcid+'" name="'+vlcid+'" events="True" target="">');
\r
158 document.write('<param name="Src" value="'+url+'" />');
\r
159 document.write('<param name="ShowDisplay" value="True" />');
\r
160 document.write('<param name="Loop" value="False" />');
\r
161 document.write('<param name="AutoPlay" value="True" />');
\r
162 document.write('<param name="Toolbar" value="True" />');
\r
163 document.write('</object>');
\r
166 function writestatusline(vlcid)
\r
168 document.write('<em><p id="'+vlcid+'p2pstatusline">Statusline</p></em>');
\r
171 function updatestatusline(vlcid)
\r
173 vlcobj = document.getElementById(vlcid);
\r
174 if (vlcobj.input != null)
\r
176 line = vlcobj.input.p2pstatus
\r
177 var p2pstatusline = document.getElementById(vlcid+"p2pstatusline");
\r
178 p2pstatusline.innerHTML = line
\r
182 function writecontrols(vlcid)
\r
184 vlcfullid = 'document.'+vlcid
\r
185 document.write('<input type=button value="Play" onClick="');
\r
186 document.write(vlcid+'.playlist.play();">');
\r
187 document.write('<input type=button value="Pause" onClick="');
\r
188 document.write(vlcid+'.playlist.togglePause();">');
\r
189 document.write('<input type=button value="Stop" onclick="');
\r
190 document.write(vlcid+'.playlist.stop();">');
\r
191 document.write('<input type=button value="Debug" onclick="debugonclick(');
\r
192 document.write(vlcid+');">');
\r
193 document.write('<input type=button value="Seek 25%" onclick="seek(');
\r
194 document.write(vlcid+',.25);">');
\r
195 document.write('<input type=button value="Seek 50%" onclick="seek(');
\r
196 document.write(vlcid+',.5);">');
\r
197 document.write('<input type=button value="Fullscreen" onClick="');
\r
198 document.write(vlcid+'.video.toggleFullscreen();">');
\r
201 function writep2pvideotag(videourl,posterurl)
\r
203 if (typeof swarmTransport != 'undefined')
\r
205 var tribeurl = "tribe://"+httpseed2tstream(videourl);
\r
206 document.write('<video controls="controls" onerror="failed(event)" preload="none" poster="'+posterurl+'">');
\r
207 document.write(' <source src="'+tribeurl+'"/>');
\r
208 document.write(' <!-- source src="'+videourl+'"/ -->');
\r
209 document.write('</video>');
\r
213 // No SwarmTransport installed
\r
214 document.write('NO SWARMTRANSPORT');
\r
215 document.write('<video controls="controls" onerror="failed(event)" poster="'+posterurl+'">');
\r
216 document.write(' <source src="'+videourl+'"/>');
\r
217 document.write('</video>');
\r
229 <!-- NextShare: Generate video code for FX or IE -->
\r
230 <script type="text/javascript">
\r
231 if (navigator.appName == "Netscape")
\r
234 // FX: use HTML5 video tag and NextShare SwarmTransport
\r
236 var posterurl = "http://upload.wikimedia.org/wikipedia/commons/thumb/c/c3/Welcome_to_globallives_2.0.ogv/seek%3D2-Welcome_to_globallives_2.0.ogv.jpg";
\r
237 var videourl = "http://upload.wikimedia.org/wikipedia/commons/c/c3/Welcome_to_globallives_2.0.ogv";
\r
238 writep2pvideotag(videourl,posterurl);
\r
243 // IE8: Fallback to NextShare SwarmPlugin
\r
245 writeplugin("vlc1","http://tracker1.p2p-next.org:6970/file?info_hash=%3E7%F1%7F%F9%C7%20%9D%BE%3D%96%10%1B%7BK%3Bs%9C%06%7E");
\r
251 <td><a href="http://globallives.org" rel="nofollow">GlobalLives.org</a> is a
\r
252 collaboratively built video library of human life experience that reshapes how
\r
253 we as both producers and viewers conceive of cultures, nations and people
\r
254 outside of our own communities. More
\r
255 <a href="http://globallives.org/about/" rel="nofollow">about global lives</a>.
\r
266 <!-- NextShare: Generate video code for FX or IE -->
\r
267 <script type="text/javascript">
\r
268 if (navigator.appName == "Netscape")
\r
271 // FX: use HTML5 video tag and NextShare SwarmTransport
\r
273 var posterurl = "http://upload.wikimedia.org/wikipedia/commons/thumb/b/bd/Elephants_Dream.ogg/seek%3D13-Elephants_Dream.ogg.jpg";
\r
274 var videourl = "http://upload.wikimedia.org/wikipedia/commons/b/bd/Elephants_Dream.ogg";
\r
275 writep2pvideotag(videourl,posterurl);
\r
280 // IE8: Fallback to NextShare SwarmPlugin
\r
282 writeplugin("vlc2","http://tracker1.p2p-next.org:6970/file?info_hash=%ED%5D%D9%81%5E%04%0A%12%07%CE/%40%7C0d%8F%7C%15%29%CB");
\r
287 <td><a href="http://www.elephantsdream.org/" rel="nofollow">Elephants Dream</a>
\r
288 is the world's first open movie, made entirely with open source graphics
\r
289 software such as <a href="http://en.wikipedia.org/wiki/Blender">Blender</a>,
\r
290 and with all production files freely available to use however you please,
\r
291 under a <a href="http://en.wikipedia.org/wiki/Creative_Commons">Creative
\r
292 Commons</a> license. This clip subtitles have been translated into many languages.
\r
301 <!-- NextShare: Generate video code for FX or IE -->
\r
302 <script type="text/javascript">
\r
303 if (navigator.appName == "Netscape")
\r
306 // FX: use HTML5 video tag and NextShare SwarmTransport
\r
308 var posterurl = "http://upload.wikimedia.org/wikipedia/commons/thumb/d/d6/Yochai_Benkler_-_On_Autonomy%2C_Control_and_Cultureal_Experience.ogg/mid-Yochai_Benkler_-_On_Autonomy%2C_Control_and_Cultureal_Experience.ogg.jpg";
\r
309 var videourl = "http://upload.wikimedia.org/wikipedia/commons/d/d6/Yochai_Benkler_-_On_Autonomy%2C_Control_and_Cultureal_Experience.ogg";
\r
310 writep2pvideotag(videourl,posterurl);
\r
315 // IE8: Fallback to NextShare SwarmPlugin
\r
317 writeplugin("vlc3","http://tracker1.p2p-next.org:6970/file?info_hash=%BCy%E5%B0%A8%0EK%E1i%00%82%94%7B%0FoH%3Dn%FAZ");
\r
322 <td><a href="http://en.wikipedia.org/wiki/Steal_This_Film">Steal This Film</a>
\r
323 is a film series documenting the movement against intellectual property produced
\r
324 by <a href="http://en.wikipedia.org/wiki/The_League_of_Noble_Peers">The League
\r
325 of Noble Peers</a> and released via the
\r
326 <a href="http://en.wikipedia.org/wiki/BitTorrent">BitTorrent</a> peer-to-peer
\r
332 <!-- End of 2-column table of videos -->
\r
342 <td class="nr"><img src="images/03_120px.png" height="120" lowsrc="images/03.png"></td>
\r
343 <td><p class="title">Statistics</p>
\r
344 <p class="text">Visit the <a href="http://tracker1.p2p-next.org:6970/">NextShare tracker</a> to see some statistics.</p>
\r
353 <table class="footer">
\r
355 <td> Home | <a href="legal.html">Legal</a> </td>
\r