Noisegate V2 #8

Merged
logan merged 47 commits from NoiseGateV2 into master 2022-03-28 00:13:08 -04:00
Showing only changes of commit 48f6812f68 - Show all commits

View File

@@ -62,6 +62,7 @@ class NoiseGate(threading.Thread):
def run(self) -> None:
while self.voice_connection.is_connected():
print(f"Raw data: '{self.PCMStream_Instance.read(16)}'")
print(f"Volume: '{float(20 * audioop.rms(self.PCMStream_Instance.read(16), 2))}'")
if float(20 * audioop.rms(self.PCMStream_Instance.read(16), 2)) >= 5:
# Play the stream