trtc-electron-sdk 9.8.8-alpha.1 → 9.8.8-beta.2

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/liteav/trtc.d.ts CHANGED
@@ -40,6 +40,7 @@ declare class TRTCCloud extends EventEmitter {
40
40
  private bgmId;
41
41
  private playAudioEffectIdList;
42
42
  private enableRenderFrame;
43
+ private screenCaptureStreamType;
43
44
  constructor();
44
45
  /**
45
46
  * 创建 TRTCCloud 对象单例
package/liteav/trtc.js CHANGED
@@ -121,6 +121,7 @@ class TRTCCloud extends events_1.EventEmitter {
121
121
  this.bgmId = 1 << 29;
122
122
  this.playAudioEffectIdList = [];
123
123
  this.enableRenderFrame = true;
124
+ this.screenCaptureStreamType = trtc_define_1.TRTCVideoStreamType.TRTCVideoStreamTypeSub;
124
125
  this.initEventHandler();
125
126
  console.log('constructor render:' + this.renderMode + '|sdk version:' + pkg.version +
126
127
  '|native sdk version:' + this.rtcCloud.getSDKVersion());
@@ -2386,9 +2387,10 @@ class TRTCCloud extends events_1.EventEmitter {
2386
2387
  console.error('startScreenCapture, params is not instanceof TRTCVideoEncParam!');
2387
2388
  return;
2388
2389
  }
2390
+ this.screenCaptureStreamType = type;
2389
2391
  if (view !== undefined) {
2390
2392
  if (view !== null) {
2391
- let key = this.getKey('local_video', trtc_define_1.TRTCVideoStreamType.TRTCVideoStreamTypeSub);
2393
+ let key = this.getKey('local_video', type);
2392
2394
  this._initRender(key, view);
2393
2395
  }
2394
2396
  this.addLocalVideoRenderCallback();
@@ -2416,9 +2418,10 @@ class TRTCCloud extends events_1.EventEmitter {
2416
2418
  * 8.10 停止屏幕分享
2417
2419
  */
2418
2420
  stopScreenCapture() {
2419
- var key = this.getKey('local_video', trtc_define_1.TRTCVideoStreamType.TRTCVideoStreamTypeSub);
2421
+ var key = this.getKey('local_video', this.screenCaptureStreamType);
2420
2422
  this._destroyRender(key, null);
2421
2423
  this.rtcCloud.stopScreenCapture();
2424
+ this.screenCaptureStreamType = trtc_define_1.TRTCVideoStreamType.TRTCVideoStreamTypeSub;
2422
2425
  }
2423
2426
  /**
2424
2427
  * 8.11 设置辅流(屏幕分享)的编码器参数
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "trtc-electron-sdk",
3
- "version": "9.8.8-alpha.1",
3
+ "version": "9.8.8-beta.2",
4
4
  "description": "trtc electron sdk",
5
5
  "main": "./liteav/trtc.js",
6
6
  "types": "./liteav/trtc.d.ts",