익명 09:42

Can I downmix stereo audio to mono?

Can I downmix stereo audio to mono?

I have one speaker next to my computer which I use mostly as a headphone amplifier. On occasion I need to use it as a loudspeaker. Is it possible to quickly change the audio output from stereo to mono, either system-wide or as a plugin for a media player?



Top Answer/Comment:
  1. Find the name of your audio sink by running

    pacmd list-sinks | grep name:
    
  2. Then run this command (taking care to remove the angled brackets from the result of previous command):

    pacmd load-module module-remap-sink sink_name=mono master=NAME_OF_AUDIO_SINK_GIVEN_BY_PREVIOUS_COMMAND channels=2 channel_map=mono,mono
    

or add

    load-module module-remap-sink sink_name=mono master=NAME_OF_AUDIO_SINK_GIVEN_BY_PREVIOUS_COMMAND channels=2 channel_map=mono,mono

to /etc/pulse/default.pa to have it run at startup.

  1. Then in Sound Preferences choose "Mono" as the output, but remember to reduce volumes by half, since two channels are getting mixed into one, or else you'll have distortion. To test, run:

    speaker-test -c 2 -t sine
    

Same thing in a single command:

pacmd load-module module-remap-sink sink_name=mono master=$(pacmd list-sinks | grep -m 1 -oP 'name:\s<\K.*(?=>)') channels=2 channel_map=mono,mono
  1. To remove the mono channel, just use:

    pacmd unload-module module-remap-sink
    
상단 광고의 [X] 버튼을 누르면 내용이 보입니다