- Home /
Question by
awkwardstreamer · Mar 27, 2021 at 10:00 PM ·
inputsoundmicrophone
Detecting sound from mic? for stealth with audio detection
i see alot about capturing audio from the mic, but im looking for a way to simply check the decibel levels. If So in my very un educated brain it would look something like this.
private float micVol;
private bool Detectable;
void Update()
{
micVol = (input for mic levels)
if (micVol <= 2.0f )detectable = false;
if (micVol >= 2.1f )detectable = true;
}
but im probably way off, any help would amazing thank you
Comment
Your answer
![](https://koobas.hobune.stream/wayback/20220613031407im_/https://answers.unity.com/themes/thub/images/avi.jpg)