[pulseaudio-tickets] [PulseAudio] #866: pa_simple_drain() takes much longer (about 2000ms) than expected to complete
PulseAudio
trac-noreply at tango.0pointer.de
Fri Oct 15 03:34:00 PDT 2010
#866: pa_simple_drain() takes much longer (about 2000ms) than expected to
complete
---------------------+------------------------------------------------------
Reporter: th | Owner: lennart
Type: defect | Status: new
Milestone: | Component: libpulse
Resolution: | Keywords:
---------------------+------------------------------------------------------
Comment(by th):
I ran the test program with pulse running with verbose logging, if you
look at the Launchpad bug entry you can see it:
[https://bugs.launchpad.net/ubuntu/+source/pulseaudio/+bug/660567] (also
pasted below).
It seems that pulse gets a buffer underrun at the time that I would expect
pa_simple_drain() to return, but it doesn't, and waits for 2s after that.
In simplistic terms, I guess pa_simple_drain() could be thought of as
"wait for buffer underrun", but for some reason it doesn't signal the
client when the buffer runs out.
{{{
...
( 0.034| 0.000) D: source.c: Processing rewind...
[0.344269] play done
[0.344328] not calling pa_simple_drain()
[0.358380] playing 680 hz tone volume 50 for 500 ms
[0.829451] play done
[0.829489] not calling pa_simple_drain()
[0.840411] playing 440 hz tone volume 50 for 500 ms
[1.303775] play done
( 1.471| 1.437) D: protocol-native.c: Underrun on 'beep', 0 bytes in
queue.
[3.505551] pa_simple_drain() done
[3.519491] playing 680 hz tone volume 50 for 500 ms
( 3.532| 2.060) D: protocol-native.c: Requesting rewind due to end of
underrun.
( 3.532| 0.000) D: alsa-sink.c: Requested to rewind 10156 bytes.
( 3.532| 0.000) D: alsa-sink.c: Limited to 10156 bytes.
( 3.532| 0.000) D: alsa-sink.c: before: 2539
( 3.532| 0.000) D: alsa-sink.c: after: 2539
( 3.532| 0.000) D: alsa-sink.c: Rewound 10156 bytes.
( 3.532| 0.000) D: sink.c: Processing rewind...
( 3.532| 0.000) D: sink-input.c: Have to rewind 10156 bytes on render
memblockq.
( 3.533| 0.000) D: source.c: Processing rewind...
[3.848197] play done
( 4.016| 0.483) D: protocol-native.c: Underrun on 'beep', 0 bytes in
queue.
[6.050165] pa_simple_drain() done
[6.062775] playing 440 hz tone volume 50 for 500 ms
...
}}}
--
Ticket URL: <http://pulseaudio.org/ticket/866#comment:6>
PulseAudio <http://pulseaudio.org/>
The PulseAudio Sound Server
More information about the pulseaudio-bugs
mailing list