diff options
author | Lennart Poettering <lennart@poettering.net> | 2010-02-21 17:35:05 +0100 |
---|---|---|
committer | Lennart Poettering <lennart@poettering.net> | 2010-02-21 17:48:55 +0100 |
commit | ea29b11097b9d4180582924ca5df142fae4b6400 (patch) | |
tree | ccaad1b2b94adc9a27b454ca863ba53af5dcab48 /src/pulsecore/play-memblockq.c | |
parent | 3f1c90b9d7fa434ae90b45018255d086b0fa6e8a (diff) |
scache: when playing a sample from the cache make sure not queue them up when the sink is suspended
libcanberra already sets the appropriate flags for uncached sample
streams, we now need to make sure to set them for cached samples too.
Diffstat (limited to 'src/pulsecore/play-memblockq.c')
-rw-r--r-- | src/pulsecore/play-memblockq.c | 7 |
1 files changed, 5 insertions, 2 deletions
diff --git a/src/pulsecore/play-memblockq.c b/src/pulsecore/play-memblockq.c index f528c496..0d6da3ee 100644 --- a/src/pulsecore/play-memblockq.c +++ b/src/pulsecore/play-memblockq.c @@ -173,7 +173,8 @@ pa_sink_input* pa_memblockq_sink_input_new( const pa_channel_map *map, pa_memblockq *q, pa_cvolume *volume, - pa_proplist *p) { + pa_proplist *p, + pa_sink_input_flags_t flags) { memblockq_stream *u = NULL; pa_sink_input_new_data data; @@ -198,6 +199,7 @@ pa_sink_input* pa_memblockq_sink_input_new( pa_sink_input_new_data_set_channel_map(&data, map); pa_sink_input_new_data_set_volume(&data, volume); pa_proplist_update(data.proplist, PA_UPDATE_REPLACE, p); + data.flags |= flags; pa_sink_input_new(&u->sink_input, sink->core, &data); pa_sink_input_new_data_done(&data); @@ -237,6 +239,7 @@ int pa_play_memblockq( pa_memblockq *q, pa_cvolume *volume, pa_proplist *p, + pa_sink_input_flags_t flags, uint32_t *sink_input_index) { pa_sink_input *i; @@ -245,7 +248,7 @@ int pa_play_memblockq( pa_assert(ss); pa_assert(q); - if (!(i = pa_memblockq_sink_input_new(sink, ss, map, q, volume, p))) + if (!(i = pa_memblockq_sink_input_new(sink, ss, map, q, volume, p, flags))) return -1; pa_sink_input_put(i); |