How does WebRTC handle many-to-many connections?

前端 未结 5 2016
南旧
南旧 2021-02-08 01:45

if I am in a room with other 7 users, I am wondering if WebRTC force every user to establish a connection to each one of other participants.

Obviously it would consume s

5条回答
  •  长情又很酷
    2021-02-08 02:08

    You are right that bandwidth adaption between peers is an issue.

    A TURN server does not solve this issue since all it does is provide a stable endpoint, typically for people behind very restrictive NAT setups.

    The solution to this issue lies in scalable video codecs. These video codecs are specifically designed to solve the multi-way video conferencing problem. H.264/SVC is one such scalable codec and it is currently used by Google+ Hangouts. VP8 also has temporal and spatial scalability and is used in WebRTC.

    The scalable video codecs are designed so that parts of the stream, typically individual UDP packets, can be removed from the stream while preserving the ability to decode the video at a lower quality. At least three types of scalabilities are used:

    • Temporal, in which the frames-per-second is reduced.
    • Spatial, where the number of pixels is reduced.
    • Quality, where the color resolutios is reduced.

    If you implement a video conferencing server, you can go into the VP8 stream at a lower level than the WebRTC-level, do the necessary changes to each video stream, and solve the bandwidth adaption issue.

提交回复
热议问题