LINXD-2270-p2 #19

Closed
sergiu wants to merge 58 commits from LINXD-2270-p2 into develop
3 changed files with 17 additions and 27 deletions
Showing only changes of commit 2ada7b66db - Show all commits

View File

@ -20385,22 +20385,17 @@ let consumerVideo // local consumer video(consumer not transport)
let consumerAudio // local consumer audio(consumer not transport)
const remoteSoundControl = document.getElementById('remoteSoundControl');
remoteSoundControl.defaultMuted = true
remoteSoundControl.addEventListener('click', function handleClick() {
console.log('remoteSoundControl.textContent', remoteSoundControl.textContent);
remoteSoundControl.textContent = 'Button clicked';
// let soundElementIcon = document.getElementById('sound')
// if (isSoundOn) {
// soundElementIcon.src = noSoundImage
// soundElementIcon.alt = 'no-sound-image'
// isSoundOn = false
// vid.muted = !isSoundOn
// } else {
// soundElementIcon.src = soundImage
// soundElementIcon.alt = 'sound-image'
// isSoundOn = true
// vid.muted = !isSoundOn
// }
if (remoteSoundControl.textContent === 'Unmute') {
vid.muted = false
remoteSoundControl.textContent = 'Mute';
} else {
vid.muted = true
remoteSoundControl.textContent = 'Unmute';
}
});
// https://mediasoup.org/documentation/v3/mediasoup-client/api/#ProducerOptions

View File

@ -48,7 +48,7 @@
</td>
<td>
<div id="sharedBtns">
<video id="remoteVideo" autoplay class="video" ></video>
<video id="remoteVideo" autoplay class="video" muted></video>
</div>
</td>
</tr>

View File

@ -27,22 +27,17 @@ let consumerVideo // local consumer video(consumer not transport)
let consumerAudio // local consumer audio(consumer not transport)
const remoteSoundControl = document.getElementById('remoteSoundControl');
remoteSoundControl.defaultMuted = true
remoteSoundControl.addEventListener('click', function handleClick() {
console.log('remoteSoundControl.textContent', remoteSoundControl.textContent);
remoteSoundControl.textContent = 'Button clicked';
// let soundElementIcon = document.getElementById('sound')
// if (isSoundOn) {
// soundElementIcon.src = noSoundImage
// soundElementIcon.alt = 'no-sound-image'
// isSoundOn = false
// vid.muted = !isSoundOn
// } else {
// soundElementIcon.src = soundImage
// soundElementIcon.alt = 'sound-image'
// isSoundOn = true
// vid.muted = !isSoundOn
// }
if (remoteSoundControl.textContent === 'Unmute') {
vid.muted = false
remoteSoundControl.textContent = 'Mute';
} else {
vid.muted = true
remoteSoundControl.textContent = 'Unmute';
}
});
// https://mediasoup.org/documentation/v3/mediasoup-client/api/#ProducerOptions