Open mohaselim opened 10 years ago
and BTW am using this source code in the URL https://www.webrtc-experiment.com/video-conferencing/
If you use single-socket and store rooms on server, then you can bring a little bit more reliability for presence detection.
Video Conferencing demo has a conference.js
file. You simply need to handle Line-116:
if (isbroadcaster && channels.split('--').length > 3) {
/* broadcasting newly connected participant for video-conferencing! */
defaultSocket.send({
newParticipant: socket.channel,
userToken: self.userToken
});
}
This snippet takes following actions:
onaddstream
event is fired from 2nd or upcoming users. It'll skip this action, if onaddstream
event is fired from 1st participant.defaultSocket
object to publicly pass 2nd user's information to 1st user.onNewParticipant
function.onNewParticipant
function. This function simply uses 2nd user's userid
and makes a participation request.To sum it up:
To customize it; simply comment-out or remove block-Line 116.
Whenever a new participant gets connected; you can push his details to server. And server can check for available/active users in current room.
At Line-273 add this:
onNewParticipant: onNewParticipant
Now, you can invoke onNewParticipant
method from UI-code:
socket.on('new-user-details', function(details) {
conferenceUI.onNewParticipant(details);
});
You can add above block anywhere in index.html
file.
You can even try meeting.js which is also doing same, however using single-socket by default.
There is a rough estimation for maximum number of interconnected users is 256.
Regarding how many concurrent rooms you can open: it depends upon signaling server. If you're using nodejs with multiple clusters then you can increase such limits. If you're using services like TokBox's Rumor, then such services are heavily optimized for millions of users (as claimed). XMPP is also a scalable solution. A good post explaining some signaling misconceptions.
I have setup the Node.Js , also i have setup the NPM , and the demo working , but i want to make sure , does it support the parallel calls ?? and what is the maximum parallel calls that can run in the same time , also i have some notices and i want to ask about it
1- some time after clicking create new conference , some of that clients in the same network ofcourse , can not see the join button , although they are using the same browsers versions as the others , and sometimes they can see the join and can enter the Conference , so based on what this sometimes happened ?
2- what is the maximum number of participants per the call , because after 8 persons , i could not add anymore , or they are added but they can not see anyone except the call initiator