This commit is contained in:
parent
af97c97f6a
commit
d39906d0b0
|
|
@ -559,15 +559,18 @@ const Meeting: React.FC = () => {
|
||||||
}
|
}
|
||||||
})
|
})
|
||||||
if (state.enableCamera) {
|
if (state.enableCamera) {
|
||||||
agora.startCameraCapture()
|
await agora.startCameraCapture()
|
||||||
}
|
}
|
||||||
agora.setJoinChannel({
|
await agora.setJoinChannel({
|
||||||
channelId: state.channelId,
|
channelId: state.channelId,
|
||||||
uid: userInfo.uid,
|
uid: userInfo.uid,
|
||||||
screenShareId: userInfo.screenShareId,
|
screenShareId: userInfo.screenShareId,
|
||||||
token: state.token,
|
token: state.token,
|
||||||
tokenA: state.tokenA,
|
tokenA: state.tokenA,
|
||||||
})
|
})
|
||||||
|
if (userInfo.roleId === '1') {
|
||||||
|
await agora.allJoinChannelEx()
|
||||||
|
}
|
||||||
}
|
}
|
||||||
// 状态更新
|
// 状态更新
|
||||||
const changeAgoraDevice = () => {
|
const changeAgoraDevice = () => {
|
||||||
|
|
|
||||||
|
|
@ -273,7 +273,6 @@ export const agora = {
|
||||||
},
|
},
|
||||||
// 摄像头采集
|
// 摄像头采集
|
||||||
startCameraCapture: async () => {
|
startCameraCapture: async () => {
|
||||||
console.log(1);
|
|
||||||
await rtcEngine.startCameraCapture(VideoSourceType.VideoSourceCamera, {
|
await rtcEngine.startCameraCapture(VideoSourceType.VideoSourceCamera, {
|
||||||
format: {
|
format: {
|
||||||
width: 640,
|
width: 640,
|
||||||
|
|
@ -284,7 +283,6 @@ export const agora = {
|
||||||
},
|
},
|
||||||
// 停止采集摄像头
|
// 停止采集摄像头
|
||||||
stopCameraCapture: async () => {
|
stopCameraCapture: async () => {
|
||||||
console.log(2);
|
|
||||||
await rtcEngine.stopCameraCapture()
|
await rtcEngine.stopCameraCapture()
|
||||||
},
|
},
|
||||||
// 加入频道
|
// 加入频道
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue