Created
July 2, 2018 14:43
-
-
Save donamkhanh/44b843051b25078a6c7bcd307cb09901 to your computer and use it in GitHub Desktop.
Fix bug show black video on Safari when using kurento-utils.js
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
const isSafari = /^((?!chrome|android).)*safari/i.test(navigator.userAgent); | |
if (isSafari) { | |
if (constraints.offerToReceiveAudio) { | |
pc.addTransceiver('audio'); | |
} | |
if (constraints.offerToReceiveVideo) { | |
pc.addTransceiver('video'); | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment