Update server
This commit is contained in:
parent
6e74083733
commit
950298c4f6
@ -20688,6 +20688,19 @@ const connectSendTransport = async () => {
|
|||||||
// https://mediasoup.org/documentation/v3/mediasoup-client/api/#transport-produce
|
// https://mediasoup.org/documentation/v3/mediasoup-client/api/#transport-produce
|
||||||
// this action will trigger the 'connect' and 'produce' events above
|
// this action will trigger the 'connect' and 'produce' events above
|
||||||
|
|
||||||
|
producerVideo = await producerTransport.produce(videoParams)
|
||||||
|
console.log('producerVideo', producerVideo);
|
||||||
|
producerVideo.on('trackended', () => {
|
||||||
|
console.log('track ended')
|
||||||
|
// close video track
|
||||||
|
})
|
||||||
|
|
||||||
|
producerVideo.on('transportclose', () => {
|
||||||
|
console.log('transport ended')
|
||||||
|
// close video track
|
||||||
|
})
|
||||||
|
|
||||||
|
|
||||||
producerAudio = await producerTransport.produce(audioParams)
|
producerAudio = await producerTransport.produce(audioParams)
|
||||||
console.log('producerAudio', producerAudio);
|
console.log('producerAudio', producerAudio);
|
||||||
producerAudio.on('trackended', () => {
|
producerAudio.on('trackended', () => {
|
||||||
@ -20702,17 +20715,6 @@ const connectSendTransport = async () => {
|
|||||||
|
|
||||||
|
|
||||||
|
|
||||||
producerVideo = await producerTransport.produce(videoParams)
|
|
||||||
console.log('producerVideo', producerVideo);
|
|
||||||
producerVideo.on('trackended', () => {
|
|
||||||
console.log('track ended')
|
|
||||||
// close video track
|
|
||||||
})
|
|
||||||
|
|
||||||
producerVideo.on('transportclose', () => {
|
|
||||||
console.log('transport ended')
|
|
||||||
// close video track
|
|
||||||
})
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
@ -330,6 +330,19 @@ const connectSendTransport = async () => {
|
|||||||
// https://mediasoup.org/documentation/v3/mediasoup-client/api/#transport-produce
|
// https://mediasoup.org/documentation/v3/mediasoup-client/api/#transport-produce
|
||||||
// this action will trigger the 'connect' and 'produce' events above
|
// this action will trigger the 'connect' and 'produce' events above
|
||||||
|
|
||||||
|
producerVideo = await producerTransport.produce(videoParams)
|
||||||
|
console.log('producerVideo', producerVideo);
|
||||||
|
producerVideo.on('trackended', () => {
|
||||||
|
console.log('track ended')
|
||||||
|
// close video track
|
||||||
|
})
|
||||||
|
|
||||||
|
producerVideo.on('transportclose', () => {
|
||||||
|
console.log('transport ended')
|
||||||
|
// close video track
|
||||||
|
})
|
||||||
|
|
||||||
|
|
||||||
producerAudio = await producerTransport.produce(audioParams)
|
producerAudio = await producerTransport.produce(audioParams)
|
||||||
console.log('producerAudio', producerAudio);
|
console.log('producerAudio', producerAudio);
|
||||||
producerAudio.on('trackended', () => {
|
producerAudio.on('trackended', () => {
|
||||||
@ -344,17 +357,6 @@ const connectSendTransport = async () => {
|
|||||||
|
|
||||||
|
|
||||||
|
|
||||||
producerVideo = await producerTransport.produce(videoParams)
|
|
||||||
console.log('producerVideo', producerVideo);
|
|
||||||
producerVideo.on('trackended', () => {
|
|
||||||
console.log('track ended')
|
|
||||||
// close video track
|
|
||||||
})
|
|
||||||
|
|
||||||
producerVideo.on('transportclose', () => {
|
|
||||||
console.log('transport ended')
|
|
||||||
// close video track
|
|
||||||
})
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user