Skip to content

Commit

Permalink
Merge pull request #15 from red5pro/feature/RPRO-3296
Browse files Browse the repository at this point in the history
allowing for  query param to specify live and/or recorded publish ses…
  • Loading branch information
bustardcelly authored Sep 21, 2016
2 parents 05dc474 + d2564ab commit 997a5f1
Showing 1 changed file with 11 additions and 1 deletion.
12 changes: 11 additions & 1 deletion flash-clients/Broadcaster/src/Broadcaster.mxml
Original file line number Diff line number Diff line change
Expand Up @@ -236,6 +236,9 @@
private var streamName:String;
private var streamHost:String = "localhost";
private var streamType:String = "live";
private static const STREAM_TYPE:Array = ["live", "record"];
private var quality:String = RESOLUTION_MID;
private var useHigherQuality:Boolean = false;
Expand Down Expand Up @@ -264,6 +267,13 @@
streamHost = loaderInfo.parameters.host;
}
if (loaderInfo.parameters.streamType) {
var st:String = loaderInfo.parameters.streamType;
if (STREAM_TYPE.indexOf(st) > -1) {
streamType = st;
}
}
// Enable input fields as we have basic criteria
streamNameField.enabled = true;
resolutionGroup.enabled = true;
Expand Down Expand Up @@ -495,7 +505,7 @@
netStream.videoStreamSettings = h264settings;
netStream.attachAudio(microphone);
netStream.publish(streamName);
netStream.publish(streamName, streamType);
log("Publishing as stream name '" + streamName + "'...");
break;
Expand Down

0 comments on commit 997a5f1

Please sign in to comment.