.TH "libpipewire-module-loopback" 7 "1.0.1" "PipeWire" \" -*- nroff -*-
.ad l
.nh
.SH NAME
libpipewire-module-loopback \- Loopback 
The loopback module passes the output of a capture stream unmodified to a playback stream\&.
.PP
It can be used to construct a link between a source and sink but also to create new virtual sinks or sources or to remap channel between streams\&.
.PP
Because both ends of the loopback are built with streams, the session manager can manage the configuration and connection with the sinks and sources\&.
.PP
.SH "MODULE NAME"
.PP
.PP
\fClibpipewire-module-loopback\fP
.PP
.SH "MODULE OPTIONS"
.PP
.PP
.IP "\(bu" 2
\fCnode\&.description\fP: a human readable name for the loopback streams
.IP "\(bu" 2
\fCtarget\&.delay\&.sec\fP: delay in seconds as float (Since 0\&.3\&.60)
.IP "\(bu" 2
\fCcapture\&.props = {}\fP: properties to be passed to the input stream
.IP "\(bu" 2
\fCplayback\&.props = {}\fP: properties to be passed to the output stream
.PP
.PP
.SH "GENERAL OPTIONS"
.PP
.PP
Options with well-known behavior\&. Most options can be added to the global configuration or the individual streams:
.PP
.IP "\(bu" 2
\fBremote.name\fP
.IP "\(bu" 2
\fBaudio.rate\fP
.IP "\(bu" 2
\fBaudio.channels\fP
.IP "\(bu" 2
\fBaudio.position\fP
.IP "\(bu" 2
\fBmedia.name\fP
.IP "\(bu" 2
\fBnode.latency\fP
.IP "\(bu" 2
\fBnode.description\fP
.IP "\(bu" 2
\fBnode.group\fP
.IP "\(bu" 2
\fBnode.link.group\fP
.IP "\(bu" 2
\fBnode.virtual\fP
.IP "\(bu" 2
\fBnode.name:\fP See notes below\&. If not specified, defaults to 'loopback-<pid>-<module-id>'\&.
.PP
.PP
Stream only properties:
.PP
.IP "\(bu" 2
\fBmedia.class\fP
.IP "\(bu" 2
\fBnode.name:\fP if not given per stream, the global node\&.name will be prefixed with 'input\&.' and 'output\&.' to generate a capture and playback stream node\&.name respectively\&.
.PP
.PP
.SH "EXAMPLE CONFIGURATION OF A VIRTUAL SINK"
.PP
.PP
This Virtual sink routes stereo input to the rear channels of a 7\&.1 sink\&.
.PP
.PP
.nf
context\&.modules = [
{   name = libpipewire-module-loopback
    args = {
        node\&.description = "CM106 Stereo Pair 2"
        #target\&.delay\&.sec = 1\&.5
        capture\&.props = {
            node\&.name = "CM106_stereo_pair_2"
            media\&.class = "Audio/Sink"
            audio\&.position = [ FL FR ]
        }
        playback\&.props = {
            node\&.name = "playback\&.CM106_stereo_pair_2"
            audio\&.position = [ RL RR ]
            target\&.object = "alsa_output\&.usb-0d8c_USB_Sound_Device-00\&.analog-surround-71"
            node\&.dont-reconnect = true
            stream\&.dont-remix = true
            node\&.passive = true
        }
    }
}
]
.fi
.PP
.PP
.SH "EXAMPLE CONFIGURATION OF A VIRTUAL SOURCE"
.PP
.PP
This Virtual source routes the front-left channel of a multi-channel input to a mono channel\&. This is useful for splitting up multi-channel inputs from USB audio interfaces that are not yet fully supported by alsa\&.
.PP
.PP
.nf
context\&.modules = [
{   name = libpipewire-module-loopback
    args = {
      node\&.description = "Scarlett Focusrite Line 1"
      capture\&.props = {
          audio\&.position = [ FL ]
          stream\&.dont-remix = true
          node\&.target = "alsa_input\&.usb-Focusrite_Scarlett_Solo_USB_Y7ZD17C24495BC-00\&.analog-stereo"
          node\&.passive = true
      }
      playback\&.props = {
          node\&.name = "SF_mono_in_1"
          media\&.class = "Audio/Source"
          audio\&.position = [ MONO ]
      }
    }
}
]
.fi
.PP
.PP
.SH "SEE ALSO"
.PP
.PP
\fCpw-loopback\fP : a tool that loads the loopback module with given parameters\&. 

