LH-265-enable-audio-in-mediasoup #16
@ -20620,16 +20620,17 @@ const createSendTransport = () => {
|
||||
console.log('[createSendTransport');
|
||||
// see server's socket.on('createWebRtcTransport', sender?, ...)
|
||||
// this is a call from Producer, so sender = true
|
||||
socket.emit('createWebRtcTransport', { sender: true, callId }, ({ params }) => {
|
||||
socket.emit('createWebRtcTransport', { sender: true, callId }, (value) => {
|
||||
|
||||
console.log(`[createWebRtcTransport] value: ${value}`);
|
||||
|
||||
const params = value;
|
||||
// The server sends back params needed
|
||||
// to create Send Transport on the client side
|
||||
if (params.error) {
|
||||
console.log(params.error)
|
||||
return
|
||||
}
|
||||
|
||||
console.log('[createWebRtcTransport] params', params)
|
||||
|
||||
// creates a new WebRTC Transport to send media
|
||||
// based on the server's producer transport params
|
||||
// https://mediasoup.org/documentation/v3/mediasoup-client/api/#TransportOptions
|
||||
|
@ -262,16 +262,17 @@ const createSendTransport = () => {
|
||||
console.log('[createSendTransport');
|
||||
// see server's socket.on('createWebRtcTransport', sender?, ...)
|
||||
// this is a call from Producer, so sender = true
|
||||
socket.emit('createWebRtcTransport', { sender: true, callId }, ({ params }) => {
|
||||
socket.emit('createWebRtcTransport', { sender: true, callId }, (value) => {
|
||||
|
||||
console.log(`[createWebRtcTransport] value: ${value}`);
|
||||
|
||||
const params = value;
|
||||
// The server sends back params needed
|
||||
// to create Send Transport on the client side
|
||||
if (params.error) {
|
||||
console.log(params.error)
|
||||
return
|
||||
}
|
||||
|
||||
console.log('[createWebRtcTransport] params', params)
|
||||
|
||||
// creates a new WebRTC Transport to send media
|
||||
// based on the server's producer transport params
|
||||
// https://mediasoup.org/documentation/v3/mediasoup-client/api/#TransportOptions
|
||||
|
Loading…
Reference in New Issue
Block a user