Internal audio program

NOTE. This is not what the microphone will use. I want to RECORD audio INSIDE.

I would like to write a program in C # or Java that records audio data sent to speakers on my computer. The final product will allow the user to press the “record” button, and everything that will be played at the moment will be recorded inside until the user clicks the “Stop” button, after which all collected data will be saved to an audio file, for example, wav, mp3, etc. .d.

I have a MacBook Pro that runs Windows 7 in parallel. I have access to several PCs, so I can also work on a clean Windows platform. Ideally, no matter which platform.

I have no idea where to start - the most I have ever done with music is to play a WAV file in Java. If anyone has any tips, tricks, suggestions, technological preferences for any language, etc., I would love it!

+4
source share
2 answers

What you are trying to do is very dependent on the operating system. You will need to write a program that creates a fake sound output device to which the operating system can send sounds. Instead of playing audio, you should capture the audio stream as soon as the user clicks “record” and stops capturing when the user clicks “stop”. Then you will need to encode the captured audio data into the desired audio file format (wav, mp3, etc.).

You can do what you ask, but this is not a trivial task, since you interact with the level of abstraction of the hardware audio system and sound coding.

+2
source

To point in the right direction if you are going to use C #. There is no support for the .NET Framework for this, however you can access the Windows API with .NET. A good starting point is http://www.pinvoke.net . You will also find code for each API entry in C #. I do not know what API calls you should use, but if there is, then it will come out in the Win32 API. I know software that doses what you are trying to execute. The name of the software is Spotify Ripper. If you use the spy API software, you can see which API calls this software!

0
source

All Articles