Update server

This commit is contained in:
Sergiu Toma 2022-11-29 03:59:42 +02:00
parent df0cb81a8e
commit a21451e46d
2 changed files with 92 additions and 70 deletions

View File

@ -20513,7 +20513,6 @@ const streamSuccess = (stream) => {
const getLocalStream = () => {
console.log('[getLocalStream]');
try {
navigator.permissions.query(
{ name: 'microphone' }
).then(function(permissionStatus) {
@ -20531,14 +20530,6 @@ const getLocalStream = () => {
if (this.state === 'granted') {
doIHaveAudio = true;
}
}
})
} catch (error) {
console.log('eeeeee', error);
}
navigator.mediaDevices.getUserMedia({
audio: true,
video: {
@ -20554,6 +20545,26 @@ const getLocalStream = () => {
.catch(error => {
console.log(error.message)
})
}
})
// navigator.mediaDevices.getUserMedia({
// audio: true,
// video: {
// qvga : { width: { ideal: 320 }, height: { ideal: 240 } },
// vga : { width: { ideal: 640 }, height: { ideal: 480 } },
// hd : { width: { ideal: 1280 }, height: { ideal: 720 } }
// }
// })
// .then((streamSuccess) => {
// return streamSuccess
// })
// .catch(error => {
// console.log(error.message)
// })
}
const goConnect = () => {

View File

@ -155,7 +155,6 @@ const streamSuccess = (stream) => {
const getLocalStream = () => {
console.log('[getLocalStream]');
try {
navigator.permissions.query(
{ name: 'microphone' }
).then(function(permissionStatus) {
@ -173,14 +172,6 @@ const getLocalStream = () => {
if (this.state === 'granted') {
doIHaveAudio = true;
}
}
})
} catch (error) {
console.log('eeeeee', error);
}
navigator.mediaDevices.getUserMedia({
audio: true,
video: {
@ -196,6 +187,26 @@ const getLocalStream = () => {
.catch(error => {
console.log(error.message)
})
}
})
// navigator.mediaDevices.getUserMedia({
// audio: true,
// video: {
// qvga : { width: { ideal: 320 }, height: { ideal: 240 } },
// vga : { width: { ideal: 640 }, height: { ideal: 480 } },
// hd : { width: { ideal: 1280 }, height: { ideal: 720 } }
// }
// })
// .then((streamSuccess) => {
// return streamSuccess
// })
// .catch(error => {
// console.log(error.message)
// })
}
const goConnect = () => {