camdata event code should be changed
hoon720823 opened this issue · 2 comments
this.on('camdata', (data) => { for (let i in this.server.clients) { let client = this.server.clients[i] if(client.readyState === WebSocket.OPEN) { client.send(data) } } })
javascript Set iteration
this.on('camdata', (data) => { for (let client of this.server.clients) { if(client.readyState === WebSocket.OPEN) { client.send(data) } } })
Hi,
Sorry for the delay.
A pull request is welcome.
after change to the hoon720823's suggestion , everything works.
thanks hoon.
https://imgur.com/WBYDwx5
the proof of how it looks like.
Wifsimster,
i really appreciate for what you did, i am actually looking for a rtsp to webrtc live-streaming solution .
your es6 version is extremely easy to understand the flow......let me have some hope to get it done.
if you add hoon's suggestion , things will works perfectly.....
( maybe user might need create a views for themself, but the things is working. )