Explorar el Código

Merge branch 'master' of http://git.dayaedu.com/yonge/dy-admin-live

lex-wxl hace 3 años
padre
commit
f4c439e6b8
Se han modificado 1 ficheros con 2 adiciones y 1 borrados
  1. 2 1
      src/components/live-broadcast/runtime.ts

+ 2 - 1
src/components/live-broadcast/runtime.ts

@@ -485,7 +485,8 @@ export const getTrack = async (
   if (trackType === "microphone") {
     res = (await runtime.rtcClient?.createMicrophoneAudioTrack("RongCloudRTC", {
       micphoneId: runtime.selectedMicrophone?.deviceId,
-      sampleRate: 44100,
+      sampleRate:
+        Number(localStorage.getItem("sampleRate") || "44100") || 44100,
     })) as TrackResult;
   } else if (trackType === "microphone2") {
     res = (await runtime.rtcClient?.createMicrophoneAudioTrack("RongCloudRTC", {