<html><head>

<style type="text/css" style="display:none"><!-- p { margin-top: 0px; margin-bottom: 0px; }--></style>
</head>
<body dir="ltr" style="font-size: 10pt; color: rgb(0, 0, 0); background-color: rgb(255, 255, 255); font-family: Calibri, Arial, Helvetica, sans-serif; word-wrap: break-word; -webkit-nbsp-mode: space; line-break: after-white-space;"><div>Hi,</div><div><br></div><div>Yes, if you do a ICE restart, the local candidates stay the same. You can re-fetch them using <i>nice_agent_get_local_candidates()</i>, but they will not have changed. The goal of a ICE restart is really to reconnect to a different endpoint but while keeping your local endpoint "unchanged", which means that you can do it seamlessly without dropping anything.</div><div><br></div><div>Olivier</div><div><span style="font-size: 10pt;"><br></span></div><div><span style="font-size: 10pt;">On Mon, 2020-12-14 at 07:45 +0000, Zachary Hueras wrote:</span></div><blockquote type="cite" style="margin:0 0 0 .8ex; border-left:2px #729fcf solid;padding-left:1ex"><p></p><p style="font-family: Calibri, Arial, Helvetica, sans-serif; font-size: 13.3333px;">On my quest, I've (belatedly) RTFM. It states:<br></p><p style="font-family: Calibri, Arial, Helvetica, sans-serif; font-size: 13.3333px;"><br></p><div style="font-family: Calibri, Arial, Helvetica, sans-serif; font-size: 13.3333px;">    Note that to modify the set of local candidates, a new stream </div><div style="font-family: Calibri, Arial, Helvetica, sans-serif; font-size: 13.3333px;">    h​as to be created. For the remote party, this looks like a ICE</div><div style="font-family: Calibri, Arial, Helvetica, sans-serif; font-size: 13.3333px;">    restart as well.​<br></div><p style="font-family: Calibri, Arial, Helvetica, sans-serif; font-size: 13.3333px;"><br></p><p style="font-family: Calibri, Arial, Helvetica, sans-serif; font-size: 13.3333px;">If I understand this correctly, if I want *new* candidates, I should replace the nice stream (e.g., nice_agent_remove_stream, nice_agent_add_stream). Otherwise, I should re-signal the old candidates?<br></p><p>​<br></p><div id="Signature"><div name="divtagdefaultwrapper" style="font-family:Calibri,Arial,Helvetica,sans-serif; font-size:; margin:0"><font size="2"><span style="color:rgb(33,33,33); background-color:rgb(255,255,255)"><font>Zachary Hueras</font></span></font><div><font size="2">Principal Software Engineer<br style="color:rgb(33,33,33); background-color:rgb(255,255,255)"><span style="color:rgb(33,33,33); background-color:rgb(255,255,255)">AMD Global Telemedicine, Inc.</span><br style="color:rgb(33,33,33); background-color:rgb(255,255,255)"><span style="color:rgb(33,33,33); background-color:rgb(255,255,255)">Cell : 978-660-3812</span><br style="color:rgb(33,33,33); background-color:rgb(255,255,255)"><span style="color:rgb(33,33,33); background-color:rgb(255,255,255)">zhueras@amdtelemedicine.com</span><br style="color:rgb(33,33,33); background-color:rgb(255,255,255)"><a tabindex="0" href="http://www.amdtelemedicine.com/" target="_blank" style="background-color:rgb(255,255,255)" id="NoLP">www.amdtelemedicine.com</a><span style="color:rgb(33,33,33); background-color:rgb(255,255,255)"> | Follow us on LinkedIn</span></font></div></div></div><div dir="ltr" style="font-size:10pt; color:#000000; background-color:#FFFFFF; font-family:Calibri,Arial,Helvetica,sans-serif"><hr tabindex="-1" style="display:inline-block; width:98%"><div id="divRplyFwdMsg" dir="ltr"><font face="Calibri, sans-serif" color="#000000" style="font-size:11pt"><b>From:</b> nice <nice-bounces@lists.freedesktop.org> on behalf of Zachary Hueras <ZHueras@amdtelemedicine.com><br><b>Sent:</b> Monday, December 14, 2020 2:23 AM<br><b>To:</b> nice@lists.freedesktop.org<br><b>Subject:</b> [libnice] nice_agent_restart_stream: proper usage and local candidate gathering with gstreamer</font><div> </div></div><div><p>Hello,<br></p><p><br>I'm trying to implement ICE restarts with gstreamer's webrtcbin. The thing I can't seem to figure out is how to get libnice to gather local candidates again. Or is this not supposed to happen?<br></p><p><br></p><p>As it stands, I:</p><p><br></p><p>- successfully generate a session description with new ufrag and pwd<br></p><p>- set-local-description on webrtcbin<br></p><p>- detect the changed credentials in GstWebRTCICEStream<br></p><p><span style="font-family:Calibri,Arial,Helvetica,sans-serif; font-size:13.3333px; background-color:rgb(255,255,255)">- invoke nice_agent_set_local_credentials</span><span style="font-family:Calibri,Arial,Helvetica,sans-serif; font-size:13.3333px; background-color:rgb(255,255,255)">​</span><br></p><p>- invoke nice_agent_restart_stream<br></p><p>- incidentally invoke nice_agent_gather_candidates (again)<br></p><p><br></p><p>However, no candidates appear to be added after this point. Is there something I'm missing?<br></p><p><br></p><p>When I connect this to a simple-peer based WebRTC application, and restart a successful connection, only the simple-peer side sends new candidates, and the connection eventually progresses to "disconnected" and ultimately "failed". <span style="font-size:10pt">I'm not sure if I'm just missing something from the gstreamer side, or if libnice is supposed to provide new candidates after a restart.</span></p><p><span style="font-size:10pt"><br></span></p><p><span style="font-size:10pt">Any and all guidance is welcome.​</span></p><p><br></p><div id="Signature"><div name="divtagdefaultwrapper" style="font-family:Calibri,Arial,Helvetica,sans-serif; font-size:; margin:0"><font size="2"><span style="color:rgb(33,33,33); background-color:rgb(255,255,255)"><font>Zachary Hueras</font></span></font><div><font size="2">Principal Software Engineer<br style="color:rgb(33,33,33); background-color:rgb(255,255,255)"><span style="color:rgb(33,33,33); background-color:rgb(255,255,255)">AMD Global Telemedicine, Inc.</span><br style="color:rgb(33,33,33); background-color:rgb(255,255,255)"><span style="color:rgb(33,33,33); background-color:rgb(255,255,255)">Cell : 978-660-3812</span><br style="color:rgb(33,33,33); background-color:rgb(255,255,255)"><span style="color:rgb(33,33,33); background-color:rgb(255,255,255)">zhueras@amdtelemedicine.com</span><br style="color:rgb(33,33,33); background-color:rgb(255,255,255)"><a tabindex="0" href="http://www.amdtelemedicine.com/" target="_blank" id="NoLP" style="background-color:rgb(255,255,255)">www.amdtelemedicine.com</a><span style="color:rgb(33,33,33); background-color:rgb(255,255,255)"> | Follow us on LinkedIn</span></font></div></div></div></div></div><div>_______________________________________________<br></div><div>nice mailing list<br></div><div><a href="mailto:nice@lists.freedesktop.org">nice@lists.freedesktop.org</a><br></div><div><a href="https://lists.freedesktop.org/mailman/listinfo/nice">https://lists.freedesktop.org/mailman/listinfo/nice</a><br></div></blockquote><div><br></div><div><span><pre>-- <br></pre><div data-evo-paragraph="" class="">Olivier Crête</div><div data-evo-paragraph="" class=""><a href="mailto:olivier.crete@collabora.com">olivier.crete@collabora.com</a></div><div data-evo-paragraph="" class=""><br></div></span></div></body></html>