Exemplo n.º 1
0
		public static AudioDeviceCollection InputDevices()
		{
			AudioDeviceCollection c=new AudioDeviceCollection();
			for(int i=0;i<waveInGetNumDevs();i++)
			{
				WAVEINCAPSA a=new WAVEINCAPSA();
				waveInGetDevCapsA(i,ref a,System.Runtime.InteropServices.Marshal.SizeOf(typeof(WAVEINCAPSA)));
				AudioDevice b=new AudioDevice();
				b.dwFormats=a.dwFormats;
				b.szPname=a.szPname;
				b.wPid=a.wPid;
				b.wMid=a.wMid;
				b.vDriverVersion=a.vDriverVersion;
				b.wChannels=a.wChannels;
				b.wReserved1=a.wReserved1;
				c.Add(b);
			}
			return c;
		}
Exemplo n.º 2
0
        public static AudioDeviceCollection InputDevices()
        {
            AudioDeviceCollection c = new AudioDeviceCollection();

            for (int i = 0; i < waveInGetNumDevs(); i++)
            {
                WAVEINCAPSA a = new WAVEINCAPSA();
                waveInGetDevCapsA(i, ref a, System.Runtime.InteropServices.Marshal.SizeOf(typeof(WAVEINCAPSA)));
                AudioDevice b = new AudioDevice();
                b.dwFormats      = a.dwFormats;
                b.szPname        = a.szPname;
                b.wPid           = a.wPid;
                b.wMid           = a.wMid;
                b.vDriverVersion = a.vDriverVersion;
                b.wChannels      = a.wChannels;
                b.wReserved1     = a.wReserved1;
                c.Add(b);
            }
            return(c);
        }
Exemplo n.º 3
0
 private extern static int waveInGetDevCapsA(int uDeviceID, ref WAVEINCAPSA pwic, int cbwic);
Exemplo n.º 4
0
		private extern static int waveInGetDevCapsA(int uDeviceID,ref WAVEINCAPSA pwic,int cbwic);