sound – PulseAudio: How to output the audio from PulseAudio to a wave file
I’m using PulseAudio to do some tests on our Call Center platform on Linux.
I’m using command python -m playwright codegen 'https://my-call-center/site/login' -o test.py
to open an chrome GUI for testing call.
I have run PulseAudio with profile as below (cat ~/.config/pulse/default.pa
):
.include /etc/pulse/default.pa
load-module module-pipe-sink file=/tmp/fifo.out
load-module module-pipe-source channels=2 file=/tmp/fifo.in
set-default-source fifo_input
set-default-sink fifo_output
This will create pipe file /tmp/fifo.out and when I call on the website, the chrome will use /tmp/fifo.out as output (as a speaker). I use cat /tmp/fifo.out | tee output.out
to got the audio content.
But the output.out file is too large and couldn’t be listen. After I removed all the \x00\x00
in this file (with python), I could be able to hear some words in the file but still not well. (I use Audacity APP to import the file to listen.)
So, I want to know how can I correctly output the audio from PulseAudio into a wave format file.
pulseaudio version 15.99.1
Read more here: Source link