コマンドラインからオーディオバランスを設定する

コマンドラインからオーディオバランスを設定する

コマンドライン (Linux) からオーディオバランスを設定したいのですが、「aumix」を調べて (そして Google で検索して) みたのですが、オプションがないようです... 何か方法を提案していただけますか?

答え1

ミキサー、左右のALSAチャンネルの音量を設定できます。例えば、

amixer sset Master 80%,20%

バランスが左にシフトします。

答え2

私はこの答えをあらゆるところで探しましたが、ここに私が得た答えがあります

  1. Alsamixer をダウンロードしてください。
  2. 設定に移動し、「alsa_amixerコントロール」またはモードの下の2番目のオプションを選択します。
  3. すべてのコマンドから「ヘッドフォンの音量」を検索し、値を 63,0 または 0,63 に変更します。

答え3

MacOS を使用している場合は、AppleScript を作成します。

# Start preferences with the right page
tell application "System Preferences"
    activate
    reveal anchor "output" of pane id "com.apple.preference.sound"
    delay 0.5 -- If you get an error, it's possible this delay isn't long enough.
end tell
# Set volume balance to normal
tell application "System Events"
    tell slider 1 of group 1 of tab group 1 of window 1 of process "System Preferences"
        set value to 0.2
    end tell
end tell
# Quit system preferences
tell application "System Preferences"
     quit
end tell

関連情報