【Xinzhi Lab-TRTC Development】Real-time audio and video from Jimei

Table of contents

Foreword:

1. Let’s talk about TRTC

Voice interactive live broadcast

language chat room

voice radio

2. Become TRTC experience officer

1. Understand TRTC products in 1 minute

 2, 2 minutes for beginners

3. Don’t forget the admission ticket, and don’t tell others

3. Complete the new application construction in 3 minutes

1. Unzip and download the source code

2. Modify the JS file

3. Modify the index file

4. Let’s have a good time with the Jimeis


Foreword:

Recently, the weather has cooled down severely, and coupled with the impact of the new crown, online office work has gradually become a trend at this time, including online teaching, online live broadcast, online companionship, etc. Recently, I came into contact with a real-time audio and video product-Tencent Cloud-TRTC, which gave me a good feeling, and I can show it crazy in front of Jimei, hahaha, the most important thing is the multiple simultaneous video calls and Share the latest entertainment headlines online, the latest developments in national aerospace, the highlights of the football cup, and finally share the screen with multiple people online, and let you draw and guess the game together with "full tacit understanding". Of course, in the end, it is necessary to tell the truth together, I really love this TRTC product!

1. Let’s talk about TRTC

Real-time audio and video (TRTC) focuses on low-latency interactive live broadcast and multi-person audio and video solutions, supports low-latency live broadcast viewing, real-time recording, screen sharing, beauty effects, stereo and other capabilities, and can be seamlessly integrated with live CDN Docking, suitable for business scenarios such as interactive mic, cross-room PK, voice radio, karaoke, small class, large class, voice chat, video chat, online conference, etc. This article will briefly introduce low-latency interactive live broadcast and multi-person audio and video Business scenarios that can be reached by the two solutions.

Voice interactive live broadcast

language chat room

Support 50 people to chat on the microphone at the same time, smooth switching between the microphone on and off, the voice chat delay is less than 300ms, and supports various audio effects such as voice changing, atmospheric sound effects, reverberation, etc., making the voice chat experience richer. Combined with instant messaging IM, it supports public chat, private chat, group chat, likes, gifts and other message interaction forms to create a good chat interaction experience. Real-time audio and video provides scene-based components of the chat room, which can be directly reused to minimize development costs.

voice radio

It supports 48kHz sampling rate, 128kbps bit rate and stereo audio, and supports MP3, AAC, WAV and other local music formats as background sound, making it easy to create super high-quality voice stations. Provide rich voice-changing special effects, free switching between uncle voice and loli voice, making voice radio more interesting. Real-time audio and video provides voice radio scene components, which can be directly reused to minimize development costs.

 Of course, there are many exciting scenes, if you want to know more, you can click the link below to view~

Real-time audio and video application scenarios-Product Introduction-Document Center-Tencent Cloud

2. Become TRTC experience officer

1. Understand TRTC products in 1 minute

In order to become a developer of TRTC, we need to obtain the certification and admission ticket of TRTC. TRTC's certification is our real-name certification. Because we use our WeChat to scan the QR code to log in, as long as our WeChat is bound to our personal information, we can directly obtain our WeChat personal information during authentication to quickly complete the authentication.

        First of all, we can click on the link below and use WeChat scan code to log in to register our Tencent Cloud account. Because it is a WeChat scan code, the account registration will be automatically completed after the scan code is successful. It is really convenient~

Tencent Cloud Industry Smart Change · Cloud Inspires the Future- Tencent

After successful login, we can jump to the management interface we need by clicking on the console, or directly searching for real-time audio and video in the search bar.

 

 2, 2 minutes for beginners

Never touched TRTC? This thing looks so advanced, can I learn it? This thing is very complicated to develop, right? Hahaha, these problems will not exist in TRTC. When you click on the development assistance, it has already told you everything you want to know, you know to enter according to the prompt, and then click next, next, four steps to complete quickly

3. Don’t forget the admission ticket, and don’t tell others

TRTC's admission ticket includes an appid and a key. You must have both of these two things to access TRTC's SDK and open the door to a new world. Of course, it is not recommended to tell others. Although 10,000 minutes are free after registration, it is still recommended to save these two things to the database or use your own small notebook to record them. These two things will tell us in our third step, it is amazing, it is applicable to all development scenarios, and it is also applicable to all the applications you build.

 

When you have achieved this step, congratulations, you have basically become a TRTC experience officer. Let me take a look at the actual application transformation. 

3. Complete the new application construction in 3 minutes

We used 1+2=3 minutes to complete the registration and getting started, now we need 3 minutes to complete our application transformation, which is divided into 3 steps.

1. Unzip and download the source code

We downloaded the source code in the second step, and we decompressed it to our usual disk location.

2. Modify the JS file

After decompression, click GenerateTestUserSig.js under ...\webrtc_latest\Web\base-js\js\debug to modify, and enter our unique appid and key.

3. Modify the index file

By modifying index.html, change the device detection, login page, chat interface, and tab page to the beautiful effect we want, as shown in the figure below.

 

 

 

 

4. Let’s have a good time with the Jimeis

When everything is ready, we can enter the same room number, tell the truth, karaoke, watch the World Cup, and learn aerospace knowledge. . . etc. Below are some screenshots of Jimei playing together. You are also welcome to join TRTC to discuss more interesting applications.

 

 

 

 

Guess you like

Origin blog.csdn.net/weixin_67209623/article/details/128141083