Populate MediaEngine from Offer in broadcast

Use offerer PayloadType when generating answer. Before we would use the
hardcoded values, this is invalid behavior and would cause browsers to
just ignore our video when publishing.
This commit is contained in:
Ben Weitzman
2020-03-25 16:03:06 -04:00
committed by Sean DuBois
parent 25305542b9
commit 73f8db9316
4 changed files with 13 additions and 12 deletions

View File

@@ -27,7 +27,7 @@ window.createSession = isPublisher => {
.catch(log)
}).catch(log)
} else {
pc.addTransceiver('video', {'direction': 'recvonly'})
pc.addTransceiver('video')
pc.createOffer()
.then(d => pc.setLocalDescription(d))
.catch(log)