如何在Windows 7上静音或设置麦克风/线路输出电平 [英] how can i mute or set the mic/line output level on windows 7

查看:106
本文介绍了如何在Windows 7上静音或设置麦克风/线路输出电平的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

你好

我目前正在努力移植一个应用程序,使其能够在前几代Windows的Windows 7上运行.通常这很简单,但是我发现了一个障碍.声音的. Vista中引入的音频更改与旧的调音台API完全不同 我不确定我们是否需要做.话虽如此,因为我可以从声音"控制面板中做到这一点.

I'm currently working on porting an app to run on windows 7 from previous generations of windows. Mostly this is straight forward but I've found one road block. Audio. The audio changes introduced in Vista are so radically different from the old mixer API that I'm not sure if what we need to do is even possible. Having said that it should be possible since I can do it from the Sound control panel.

我需要应用程序能够执行的操作是使麦克风/线路的输出静音,以使音频仍可以录入,但在应用程序处于播放模式时不会听见,因此听起来很糟糕,打败了目标演奏 共.如果我转到声音"控制面板,然后打开扬声器的属性,则会有一个选项卡,其中包含我需要设置的所有级别和静音,但是我一生都无法解决如何使用它们.我可以获取/设置整体输出量 和输入记录卷,但是如果我无法移植输入实时卷的静音,则无法将应用移植到Win7.

What I need to application to be able to do is to mute the output of the mic/line so that the audio is still coming in to be recorded but won't be audible while the application is in playback mode since then it would sound awful and defeat the purpose playing altogether. If I go to the Sound control panel and then open the properties of the speakers there's a tab that has all the levels and mutes that I need to set, but i can't for the life of me work out how to get at them. I can get/set the overall output volume and the input record volumes but if I can't port the muting of the inputs live volume then i can't port the app to Win7.

作为参考,有问题的声卡是Realtek高清晰度音频板载卡.

For reference purposes the sound card in questions is a Realtek High Definition Audio onboard card.

推荐答案

有两种不同的选择适用于麦克风的音量和静音...请确保我们在谈论相同的麦克风.

There are a couple of different levels and mutes that apply to microphones... let's make sure we're talking about the same ones.

首先,麦克风和线路输入有自己的音量和静音设置.这些会影响到通过麦克风或线路输入录制的应用程序的音频.通过转到声音"控制面板的录制"选项卡,然后双击,可以查看这些设置. 在麦克风"或线路输入"设备上,然后转到级别"标签.这些可以通过各种音量API进行配置-大多数应用应使用ISimpleAudioVolume.一切都很好.

First, mics and line ins have their own volume and mute settings.  These affect audio that goes to apps which record from the mic or line in.  You can see these settings by going to the Recording tab of the Sound control panel, then double-clicking on the Microphone or Line In device, then going to the Levels tab.  These are configurable by various volume APIs - most apps should use ISimpleAudioVolume.  All well and good.

但是,阅读您的文章后,我相信这些并不是您感兴趣的音量和静音设置.

But, reading your post, I believe those are NOT the volume and mute settings you're interested in.

第二,一些音频设备(但不是全部)公开模拟混音器".这样一来,您就可以将通过麦克风或线路输入传入的音频直接馈送到扬声器或线路输出,而无需通过整个应用程序.如你所愿 注意,您可以通过以下方式查看这些设置:转到声音"控制面板的播放"选项卡,然后双击扬声器",耳机"或线路输出"设备,然后转到级别"选项卡.主音量滑块和静音控制 播放设备;如果主音量开关下方有辅助音量滑块和静音键,则它们将控制模拟混音器路径.还有一种方法可以通过程序控制这些……但是首先我应该注意:

Second, some audio devices (but not all) expose an "analog mixer".  This allows you to feed audio that's coming in via the mic or line in directly through to the speaker or line out, without going through the application at all.  As you've noticed, you can see these settings by going to the Playback tab of the Sound control panel, then double-clicking on the Speaker or Headphone or Line Out device, then going to the Levels tab.  The main volume slider and mute controls the output of the playback device; if there are subsidiary volume sliders and mutes below the main one, they control analog mixer paths.  There's also a way to control these programmatically... but first I should note:

Windows 7具有听"功能.该功能与模拟混音器的功能大致相同,但使用软件而非硬件;用户可以通过以下方式打开或关闭此功能:转到录制"选项卡,双击麦克风"或线路输入"设备,然后选择 听"标签.同时转动模拟混频器和听"音源.同时启用该功能听起来确实很奇怪,因此不推荐.

Windows 7 has a "Listen" feature that does much the same thing as the analog mixer but in software rather than hardware; users can turn this on or off by going to the Recording tab, double-clicking on the Microphone or Line In device, and choosing the "Listen" tab.  Turning both the analog mixer and the "Listen" feature on at the same time sounds really strange and is not recommended.

在Windows Vista及更高版本中以编程方式控制模拟混音器路径的方法是使用IDeviceTopology API.请参阅这篇文章中的WalkTreeBackwardsFromPart函数:

The way to control analog mixer paths programmatically in Windows Vista and up is to use the IDeviceTopology API.  See the WalkTreeBackwardsFromPart function in this post:

http://social. msdn.microsoft.com/forums/zh-CN/windowspro-audiodevelopment/thread/9741bae1-c330-4802-9860-2fd202dba797/


这篇关于如何在Windows 7上静音或设置麦克风/线路输出电平的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆