aboutsummaryrefslogtreecommitdiff
path: root/.scripts
diff options
context:
space:
mode:
authorVidhu Kant Sharma <vidhukant@vidhukant.com>2023-10-15 11:46:50 +0530
committerVidhu Kant Sharma <vidhukant@vidhukant.com>2023-10-15 11:46:50 +0530
commit1b199983fbcc6ff7f17d300235158c9e9f44d25b (patch)
tree63271cd4d0ef2fb355dd9cd93a0a2f442e0fc20e /.scripts
parent4eb5ec205670c05b4ece734ba5780d6e0f5107de (diff)
adding virtual mic script
Diffstat (limited to '.scripts')
-rw-r--r--.scripts/virtual_mic.sh10
1 files changed, 10 insertions, 0 deletions
diff --git a/.scripts/virtual_mic.sh b/.scripts/virtual_mic.sh
new file mode 100644
index 0000000..20d791d
--- /dev/null
+++ b/.scripts/virtual_mic.sh
@@ -0,0 +1,10 @@
+#!/bin/sh
+
+# create virtual sinks
+pactl load-module module-null-sink sink_name=VirtualSpeaker
+pactl load-module module-null-sink media.class=Audio/Duplex sink_name=VirtualMicrophone
+
+# create loopbacks
+pactl load-module module-loopback source="VirtualSpeaker.monitor" sink="$(pactl get-default-sink)"
+pactl load-module module-loopback source="$(pactl get-default-source)" sink="VirtualMicrophone"
+pactl load-module module-loopback source="VirtualSpeaker.monitor" sink="VirtualMicrophone"