[英]Should I wait for RTCPeerConnection.setRemoteDescription() & RTCPeerConnection.addIceCandidate() Promises to settle?
RTCPeerConnection.setRemoteDescription() returns a Promise that resolves once the value of the connection's remoteDescription is successfully changed. RTCPeerConnection.setRemoteDescription()返回一个 Promise,一旦连接的 remoteDescription 的值成功更改,它就会解析。 Do I need to wait for this Promise to resolve successfully before calling RTCPeerConnection.addIceCandidate() ?在调用RTCPeerConnection.addIceCandidate()之前,我是否需要等待此 Promise 成功解析?
Furthermore RTCPeerConnection.addIceCandidate()
returns a Promise which is fulfilled when the candidate has been successfully added to the remote peer's description by the ICE agent.此外, RTCPeerConnection.addIceCandidate()
返回一个 Promise,当 ICE 代理成功地将候选者添加到远程对等方的描述时,该承诺就会被实现。 Should I wait for this Promise to resolve successfully before adding the next available candidate via RTCPeerConnection.addIceCandidate()
or can IceCandidates be added in parallel?在通过RTCPeerConnection.addIceCandidate()
添加下一个可用的候选之前,我应该等待这个 Promise 成功解析还是可以并行添加 IceCandidates?
这是没有必要的,见的操作链的描述在本说明书中这保证了在顺序执行。
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.