Audio recorder is Choosing wrong source with pulseaudio
Bug #1243442 reported by
poe
This bug affects 1 person
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
Audio Recorder |
Fix Released
|
High
|
moma |
Bug Description
I am using kubuntu 13.04. And Pulseaudio is installed. When choosing a playback device, and recording, and going to pavucontrol,
the Audio recorder is taking input from "Built in Audio Analog Stereo"(screenshot 1- not recording) and recording nothing, when it should choose "Monitor of built in Audio Analog stereo"(screenshot 2-recording ) and when i change to that its recording. I am including two screenshots here..
Screenshot 1 = http://
Screenshot 2 = http://
Changed in audio-recorder: | |
assignee: | nobody → moma (osmoma) |
Changed in audio-recorder: | |
status: | Triaged → Fix Released |
To post a comment you must log in.
Hi, bildr.no/ view/1305665
Are the two pictures same?
Please send also picture of the main window when you open the device-list.
Alá: http://
An interesting question.
There is always a possibility that the program picks a Sink(output) device-id instead of Source(input) device. We have to investigate the source-code and test a Gstreamer-pipeline from a command line.
The recorder uses PulseAudio to get a list of "Source" input-devices. Source devices can either be microphones (webcams, mic input on a soundcard, etc.) or so-called ".monitor" devices that point to a real audio-card.
Please study src/pulseaudio.c. bazaar. launchpad. net/~osmoma/ audio-recorder/ trunk/view/ head:/src/ pulseaudio. c
http://
The function pa_get_ device_ lists_ext( ) loads IDs and Description of both Source(input) and Sink(output) devices. The program uses the Sink-list to read the audio-cards' real name/description. Then the Sink-list is never read or used again. device_ lists() and its description.
Please see void pa_get_
Now, let's test the devices and recording from the command line?
0) First, take a listing of available "Source" devices with the pactl command.
pactl comes from the "pulseaudio-utils" package, so apt-get it first.
$ pactl list | grep -A2 'Source #'
Notice that the "Source" word may have been translated to your language (depending on the language settings), so check the listing with "pactl list" first.
Equally, you can also list the "Sink" devices, though we do not need them here.
$ pactl list | grep -A2 'Sink #'
1) Now you should have the IDs and Names/Descriptions of all Source-devices.
This is the device listing from my computer. I show only the device names/ids here. Ok?
$ pactl list | grep -A2 'Source #' pci-0000_ 00_1b.0. analog- stereo. monitor
Name: alsa_output.
(sound card1 we can record from / we can tap its output).
Name: alsa_input. pci-0000_ 00_1b.0. analog- stereo
(3.5mm mic input on a sound card1).
Name: alsa_output. pci-0000_ 06_01.0. analog- stereo. monitor
(sound card2 we can record from / we can tap its output).
Name: alsa_input. pci-0000_ 06_01.0. analog- stereo
(mic input on a sound card2).
Name: alsa_input. usb-Creative_ Ltd._VF0610_ WebCam< snip>.analog- mono
(webcam with microphone).
Some device names end with a ".monitor" label. These IDs can tap (record) audio from a real audio-card. Eg. in my case its Sink (output device) is "alsa_output. pci-0000_ 00_1b.0. analog- stereo" (only shown in the Sink-listing). This is the real sound-card with loudspeakers. We CANNOT record from it. BUT we can record from its ".monitor" device that is "alsa_output. pci-0000_ 00_1b.0. analog- stereo. monitor" . Ok?
2) Now, test the recording with various device names (in a terminal window).
Create a GStreamer pipeline for recording. Take the device id for the above listing and put it into the device="xxxx" argument. Like this:
$ gst-launch-1.0 pulsesrc device= "alsa_output. pci-0000_ 06_01.0. analog- stereo. monitor" ! queue ! audioconvert ! vorbisenc ! oggmux ! filesink location=test.oga
Play some music or speak to the microphone, etc! 0-tools" package. Sudo apt-get it.
Notice: the gst-launch command comes from "gstreamer1.
Here the filesink location= "test.oga" , so it outp...