How to Develop a Video Calling App Like Google Duo?
You can laugh at everything but not with everyone.
Bernard Werber “Custom Paradise”
Can you imagine your life without communication, without sharing your feelings and emotions, without hearing from your friends and acquaintances? This question is rhetorical since the human is a social creature whose whole life is based on social connections and information exchange. At any responsible moment of your life, you usually seek advice or consultation, be that an intention to buy a washing machine or to travel to fabulous Algeria for a vacation. You would like to know what others think about it to make sure your actions and wishes are right.
People became closer to each other with the introduction of telecommunications. Thus, the telephone has been considered to be the most popular means of communication since 1876. Mankind felt freedom. You don’t need to wait long for a reply to your letter any more as everything is handled in real time. Distance is not critical for choosing a circle of contacts anymore. It doesn’t matter what your current location is, your house or working place, a store or public transport, you are always connected and are able to get in touch with people you need. And this is wonderful!
Messengers are much used in this regard. There are a lot of them that also provide an opportunity for video calls. The most popular ones are Facetime, BBM, Hangouts, ICQ, JustTalk, KakaoTalk, Line, Skype, Viber, WeChat, etc.
They all excellently cope with the tasks put to them being a universal means for chatting, sending files, making voice and video calls. It should seem very convenient due to keeping everything needed for communication in one place. But there is something fishy about this. Think of your kitchen - you have everything at its place, each object performs its specific function.
Modern messengers cause some confusion and the impression of being overstuffed with features. Guys from Google have probably also felt that and decided to go a different way, which is to separate all these functions. With that said, we would like to introduce a new Google Duo app to you.
About Google Duo
If you use Google Hangouts, you have probably had questions regarding the quality of its performance. And this refers not only to video calls. The company tries to improve but instead of solving issues with the existing application they start everything from scratch. Two new apps, Google Duo and Google Allo, were announced at Google I/O. Their core features are video calls and messages correspondingly. Google SMS Messenger can also be mentioned in this range but we will create a mix of apps with similar functionality in such a way. So, what makes Google Duo so unique?
The app gives you an opportunity to call someone from your contact list. From the point of view of a Duo user, this is a very simple service similar to Facetime from Apple that needs a phone number instead of an email address to identify an account. Just like Hangouts, it has an iOS version too. Google Duo supports end-to-end encryption that will keep all of your secrets.
You need to carefully read everything and agree to them by clicking "I agree". The screen is quite simple in terms of implementation.
The next step is binding your phone number to your Duo account. Everything is done fast and easily, with minimum efforts from the user. You just need to tap the button and the app will take the verification code and paste it to the necessary field itself.
One click and you are on board. The main screen tells you with its whole view what this app is created for and it is difficult to misinterpret it.
Tap the video call button and you will immediately see the screen with your contacts. The app automatically pulls them from your phone book and synchronized accounts. You can invite your friends who haven’t tried Duo yet by sending an SMS with the link to the application.
The screen also contains the search by a phone number and contact name. To make a call you just need to tap the contact already available in the Duo system.
The most interesting app feature is called Knock Knock - a user you phone can see you before answering the incoming call. This can be turned off in the settings of the application. We will return to it later. Meanwhile, look at the main app function in action - a user’s friend has just taken the call.
On the screen of the current video call, you can change places of your thumbnail and the picture of your conversation partner by simply tapping the miniature area.
There is also a function of switching between the main and front cameras. To do this, you should tap the appropriate button.
You can also turn off the microphone. The same is impossible to do with the camera but you always have a spare finger to cover it :)
So, you’ve tried to call via the app, liked its advantages and decided to customize it. This is done with the help of settings. They can be reached via an icon on the main screen that has a menu with the appropriate section and one more providing help and feedback.
The following list of settings is available to the user:
- Vibration signal for an incoming call
- The Knock Knock feature
- Limited usage of mobile data
- Unregister a current phone number
- A list of blocked contacts
The entry “About, terms, and privacy” provides access to the general information about the application and the list of ready-made solutions used in its development.
Magic Inside - WebRTC
So, the core feature of Google Duo is video calls. They are implemented with the help of the WebRTC project and other additional functions that change the quality of video depending on the quality of the connection.
WebRTC (real-time communications) is an open-source Internet protocol designed for arranging voice and video calls via the Internet in real time.
WebRTC is generally developed for modern browsers to implement Peer-to-Peer without the help of a third-party web server but still being able to transmit media content. WebRTC is basically a composition of Media Streams and Peer Connections.
Media Streams are API, which allows access to the camera and microphone through a browser without any additional plugins or flash technologies.
Peer Connection is API, that makes it possible to install Peer-to-Peer connections between browsers.
- The first client sends a so-called Offer to another client via a server (PeerConnection Observer).
- The second client (Remote Peer) sends a reply to the first one via the server too.
- The P2P connection is established between the clients.
It is interesting that the server becomes optional for the further work of such a connection. That is, the data will still be transferred even after it is disabled. The further involvement of PeerConnection Observer is required only to properly close the connection, add new members, etc.
Is WebRTC Safe?
To transfer data in real time, WebRTC uses the protocol called Datagram Transport Layer Security. In the connection encrypted with DTLS, any eavesdropping and information falsification are excluded.
Accept DTLS, the WebRTC technology uses Secure Real-Time Protocol for video and audio data encryption. This protocol doesn’t also allow eavesdropping or scanning an IP-connection (voice and video traffic) by unauthorized people.
So, if you would like to develop an app like Google Duo the WebRTC protocol should be its main constituent. It attracts with its simplicity and working with it on web or mobile platforms is nothing special.
In terms of mobile app development, the implementation of a good WebRTC client and building of media data transfer and acquisition via it (audio and video content in our case) are its Achilles' heel.
You can find the list of third-party libraries and technologies in Google Duo that you may use to build your own app for video calls. Most of them are designed to process video and sound, and to implement the WebRTC client, of course. It is also possible to find a lot of ready-made solutions on the Internet and use them to save time. For example, there is an open-source project that already includes the implementation of the WebRTC server and a client for Android. It is called ProjectRTC.
The market is already overсrowded with apps that have the video call feature, so it can be difficult to compete with them. But if you already have an application with social aspect this function might be very reasonable for increasing your audience.
Want to create the next big app?
MLSDev Team is always here to help you do it. Contact us to discuss your idea, learn more about us, and receive a consultation from our experts.