Skip to content

Commit 1627a87

Browse files
author
Germano Fronza
authored
Merge pull request #62 from eventials/master
RTMPS and proxyType option
2 parents a3f8dd3 + aa5734b commit 1627a87

File tree

12 files changed

+16
-12
lines changed

12 files changed

+16
-12
lines changed

README.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -38,6 +38,7 @@ The plugin accepts several **optional** configuration options, such as:
3838
- `bufferTime` (default **0.1**) - How long to buffer before start playing the media.
3939
- `startLevel` (default **-1**) - Initial quality level index.
4040
- `useAppInstance` (default **false**) - Set it to `true` if your source url contains the app instance (not required if the app instance is `_definst_`).
41+
- `proxyType` (default **none**) - Determines which fallback methods are tried if an initial connection attempt to Flash Media Server fails.
4142

4243
## Building
4344

dist/assets/RTMP.swf

227 Bytes
Binary file not shown.

dist/rtmp.js

Lines changed: 2 additions & 2 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

dist/rtmp.min.js

Lines changed: 2 additions & 2 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

dist/rtmp.min.js.map

Lines changed: 1 addition & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"name": "clappr-rtmp",
3-
"version": "0.0.14",
3+
"version": "0.0.15-rc1",
44
"description": "RTMP Support for Clappr Player",
55
"main": "dist/rtmp.js",
66
"author": "Flávio Ribeiro",

public/RTMP.swf

227 Bytes
Binary file not shown.

public/flash.html

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@
77
<param name="allowFullScreen" value="false">
88
<param name="wmode" value="<%= wmode %>">
99
<param name="tabindex" value="1">
10-
<param name=FlashVars value="playbackId=<%= playbackId %>&scaling=<%= scaling %>&bufferTime=<%= bufferTime %>&playbackType=<%= playbackType %>&startLevel=<%= startLevel %>&useAppInstance=<%= useAppInstance %>"/>
10+
<param name=FlashVars value="playbackId=<%= playbackId %>&scaling=<%= scaling %>&bufferTime=<%= bufferTime %>&playbackType=<%= playbackType %>&startLevel=<%= startLevel %>&useAppInstance=<%= useAppInstance %>&proxyType=<%= proxyType %>"/>
1111
<embed
1212
name="<%= cid %>"
1313
type="application/x-shockwave-flash"
@@ -22,7 +22,7 @@
2222
swliveconnect="true"
2323
allowfullscreen="false"
2424
bgcolor="#000000"
25-
FlashVars="playbackId=<%= playbackId %>&scaling=<%= scaling %>&bufferTime=<%= bufferTime %>&playbackType=<%= playbackType %>&startLevel=<%= startLevel %>&useAppInstance=<%= useAppInstance %>"
25+
FlashVars="playbackId=<%= playbackId %>&scaling=<%= scaling %>&bufferTime=<%= bufferTime %>&playbackType=<%= playbackType %>&startLevel=<%= startLevel %>&useAppInstance=<%= useAppInstance %>&proxyType=<%= proxyType %>"
2626
src="<%= swfPath %>"
2727
width="100%"
2828
height="100%">

src/OSMF.swc

-191 Bytes
Binary file not shown.

src/RTMP.as

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -52,6 +52,7 @@ package {
5252
private var playbackState:String = "IDLE";
5353
private var isLive:Boolean = false;
5454
private var useAppInstance:Boolean = false;
55+
private var proxyType:String = "none";
5556

5657
CONFIG::LOGGING {
5758
private static const logInit:Boolean = initLog();
@@ -71,6 +72,7 @@ package {
7172
playbackId = this.root.loaderInfo.parameters.playbackId;
7273
isLive = this.root.loaderInfo.parameters.playbackType == 'live';
7374
useAppInstance = this.root.loaderInfo.parameters.useAppInstance == 'true';
75+
proxyType = this.root.loaderInfo.parameters.proxyType;
7476
mediaFactory = new DefaultMediaFactory();
7577
mediaContainer = new MediaContainer();
7678

@@ -195,9 +197,9 @@ package {
195197
try {
196198
if (!mediaElement) {
197199
if (isLive) {
198-
urlResource = new StreamingURLResource(url, StreamType.LIVE, NaN, NaN, null, useAppInstance);
200+
urlResource = new StreamingURLResource(url, StreamType.LIVE, NaN, NaN, null, useAppInstance, null, proxyType);
199201
} else {
200-
urlResource = new StreamingURLResource(url, StreamType.RECORDED, NaN, NaN, null, useAppInstance);
202+
urlResource = new StreamingURLResource(url, StreamType.RECORDED, NaN, NaN, null, useAppInstance, null, proxyType);
201203
}
202204

203205
var startLevel:int = int(this.root.loaderInfo.parameters.startLevel);

0 commit comments

Comments
 (0)