English | 简体中文

Tencent Cloud UIKit for Video Conference

TUIRoomKit (tencent_conference_uikit) is Tencent Cloud launched a positioning enterprise meeting, online class, network salon and other scenes of the UI component, through the integration of the component, you only need to write a few lines of code can add similar video conference functions for your App, and support screen sharing, member management, ban the ban painting, chat and other functions. TUIRoomKit supports Windows, Mac, Android, iOS, Flutter, Web, Electron and other development platforms.

Features

  • Easy access: Provide open source components with UI, save 90% development time, fast online video conference function.
  • Platform connectivity: TUIRoomKit components of all platforms are interconnected and accessible.
  • Screen sharing: Based on the screen acquisition capability of each platform jointly polished by 3000+ market applications, with exclusive AI coding algorithm, lower bit rate and clearer picture.
  • Member management: It supports multiple standard room management functions such as all mute, single member gag, drawing, inviting to speak, kicking out of the room, etc.
  • Other features: Support room members chat screen, sound Settings and other features, welcome to use.

Make a first video Conference

Environment preparation

Platform Version
Flutter 3.7.0 and above versions.
Android - Android 4.1 (SDK API level 16) or later (Android 5.0 (SDK API level 21) or later is recommended).
- Android Studio 3.5 or later (Gradle 3.5.4 or later).
- Mobile phone on Android 4.1 or later.
iOS iOS 12.0 and higher.

Active the service

You can follow the steps below to activate the TRTC Conference product service and receive a free 14-day trial version.

Note:

If you wish to purchase the paid version, please refer to TRTC Conference Monthly Packages, follow the Purchasing Guide to complete the purchase.

  1. Visit TRTC Console > Applications, select Create application.

  2. In the Create application pop-up, select Conference and enter the application name, click Create.

  3. After completing the application creation, you will default entry to the application details page, select the Free Trail in the floating window, and click to** Get started for free**.

  4. After the activation is completed, you can view the edition information on the current page. The SDKAppID and SDKSecretKey here will be used in the integration guide.

Access and use

  • Step 1: Add the dependency

    Add the tencent_conference_uikit plugin dependency in pubspec.yaml file in your project.

    dependencies:  
     tencent_conference_uikit: latest release version
    

    Execute the following command to install the plugin.

    flutter pub get
    
  • Step 2: Complete Project Configuration

    • Since the tencent_conference_uikit has utilized the relevant features of the GetX state management library,, you need to use GetMaterialApp instead of MaterialApp in your application. Or you can set the navigatorKey property in your MaterialApp to Get.key to achieve the same effect.

      // This step requires importing the get package before proceeding. 
      // Since the tencent_conference_uikit already has a dependency on get, you don't need to make any additional configurations in your pubspec.yaml.
      import 'package:get/get.dart';  
      
      class MyApp extends StatelessWidget {
        @override
        Widget build(BuildContext context) {
          return GetMaterialApp(  // Use GetMaterialApp to replace MaterialApp
            // Your original MaterialApp content
          );
        }
      }
      
    • Use Xcode to open your project, select Project -> Building Settings -> Deployment, and set the Strip Style to Non-Global Symbols to retain all global symbol information.

    • To use the audio and video functions on iOS, you need to authorize the use of the mic and camera (For Android, the relevant permissions have been declared in the SDK, so you do not need to manually configure them).

      Add the following two items to the Info.plist of the App, which correspond to the prompt messages of the mic and camera when the system pops up the authorization dialog box.

      <key>NSCameraUsageDescription</key>
      <string>TUIRoom needs access to your Camera permission</string>
      <key>NSMicrophoneUsageDescription</key>
      <string>TUIRoom needs access to your Mic permission</string>
      

      After completing the above additions, add the following preprocessor definitions in your ios/Podfile to enable camera and microphone permissions.

      post_install do |installer|
        installer.pods_project.targets.each do |target|
          flutter_additional_ios_build_settings(target)
            target.build_configurations.each do |config|
              config.build_settings['GCC_PREPROCESSOR_DEFINITIONS'] ||= [
            '$(inherited)',
            'PERMISSION_MICROPHONE=1',
            'PERMISSION_CAMERA=1',
            ]
          end
        end
      end
      
  • Step 3: Login tencent_conference_uikit plugin

    Add the following code to your project, which serves to log in to the component by calling the relevant APIs in TUIRoomKit. This step is extremely critical, as only after logging in can you use the various functions of TUIRoomKit, so please be patient and check if the relevant parameters are configured correctly:

    import 'package:rtc_room_engine/rtc_room_engine.dart';
    
    var result = await TUIRoomEngine.login(
    SDKAPPID, // Please replace with your SDKAPPID
    'userId', // Please replace with your user ID
    'userSig',// Please replace with your userSig
    );
    
    if (result.code == TUIError.success) {
      // login success
    } else {
      // login error
    }
    

    Parameter Description

    Here is a detailed introduction to the key parameters used in the login function:

    • SDKAppID:Obtained it in Active the service.

    • UserID:The ID of the current user, which is a string that can only contain English letters (a-z and A-Z), numbers (0-9), hyphens (-), and underscores (_).

    • UserSig:The authentication credential used by Tencent Cloud to verify whether the current user is allowed to use the TRTC service. You can get it by using the SDKSecretKey to encrypt information such as SDKAppID and UserID. You can generate a temporary UserSig on the UserSig Tools page in the TRTC console.

    • For more information, please refer to the UserSig.

    Note:

    • Many developers have contacted us with questions regarding this step. Below are some of the frequently encountered problems:
      • The SDKAppID is set incorrectly.
      • UserSig is set to the value of SDKSecretKey mistakenly. The UserSig is generated by using the SDKSecretKey for the purpose of encrypting information such as SDKAppID, UserID, and the expiration time. But the value of the UserSig cannot be directly substituted with the value of the SDKSecretKey.
      • The UserID is set to a simple string such as 1, 123, or 111, and your colleague may be using the same UserID while working on a project simultaneously. In this case, login will fail as TUIRoomKit doesn't support login on multiple terminals with the same UserID. Therefore, we recommend you use some distinguishable UserID values during debugging.
    • The sample code on GitHub uses the genTestUserSig function to calculate UserSig locally, so as to help you complete the current integration process more quickly. However, this scheme exposes your SDKSecretKey in the application code, which makes it difficult for you to upgrade and protect your SDKSecretKey subsequently. Therefore, we strongly recommend you run the UserSig calculation logic on the server and make the application request the UserSig calculated in real time every time the application uses the TUIRoomKit component from the server.

    Log in to Floating Chat (optional)

    Flutter TUIRoomKit (tencent_conference_uikit) introduced the floating chat feature starting from version 2.4.1. If you need to use the floating chat feature, you need to complete the following initialization and login (If you also need to use the In-Conference Chat page, you can Ignore this step and complete the initialization and login for In-Conference Chat):

    import 'package:tencent_cloud_chat_sdk/enum/V2TimSDKListener.dart';
    import 'package:tencent_cloud_chat_sdk/enum/log_level_enum.dart';
    import 'package:tencent_cloud_chat_sdk/models/v2_tim_callback.dart';
    import 'package:tencent_cloud_chat_sdk/tencent_im_sdk_plugin.dart';
    
    // Initialize
    var initResult = await TencentImSDKPlugin.v2TIMManager.initSDK(
        sdkAppID: SDKAPPID,                     // Replace with your SDKAPPID
        loglevel: LogLevelEnum.V2TIM_LOG_INFO,  // Log registration level
        listener: V2TimSDKListener(),           // Event listener. When using the floating chat, pass an empty object here.
    );
          
    if (initResult.code == 0) { // Initialized successfully
        // Login   
        V2TimCallback imLoginResult = await TencentImSDKPlugin.v2TIMManager.login(
          userID: 'userId',   // Replace with your userID
          userSig: 'userSig', // Replace with your userSig
        );
    }
    

    Note:

    The floating chat feature is enabled by default in TUIRoomKit. If you do not need the floating chat feature, you do not need to perform the above initialization and login steps. You can disable the floating chat feature through the Bottom toolbar -> Setting -> Open Floating Chat option.

  • Step 4: User tencent_conference_uikit plugin

    • Set self username and profile photo (optional)

      import 'package:rtc_room_engine/rtc_room_engine.dart';
      
      TUIRoomEngine.setSelfInfo(userName, avatarURL);
      
    • Start a quick conference

      import 'package:tencent_conference_uikit/tencent_conference_uikit.dart';
      
      ConferenceSession.newInstance('your roomId') 
        ..onActionSuccess = _quickStartSuccess
        ..onActionError = _quickStartError
        ..quickStart();
      
      void _quickStartSuccess() {
        //You can navigate to the conference page on your own in this success callback of starting a quick conference.
        Navigator.push(
          context,
          MaterialPageRoute(
            builder: (context) => ConferenceMainPage(),
          ),
        );
      }
      
      void _quickStartError(ConferenceError error, String message) {
        debugPrint("code: $error message: $message");
      }
      
    • Join a conference

      import 'package:tencent_conference_uikit/tencent_conference_uikit.dart';
      
      ConferenceSession.newInstance('your roomId') 
        ..onActionSuccess = _joinSuccess
        ..onActionError = _joinError
        ..join();
      
      void _joinSuccess() {
        //You can navigate to the conference page on your own in this success callback of joining a conference.
        Navigator.push(
          context,
          MaterialPageRoute(
            builder: (context) => ConferenceMainPage(),
          ),
        );
      }
      
      void _joinError(ConferenceError error, String message) {
        debugPrint("code: $error message: $message");
      }
      
  • If you encounter difficulties, you can refer to FAQs, here are the most frequently encountered problems of developers, covering various platforms, I hope it can Help you solve problems quickly.

  • If you would like to see more official examples, you can refer to the example Demo of each platform: Web, Android, iOS, Electron, Qt.

  • If you would like to see some of our latest product features, you can check the Update Log, here are the latest features of tencent_conference_uikit, as well as the historical version features iterate

  • For complete API documentation, see API reference: including TUIRoomKit (with UIKit), TUIRoomEngine (without UIKit), and events Callbacks, etc.

  • If you want to learn more about the projects maintained by Tencent Cloud Media Services Team, you can check our Product Official Website, Github Organizations etc.

Communication and feedback

If you have any suggestions or comments during the use of our product, please feel free to contact us at info_rtc@tencent.com or submit an issue. Your feedback is greatly appreciated.

Libraries

common/extension/date_time_extension
common/extension/double_extension
common/extension/index
common/extension/string_extension
common/index
common/languages/en_us
common/languages/index
common/languages/translation_service
common/languages/zh_cn
common/models/audio
common/models/index
common/models/time_zone
common/models/user
common/models/user_info
common/models/video
common/store/index
common/store/room
common/store/schedule_room
common/style/colors
common/style/index
common/style/theme
common/values/constants
common/values/images
common/values/index
common/widgets/attendee_item
common/widgets/attendees_sheet
common/widgets/bottom_sheet
common/widgets/copy_text_button
common/widgets/dialog
common/widgets/index
common/widgets/info_item
common/widgets/invite_sheet
common/widgets/rounded_container
common/widgets/setting_item
common/widgets/single_select_list
common/widgets/slider
common/widgets/stick_render
common/widgets/stick_widget
common/widgets/switch
common/widgets/toast
common/widgets/user_info
common/widgets/volume_bar
conference/conference_error
conference/conference_observer
conference/conference_params
conference/conference_session
conference/tui_room_kit
conference/tui_room_kit_impl
event/conference_list_event_handler
event/room_event_handler
manager/conference_list_manager
manager/rtc_engine_manager
pages/conference_list/controller
pages/conference_list/index
pages/conference_list/view
pages/conference_list/widgets/conference_date_item
pages/conference_list/widgets/conference_item
pages/conference_list/widgets/no_schedule_widget
pages/conference_list/widgets/widgets
pages/conference_main/controller
pages/conference_main/index
pages/conference_main/view
pages/conference_main/widgets/bottom_view/controller
pages/conference_main/widgets/bottom_view/index
pages/conference_main/widgets/bottom_view/view
pages/conference_main/widgets/bottom_view/widgets/bottom_button_item
pages/conference_main/widgets/bottom_view/widgets/bottom_buttons
pages/conference_main/widgets/bottom_view/widgets/mic_button
pages/conference_main/widgets/bottom_view/widgets/widgets
pages/conference_main/widgets/exit/controller
pages/conference_main/widgets/exit/index
pages/conference_main/widgets/exit/view
pages/conference_main/widgets/float_window/controller
pages/conference_main/widgets/float_window/index
pages/conference_main/widgets/float_window/view
pages/conference_main/widgets/float_window/window_manager
pages/conference_main/widgets/local_screen_sharing/local_screen_sharing
pages/conference_main/widgets/raise_hand_list/controller
pages/conference_main/widgets/raise_hand_list/index
pages/conference_main/widgets/raise_hand_list/view
pages/conference_main/widgets/raise_hand_list/widgets/title
pages/conference_main/widgets/raise_hand_list/widgets/user_item
pages/conference_main/widgets/raise_hand_list/widgets/user_table
pages/conference_main/widgets/raise_hand_list/widgets/widgets
pages/conference_main/widgets/setting/controller
pages/conference_main/widgets/setting/index
pages/conference_main/widgets/setting/view
pages/conference_main/widgets/setting/widgets/audio_setting
pages/conference_main/widgets/setting/widgets/other_setting
pages/conference_main/widgets/setting/widgets/setting_info_select
pages/conference_main/widgets/setting/widgets/video_setting
pages/conference_main/widgets/setting/widgets/widgets
pages/conference_main/widgets/top_view/controller
pages/conference_main/widgets/top_view/index
pages/conference_main/widgets/top_view/view
pages/conference_main/widgets/top_view/widgets/meeting_title
pages/conference_main/widgets/top_view/widgets/room_info_sheet
pages/conference_main/widgets/top_view/widgets/top_button_item
pages/conference_main/widgets/top_view/widgets/widgets
pages/conference_main/widgets/transfer_host/controller
pages/conference_main/widgets/transfer_host/index
pages/conference_main/widgets/transfer_host/view
pages/conference_main/widgets/transfer_host/widgets/title
pages/conference_main/widgets/transfer_host/widgets/user_item
pages/conference_main/widgets/transfer_host/widgets/user_table
pages/conference_main/widgets/transfer_host/widgets/widgets
pages/conference_main/widgets/user_list/controller
pages/conference_main/widgets/user_list/index
pages/conference_main/widgets/user_list/view
pages/conference_main/widgets/user_list/widgets/button_item
pages/conference_main/widgets/user_list/widgets/user_control
pages/conference_main/widgets/user_list/widgets/user_control_item
pages/conference_main/widgets/user_list/widgets/user_item
pages/conference_main/widgets/user_list/widgets/user_table
pages/conference_main/widgets/user_list/widgets/widgets
pages/conference_main/widgets/video_seat/video_layout/controller
pages/conference_main/widgets/video_seat/video_layout/index
pages/conference_main/widgets/video_seat/video_layout/view
pages/conference_main/widgets/video_seat/video_layout/widgets/video_item/view
pages/conference_main/widgets/video_seat/video_layout/widgets/video_item/widgets/video_user_info
pages/conference_main/widgets/video_seat/video_layout/widgets/video_item/widgets/widgets
pages/conference_main/widgets/video_seat/video_layout/widgets/widgets
pages/conference_main/widgets/video_seat/video_layout/widgets/with_draggable_window_widget
pages/conference_main/widgets/video_seat/video_page_turning/controller
pages/conference_main/widgets/video_seat/video_page_turning/index
pages/conference_main/widgets/video_seat/video_page_turning/view
pages/conference_main/widgets/video_seat/video_page_turning/widgets/page_indicator
pages/conference_main/widgets/video_seat/video_page_turning/widgets/widgets
pages/conference_main/widgets/widgets
pages/index
pages/schedule_conference/controller
pages/schedule_conference/index
pages/schedule_conference/view
pages/schedule_conference/widgets/attendee_selector/controller
pages/schedule_conference/widgets/attendee_selector/index
pages/schedule_conference/widgets/attendee_selector/view
pages/schedule_conference/widgets/attendee_selector/widgets/selected_attendees
pages/schedule_conference/widgets/attendee_selector/widgets/widgets
pages/schedule_conference/widgets/duration_selector
pages/schedule_conference/widgets/room_control
pages/schedule_conference/widgets/room_info
pages/schedule_conference/widgets/room_type
pages/schedule_conference/widgets/start_time_selector
pages/schedule_conference/widgets/time_zone_selector
pages/schedule_conference/widgets/widgets
pages/schedule_details/controller
pages/schedule_details/index
pages/schedule_details/view
pages/schedule_details/widgets/details_button_item
pages/schedule_details/widgets/room_info
pages/schedule_details/widgets/widgets
platform/rtc_conference_tuikit_method_channel
platform/rtc_conference_tuikit_platform_interface
tencent_conference_uikit