2016-01-04 80 views
1

如何使用NAudio庫列出ASIO音頻輸出設備?列出NAIO中的ASIO音頻輸出設備

對於WaveIn,這將是:

int devcount = WaveIn.DeviceCount; 
for (int c= 0; c < devcount; c++) 
{ 
    WaveInCapabilities info = WaveIn.GetCapabilities(c); 
    Console.Out.WriteLine("{0}, {1}", info.ProductName, info.Channels); 
} 

對於WASAPI,這將是:

MMDeviceEnumerator enumerator = new MMDeviceEnumerator(); 
foreach (MMDevice device in enumerator.EnumerateAudioEndPoints(DataFlow.Capture, DeviceState.All)) 
{ 
    Console.WriteLine("{0}, {1}", device.FriendlyName, device.State); 
} 

回答

相關問題