This article will show you how to quickly run the video live streaming demo. Following this document, you can run the demo in 10 minutes and finally experience a video live streaming function with a complete UI interface.
2. Open the/iOS/Example/Debug/GenerateTestUserSig.swiftDocument,file, and enter the SDKAppID and SDKSecretKey obtained when Activate the service:
Step 3: Run the Demo
1. Select the device on which you want to run the Demo in XCode as shown below:
2. Once the selection is complete, click Run to run our Demo on the target device.
3. After Demo runs successfully on the device, you can perform the following steps to initiate and watch live broadcasts.
Start Live Broadcast
Note:
In order to allow you to experience the complete video live broadcast process, please log in two users on two devices to use the Demo, one as the host and the other as the audience.
1. Log in & Signup
Please enter your UserId in the User ID field. If your current User ID has not been used before, you will be taken to the Registration page where you can set an avatar and nickname for yourself.
Note:
Try to avoid setting your User ID to simple strings like "1", "123", "111", as TRTC does not support the same User ID being logged into from multiple devices. Such User IDs like "1", "123", "111" are easily occupied by your colleagues during collaborative development, leading to login failures. Therefore, we recommend setting highly recognizable User IDs while debugging.
2. The anchor starts the live broadcast.
Click the Start Broadcast button in the middle of the bottom of the homepage to enter the broadcast preview page, and then click "Start Live" to start the live broadcast.
Anchor: Before entering
Anchor: Preview
Anchor: Live
3. Viewers join the live broadcast room.
Click on any room in the live broadcast list to enter the live broadcast room.