1 -- Default policy config file --
5 default_policy.endpoints = {
6 -- [endpoint name] = { endpoint properties }
8 ["endpoint.multimedia"] = {
9 ["media.class"] = "Audio/Sink",
10 ["role"] = "Multimedia",
12 ["endpoint.speech_low"] = {
13 ["media.class"] = "Audio/Sink",
14 ["role"] = "Speech-Low",
16 ["endpoint.custom_low"] = {
17 ["media.class"] = "Audio/Sink",
18 ["role"] = "Custom-Low",
20 ["endpoint.navigation"] = {
21 ["media.class"] = "Audio/Sink",
22 ["role"] = "Navigation",
24 ["endpoint.speech_high"] = {
25 ["media.class"] = "Audio/Sink",
26 ["role"] = "Speech-High",
28 ["endpoint.custom_high"] = {
29 ["media.class"] = "Audio/Sink",
30 ["role"] = "Custom-High",
32 ["endpoint.communication"] = {
33 ["media.class"] = "Audio/Sink",
34 ["role"] = "Communication",
36 ["endpoint.emergency"] = {
37 ["media.class"] = "Audio/Sink",
38 ["role"] = "Emergency",
42 default_policy.policy = {
43 ["move"] = false, -- moves session items when metadata target.node changes
44 ["follow"] = true, -- moves session items to the default device when it has changed
46 -- Set to 'true' to disable channel splitting & merging on nodes and enable
47 -- passthrough of audio in the same format as the format of the device.
48 -- Note that this breaks JACK support; it is generally not recommended
49 ["audio.no-dsp"] = false,
51 -- how much to lower the volume of lower priority streams when ducking
52 -- note that this is a linear volume modifier (not cubic as in the mixer)
57 ["alias"] = { "Movie", "Music", "Game" },
59 ["action.default"] = "cork",
63 ["action.default"] = "cork",
64 ["action.Speech-Low"] = "mix",
68 ["action.default"] = "cork",
69 ["action.Custom-Low"] = "mix",
73 ["action.default"] = "duck",
74 ["action.Navigation"] = "mix",
78 ["action.default"] = "cork",
79 ["action.Speech-High"] = "mix",
83 ["action.default"] = "cork",
84 ["action.Custom-High"] = "mix",
88 ["action.default"] = "cork",
89 ["action.Communication"] = "mix",
92 ["alias"] = { "Alert" },
94 ["action.default"] = "cork",
95 ["action.Emergency"] = "mix",
100 function default_policy.enable()
101 -- Session item factories, building blocks for the session management graph
102 -- Do not disable these unless you really know what you are doing
103 load_module("si-node")
104 load_module("si-audio-adapter")
105 load_module("si-standard-link")
106 load_module("si-audio-endpoint")
108 -- API to access default nodes from scripts
109 load_module("default-nodes-api")
111 -- API to access mixer controls, needed for volume ducking
112 load_module("mixer-api")
114 -- Create endpoints statically at startup
115 load_script("static-endpoints.lua", default_policy.endpoints)
117 -- Create session items for nodes that appear in the graph
118 load_script("create-item.lua", default_policy.policy)
120 -- Link nodes to each other to make media flow in the graph
121 load_script("policy-node.lua", default_policy.policy)
123 -- Link client nodes with endpoints to make media flow in the graph
124 load_script("policy-endpoint-client.lua", default_policy.policy)
125 load_script("policy-endpoint-client-links.lua", default_policy.policy)
127 -- Link endpoints with device nodes to make media flow in the graph
128 load_script("policy-endpoint-device.lua", default_policy.policy)