RtcEngine修改为RtcEngineEx

This commit is contained in:
fuenmao 2024-12-04 11:54:49 +08:00
parent 19c46516f3
commit 674a5f8a53
5 changed files with 9 additions and 9 deletions

Binary file not shown.

After

Width:  |  Height:  |  Size: 618 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 863 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 362 B

View File

@ -201,7 +201,7 @@ class MeetingMainLogic extends GetxController with RequestToolMixin{
Future<void> doHttpGetTvAnchor() async { Future<void> doHttpGetTvAnchor() async {
BaseStructureResult res = await getClient().getTvAnchor(state.roomNumber.value); BaseStructureResult res = await getClient().getTvAnchor(state.roomNumber.value);
/*var s = 2; /*var s = 2;
// if(res.data!.toString().length != 9){ if(res.data!.toString().length != 9){
if(s == 2){ if(s == 2){
state.remoteUid.value = "18"; state.remoteUid.value = "18";
setEnableVideo(); setEnableVideo();
@ -222,12 +222,12 @@ class MeetingMainLogic extends GetxController with RequestToolMixin{
changePageState(1); changePageState(1);
}*//* }*//*
}*/ }*/
Future.delayed(const Duration(milliseconds: 500), () { state.remoteUid.value = res.data!.toString();
state.remoteUid.value = "18"; if(res.data!.toString().length != 9){
setEnableVideo(); Future.delayed(const Duration(milliseconds: 1000), () {
changePageState(1); changePageState(1);
}); });
}
} }
/// --------------------------signalR Socket相关 /// --------------------------signalR Socket相关
@ -463,7 +463,7 @@ class MeetingMainLogic extends GetxController with RequestToolMixin{
PermissionHandler.requestMicrophonePermission(); PermissionHandler.requestMicrophonePermission();
// RtcEngine // RtcEngine
state.rctEngine.value = createAgoraRtcEngine(); state.rctEngine.value = createAgoraRtcEngineEx();
// RtcEngine channelProfileLiveBroadcasting // RtcEngine channelProfileLiveBroadcasting
await state.rctEngine.value?.initialize(RtcEngineContext( await state.rctEngine.value?.initialize(RtcEngineContext(

View File

@ -71,7 +71,7 @@ class MeetingMainState {
/// ///
final String appId = "4a4f7be64fa1404ebda74784fe9ac381"; final String appId = "4a4f7be64fa1404ebda74784fe9ac381";
late Rx<RtcEngine?> rctEngine = Rx(null); late Rx<RtcEngineEx?> rctEngine = Rx(null);
/// ///
late RxBool isAutoSubscribeVideo = false.obs; late RxBool isAutoSubscribeVideo = false.obs;
/// ///