Beispiel #1
0
        public static float GetWaveOutVolume(IntPtr hWaveOut, object lockObject)
        {
            int      dwVolume;
            MmResult volume;

            lock (lockObject)
                volume = AudioInterop.waveOutGetVolume(hWaveOut, out dwVolume);
            MmException.Try(volume, "waveOutGetVolume");
            return((dwVolume & ushort.MaxValue) / (float)ushort.MaxValue);
        }