Permalink
Browse files

deskshare transition to webrtc screenshare changes

  • Loading branch information...
1 parent a22b21f commit 2ae55432fdf98c5246992c7ff8845a323b948afd @antobinary antobinary committed Jul 29, 2016
@@ -183,7 +183,8 @@ class LiveMeeting(val mProps: MeetingProperties,
}
def handleDeskShareStoppedRequest(msg: DeskShareStoppedRequest): Unit = {
- log.info("handleDeskShareStoppedRequest: dsStarted=" + meetingModel.getDeskShareStarted())
+ log.info("handleDeskShareStoppedRequest: dsStarted=" + meetingModel.getDeskShareStarted() +
+ " URL:" + meetingModel.getRTMPBroadcastingUrl())
// Tell FreeSwitch to stop broadcasting to RTMP
outGW.send(new DeskShareStopRTMPBroadcast(msg.conferenceName, meetingModel.getRTMPBroadcastingUrl()))
@@ -192,7 +193,8 @@ class LiveMeeting(val mProps: MeetingProperties,
}
def handleDeskShareRTMPBroadcastStartedRequest(msg: DeskShareRTMPBroadcastStartedRequest): Unit = {
- log.info("handleDeskShareRTMPBroadcastStartedRequest: isBroadcastingRTMP=" + meetingModel.isBroadcastingRTMP())
+ log.info("handleDeskShareRTMPBroadcastStartedRequest: isBroadcastingRTMP=" + meetingModel.isBroadcastingRTMP() +
+ " URL:" + meetingModel.getRTMPBroadcastingUrl())
// only valid if not broadcasting yet
if (!meetingModel.isBroadcastingRTMP()) {
@@ -210,7 +212,8 @@ class LiveMeeting(val mProps: MeetingProperties,
}
def handleDeskShareRTMPBroadcastStoppedRequest(msg: DeskShareRTMPBroadcastStoppedRequest): Unit = {
- log.info("handleDeskShareRTMPBroadcastStoppedRequest: isBroadcastingRTMP=" + meetingModel.isBroadcastingRTMP())
+ log.info("handleDeskShareRTMPBroadcastStoppedRequest: isBroadcastingRTMP=" + meetingModel
+ .isBroadcastingRTMP() + " URL:" + meetingModel.getRTMPBroadcastingUrl())
// only valid if currently broadcasting
if (meetingModel.isBroadcastingRTMP()) {
@@ -227,7 +230,8 @@ class LiveMeeting(val mProps: MeetingProperties,
def handleDeskShareGetDeskShareInfoRequest(msg: DeskShareGetDeskShareInfoRequest): Unit = {
- log.info("handleDeskShareGetDeskShareInfoRequest: " + msg.conferenceName + "isBroadcasting=" + meetingModel.isBroadcastingRTMP())
+ log.info("handleDeskShareGetDeskShareInfoRequest: " + msg.conferenceName + "isBroadcasting="
+ + meetingModel.isBroadcastingRTMP() + " URL:" + meetingModel.getRTMPBroadcastingUrl())
if (meetingModel.isBroadcastingRTMP()) {
// if the meeting has an ongoing WebRTC Deskshare session, send a notification
outGW.send(new DeskShareNotifyASingleViewer(mProps.meetingID, msg.requesterID, meetingModel.getRTMPBroadcastingUrl(),
@@ -66,9 +66,6 @@ public void conferenceEventJoin(String uniqueId, String confName, int confSize,
String voiceUserId = callerIdName;
- System.out.println("User joined voice conference, user=[" + callerIdName + "], conf=[" +
- confName + "] callerId=[" + callerId + "]");
-
Matcher gapMatcher = GLOBAL_AUDION_PATTERN.matcher(callerIdName);
if (gapMatcher.matches()) {
System.out.println("Ignoring GLOBAL AUDIO USER [" + callerIdName + "]");
@@ -78,6 +75,8 @@ public void conferenceEventJoin(String uniqueId, String confName, int confSize,
// (WebRTC) Deskstop sharing conferences' name is of the form ddddd-DESKSHARE
// Voice conferences' name is of the form ddddd
if (confName.endsWith(DESKSHARE_CONFERENCE_NAME_SUFFIX)) {
+ System.out.println("User joined deskshare conference, user=[" + callerIdName + "], " +
+ "conf=[" + confName + "] callerId=[" + callerId + "]");
DeskShareStartedEvent dsStart = new DeskShareStartedEvent(confName, callerId, callerIdName);
conferenceEventListener.handleConferenceEvent(dsStart);
} else {
@@ -87,6 +86,9 @@ public void conferenceEventJoin(String uniqueId, String confName, int confSize,
callerIdName = matcher.group(2).trim();
}
+ System.out.println("User joined voice conference, user=[" + callerIdName + "], conf=[" +
+ confName + "] callerId=[" + callerId + "]");
+
VoiceUserJoinedEvent pj = new VoiceUserJoinedEvent(voiceUserId, memberId.toString(), confName, callerId, callerIdName, muted, speaking, "");
conferenceEventListener.handleConferenceEvent(pj);
}
@@ -95,16 +97,19 @@ public void conferenceEventJoin(String uniqueId, String confName, int confSize,
@Override
public void conferenceEventLeave(String uniqueId, String confName, int confSize, EslEvent event) {
Integer memberId = this.getMemberIdFromEvent(event);
- System.out.println("User left voice conference, user=[" + memberId.toString() + "], conf=[" + confName + "]");
String callerId = this.getCallerIdFromEvent(event);
String callerIdName = this.getCallerIdNameFromEvent(event);
// (WebRTC) Deskstop sharing conferences' name is of the form ddddd-DESKSHARE
// Voice conferences' name is of the form ddddd
if (confName.endsWith(DESKSHARE_CONFERENCE_NAME_SUFFIX)) {
+ System.out.println("User left deskshare conference, user=[" + memberId.toString() +
+ "], " + "conf=[" + confName + "]");
DeskShareEndedEvent dsEnd = new DeskShareEndedEvent(confName, callerId, callerIdName);
conferenceEventListener.handleConferenceEvent(dsEnd);
} else {
+ System.out.println("User left voice conference, user=[" + memberId.toString() + "], " +
+ "conf=[" + confName + "]");
VoiceUserLeftEvent pl = new VoiceUserLeftEvent(memberId.toString(), confName);
conferenceEventListener.handleConferenceEvent(pl);
}
@@ -224,7 +229,8 @@ private Long genTimestamp() {
@Override
public void eventReceived(EslEvent event) {
- System.out.println("ESL Event Listener received event=[" + event.getEventName() + "]");
+ System.out.println("ESL Event Listener received event=[" + event.getEventName() + "]" +
+ event.getEventHeaders().toString());
// if (event.getEventName().equals(FreeswitchHeartbeatMonitor.EVENT_HEARTBEAT)) {
//// setChanged();
// notifyObservers(event);
@@ -23,13 +23,14 @@ class VoiceConferenceService(sender: RedisPublisher) extends IVoiceConferenceSer
def userJoinedVoiceConf(voiceConfId: String, voiceUserId: String, userId: String, callerIdName: String,
callerIdNum: String, muted: java.lang.Boolean, talking: java.lang.Boolean, avatarURL: String) {
- // println("******** FreeswitchConferenceService received voiceUserJoined vui=[" + userId + "] wui=[" + webUserId + "]")
+ println("******** FreeswitchConferenceService received voiceUserJoined vui=[" +
+ userId + "] wui=[" + voiceUserId + "]")
val msg = new UserJoinedVoiceConfMessage(voiceConfId, voiceUserId, userId, callerIdName, callerIdNum, muted, talking, avatarURL)
sender.publish(FROM_VOICE_CONF_SYSTEM_CHAN, msg.toJson())
}
def userLeftVoiceConf(voiceConfId: String, voiceUserId: String) {
- // println("******** FreeswitchConferenceService received voiceUserLeft vui=[" + userId + "] conference=[" + conference + "]")
+ println("******** FreeswitchConferenceService received voiceUserLeft vui=[" + voiceUserId + "] conference=[" + voiceConfId + "]")
val msg = new UserLeftVoiceConfMessage(voiceConfId, voiceUserId)
sender.publish(FROM_VOICE_CONF_SYSTEM_CHAN, msg.toJson())
}
@@ -8,6 +8,7 @@ Verto = function (
onFail = null,
chromeExtension = null) {
+ voiceBridge += "-DESKSHARE";
this.cur_call = null;
this.share_call = null;
this.vertoHandle;
@@ -508,3 +509,5 @@ window.vertoExtensionGetChromeExtensionStatus = function (extensionid, callback)
callback = Verto.normalizeCallback(callback);
getChromeExtensionStatus(extensionid, callback);
};
+
+
@@ -25,10 +25,10 @@ package org.bigbluebutton.modules.screenshare.managers
import org.bigbluebutton.core.UsersUtil;
import org.bigbluebutton.main.events.MadePresenterEvent;
import org.bigbluebutton.modules.screenshare.events.IsSharingScreenEvent;
- import org.bigbluebutton.modules.screenshare.events.ShareStartRequestResponseEvent;
+ import org.bigbluebutton.modules.screenshare.events.ShareStartRequestResponseEvent;
import org.bigbluebutton.modules.screenshare.events.StartShareRequestFailedEvent;
import org.bigbluebutton.modules.screenshare.events.StartShareRequestSuccessEvent;
- import org.bigbluebutton.modules.deskshare.events.UseJavaModeCommand;
+ import org.bigbluebutton.modules.screenshare.events.UseJavaModeCommand;
import org.bigbluebutton.modules.screenshare.events.StreamStartedEvent;
import org.bigbluebutton.modules.screenshare.events.ViewStreamEvent;
import org.bigbluebutton.modules.screenshare.model.ScreenshareModel;
@@ -73,7 +73,7 @@ package org.bigbluebutton.modules.screenshare.services.red5
event.videoHeight = height;
dispatcher.dispatchEvent(event); //TODO why?
} else {
- LOGGER.debug("No deskshare stream being published");
+ LOGGER.debug("No screenshare stream being published");
var connEvent:WebRTCConnectionEvent = new WebRTCConnectionEvent();
connEvent.status = WebRTCConnectionEvent.NO_DESKSHARE_STREAM;
dispatcher.dispatchEvent(connEvent); //TODO why?
@@ -286,7 +286,7 @@ package org.bigbluebutton.modules.screenshare.services.red5
event.status = WebRTCConnectionEvent.CHECK_FOR_DESKSHARE_STREAM;
dispatcher.dispatchEvent(event); // TODO anton send to akka-bbb-apps
- nc.call("deskshare.checkIfStreamIsPublishing", responder, room);
+ nc.call("screenshare.checkIfStreamIsPublishing", responder, room);
}
public function disconnect():void{
@@ -178,6 +178,9 @@ with BigBlueButton; if not, see <http://www.gnu.org/licenses/>.
stream = rtmp.substring(rtmp.lastIndexOf('/')+1, rtmp.length);
LOGGER.debug("DesktopPublishWindow::startVideo meetingurl=[{0}] and stream=[{1}]",[meetingUrl, stream]);
+ JSLog.warn("DesktopPublishWindow::startVideo meetingurl= ",meetingUrl);
+ JSLog.warn("DesktopPublishWindow::startVideo stream=", stream);
+
connection = new NetConnection();
connection.proxyType = "best";
connection.objectEncoding = ObjectEncoding.AMF0;
@@ -53,8 +53,8 @@ package org.bigbluebutton.modules.users.services
import org.bigbluebutton.modules.present.events.RemovePresentationEvent;
import org.bigbluebutton.modules.present.events.UploadEvent;
import org.bigbluebutton.modules.users.events.MeetingMutedEvent;
- import org.bigbluebutton.modules.deskshare.events.ViewStreamEvent;
- import org.bigbluebutton.modules.deskshare.events.WebRTCViewStreamEvent;
+ import org.bigbluebutton.modules.screenshare.events.ViewStreamEvent;
+ import org.bigbluebutton.modules.screenshare.events.WebRTCViewStreamEvent;
import org.bigbluebutton.main.api.JSLog;
import org.bigbluebutton.modules.users.events.MeetingMutedEvent;
@@ -175,6 +175,8 @@ package org.bigbluebutton.modules.users.services
private function handleDeskShareRTMPBroadcastNotification(msg:Object):void {
LOGGER.debug("*** handleDeskShareRTMPBroadcastNotification **** \n", [msg]);
+ JSLog.warn("*** handleDeskShareRTMPBroadcastNotification **** url=", msg.rtmpUrl);
+ JSLog.warn("*** handleDeskShareRTMPBroadcastNotification **** broadcasting=", msg.broadcasting);
var event:WebRTCViewStreamEvent;
if (msg.broadcasting) {
@@ -0,0 +1,17 @@
+#!/usr/bin/env bash
+
+cd /var/lib/red5/webapps
+echo 'Starting with:'
+ls -dl video-broadcast
+sudo chown root:root video-broadcast
+sudo chmod -R 777 video-broadcast
+
+cd video-broadcast
+
+ls -al
+sudo chown root:root META-INF
+sudo chown red5:red5 streams
+sudo chown root:root WEB-INF
+
+echo 'After the procedure:'
+ls -al

0 comments on commit 2ae5543

Please sign in to comment.