14

I'm trying to record a phone call made with Google Voice Chat using Audacity. I'm running Linux Mint 17.

In this example, I'm making an outbound phone call from my computer to a person on a normal phone. I will refer to audio travelling from my computer to the phone as outbound audio, and audio travelling from the phone to my computer as inbound audio.

I followed the section for PulseAudio in this tutorial. This almost works the way I want it to, but not perfectly because I can only record either outbound audio, or inbound audio, but not both simultaneously.

screenshot

In the PulseAudio Volume Control, there are 3 options available (see screenshot). They are:

  1. Monitor of GF108 High Definition Audio Controller Digital Stereo (HDMI)
  2. Monitor of Built-in Audio Analog Stereo
  3. Built-in Audio Analog Stereo.

If I choose option 1, no sound is recorded in Audacity. If I choose option 2, only inbound audio is recorded. If I choose option 3, only outbound audio is recorded.

This means that using Audacity, I can only record one side of the conversation at any given time. I'm trying to figure out how to record both sides of the conversation simultaneously.

The closest I have come to achieving my goal is to manually toggle the "ALSA Capture from" option between option 2 and option 3 during a conversation. But this is tedious and does not allow interruptions in the conversation to be recorded.

Is there a way to record both the "Built-in Audio Analog Stereo" and the "Monitor of Built-in Audio Analog Stereo" at the same time? If so, how?

axiopisty
  • 296

4 Answers4

15

By creating a virtual sound card and looping back both the real sound card's input and output into it, it's possible to record both, without hearing yourself speak.

The following is adapted from this solution to a more complex problem.

First create a sink to be used as a virtual sound card, and add two loopbacks into it, which will be used to route the real sound card's input and output.

pactl load-module module-null-sink sink_name=Virtual1 sink_properties=device.description=Virtual-Sound-Card
pactl load-module module-loopback sink=Virtual1
pactl load-module module-loopback sink=Virtual1

Next, open pavucontrol, navigate to the "Recording" tab and set the real sound card's input and output as the sources for each loopback, which in the OP's case would be "Built-in Audio Analog Stereo" and "Monitor of Built-in Audio Analog Stereo".

Example of Recording tab configuration

Finally, navigate pavucontrol's "Input Devices" tab and set the monitor of the virtual sound card as the fallback device (by clicking the button with a check mark in a green circle to the right of "Monitor of Virtual-Sound-Card").

Example of virtual sound card set as fallback

If you're using the ALSA plug-in, as depicted in the OP's screenshot, set "ALSA Capture from" to "Monitor of Virtual-Sound-Card" in the "Recording" tab.

Now, audacity should pick up the virtual sound card's input, which contains both the real sound card's input and output, while your speakers/headphones will still be reproducing the real sound card's output only, so you won't be hearing your microphone.

viam0Zah
  • 2,086
upuoth
  • 151
9

You can try to enable "the stereo mixer" using pactl to load module-loopback

The idea is to mix the source stream from your microphone to the speakers. With a correct set for volume and reciprocal position of microphone and speakers you should be able to avoid the Larson effect. :-)

Load the module-loopback

 pactl load-module module-loopback

and after change the recording device (Alsa capture from) from the built-in to the monitor one.
[You find in Volume control->Recording->Alsa plug in / Alsa capture from].

There's a short video for Ubuntu system on youtube

Notes:

module-loopback
allows one to route audio from a source directly back to a sink.

Hastur
  • 19,483
  • 9
  • 55
  • 99
5

After trying all the hacks and tools (Audacity, audio recorder etc ). Finally found this Open Broadcaster Software (OBS), which is super easy and just does the job.

In Settings → Audio, I was able to select:

. Audio output (Either desktop or earphone or bluetooth also possible)
. Mic - (Desktop | earphone)

For Source, I selected Screen Capture (XSHM) to capture the entire desktop or can keep it blank as well.

To install:

sudo add-apt-repository ppa:obsproject/obs-studio && sudo apt install obs-studio

bak2trak
  • 151
1

Note: Okay this answer might seem like a cop-out but it works and its great software, especially if you want to record your speaker output and microphone output at the same time. Or if you also need to video record your computer screen on top of the audio as well.

Anyways, been pulling my hair out forever googling for an answer that is simple to use and provides everything I need.

Just like the other user here, install and use Open Broadcaster Software (OBS). Seriously, that's it. Don't use the installation instructions from people here since it might be outdated. Googling "install OBS" or similar should bring up recent installation instructions tailored to your machine.

Just record with OBS and it will just make a video with your audio in it. If you only want to record audio, just record without a video source and it will make a blank video with your recording. If you want to record only speaker output and not the mic, simply mute the microphone with a press of a button. Intuitive.

(Note this gives you a video file. It doesn't bother me but if you need an audio file like an mp3 you would have to figure out how to convert the video file you made into an audio file (I don't know how to do that, but there are plenty of resources out there that tell you).)