#WebRTC - screen sharing feature not working as expected

1 messages · Page 1 of 1 (latest)

nova solarBOT
#

@solid thorn

Hakeron Uploaded Some Code

I am building a streaming web application using WebRTC and Web Sockets to handle communication. I managed to implement everything, but I am currently struggling with a screen sharing functionality.
Currently, the screen sharing feature works and other peers in the room can see the shared screen content correctly. But after toggling screen sharing for the first time, I can't turn on or off my microphone. I also tried putting some logs and the listener for the mute-audio-btn works fine, I think the problem is that I lose the reference to the audioTrack.


Uploaded these files to a Gist
solid thorn
#

Also.. the error thrown by clicking on the mute-audio-btn after enabling screen sharing is the following:

"Cannot read properties of undefined (reading 'enabled')".

worldly trellisBOT
#

ℹ️ @solid thorn this post has been closed. Feel free to reopen it if you have any further questions.