Detect current volume level while a file is playing using Naudio
问题 So I have IWavePlayer waveOutDevice; WaveStream mainOutputStream; WaveChannel32 volumeStream; private WaveStream CreateInputStream(string fileName) { WaveChannel32 inputStream; if (fileName.EndsWith(".mp3")) { WaveStream mp3Reader = new Mp3FileReader(fileName); inputStream = new WaveChannel32(mp3Reader); } else { throw new InvalidOperationException("Unsupported extension"); } volumeStream = inputStream; return volumeStream; } private void Stop() { if (waveOutDevice != null) { waveOutDevice