summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorTanu Kaskinen <tanu.kaskinen@linux.intel.com>2014-06-17 14:01:15 +0300
committerWim Taymans <wtaymans@redhat.com>2014-08-05 11:39:46 +0200
commit7fb7a68d3153d7b4cc1d1f8696be9aa69812b93f (patch)
treec47c1a34dca9e4d1c45b8153265eefaaf7e72ff2
parent37225b927ecd3ab7780b9769dfda9136d26f6b5e (diff)
combine-sink: Add a convenience variable
-rw-r--r--src/modules/module-combine-sink.c13
1 files changed, 8 insertions, 5 deletions
diff --git a/src/modules/module-combine-sink.c b/src/modules/module-combine-sink.c
index 37c2c79a6..8a2e43bd3 100644
--- a/src/modules/module-combine-sink.c
+++ b/src/modules/module-combine-sink.c
@@ -915,6 +915,7 @@ static void update_description(struct userdata *u) {
}
static int output_create_sink_input(struct output *o) {
+ struct userdata *u;
pa_sink_input_new_data data;
pa_assert(o);
@@ -922,18 +923,20 @@ static int output_create_sink_input(struct output *o) {
if (o->sink_input)
return 0;
+ u = o->userdata;
+
pa_sink_input_new_data_init(&data);
pa_sink_input_new_data_set_sink(&data, o->sink, FALSE);
data.driver = __FILE__;
pa_proplist_setf(data.proplist, PA_PROP_MEDIA_NAME, "Simultaneous output on %s", pa_strnull(pa_proplist_gets(o->sink->proplist, PA_PROP_DEVICE_DESCRIPTION)));
pa_proplist_sets(data.proplist, PA_PROP_MEDIA_ROLE, "filter");
- pa_sink_input_new_data_set_sample_spec(&data, &o->userdata->sink->sample_spec);
- pa_sink_input_new_data_set_channel_map(&data, &o->userdata->sink->channel_map);
- data.module = o->userdata->module;
- data.resample_method = o->userdata->resample_method;
+ pa_sink_input_new_data_set_sample_spec(&data, &u->sink->sample_spec);
+ pa_sink_input_new_data_set_channel_map(&data, &u->sink->channel_map);
+ data.module = u->module;
+ data.resample_method = u->resample_method;
data.flags = PA_SINK_INPUT_VARIABLE_RATE|PA_SINK_INPUT_DONT_MOVE|PA_SINK_INPUT_NO_CREATE_ON_SUSPEND;
- pa_sink_input_new(&o->sink_input, o->userdata->core, &data);
+ pa_sink_input_new(&o->sink_input, u->core, &data);
pa_sink_input_new_data_done(&data);