mirror of
https://github.com/nextcloud/talk-android
synced 2025-03-06 14:27:24 +00:00
Merge pull request #905 from nextcloud/fix-frozen-video-when-screen-is-shared
[v8.0.x] Fix frozen video when screen is shared
This commit is contained in:
commit
518d1ea62e
@ -109,11 +109,13 @@ public class MagicPeerConnectionWrapper {
|
|||||||
magicDataChannel.registerObserver(new MagicDataChannelObserver());
|
magicDataChannel.registerObserver(new MagicDataChannelObserver());
|
||||||
if (isMCUPublisher) {
|
if (isMCUPublisher) {
|
||||||
peerConnection.createOffer(magicSdpObserver, sdpConstraints);
|
peerConnection.createOffer(magicSdpObserver, sdpConstraints);
|
||||||
} else if (hasMCU) {
|
} else if (hasMCU && this.videoStreamType.equals("video")) {
|
||||||
|
// If the connection type is "screen" the client sharing the screen will send an
|
||||||
|
// offer; offers should be requested only for videos.
|
||||||
HashMap<String, String> hashMap = new HashMap<>();
|
HashMap<String, String> hashMap = new HashMap<>();
|
||||||
hashMap.put("sessionId", sessionId);
|
hashMap.put("sessionId", sessionId);
|
||||||
EventBus.getDefault().post(new WebSocketCommunicationEvent("peerReadyForRequestingOffer", hashMap));
|
EventBus.getDefault().post(new WebSocketCommunicationEvent("peerReadyForRequestingOffer", hashMap));
|
||||||
} else if (hasInitiated) {
|
} else if (!hasMCU && hasInitiated) {
|
||||||
peerConnection.createOffer(magicSdpObserver, sdpConstraints);
|
peerConnection.createOffer(magicSdpObserver, sdpConstraints);
|
||||||
|
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user