Eq, and Surround sound simultaneously
I want to use both eq and virtual surround together, but even after reading the multiple nodes example in the wiki I'm clueless. How do I merge these two files into one filtered sink?
Virtual surround
context.modules = [
{ name = libpipewire-module-filter-chain
flags = [ nofail ]
args = {
node.description = "Virtual Surround Sink"
media.name = "Virtual Surround Sink"
filter.graph = {
nodes = [
# duplicate inputs
{ type = builtin label = copy name = copyFL }
{ type = builtin label = copy name = copyFR }
{ type = builtin label = copy name = copyFC }
{ type = builtin label = copy name = copyRL }
{ type = builtin label = copy name = copyRR }
{ type = builtin label = copy name = copySL }
{ type = builtin label = copy name = copySR }
{ type = builtin label = copy name = copyLFE }
# apply hrir - HeSuVi 14-channel WAV (not the *-.wav variants) (note: */44/* in HeSuVi are the same, but resampled to 44100)
{ type = builtin label = convolver name = convFL_L config = { filename = "/etc/pipewire/pipewire.conf.d/atmos.wav" channel = 0 } }
{ type = builtin label = convolver name = convFL_R config = { filename = "/etc/pipewire/pipewire.conf.d/atmos.wav" channel = 1 } }
{ type = builtin label = convolver name = convSL_L config = { filename = "/etc/pipewire/pipewire.conf.d/atmos.wav" channel = 2 } }
{ type = builtin label = convolver name = convSL_R config = { filename = "/etc/pipewire/pipewire.conf.d/atmos.wav" channel = 3 } }
{ type = builtin label = convolver name = convRL_L config = { filename = "/etc/pipewire/pipewire.conf.d/atmos.wav" channel = 4 } }
{ type = builtin label = convolver name = convRL_R config = { filename = "/etc/pipewire/pipewire.conf.d/atmos.wav" channel = 5 } }
{ type = builtin label = convolver name = convFC_L config = { filename = "/etc/pipewire/pipewire.conf.d/atmos.wav" channel = 6 } }
{ type = builtin label = convolver name = convFR_R config = { filename = "/etc/pipewire/pipewire.conf.d/atmos.wav" channel = 7 } }
{ type = builtin label = convolver name = convFR_L config = { filename = "/etc/pipewire/pipewire.conf.d/atmos.wav" channel = 8 } }
{ type = builtin label = convolver name = convSR_R config = { filename = "/etc/pipewire/pipewire.conf.d/atmos.wav" channel = 9 } }
{ type = builtin label = convolver name = convSR_L config = { filename = "/etc/pipewire/pipewire.conf.d/atmos.wav" channel = 10 } }
{ type = builtin label = convolver name = convRR_R config = { filename = "/etc/pipewire/pipewire.conf.d/atmos.wav" channel = 11 } }
{ type = builtin label = convolver name = convRR_L config = { filename = "/etc/pipewire/pipewire.conf.d/atmos.wav" channel = 12 } }
{ type = builtin label = convolver name = convFC_R config = { filename = "/etc/pipewire/pipewire.conf.d/atmos.wav" channel = 13 } }
# treat LFE as FC
{ type = builtin label = convolver name = convLFE_L config = { filename = "/etc/pipewire/pipewire.conf.d/atmos.wav" channel = 6 } }
{ type = builtin label = convolver name = convLFE_R config = { filename = "/etc/pipewire/pipewire.conf.d/atmos.wav" channel = 13 } }
# stereo output
{ type = builtin label = mixer name = mixL }
{ type = builtin label = mixer name = mixR }
]
links = [
# input
{ output = "copyFL:Out" input="convFL_L:In" }
{ output = "copyFL:Out" input="convFL_R:In" }
{ output = "copySL:Out" input="convSL_L:In" }
{ output = "copySL:Out" input="convSL_R:In" }
{ output = "copyRL:Out" input="convRL_L:In" }
{ output = "copyRL:Out" input="convRL_R:In" }
{ output = "copyFC:Out" input="convFC_L:In" }
{ output = "copyFR:Out" input="convFR_R:In" }
{ output = "copyFR:Out" input="convFR_L:In" }
{ output = "copySR:Out" input="convSR_R:In" }
{ output = "copySR:Out" input="convSR_L:In" }
{ output = "copyRR:Out" input="convRR_R:In" }
{ output = "copyRR:Out" input="convRR_L:In" }
{ output = "copyFC:Out" input="convFC_R:In" }
{ output = "copyLFE:Out" input="convLFE_L:In" }
{ output = "copyLFE:Out" input="convLFE_R:In" }
# output
{ output = "convFL_L:Out" input="mixL:In 1" }
{ output = "convFL_R:Out" input="mixR:In 1" }
{ output = "convSL_L:Out" input="mixL:In 2" }
{ output = "convSL_R:Out" input="mixR:In 2" }
{ output = "convRL_L:Out" input="mixL:In 3" }
{ output = "convRL_R:Out" input="mixR:In 3" }
{ output = "convFC_L:Out" input="mixL:In 4" }
{ output = "convFC_R:Out" input="mixR:In 4" }
{ output = "convFR_R:Out" input="mixR:In 5" }
{ output = "convFR_L:Out" input="mixL:In 5" }
{ output = "convSR_R:Out" input="mixR:In 6" }
{ output = "convSR_L:Out" input="mixL:In 6" }
{ output = "convRR_R:Out" input="mixR:In 7" }
{ output = "convRR_L:Out" input="mixL:In 7" }
{ output = "convLFE_R:Out" input="mixR:In 8" }
{ output = "convLFE_L:Out" input="mixL:In 8" }
]
inputs = [ "copyFL:In" "copyFR:In" "copyFC:In" "copyLFE:In" "copyRL:In" "copyRR:In", "copySL:In", "copySR:In" ]
outputs = [ "mixL:Out" "mixR:Out" ]
}
capture.props = {
node.name = "effect_input.virtual-surround-7.1-hesuvi"
media.class = Audio/Sink
audio.channels = 8
audio.position = [ FL FR FC LFE RL RR SL SR ]
}
playback.props = {
node.name = "effect_output.virtual-surround-7.1-hesuvi"
node.passive = true
audio.channels = 2
audio.position = [ FL FR ]
}
}
}
]
Eq
context.modules = [
{ name = libpipewire-module-filter-chain
args = {
node.description = "Equalizer Sink"
media.name = "Equalizer Sink"
filter.graph = {
nodes = [
{
type = builtin
name = eq_band_1
label = bq_highshelf
control = { "Freq" = 0 "Q" = 1.0 "Gain" = -5.4 }
}
{
type = builtin
name = eq_band_2
label = bq_peaking
control = { "Freq" = 52.0 "Q" = 2.0 "Gain" = -1.4 }
}
{
type = builtin
name = eq_band_3
label = bq_peaking
control = { "Freq" = 75.0 "Q" = 0.9 "Gain" = -4.5 }
}
{
type = builtin
name = eq_band_4
label = bq_lowshelf
control = { "Freq" = 105.0 "Q" = 0.71 "Gain" = 5.5 }
}
{
type = builtin
name = eq_band_5
label = bq_peaking
control = { "Freq" = 260.0 "Q" = 4.0 "Gain" = -1.5 }
}
{
type = builtin
name = eq_band_6
label = bq_highshelf
control = { "Freq" = 1650.0 "Q" = 3.5 "Gain" = -3.9 }
}
{
type = builtin
name = eq_band_7
label = bq_peaking
control = { "Freq" = 2100.0 "Q" = 1.0 "Gain" = 2.6 }
}
{
type = builtin
name = eq_band_8
label = bq_peaking
control = { "Freq" = 2600.0 "Q" = 5.0 "Gain" = -1.1 }
}
{
type = builtin
name = eq_band_9
label = bq_peaking
control = { "Freq" = 5100.0 "Q" = 4.8 "Gain" = -4.7 }
}
{
type = builtin
name = eq_band_10
label = bq_highshelf
control = { "Freq" = 8000.0 "Q" = 0.71 "Gain" = 2.0 }
}
{
type = builtin
name = eq_band_11
label = bq_peaking
control = { "Freq" = 9000.0 "Q" = 4.0 "Gain" = 0.0 }
}
]
links = [
{ output = "eq_band_1:Out" input = "eq_band_2:In" }
{ output = "eq_band_2:Out" input = "eq_band_3:In" }
{ output = "eq_band_3:Out" input = "eq_band_4:In" }
{ output = "eq_band_4:Out" input = "eq_band_5:In" }
{ output = "eq_band_5:Out" input = "eq_band_6:In" }
{ output = "eq_band_6:Out" input = "eq_band_7:In" }
{ output = "eq_band_7:Out" input = "eq_band_8:In" }
{ output = "eq_band_8:Out" input = "eq_band_9:In" }
{ output = "eq_band_9:Out" input = "eq_band_10:In" }
{ output = "eq_band_10:Out" input = "eq_band_11:In" }
]
}
audio.channels = 2
audio.position = [ FL FR ]
capture.props = {
node.name = "effect_input.eq6"
media.class = Audio/Sink
}
playback.props = {
node.name = "effect_output.eq6"
node.passive = true
}
}
}
]