日韩性视频-久久久蜜桃-www中文字幕-在线中文字幕av-亚洲欧美一区二区三区四区-撸久久-香蕉视频一区-久久无码精品丰满人妻-国产高潮av-激情福利社-日韩av网址大全-国产精品久久999-日本五十路在线-性欧美在线-久久99精品波多结衣一区-男女午夜免费视频-黑人极品ⅴideos精品欧美棵-人人妻人人澡人人爽精品欧美一区-日韩一区在线看-欧美a级在线免费观看

歡迎訪問 生活随笔!

生活随笔

當前位置: 首頁 > 编程资源 > 编程问答 >内容正文

编程问答

RTCPeerConnection.onicecandidate属性

發布時間:2023/12/20 编程问答 24 豆豆
生活随笔 收集整理的這篇文章主要介紹了 RTCPeerConnection.onicecandidate属性 小編覺得挺不錯的,現在分享給大家,幫大家做個參考.

2019獨角獸企業重金招聘Python工程師標準>>>

RTCPeerConnection.onicecandidate屬性是一個EventHandler,它指定在RTCPeerConnection實例上發生icecandidate事件時要調用的函數。當本地ICE代理需要通過信令服務器向另一個對等體發送消息時,就會發生這種情況。這允許ICE代理與遠程對等體進行協商,而瀏覽器本身不需要知道關于用于信令的技術的任何細節;只需執行此方法即可使用您選擇的任何消息傳遞技術將ICE候選者發送給遠程對等體。

語法 RTCPeerConnection.onicecandidate = eventHandler;這應該被設置為您提供的函數,該函數接受表示icecandidate事件的RTCPeerConnectionIceEvent對象作為輸入。該功能應該通過信令服務器將在事件候選屬性中可以找到其SDP的ICE候選者發送給遠程對等體。 如果事件的候選資源為空,ICE收集完成。

Example

下面的示例是基于信號和視頻調用的代碼,為icecandidate事件設置一個處理程序,以將候選者發送到遠程對等體。 pc.onicecandidate = function(event) { ? if (event.candidate) { ?? ?// Send the candidate to the remote peer ? } else { ?? ?// All ICE candidates have been sent ? } }

SpecificationsEDIT

Specification

Status

Comment

WebRTC 1.0: Real-time Communication Between Browsers
The definition of 'RTCPeerConnection.onicecandidate' in that specification.

Working Draft

Initial specification.

Browser compatibilityEDIT

·???????? Desktop

?

·???????? Mobile

Feature

Chrome

Edge

Firefox (Gecko)

Internet Explorer

Opera

Safari

Basic support

(Yes)?[1]

(Yes)

18?(18) [2]

No?support

(Yes)

?

[1] Though this property is not prefixed, the interface it belongs to was until Chrome 56.

[2] Though this property is not prefixed, the?RTCPeerConnection?interface it's a member of was until Firefox 44.

?

轉載于:https://my.oschina.net/u/3053883/blog/900063

總結

以上是生活随笔為你收集整理的RTCPeerConnection.onicecandidate属性的全部內容,希望文章能夠幫你解決所遇到的問題。

如果覺得生活随笔網站內容還不錯,歡迎將生活随笔推薦給好友。