trtc-electron-sdk 10.2.8-beta.0 → 10.2.8-beta.3
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.js +15 -11
- package/package.json +1 -1
package/liteav/trtc.js
CHANGED
|
@@ -3499,11 +3499,13 @@ class TRTCCloud extends events_1.EventEmitter {
|
|
|
3499
3499
|
return;
|
|
3500
3500
|
}
|
|
3501
3501
|
this.rtcCloud.addLocalVideoRenderCallback((id, type, width, height, timestamp, rotation) => {
|
|
3502
|
-
if (this.
|
|
3503
|
-
this.
|
|
3504
|
-
|
|
3505
|
-
|
|
3506
|
-
|
|
3502
|
+
if (this.enableRenderFrame) {
|
|
3503
|
+
if (this.isScreenCapturing && this.screenCaptureStreamType === type) {
|
|
3504
|
+
this._onRenderFrame(id, type, width, height, timestamp, rotation, screenVideoBuffer.buffer);
|
|
3505
|
+
}
|
|
3506
|
+
else {
|
|
3507
|
+
this._onRenderFrame(id, type, width, height, timestamp, rotation, localVideoBuffer.buffer);
|
|
3508
|
+
}
|
|
3507
3509
|
}
|
|
3508
3510
|
}, this.pixelformate);
|
|
3509
3511
|
}
|
|
@@ -3525,12 +3527,14 @@ class TRTCCloud extends events_1.EventEmitter {
|
|
|
3525
3527
|
return;
|
|
3526
3528
|
}
|
|
3527
3529
|
this.rtcCloud.addRemoteVideoRenderCallback(userId, (id, type, width, height, timestamp, rotation) => {
|
|
3528
|
-
|
|
3529
|
-
|
|
3530
|
-
|
|
3531
|
-
|
|
3532
|
-
|
|
3533
|
-
|
|
3530
|
+
if (this.enableRenderFrame) {
|
|
3531
|
+
const videoBufferInfo = remoteVideoBufferMap.get(id);
|
|
3532
|
+
if (videoBufferInfo && videoBufferInfo.streamType === type) {
|
|
3533
|
+
this._onRenderFrame(id, type, width, height, timestamp, rotation, videoBufferInfo.buffer);
|
|
3534
|
+
}
|
|
3535
|
+
else {
|
|
3536
|
+
this._onRenderFrame(id, type, width, height, timestamp, rotation, screenVideoBuffer.buffer);
|
|
3537
|
+
}
|
|
3534
3538
|
}
|
|
3535
3539
|
}, this.pixelformate);
|
|
3536
3540
|
}
|