Edit Audio Files

Jun 18, 2014 at 12:59 PM
Edited Jun 18, 2014 at 12:59 PM

Is it possible to edit audio files to perform operations such as amplification, adding effects, equalizers, etc and save them?

Jun 19, 2014 at 4:21 PM
Since CSCore provides access to the raw samples of a sound, you can apply effects, ... on any sounds.
To understand how it works, you may want to take a look at this:

If you want to save the audio data instead of playing it, you can just call the Read method of the IWaveSource-interface to get the audio data. You can then do with this data what ever you want (e.g. save it to a file). If you just want to save it as a flat wav file/stream, you can use the WriteToWaveStream- or the WriteToFile-method.
If you want to save the data as a mp3, mp4 (aac), etc. file you can use the MediaFoundationEncoder class (see https://cscore.codeplex.com/SourceControl/latest#CSCore.Test/MediaFoundation/MediafoundationEncoderTests.cs for examples).

Also take a look at http://stackoverflow.com/questions/22018898/sound-with-equalizer or at the equalizer sample (https://cscore.codeplex.com/SourceControl/latest#Samples/Equalizer/MainWindow.cs) for an example on how to create an equalizer.