【问题标题】:ALSA - route front left to rear, Center/LFE and adjust volume individually for each channelALSA - 将前左到后、中心/LFE 路由并为每个通道单独调整音量
【发布时间】:2015-08-20 23:18:01
【问题描述】:

我不知道这是否可能,但我想将声音从前置扬声器路由到后置扬声器,并且仍然能够单独控制每个通道的音量。

我有一个带有 3 条线路输出的 USB 声卡,FRONT、REAR 和 Center/LFE。

我已经弄清楚了如何在 /etc/asound.conf 中将声音从前到后、中置/LFE 扬声器路由。在谷歌上呆了很长时间后,我仍然不知道如何分别控制前置、后置和中置/LFE 扬声器的音量。

我使用以下 asound.conf 从前置扬声器进行路由。

pcm.!默认{ 输入软件 slave.pcm "20to51" 控制 { name "softMixer" # 这个名字在 mopidy 配置中使用 卡 0 } } ctl.!默认{ 输入硬件 卡 0 } pcm.20to51 { 类型路线 slave.pcm环绕51 slave.channels 6 ttable.0.0 1 ttable.1.1 1 ttable.0.2 1 ttable.1.3 1 ttable.0.4 0.5 ttable.1.4 0.5 ttable.1.5 0.5 ttable.0.5 0.5 }

关于如何单独调整每个通道的任何想法?

编辑: 来自 amixer scontents 的内容

Simple mixer control 'Speaker',0
  Capabilities: pvolume pswitch pswitch-joined penum
  Playback channels: Front Left - Front Right - Rear Left - Rear Right - Front Center - Woofer - Side Left - Side Right
  Limits: Playback 0 - 197
  Mono:
  Front Left: Playback 4 [2%] [-36.19dB] [off]
  Front Right: Playback 4 [2%] [-36.19dB] [off]
  Rear Left: Playback 4 [2%] [-36.19dB] [off]
  Rear Right: Playback 4 [2%] [-36.19dB] [off]
  Front Center: Playback 4 [2%] [-36.19dB] [off]
  Woofer: Playback 4 [2%] [-36.19dB] [off]
  Side Left: Playback 4 [2%] [-36.19dB] [off]
  Side Right: Playback 4 [2%] [-36.19dB] [off]
Simple mixer control 'PCM',0
  Capabilities: cvolume cswitch cswitch-joined penum
  Capture channels: Front Left - Front Right
  Limits: Capture 0 - 6928
  Front Left: Capture 5543 [80%] [5.65dB] [on]
  Front Right: Capture 5543 [80%] [5.65dB] [on]
Simple mixer control 'PCM Capture Source',0
  Capabilities: enum
  Items: 'Mic' 'Line' 'IEC958 In' 'Mixer'
  Item0: 'Mic'
Simple mixer control 'Front Master',0
  Capabilities: volume penum
  Playback channels: Front Left - Front Right
  Capture channels: Front Left - Front Right
  Limits: 0 - 255
  Front Left: 0 [0%]
  Front Right: 0 [0%]
Simple mixer control 'Line',0
  Capabilities: pvolume cvolume pswitch pswitch-joined cswitch cswitch-joined penum
  Playback channels: Front Left - Front Right
  Capture channels: Front Left - Front Right
  Limits: Playback 0 - 8065 Capture 0 - 6928
  Front Left: Playback 0 [0%] [-24.00dB] [off] Capture 4096 [59%] [0.01dB] [on]
  Front Right: Playback 0 [0%] [-24.00dB] [off] Capture 4096 [59%] [0.01dB] [on]
Simple mixer control 'Mic',0
  Capabilities: pvolume cvolume pswitch pswitch-joined cswitch cswitch-joined penum
  Playback channels: Front Left - Front Right
  Capture channels: Front Left - Front Right
  Limits: Playback 0 - 8065 Capture 0 - 6928
  Front Left: Playback 0 [0%] [-24.00dB] [off] Capture 0 [0%] [-16.00dB] [on]
  Front Right: Playback 0 [0%] [-24.00dB] [off] Capture 0 [0%] [-16.00dB] [on]
Simple mixer control 'IEC958 In',0
  Capabilities: cswitch cswitch-joined penum
  Capture channels: Mono
  Mono: Capture [on]
Simple mixer control 'SoftMaster',0
  Capabilities: volume penum
  Playback channels: Front Left - Front Right
  Capture channels: Front Left - Front Right
  Limits: 0 - 255
  Front Left: 0 [0%]
  Front Right: 0 [0%]
Simple mixer control 'softMixer',0
  Capabilities: volume penum
  Playback channels: Front Left - Front Right
  Capture channels: Front Left - Front Right
  Limits: 0 - 255
  Front Left: 240 [94%]
  Front Right: 240 [94%]

【问题讨论】:

  • softvol 插件不支持两个以上的通道。如果您的设备没有按通道混音器控件,这是不可能的。
  • 嗨,我很确定它确实有混音器控制。频道..也许我不需要创建一个softvol来将声音从前到后路由?
  • 显示amixer scontents的输出。
  • 在我的帖子中添加了输出。

标签: alsa


【解决方案1】:

我想我明白了

pcm.!default {
        type plug
        slave.pcm "ch2to5"
}

pcm.digitalhw {
        type hw
        card 0
}

pcm.ch2to5 {
        type route
        slave.pcm "digitalhw"
        slave.channels 6
        ttable.0.0 1
        ttable.1.1 1
        ttable.0.2 1
        ttable.1.3 1
        ttable.0.4 0.5
        ttable.1.4 0.5
        ttable.1.5 0.5
        ttable.0.5 0.5
}

ctl.!default {
        type hw
        card 0
}

有了这个配置,前面的声音被路由到后面和 LFE/Center,我可以使用 alsamixer 来控制每个通道的音量。

【讨论】:

    猜你喜欢
    • 1970-01-01
    • 2015-06-26
    • 1970-01-01
    • 1970-01-01
    • 2014-04-01
    • 2023-04-10
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    相关资源
    最近更新 更多