From adc2973c8dfab862d4333e0c1206995cd2df20c6 Mon Sep 17 00:00:00 2001 From: Lennart Poettering Date: Sun, 26 Oct 2008 19:32:04 +0100 Subject: Implement new flags DONT_INHIBIT_AUTO_SUSPEND and START_UNMUTED --- src/pulse/stream.c | 12 +++++++++++- 1 file changed, 11 insertions(+), 1 deletion(-) (limited to 'src/pulse/stream.c') diff --git a/src/pulse/stream.c b/src/pulse/stream.c index 00aa1cf9..c0ae4ac2 100644 --- a/src/pulse/stream.c +++ b/src/pulse/stream.c @@ -887,7 +887,9 @@ static int create_stream( PA_STREAM_PEAK_DETECT| PA_STREAM_START_MUTED| PA_STREAM_ADJUST_LATENCY| - PA_STREAM_EARLY_REQUESTS)), PA_ERR_INVALID); + PA_STREAM_EARLY_REQUESTS| + PA_STREAM_DONT_INHIBIT_AUTO_SUSPEND| + PA_STREAM_START_UNMUTED)), PA_ERR_INVALID); PA_CHECK_VALIDITY(s->context, s->context->version >= 12 || !(flags & PA_STREAM_VARIABLE_RATE), PA_ERR_NOTSUPPORTED); PA_CHECK_VALIDITY(s->context, s->context->version >= 13 || !(flags & PA_STREAM_PEAK_DETECT), PA_ERR_NOTSUPPORTED); @@ -1007,6 +1009,14 @@ static int create_stream( pa_tagstruct_put_boolean(t, flags & PA_STREAM_EARLY_REQUESTS); } + if (s->context->version >= 15) { + + if (s->direction == PA_STREAM_PLAYBACK) + pa_tagstruct_put_boolean(t, flags & (PA_STREAM_START_MUTED|PA_STREAM_START_UNMUTED)); + + pa_tagstruct_put_boolean(t, flags & PA_STREAM_DONT_INHIBIT_AUTO_SUSPEND); + } + pa_pstream_send_tagstruct(s->context->pstream, t); pa_pdispatch_register_reply(s->context->pdispatch, tag, DEFAULT_TIMEOUT, pa_create_stream_callback, s, NULL); -- cgit