Do-Able! Don't send answers/offers or ice candidates. Wait for ice done event and send the sdp, then use that as offer or answer.
That's a vague answer, let me know if you need more information,
--
You received this message because you are subscribed to the Google Groups "kurento" group.
To unsubscribe from this group and stop receiving emails from it, send an email to kurento+u...@googlegroups.com.
To post to this group, send email to kur...@googlegroups.com.
Visit this group at https://groups.google.com/group/kurento.
To view this discussion on the web visit https://groups.google.com/d/msgid/kurento/731eddf1-01dc-40d5-bff8-15c950e90261%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.
You do it in the icecandidates handler. If it is not a
candidate, it must be done (I think)
Mine looks like this. I send it all to the backend and let java
figure out what to do when by 'connectionType'
function iceCandidateEventHandler(event) {
time = new Date();
if(! event.candidate) {
console.log("[" + time.toLocaleTimeString() + "] " +
"iceCandidateEventHandler done"+":"+cid);
myPeerConnection.addIceCandidate(event.candidate);
myMessage = {
'mydetv':mydetv,
verb : 'iceCandidatesDone',
connectionType: connectionType,
role: role,
cid: cid,
sdp: myPeerConnection.localDescription
};
sendMessage(myMessage);
return;
}
else {
console.log("[" + time.toLocaleTimeString() + "] " +
"iceCandidateEventHandler candidate:"+event.candidate);
myMessage = {
'mydetv':mydetv,
verb : 'iceCandidate',
connectionType: connectionType,
role: role,
cid: cid,
candidate: event.candidate
};
sendMessage(myMessage);
}
}
To view this discussion on the web visit https://groups.google.com/d/msgid/kurento/3baf6578-8310-49a8-9a8d-6237aa562bbb%40googlegroups.com.
addIceCandidate(event.candidate);" line, if it's inside the branch where it's not a candidate? And, regardless, it should be used for ICE candidates from the remote endpoint, not the locally discovered ones, isn't it?
Does this code actually work for you?
That event is for the locally created candidates AFAIK, correct me if I am wrong. The remote candidates are sent via websockets from the other side and looks like this:
function iceCandidate(message) {
time = new Date();
myIceCandidate = message.iceCandidate;
rtcIceCandidate = new RTCIceCandidate(myIceCandidate);
myPeerConnection.addIceCandidate(rtcIceCandidate)
.catch(function(err) {
console.log("[" + time.toLocaleTimeString() + "] "
+ "iceCandidate error "+err.name+":"+err.message);
});
}
Paul
To view this discussion on the web visit https://groups.google.com/d/msgid/kurento/5af2060b-c0d8-4176-95db-0d8957dedfbf%40googlegroups.com.
--
You received this message because you are subscribed to the Google Groups "kurento" group.
To unsubscribe from this group and stop receiving emails from it, send an email to kurento+u...@googlegroups.com.
To post to this group, send email to kur...@googlegroups.com.
Visit this group at https://groups.google.com/group/kurento.
To view this discussion on the web visit https://groups.google.com/d/msgid/kurento/347cd71a-97e6-4490-af89-10741abbb00b%40googlegroups.com.