Skip to content

Commit 43e6648

Browse files
committed
播放RTMP直播流,同时显示直播流的详细信息
1 parent e5b6f03 commit 43e6648

11 files changed

+692
-1
lines changed

(Push)Play-RTMP-Info/GrindPlayer.swf

990 KB
Binary file not shown.

(Push)Play-RTMP-Info/Main.swf

93.8 KB
Binary file not shown.
+91
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,91 @@
1+
/*******************************************************************************
2+
*
3+
* ParsedQueryString version 1.0
4+
* Copyright 2007, Jeff Mott <[email protected]>. All rights reserved.
5+
*
6+
* Redistribution and use in source and binary forms with or without
7+
* modification are permitted provided that the above copyright notice,
8+
* this condition, and the following disclaimer are retained.
9+
*
10+
* THIS SOFTWARE IS PROVIDED AS IS, AND ANY EXPRESS OR IMPLIED WARRANTIES,
11+
* INCLUDING BUT NOT LIMITED TO THE IMPLIED WARRANTIES OF MERCHANTABILITY AND
12+
* FITNESS FOR A PARTICULAR PURPOSE, ARE DISCLAIMED. IN NO EVENT SHALL THE
13+
* COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT,
14+
* INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING BUT NOT
15+
* LIMITED TO PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR
16+
* PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF
17+
* LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING
18+
* NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE,
19+
* EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
20+
*
21+
******************************************************************************/
22+
23+
function ParsedQueryString() {
24+
this._init();
25+
}
26+
27+
ParsedQueryString.version = '1.0';
28+
29+
ParsedQueryString.prototype =
30+
{
31+
_init:
32+
function ()
33+
{
34+
this._parameters = {};
35+
36+
if (location.search.length <= 1)
37+
return;
38+
var pairs = location.search.substr(1).split(/[&;]/);
39+
for (var i = 0; i < pairs.length; i++)
40+
{
41+
var pair = pairs[i].split(/=/);
42+
var name = this._decodeURL(pair[0]);
43+
if (Boolean(pair[1]))
44+
{
45+
var value = this._decodeURL(pair[1]);
46+
if (Boolean(this._parameters[name]))
47+
this._parameters[name].push(value);
48+
else
49+
this._parameters[name] = [value];
50+
}
51+
}
52+
},
53+
54+
_decodeURL:
55+
function (url) {
56+
return decodeURIComponent(url.replace(/\+/g, " "));
57+
},
58+
59+
param:
60+
function (name)
61+
{
62+
if (Boolean(this._parameters[name]))
63+
return this._parameters[name][0];
64+
else
65+
return "";
66+
},
67+
68+
params:
69+
function (name)
70+
{
71+
if (Boolean(name))
72+
{
73+
if (Boolean(this._parameters[name]))
74+
{
75+
var values = [];
76+
for (var i = 0; i < this._parameters[name].length; i++)
77+
values.push(this._parameters[name][i]);
78+
return values;
79+
}
80+
else
81+
return [];
82+
}
83+
else
84+
{
85+
var names = [];
86+
for (var name in this._parameters)
87+
names.push(name);
88+
return names;
89+
}
90+
}
91+
};

(Push)Play-RTMP-Info/crossdomain.xml

+3
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,3 @@
1+
<cross-domain-policy>
2+
<allow-access-from domain="*"/>
3+
</cross-domain-policy>

(Push)Play-RTMP-Info/flashlsOSMF.swf

87.7 KB
Binary file not shown.

(Push)Play-RTMP-Info/index.html

+111
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,111 @@
1+
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
2+
<!-- saved from url=(0014)about:internet -->
3+
<html xmlns="http://www.w3.org/1999/xhtml" lang="en" xml:lang="en">
4+
<!--
5+
Smart developers always View Source.
6+
7+
This application was built using Adobe Flex, an open source framework
8+
for building rich Internet applications that get delivered via the
9+
Flash Player or to desktops via Adobe AIR.
10+
11+
Learn more about Flex at http://flex.org
12+
// -->
13+
<head>
14+
<title>NodeMedia Rtmp 直播测试器</title>
15+
<meta name="google" value="notranslate" />
16+
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
17+
<!-- Include CSS to eliminate any default margins/padding and set the height of the html element and
18+
the body element to 100%, because Firefox, or any Gecko based browser, interprets percentage as
19+
the percentage of the height of its parent container, which has to be set explicitly. Fix for
20+
Firefox 3.6 focus border issues. Initially, don't display flashContent div so it won't show
21+
if JavaScript disabled.
22+
-->
23+
<style type="text/css" media="screen">
24+
html, body { height:100%; }
25+
body { margin:0; padding:0; overflow:auto; text-align:center;
26+
background-color: #ffffff; }
27+
object:focus { outline:none; }
28+
#flashContent { display:none; }
29+
</style>
30+
31+
<!-- Enable Browser History by replacing useBrowserHistory tokens with two hyphens -->
32+
<!-- BEGIN Browser History required section -->
33+
<link rel="stylesheet" type="text/css" href="history/history.css" />
34+
<script type="text/javascript" src="history/history.js"></script>
35+
<!-- END Browser History required section -->
36+
37+
<script type="text/javascript" src="swfobject.js"></script>
38+
<script type="text/javascript">
39+
// For version detection, set to min. required Flash Player version, or 0 (or 0.0.0), for no version detection.
40+
var swfVersionStr = "11.1.0";
41+
// To use express install, set to playerProductInstall.swf, otherwise the empty string.
42+
var xiSwfUrlStr = "playerProductInstall.swf";
43+
var flashvars = {};
44+
var params = {};
45+
params.quality = "high";
46+
params.bgcolor = "#ffffff";
47+
params.allowscriptaccess = "sameDomain";
48+
params.allowfullscreen = "true";
49+
var attributes = {};
50+
attributes.id = "Main";
51+
attributes.name = "Main";
52+
attributes.align = "middle";
53+
swfobject.embedSWF(
54+
"Main.swf", "flashContent",
55+
"1300", "600",
56+
swfVersionStr, xiSwfUrlStr,
57+
flashvars, params, attributes);
58+
// JavaScript enabled so display the flashContent div in case it is not replaced with a swf object.
59+
swfobject.createCSS("#flashContent", "display:block;text-align:left;");
60+
</script>
61+
</head>
62+
<body>
63+
<!-- SWFObject's dynamic embed method replaces this alternative HTML content with Flash content when enough
64+
JavaScript and Flash plug-in support is available. The div is initially hidden so that it doesn't show
65+
when JavaScript is disabled.
66+
-->
67+
<div>
68+
<a href="/vod.html">RTMP 点播测试器</a> <a href="/stat" target="_blank">RTMP 流监控</a> <a href="http://www.nodemedia.cn/" target="_blank">获取Android & iOS RTMP 开发SDK</a>
69+
</div>
70+
<div id="flashContent">
71+
<p>
72+
To view this page ensure that Adobe Flash Player version
73+
11.1.0 or greater is installed.
74+
</p>
75+
<script type="text/javascript">
76+
var pageHost = ((document.location.protocol == "https:") ? "https://" : "http://");
77+
document.write("<a href='http://www.adobe.com/go/getflashplayer'><img src='"
78+
+ pageHost + "www.adobe.com/images/shared/download_buttons/get_flash_player.gif' alt='Get Adobe Flash player' /></a>" );
79+
</script>
80+
</div>
81+
82+
<noscript>
83+
<object classid="clsid:D27CDB6E-AE6D-11cf-96B8-444553540000" width="100%" height="100%" id="Main">
84+
<param name="movie" value="Main.swf" />
85+
<param name="quality" value="high" />
86+
<param name="bgcolor" value="#ffffff" />
87+
<param name="allowScriptAccess" value="sameDomain" />
88+
<param name="allowFullScreen" value="true" />
89+
<!--[if !IE]>-->
90+
<object type="application/x-shockwave-flash" data="Main.swf" width="100%" height="100%">
91+
<param name="quality" value="high" />
92+
<param name="bgcolor" value="#ffffff" />
93+
<param name="allowScriptAccess" value="sameDomain" />
94+
<param name="allowFullScreen" value="true" />
95+
<!--<![endif]-->
96+
<!--[if gte IE 6]>-->
97+
<p>
98+
Either scripts and active content are not permitted to run or Adobe Flash Player version
99+
11.1.0 or greater is not installed.
100+
</p>
101+
<!--<![endif]-->
102+
<a href="http://www.adobe.com/go/getflashplayer">
103+
<img src="http://www.adobe.com/images/shared/download_buttons/get_flash_player.gif" alt="Get Adobe Flash Player" />
104+
</a>
105+
<!--[if !IE]>-->
106+
</object>
107+
<!--<![endif]-->
108+
</object>
109+
</noscript>
110+
</body>
111+
</html>

0 commit comments

Comments
 (0)