You are not logged in.

#1 2011-11-15 06:02:14

qubodup
Member
Registered: 2008-01-19
Posts: 66

ALSA: Recording Playback Audio with HDA-Intel

Hello,

My alsa-info. I only use analog output.

Alsamixer looks like this: http://ompldr.org/vYmE4Mw http://ompldr.org/vYmE4NA

I would like to record audio which is being played back on my computer. I need it for recording of gameplay videos. I want to use only ALSA for this and want to avoid PulseAudio, if possible.

Recording audio playing on the computer with Alsamixer tells me that I should use the "Mix" control of the Capture device. However, HDA-Intel appears not to provide such a control.

Does anyone know how I can create such control? Or perhaps I can somehow fake a capture device, that in fact simply plays back the hw:0,0 playback device?

Perhaps the snd-aloop module is a solution.

I will now start reading about .asoundrc files but wanted to leave this question here, because I feel that I'm likely to fail in my search for knowledge.

Cheers

Offline

#2 2011-11-15 06:12:12

/dev/zero
Member
From: Melbourne, Australia
Registered: 2011-10-20
Posts: 1,247

Re: ALSA: Recording Playback Audio with HDA-Intel

What about icecast? As I recall, it will stream sound off your sound card to some port, which you can then record from as for any other stream.

Offline

#3 2011-11-16 03:10:59

qubodup
Member
Registered: 2008-01-19
Posts: 66

Re: ALSA: Recording Playback Audio with HDA-Intel

I can't see a straightforward way to configure icecast to do this on the Arch Wiki.

I tried alsaloop, but it blocks devices when in use. Maybe I'm doing it wrong.

alsaloop -C hw:0,0 -P hw:0,0 -t 10000

I'm not the first to have this problem (thread of 2010-05-22)
I managed to get play-to-file working but ffmpeg doesn't seem to be able to handle the raw output and I'd have to make "default" play to file, as most games don't allow to set what alsa device to use for sound.

Offline

#4 2011-11-16 13:38:15

brebs
Member
Registered: 2007-04-03
Posts: 3,742

Re: ALSA: Recording Playback Audio with HDA-Intel

I would expect that the ~/.asoundrc answer contains things like "route_policy duplicate" and "type file".

You can just redefine "default", e.g.:

pcm.!default {

The exclamation mark is there to make clear that you are *re*-defining a PCM that's already defined. Or summat like that.

Last edited by brebs (2011-11-16 13:40:53)

Offline

Board footer

Powered by FluxBB