This project has moved and is read-only. For the latest updates, please go here.

About audio level alignment

Nov 3, 2012 at 2:08 PM
Edited Nov 3, 2012 at 2:10 PM

I found the maximum amplitude of a wavefile1 in respect to 1. I want to play a wavefile2 whose maximum amplitude is at 1 with the same volume in realtime as wavefile1 to have them at equal volume when playing together; in other words:

How to multiply the amplitude of wavefile2 with - for instance - 0.3 in realtime?

What would be the elegant way to do this with NAudio?

Nov 3, 2012 at 4:29 PM

You can adjust volume using any of the SampleProviders or WaveProviders with a volume property. For example, if you use AudioFileReader, then you can simply set its Volume to 0.3

Nov 3, 2012 at 5:39 PM

Now it is working. Thanks for your help.