Record a device out

Next Topic
 
classic Classic list List threaded Threaded
7 messages Options
Reply | Threaded
Open this post in threaded view
|

Record a device out

msavigo1
Hello,

I am able to record the input of a device using:

uos_AddFromDevIn(PlayerIndex, DEVICE, -1, -1, -1, -1, -1, -1);

In this case the DEVICE = 7 (default).
This device is for input and output.
The input is my microphone.
The output is my speaker.

I can't find a method like AddFromDevOut to record all output of my speaker.
Is it possible to record the output of a device?
Reply | Threaded
Open this post in threaded view
|

Re: Record a device out

fredvs
Administrator
> Is it possible to record the output of a device?

Huh, that's the question I feared...

It is not easy because of synchronization problems.
It is on the TODO list.

Maybe you can try with a custom DSP (like you use for recording blocks).

Fre;D
Reply | Threaded
Open this post in threaded view
|

Re: Record a device out

fredvs
Administrator
This post was updated on .
In reply to this post by msavigo1
What OS are you using ?

If you use Windows XP, there is a "record what you hear" parameter for input.
If you use that input you will record all what goes to your sound-card.

IMHO with Windows 7, 8, 10 it is not possible "out of the box".
Sure it must exist tips but I do not know this.

For Linux, with Pulse-audio you may create a virtual input and assign the output of the sound card.
In my Linux Manjaro, I have to select :

"Monitor of Audio Interne Stereo Analogique."



That way, the input is the output of the sound card (and not the microphone or aux)

Fre;D

Reply | Threaded
Open this post in threaded view
|

Re: Record a device out

Dibo
Any progress here? I'm also starting app which need to "record what you hear". I have two problems:
1. I'm linux user and here I solved this with "Monitor of Internal Audio Stereo Analog" but I have to do it manually each time when I start recording :/ . Pavucontrol doesn't remember it
2. Didn't test windows yet, but here it is called WASAPI and works on all versions. Seems that PortAudio has support for it so it will also work with UOS?
Reply | Threaded
Open this post in threaded view
|

Re: Record a device out

fredvs
Administrator
Hello Dibo.

> Seems that PortAudio has support for it so it will also work with UOS?

If PortAudio support it, uos will do it also!

Do you have a idea how Portaudio does it, what method does it use?

Thanks.

Fre;D
Reply | Threaded
Open this post in threaded view
|

Re: Record a device out

fredvs
Administrator
In reply to this post by Dibo
Re-hello Dibo.

> Pavucontrol doesn't remember it

https://askubuntu.com/questions/166953/how-to-make-pavucontrol-changes-permanent

Maybe using pavucontrol for Linux and find something for Windows and then add it in uos ?

Fre;D
Reply | Threaded
Open this post in threaded view
|

Re: Record a device out

Dibo
Here someone mentioning about portaudio hosts:
https://forum.lazarus.freepascal.org/index.php/topic,17521.msg113061.html#msg113061

  PaHostApiTypeId =(paInDevelopment := 0,
    paDirectSound := 1,    
    paMME := 2,
    paASIO := 3,
    paSoundManager := 4,
    paCoreAudio := 5,
    paOSS := 7,
    paALSA := 8,
    paAL := 9,
    paBeOS := 10,
    paWDMKS := 11,
    paJACK := 12,
    paWASAPI := 13,
    paAudioScienceHPI := 14
  );

As you can see there is paWASAPI so maybe it is only a matther of set that type on windows and it will work automatically with uos?