From d652eb7f9b135d742e9b5579f5673aa104e21d65 Mon Sep 17 00:00:00 2001 From: prlanzarin Date: Mon, 27 Aug 2018 07:37:25 +0000 Subject: [PATCH] Added voiceBridge prop to video-provider and forward it to SFU --- .../imports/ui/components/video-provider/component.jsx | 3 ++- .../imports/ui/components/video-provider/container.jsx | 1 + .../imports/ui/components/video-provider/service.js | 6 ++++++ 3 files changed, 9 insertions(+), 1 deletion(-) diff --git a/bigbluebutton-html5/imports/ui/components/video-provider/component.jsx b/bigbluebutton-html5/imports/ui/components/video-provider/component.jsx index 1c7fe511e3..24095302e5 100755 --- a/bigbluebutton-html5/imports/ui/components/video-provider/component.jsx +++ b/bigbluebutton-html5/imports/ui/components/video-provider/component.jsx @@ -388,7 +388,7 @@ class VideoProvider extends Component { } async createWebRTCPeer(id, shareWebcam) { - const { meetingId, sessionToken } = this.props; + const { meetingId, sessionToken, voiceBridge } = this.props; let iceServers = []; try { @@ -448,6 +448,7 @@ class VideoProvider extends Component { sdpOffer: offerSdp, cameraId: id, meetingId, + voiceBridge, }; this.sendMessage(message); diff --git a/bigbluebutton-html5/imports/ui/components/video-provider/container.jsx b/bigbluebutton-html5/imports/ui/components/video-provider/container.jsx index 12bab47d13..eb6bbd51d1 100755 --- a/bigbluebutton-html5/imports/ui/components/video-provider/container.jsx +++ b/bigbluebutton-html5/imports/ui/components/video-provider/container.jsx @@ -14,4 +14,5 @@ export default withTracker(() => ({ sessionToken: VideoService.sessionToken(), userName: VideoService.userName(), enableVideoStats: getFromUserSettings('enableVideoStats', Meteor.settings.public.kurento.enableVideoStats), + voiceBridge: VideoService.voiceBridge(), }))(VideoProviderContainer); diff --git a/bigbluebutton-html5/imports/ui/components/video-provider/service.js b/bigbluebutton-html5/imports/ui/components/video-provider/service.js index 5c672116d7..0637da6234 100755 --- a/bigbluebutton-html5/imports/ui/components/video-provider/service.js +++ b/bigbluebutton-html5/imports/ui/components/video-provider/service.js @@ -126,6 +126,11 @@ class VideoService { return Auth.sessionToken; } + voiceBridge() { + const voiceBridge = Meetings.findOne({ meetingId: Auth.meetingID }).voiceProp.voiceConf; + return voiceBridge; + } + isConnected() { return this.isConnected; } @@ -157,4 +162,5 @@ export default { meetingId: () => videoService.meetingId(), getAllUsersVideo: () => videoService.getAllUsersVideo(), sessionToken: () => videoService.sessionToken(), + voiceBridge: () => videoService.voiceBridge(), };