Created
April 28, 2026 20:43
-
-
Save litui/ae954f6b77ee41cdb5100b21cbf1bee5 to your computer and use it in GitHub Desktop.
Merging of two stereo sinks to a reversible 4.0 surround setup and mirrored stereo setups in pipewire
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| # Thrown in ~/.config/pipewire/pipewire.conf.d | |
| context.modules = [ | |
| { name = libpipewire-module-combine-stream | |
| args = { | |
| combine.mode = sink | |
| node.name = "combine_sink_4_0_desk" | |
| node.description = "Pink Room Audio - Desk Surround" | |
| combine.latency-compensate = false | |
| combine.props = { | |
| audio.position = [ FL FR RL RR ] | |
| } | |
| # stream.props = { | |
| # stream.dont-remix = true # link matching channels without remixing | |
| # } | |
| stream.rules = [ | |
| { matches = [ | |
| { media.class = "Audio/Sink" | |
| node.name = "alsa_output.usb-IK_Multimedia_iRig_PRO_DUO-00.analog-stereo" | |
| } ] | |
| actions = { create-stream = { | |
| combine.audio.position = [ FL FR ] | |
| audio.position = [ FL FR ] | |
| } } } | |
| { matches = [ | |
| { media.class = "Audio/Sink" | |
| node.name = "alsa_output.usb-Focusrite_Scarlett_4i4_USB_D8RMNFG131AA25-00.analog-surround-40" | |
| } ] | |
| actions = { create-stream = { | |
| combine.audio.position = [ RR RL ] | |
| audio.position = [ FL FR ] | |
| } } } | |
| ] | |
| } | |
| } | |
| { name = libpipewire-module-combine-stream | |
| args = { | |
| combine.mode = sink | |
| node.name = "combine_sink_4_0_desk_stereo" | |
| node.description = "Pink Room Audio - Desk Stereo" | |
| combine.latency-compensate = false | |
| combine.props = { | |
| audio.position = [ FL FR ] | |
| } | |
| # stream.props = { | |
| # stream.dont-remix = true # link matching channels without remixing | |
| # } | |
| stream.rules = [ | |
| { matches = [ | |
| { media.class = "Audio/Sink" | |
| node.name = "alsa_output.usb-Focusrite_Scarlett_4i4_USB_D8RMNFG131AA25-00.analog-surround-40" | |
| } ] | |
| actions = { create-stream = { | |
| combine.audio.position = [ FR FL ] | |
| audio.position = [ FL FR ] | |
| } } } | |
| { matches = [ | |
| { media.class = "Audio/Sink" | |
| node.name = "alsa_output.usb-IK_Multimedia_iRig_PRO_DUO-00.analog-stereo" | |
| } ] | |
| actions = { create-stream = { | |
| combine.audio.position = [ FL FR ] | |
| audio.position = [ FL FR ] | |
| } } } | |
| ] | |
| } | |
| } | |
| { name = libpipewire-module-combine-stream | |
| args = { | |
| combine.mode = sink | |
| node.name = "combine_sink_4_0_bench" | |
| node.description = "Pink Room Audio - Bench Surround" | |
| combine.latency-compensate = false | |
| combine.props = { | |
| audio.position = [ FL FR RL RR ] | |
| } | |
| # stream.props = { | |
| # stream.dont-remix = true # link matching channels without remixing | |
| # } | |
| stream.rules = [ | |
| { matches = [ | |
| { media.class = "Audio/Sink" | |
| node.name = "alsa_output.usb-IK_Multimedia_iRig_PRO_DUO-00.analog-stereo" | |
| } ] | |
| actions = { create-stream = { | |
| combine.audio.position = [ RR RL ] | |
| audio.position = [ FL FR ] | |
| } } } | |
| { matches = [ | |
| { media.class = "Audio/Sink" | |
| node.name = "alsa_output.usb-Focusrite_Scarlett_4i4_USB_D8RMNFG131AA25-00.analog-surround-40" | |
| } ] | |
| actions = { create-stream = { | |
| combine.audio.position = [ FL FR ] | |
| audio.position = [ FL FR ] | |
| } } } | |
| ] | |
| } | |
| } | |
| { name = libpipewire-module-combine-stream | |
| args = { | |
| combine.mode = sink | |
| node.name = "combine_sink_4_0_bench_stereo" | |
| node.description = "Pink Room Audio - Bench Stereo" | |
| combine.latency-compensate = false | |
| combine.props = { | |
| audio.position = [ FL FR ] | |
| } | |
| # stream.props = { | |
| # stream.dont-remix = true # link matching channels without remixing | |
| # } | |
| stream.rules = [ | |
| { matches = [ | |
| { media.class = "Audio/Sink" | |
| node.name = "alsa_output.usb-Focusrite_Scarlett_4i4_USB_D8RMNFG131AA25-00.analog-surround-40" | |
| } ] | |
| actions = { create-stream = { | |
| combine.audio.position = [ FL FR ] | |
| audio.position = [ FL FR ] | |
| } } } | |
| { matches = [ | |
| { media.class = "Audio/Sink" | |
| node.name = "alsa_output.usb-IK_Multimedia_iRig_PRO_DUO-00.analog-stereo" | |
| } ] | |
| actions = { create-stream = { | |
| combine.audio.position = [ FR FL ] | |
| audio.position = [ FL FR ] | |
| } } } | |
| ] | |
| } | |
| } | |
| ] |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment