Lines Matching defs:sink
30 #include <pulsecore/sink-input.h>
82 if (new_data->sink) {
92 /* Prefer the default sink over any other sink, just in case... */
163 static pa_hook_result_t sink_put_hook_callback(pa_core *c, pa_sink *sink, struct userdata *u) {
168 pa_assert(sink);
175 if (si->sink == sink)
180 if (!si->sink)
183 if (pa_safe_streq(si->sink->name, si->preferred_sink))
186 /* It might happen that a stream and a sink are set up at the
195 if (role_match(si->sink->proplist, role))
198 if (!role_match(sink->proplist, role))
201 pa_sink_input_move_to(si, sink, false);
257 static pa_hook_result_t sink_unlink_hook_callback(pa_core *c, pa_sink *sink, struct userdata *u) {
262 pa_assert(sink);
270 /* If there not default sink, then there is no sink at all */
274 PA_IDXSET_FOREACH(si, sink->inputs, idx) {
279 if (!si->sink)
285 /* Would the default sink fit? If so, let's use it */
286 if (c->default_sink != sink && role_match(c->default_sink->proplist, role))
290 /* Try to find some other fitting sink */
293 if (d == c->default_sink || d == sink)