简体中文 | English
This document describes how to quickly run the TRTC demo for Flutter.
Note: The international version only supports Android and IOS.
You have signed up for a Tencent Cloud account and completed identity verification.
[](id:step1)
APIExample
. If you have already created an application, click Select Existing Application.
An application name can contain up to 15 characters. Only digits, letters, Chinese characters, and underscores are allowed.
Tags are used to identify and organize your Tencent Cloud resources. For example, an enterprise may have multiple business units, each of which has one or more TRTC applications. In this case, the enterprise can tag TRTC applications to mark out the unit information. Tags are optional and can be added or edited according to your actual business needs.
[](id:step2)
[](id:step3)
/lib/debug/GenerateTestUserSig.dart
.GenerateTestUserSig.dart
as follows.The method for generating
UserSig
described in this document involves configuringSECRETKEY
in client code. In this method,SECRETKEY
may be easily decompiled and reversed, and if your key is leaked, attackers can steal your Tencent Cloud traffic. Therefore, this method is only suitable for the local execution and debugging of the demo.The correct
UserSig
distribution method is to integrate the calculation code ofUserSig
into your server and provide an application-oriented API. WhenUserSig
is needed, your application can send a request to the business server for a dynamicUserSig
. For more information, please see How do I calculate UserSig on the server?.
[](id:step4)
flutter pub get
.flutter run
.pod install
./ios
demo project in the source code directory with Xcode (11.0 or above) and compile and run the demo project.flutter run -d windows
flutter run -d macos
TRTC logs are compressed and encrypted by default with the .xlog
extension at the following address:
Documents/log
in the sandbox./sdcard/log/tencent/liteav
./sdcard/Android/data/package name/files/log/tencent/liteav/
.Please check whether io.flutter.embedded_views_preview
is YES
in your info.plist
.
Open /example/android/app/src/main/AndroidManifest.xml
.
xmlns:tools="http://schemas.android.com/tools"
to manifest
.tools:replace="android:label"
to application
.
For more FAQs, please see Flutter.