Skip to content

Commit e45cda4

Browse files
author
lihao
committed
✨ Add Live streaming feature
1 parent 64418a8 commit e45cda4

File tree

8 files changed

+325
-121
lines changed

8 files changed

+325
-121
lines changed

ZegoExpressManager/index.js

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -179,6 +179,15 @@ var ZegoExpressManager = /** @class */ (function () {
179179
return engine;
180180
});
181181
};
182+
ZegoExpressManager.destroyEngine = function () {
183+
return zego_express_engine_reactnative_1.default
184+
.destroyEngine()
185+
.then(function () {
186+
console.warn(
187+
'[ZEGOCLOUD LOG][Manager][destroyEngine] - Destroy engine success',
188+
);
189+
});
190+
};
182191
ZegoExpressManager.prototype.joinRoom = function (
183192
roomID,
184193
token,
@@ -289,6 +298,7 @@ var ZegoExpressManager = /** @class */ (function () {
289298
_this.triggerStreamHandle('mic', enable);
290299
});
291300
};
301+
// Can be called repeatedly without affecting the push-pull stream
292302
ZegoExpressManager.prototype.setLocalVideoView = function (renderView) {
293303
if (!this.roomID) {
294304
console.error(

ZegoExpressManager/index.ts

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -58,6 +58,13 @@ export class ZegoExpressManager {
5858
},
5959
);
6060
}
61+
static destroyEngine(): Promise<void> {
62+
return ZegoExpressEngine.destroyEngine().then(() => {
63+
console.warn(
64+
'[ZEGOCLOUD LOG][Manager][destroyEngine] - Destroy engine success',
65+
);
66+
});
67+
}
6168
joinRoom(
6269
roomID: string,
6370
token: string,
@@ -153,6 +160,7 @@ export class ZegoExpressManager {
153160
this.triggerStreamHandle('mic', enable);
154161
});
155162
}
163+
// Can be called repeatedly without affecting the push-pull stream
156164
setLocalVideoView(renderView: number) {
157165
if (!this.roomID) {
158166
console.error(

img/icon_camera.png

1.78 KB
Loading

img/icon_cohost.png

955 Bytes
Loading

img/icon_mic.png

2.53 KB
Loading

img/icon_phone.png

1.08 KB
Loading

0 commit comments

Comments
 (0)