如何从播放设备录制声音并在录制设备上重现?

时间:2013-04-22 16:33:25

标签: c# naudio

我想从扬声器中捕捉声音并使用Line 1或其他API在我的录音设备NAudio中播放。

我该怎么做?

我可以使用

列出WaveInWaveOut设备
public void ListDevices()
{
    Console.WriteLine(" WaveIn devices ");

    int waveInDevices = WaveInEvent.DeviceCount;
    for (int i = 0; i < waveInDevices; i++)
    {
        WaveInCapabilities deviceInfo = WaveInEvent.GetCapabilities(i);
        Console.WriteLine("Device {0}: {1}, {2} channels", i, deviceInfo.ProductName, deviceInfo.Channels);
    }

    Console.WriteLine(" WaveOut devices ");

    int waveOutDevices = WaveOut.DeviceCount;
    for (int i = 0; i < waveOutDevices; i++)
    {
        WaveOutCapabilities deviceInfo = WaveOut.GetCapabilities(i);
        Console.WriteLine("Device {0}: {1}, {2} channels", i, deviceInfo.ProductName, deviceInfo.Channels);
    }
}

但它们与我想要的完全相反。我能够从麦克风录制并在我的扬声器上收听,但我想做相反的事情。怎么样?

0 个答案:

没有答案
相关问题