This message was deleted.
# helpdesk
s
This message was deleted.
w
I think there is a volume parameter in webrtc but I also think you need to be connected to utilize it. However flutter have several packages you could use to see if a microphone is working before joining a room. "Noise meter" and "record" both have that capability
w
I cant use either for flutter web without recording the footage 😞
w
Hmm then I guess you could give AudioContext a try... https://api.dart.dev/stable/3.1.3/dart-web_audio/dart-web_audio-library.html | https://developer.mozilla.org/en-US/docs/Web/API/AudioContext | might be a little bit more tricky thought.
w
Its strange that livekit doesent allow us to listen to trakcevents
until the track is published? Do I understand that correctly
w
In order to utilize the various event listeners I'm quite certain you need to be connected to a room otherwise it would be difficult (impossible?) for livekit to know whats happening and what listeners to trigger. But it shouldn't be impossible to write your own listeners to listen to changes on audio input but thats not something livekit offers (that im aware of) by using audioContext. Do you wanna make sure the microphone is working before entering a room?
w
Yeah im trying to make sure the mic is working
And I would like the solution to preferably work on all platforms but web is fine for now 😄
Also I tried record package but it gives same volume all the time and looks like others have the same issue as well
w
Hmm 🤔 if the record packaged is not to your liking (or not enough) then I suggest take a look at the audioContext class and Mozillas documentation on it because it looks doable. Or maybe someone from Livekit could help you with another solution.
w
I wonder how ill use the audioContext class in flutter code
w
AudioContext should be a part of dart:web_audio library according to the documentations, but as I said earlier I only looked at the documentations so you might have to do some own research on that part, or wait for a better response from Livekit.
I think the easiest solution in order to test the microphone would be to actually record something with it and then just discard the recording. You might find some other packages on pub.dev to achieve that?
w
Ah I managed to make the record package work
👍 1
d
I guess another workaround could be to connect the user to a "staging" room that's unique for every user, then use the speaker events to determine if things are working properly.