浏览代码

fix(screenshare): specify source type for fake and proxy (#878)

Spot is the consumer of screensharing using a camera
input and through a proxy connection. To differentiate
which one is active, declare a source type on the
created "desktop" stream.
dev1
virtuacoplenny 6 年前
父节点
当前提交
48bd70c6a9
没有帐户链接到提交者的电子邮件
共有 2 个文件被更改,包括 5 次插入1 次删除
  1. 4
    1
      modules/RTC/RTCUtils.js
  2. 1
    0
      modules/proxyconnection/ProxyConnectionService.js

+ 4
- 1
modules/RTC/RTCUtils.js 查看文件

1329
 
1329
 
1330
                         return applyConstrainsPromise
1330
                         return applyConstrainsPromise
1331
                             .then(() => {
1331
                             .then(() => {
1332
-                                return { stream };
1332
+                                return {
1333
+                                    sourceType: 'device',
1334
+                                    stream
1335
+                                };
1333
                             });
1336
                             });
1334
                     });
1337
                     });
1335
             }
1338
             }

+ 1
- 0
modules/proxyconnection/ProxyConnectionService.js 查看文件

270
                     deviceId:
270
                     deviceId:
271
                         `proxy:${this._peerConnection.getPeerJid()}`,
271
                         `proxy:${this._peerConnection.getPeerJid()}`,
272
                     mediaType: isVideo ? MediaType.VIDEO : MediaType.AUDIO,
272
                     mediaType: isVideo ? MediaType.VIDEO : MediaType.AUDIO,
273
+                    sourceType: 'proxy',
273
                     stream: mediaStream,
274
                     stream: mediaStream,
274
                     track: mediaStream.getVideoTracks()[0],
275
                     track: mediaStream.getVideoTracks()[0],
275
                     videoType
276
                     videoType

正在加载...
取消
保存