A bit about WebRTC: what to use and the case from practice

WebRTC is a browser technology designed to transfer streaming data between browsers or applications using point-to-point transmission technology .




This technology is good in that it allows you to establish communication between users using only a browser. For some developers, when they learn about WebRTC, this becomes a discovery: you can create a video chat without using a third-party server - you only need a browser.

WebRTC does not require the installation of additional plugins. You just need to write the code in HTML or JavaScript, and the video streams in the browser will work smoothly.


WebRTC can be used not only for video chats: the technology allows you to transfer files of any format and text messages.


WebRTC API


WebRTC has a fairly large set of features and tools. In this article, we will analyze three APIs.


1. getUserMedia


The API allows you to manage user devices from a browser. Here you can choose:


  • the camera from which the video should be broadcast;
  • microphone;
  • transmitted image quality.

. , , 360 .


: .


2. RTCPeerConnection


API- Peer-to-Peer, , . , .


RTCPeerConnection — Stun/Turn, NAT, - .


Stun/Turn . , Stun/Turn . , - NAT.


3. RTCDataChannel


RTCDataChannel, .


API . , 4 ( , ).


Flash


Flash . ( - ), Flash, , WebRTC.


, WebRTC , . , , .


, WebRTC Flash. , Flash.



WebRTC — — TCP UDP.


TCP , : , . . , Full HD .


UDP: . : . - .


. WebRTC , , , .


WebRTC


, WebRTC — - . . , Skype .


?


WebRTC , . , , .


WebRTC


Google Chrome , WebRTC. : , , , Stun/Turn.


:


, WebRTC. . — 16 ( 15 ).


— 15 .


- , , -. - Wowza, . - - Amazon, . , , — , .


FFmpeg — , .


We needed to find a solution to the problem of displaying video streams without using third-party systems. We decided to use WebRTC technology, and this turned out to be an ideal solution for streaming video through a browser.


Conclusion


We still do not have much experience in applying this technology, so I will be grateful if you share your cases from practice and cool sources for a more in-depth study.


All Articles