xref: /OK3568_Linux_fs/buildroot/package/pulseaudio/default.pa (revision 4882a59341e53eb6f0b4789bf948001014eff981)
1*4882a593Smuzhiyun#!/usr/bin/pulseaudio -nF
2*4882a593Smuzhiyun#
3*4882a593Smuzhiyun# This file is part of PulseAudio.
4*4882a593Smuzhiyun#
5*4882a593Smuzhiyun# PulseAudio is free software; you can redistribute it and/or modify it
6*4882a593Smuzhiyun# under the terms of the GNU Lesser General Public License as published by
7*4882a593Smuzhiyun# the Free Software Foundation; either version 2 of the License, or
8*4882a593Smuzhiyun# (at your option) any later version.
9*4882a593Smuzhiyun#
10*4882a593Smuzhiyun# PulseAudio is distributed in the hope that it will be useful, but
11*4882a593Smuzhiyun# WITHOUT ANY WARRANTY; without even the implied warranty of
12*4882a593Smuzhiyun# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
13*4882a593Smuzhiyun# General Public License for more details.
14*4882a593Smuzhiyun#
15*4882a593Smuzhiyun# You should have received a copy of the GNU Lesser General Public License
16*4882a593Smuzhiyun# along with PulseAudio; if not, see <http://www.gnu.org/licenses/>.
17*4882a593Smuzhiyun
18*4882a593Smuzhiyun# This startup script is used only if PulseAudio is started per-user
19*4882a593Smuzhiyun# (i.e. not in system mode)
20*4882a593Smuzhiyun
21*4882a593Smuzhiyun.fail
22*4882a593Smuzhiyun
23*4882a593Smuzhiyun### Automatically restore the volume of streams and devices
24*4882a593Smuzhiyunload-module module-device-restore
25*4882a593Smuzhiyunload-module module-stream-restore
26*4882a593Smuzhiyunload-module module-card-restore
27*4882a593Smuzhiyun
28*4882a593Smuzhiyun### Automatically augment property information from .desktop files
29*4882a593Smuzhiyun### stored in /usr/share/application
30*4882a593Smuzhiyunload-module module-augment-properties
31*4882a593Smuzhiyun
32*4882a593Smuzhiyun### Should be after module-*-restore but before module-*-detect
33*4882a593Smuzhiyunload-module module-switch-on-port-available
34*4882a593Smuzhiyun
35*4882a593Smuzhiyun### Load audio drivers statically
36*4882a593Smuzhiyun### (it's probably better to not load these drivers manually, but instead
37*4882a593Smuzhiyun### use module-udev-detect -- see below -- for doing this automatically)
38*4882a593Smuzhiyun#load-module module-alsa-sink
39*4882a593Smuzhiyun#load-module module-alsa-source device=hw:1,0
40*4882a593Smuzhiyun#load-module module-oss device="/dev/dsp" sink_name=output source_name=input
41*4882a593Smuzhiyun#load-module module-oss-mmap device="/dev/dsp" sink_name=output source_name=input
42*4882a593Smuzhiyun#load-module module-null-sink
43*4882a593Smuzhiyun#load-module module-pipe-sink
44*4882a593Smuzhiyun
45*4882a593Smuzhiyun### Automatically load driver modules depending on the hardware available
46*4882a593Smuzhiyun.ifexists module-udev-detect.so
47*4882a593Smuzhiyunload-module module-udev-detect tsched=0
48*4882a593Smuzhiyun.else
49*4882a593Smuzhiyun### Use the static hardware detection module (for systems that lack udev support)
50*4882a593Smuzhiyunload-module module-detect
51*4882a593Smuzhiyun.endif
52*4882a593Smuzhiyun
53*4882a593Smuzhiyun### Automatically connect sink and source if JACK server is present
54*4882a593Smuzhiyun.ifexists module-jackdbus-detect.so
55*4882a593Smuzhiyun.nofail
56*4882a593Smuzhiyunload-module module-jackdbus-detect channels=2
57*4882a593Smuzhiyun.fail
58*4882a593Smuzhiyun.endif
59*4882a593Smuzhiyun
60*4882a593Smuzhiyun### Automatically load driver modules for Bluetooth hardware
61*4882a593Smuzhiyun.ifexists module-bluetooth-policy.so
62*4882a593Smuzhiyunload-module module-bluetooth-policy
63*4882a593Smuzhiyun.endif
64*4882a593Smuzhiyun
65*4882a593Smuzhiyun.ifexists module-bluetooth-discover.so
66*4882a593Smuzhiyunload-module module-bluetooth-discover
67*4882a593Smuzhiyun.endif
68*4882a593Smuzhiyun
69*4882a593Smuzhiyun### Load several protocols
70*4882a593Smuzhiyun.ifexists module-esound-protocol-unix.so
71*4882a593Smuzhiyunload-module module-esound-protocol-unix
72*4882a593Smuzhiyun.endif
73*4882a593Smuzhiyunload-module module-native-protocol-unix auth-anonymous=1 socket=/tmp/pulse-socket
74*4882a593Smuzhiyun
75*4882a593Smuzhiyun### Network access (may be configured with paprefs, so leave this commented
76*4882a593Smuzhiyun### here if you plan to use paprefs)
77*4882a593Smuzhiyun#load-module module-esound-protocol-tcp
78*4882a593Smuzhiyun#load-module module-native-protocol-tcp
79*4882a593Smuzhiyun#load-module module-zeroconf-publish
80*4882a593Smuzhiyun
81*4882a593Smuzhiyun### Load the RTP receiver module (also configured via paprefs, see above)
82*4882a593Smuzhiyun#load-module module-rtp-recv
83*4882a593Smuzhiyun
84*4882a593Smuzhiyun### Load the RTP sender module (also configured via paprefs, see above)
85*4882a593Smuzhiyun#load-module module-null-sink sink_name=rtp format=s16be channels=2 rate=44100 sink_properties="device.description='RTP Multicast Sink'"
86*4882a593Smuzhiyun#load-module module-rtp-send source=rtp.monitor
87*4882a593Smuzhiyun
88*4882a593Smuzhiyun### Load additional modules from GSettings. This can be configured with the paprefs tool.
89*4882a593Smuzhiyun### Please keep in mind that the modules configured by paprefs might conflict with manually
90*4882a593Smuzhiyun### loaded modules.
91*4882a593Smuzhiyun.ifexists module-gsettings.so
92*4882a593Smuzhiyun.nofail
93*4882a593Smuzhiyunload-module module-gsettings
94*4882a593Smuzhiyun.fail
95*4882a593Smuzhiyun.endif
96*4882a593Smuzhiyun
97*4882a593Smuzhiyun
98*4882a593Smuzhiyun### Automatically restore the default sink/source when changed by the user
99*4882a593Smuzhiyun### during runtime
100*4882a593Smuzhiyun### NOTE: This should be loaded as early as possible so that subsequent modules
101*4882a593Smuzhiyun### that look up the default sink/source get the right value
102*4882a593Smuzhiyunload-module module-default-device-restore
103*4882a593Smuzhiyun
104*4882a593Smuzhiyun### Automatically move streams to the default sink if the sink they are
105*4882a593Smuzhiyun### connected to dies, similar for sources
106*4882a593Smuzhiyun#load-module module-rescue-streams
107*4882a593Smuzhiyun
108*4882a593Smuzhiyun### Make sure we always have a sink around, even if it is a null sink.
109*4882a593Smuzhiyunload-module module-always-sink
110*4882a593Smuzhiyun
111*4882a593Smuzhiyun### Honour intended role device property
112*4882a593Smuzhiyunload-module module-intended-roles
113*4882a593Smuzhiyun
114*4882a593Smuzhiyun### Automatically suspend sinks/sources that become idle for too long
115*4882a593Smuzhiyunload-module module-suspend-on-idle
116*4882a593Smuzhiyun
117*4882a593Smuzhiyun### If autoexit on idle is enabled we want to make sure we only quit
118*4882a593Smuzhiyun### when no local session needs us anymore.
119*4882a593Smuzhiyun.ifexists module-console-kit.so
120*4882a593Smuzhiyunload-module module-console-kit
121*4882a593Smuzhiyun.endif
122*4882a593Smuzhiyun.ifexists module-systemd-login.so
123*4882a593Smuzhiyunload-module module-systemd-login
124*4882a593Smuzhiyun.endif
125*4882a593Smuzhiyun
126*4882a593Smuzhiyun### Enable positioned event sounds
127*4882a593Smuzhiyunload-module module-position-event-sounds
128*4882a593Smuzhiyun
129*4882a593Smuzhiyun### Cork music/video streams when a phone stream is active
130*4882a593Smuzhiyunload-module module-role-cork
131*4882a593Smuzhiyun
132*4882a593Smuzhiyun### Modules to allow autoloading of filters (such as echo cancellation)
133*4882a593Smuzhiyun### on demand. module-filter-heuristics tries to determine what filters
134*4882a593Smuzhiyun### make sense, and module-filter-apply does the heavy-lifting of
135*4882a593Smuzhiyun### loading modules and rerouting streams.
136*4882a593Smuzhiyunload-module module-filter-heuristics
137*4882a593Smuzhiyunload-module module-filter-apply
138*4882a593Smuzhiyun
139*4882a593Smuzhiyun### Make some devices default
140*4882a593Smuzhiyun#set-default-sink output
141*4882a593Smuzhiyun#set-default-source input
142