let stream: MediaStream | null = null
try {
// 1. 请求麦克风权限并获取音频流
stream = await navigator.mediaDevices.getUserMedia({
audio: true
})
} catch (error) {
console.error(‘获取麦克风权限失败:’, error);
stream = null
return;
}
Why can’t the media volume be adjusted when running on a mobile phone? It seems that it uses the voice call volume channel instead of the media/music volume
