[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Gnash-commit] /srv/bzr/gnash/rtmp r10083: support using flashVars to se
From: |
rob |
Subject: |
[Gnash-commit] /srv/bzr/gnash/rtmp r10083: support using flashVars to set hostname and ports. |
Date: |
Tue, 31 Mar 2009 15:36:56 -0600 |
User-agent: |
Bazaar (1.5) |
------------------------------------------------------------
revno: 10083
committer: address@hidden
branch nick: rtmp
timestamp: Tue 2009-03-31 15:36:56 -0600
message:
support using flashVars to set hostname and ports.
modified:
testsuite/misc-ming.all/red5test.as
=== modified file 'testsuite/misc-ming.all/red5test.as'
--- a/testsuite/misc-ming.all/red5test.as 2009-03-28 18:35:12 +0000
+++ b/testsuite/misc-ming.all/red5test.as 2009-03-31 21:36:56 +0000
@@ -33,8 +33,20 @@
play();
};
-if ( ! _root.hasOwnProperty('host') ) {
- host="localhost";
+// -P FlashVars='hostname=localhost,rtmptport5080=rtmpport=1935'
+if (hostname == undefined) {
+ hostname="localhost";
+ note("No hostname specified, defaulting to "+hostname);
+}
+
+if (rtmptport == undefined) {
+ rtmptport = 5080;
+ note("No RTMPT port specified, defaulting to "+rtmptport);
+}
+
+if (rtmpport == undefined) {
+ rtmpport = 1935;
+ note("No RTMP port specified, defaulting to "+rtmpport);
}
nc = new NetConnection;
@@ -42,7 +54,7 @@
nc.onStatus = function()
{
this.statuses.push(arguments);
- note('NetConnection.onStatus called with args: '+dumpObject(arguments));
+ note('NetConnection.onStatus called with args: ');
};
nc.onResult = function()
@@ -66,12 +78,9 @@
// };
};
-// nc.onStatus: level:error, code:NetConnection.Connect.InvalidApp
-// nc.onStatus: level:status, code:NetConnection.Connect.Closed
-//nc.connect("rtmp://localhost/");
-
-// nc.onStatus: level:status, code:NetConnection.Connect.Success
-rtmpuri = "http://"+host+":5080/echo/gateway";
+
+
+rtmpuri = "http://"+hostname+":"+rtmptport+"/echo/gateway";
note("Connecting to "+rtmpuri);
nc.connect(rtmpuri);
// The network connection is not opened at connect() time, but when
@@ -560,7 +569,7 @@
};
-rtmpuri = "rtmp://"+host+":1935/echo";
+rtmpuri = "rtmp://"+hostname+":"+rtmpport+"/echo";
note("Connecting to "+rtmpuri);
ncrtmp.connect(rtmpuri);
[Prev in Thread] |
Current Thread |
[Next in Thread] |
- [Gnash-commit] /srv/bzr/gnash/rtmp r10083: support using flashVars to set hostname and ports.,
rob <=