WebRTC-Experiment icon indicating copy to clipboard operation
WebRTC-Experiment copied to clipboard

custom socket

Open adilfaiz001 opened this issue 4 years ago • 0 comments

Hi, I am using RTCMulticonnection opened socket for chat service while audio conferencing, like when user join in room and connection stablished via signaling server, I add few socket function to add chat service in RTCMulticonnection file, will it affect connection or will it make connection to lose in between.

   ` connection.sendMessage = function(messagePacket, roomid, callback) {
        connection.socket.emit('message', messagePacket, roomid);
        connection.socket.on('send-message', () => {
            callback();
        });
    }

    connection.onReceiveMessage = function(callabck) {
        connection.socket.on('receive-message',(messagePacket) => {
            callabck(messagePacket);
        });
    }

`

@muaz-khan

adilfaiz001 avatar Jul 31 '19 11:07 adilfaiz001