问题描述
我处理的,在Windows上使用portaudio遗留code。在code抓起从台式麦克风音频和具有配置输入音量的能力。它完美地工作在Windows XP下,但调整音频输入电平是在Windows 7下破,改变参数,对输出音频流没有影响。
code执行以下操作来调节音量
I am dealing with a legacy code that uses portaudio on windows. The code grabs audio from desktop mic and has ability to configure input volume. It worked perfectly under windows xp, but tuning audio input level is broken under windows 7, changing the parameter has no effect on output audio stream.Code do the following to adjust volume
mp_mixer = Px_OpenMixer(mp_inputStream, m_dev_num);
if(mp_mixer) Px_SetInputVolume(mp_mixer, m_volume);
我发现,那下属winmme功能无法在Windows Vista和更新工作。我已经更新到portaudio pa_stable_v19_20140130在混音器功能无法使用了的最后一个版本。我无法找到替代的方式来调节输入量portsound,有没有?
I have discovered, that underling winmme functions does not work in Windows Vista and newer. I have updated to last version of portaudio pa_stable_v19_20140130 in which Mixer functions are not available anymore. I can't find alternative way to adjust input volume in portsound, Is there any?
推荐答案
我想你将不得不使用音频端点设备API。的
I think you are going to have to use the Audio Endpoint Device API. http://msdn.microsoft.com/en-us/library/windows/desktop/dd370793(v=vs.85).aspx
就像你说的WMME混频器API不再支持。
Like you said the WMME mixer API is no longer supported.
这个API是不是太糟糕。只要确保你使用portaudio API设备索引标识设备混频器的API中。
The API isn't too bad. Just make sure you use the portaudio API device index to identify the device in the mixer API.
这篇关于使用portaudio组音频输入电平的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持!