0
votes

As title, I just searched very thoroughly on the web, still not having an answer. I'm working with WaveChannel32 like this : WaveChannel32 volumeStream and setting the volume like : volumeStream.Volume, the default value is 1 but if it increase, the volume increase only once, so I suspect is it more like a toggle than a volume control. If I am right, so how to control the volume?
Refer to http://naudio.codeplex.com/wikipage?title=MP3

1
Have you checked the NAudio samples? There are at least two that also allow you to change the volumen - and they work ;-) - Daniel Hilgarth
samples? which samples you mean, can you give a link? - giiYanJ
Well, those from the download page of the project? Download "Demo Apps" if you want the binaries, "Source" if you want the source - this will download the complete NAudio source including samples. - Daniel Hilgarth
nope, can't find any things there =( - giiYanJ
Nonsense. Did you even have a look? If so, where did you look? - Daniel Hilgarth

1 Answers

2
votes

The Volume property is a multiplier. So 1 means keep the volume the same, 0 means silence. 0.5 would make it quieter, 2.0 would double the amplitude of each sample etc. Note that if you increase this value above 1 there is the chance that you will clip your audio later when you play it or convert it back to a WAV file.