Skip to content

Commit

Permalink
pulse: set battr.minreq and battr.maxlength to -1
Browse files Browse the repository at this point in the history
We really just want to set battr.tlength (as its default is 2s).
It's better to left the others for pulse to determine.
  • Loading branch information
tomty89 committed Aug 1, 2018
1 parent f4c40b8 commit 3fba46f
Showing 1 changed file with 1 addition and 3 deletions.
4 changes: 1 addition & 3 deletions src/plugins/pulse/ao_pulse.c
Original file line number Diff line number Diff line change
Expand Up @@ -256,12 +256,10 @@ int ao_plugin_open(ao_device *device, ao_sample_format *format) {
}

/* buffering attributes */
battr.prebuf = battr.minreq = battr.fragsize = -1;
battr.prebuf = battr.minreq = battr.fragsize = battr.maxlength = -1;

battr.tlength = internal->buffer_time * format->rate / 1000000 *
(format->bits / 8) * device->output_channels;
battr.minreq = battr.tlength/4;
battr.maxlength = battr.tlength+battr.minreq;

internal->simple = pa_simple_new(internal->server, t, PA_STREAM_PLAYBACK,
internal->sink, t2, &ss,
Expand Down

0 comments on commit 3fba46f

Please sign in to comment.