[pulseaudio-discuss] Emptying a record stream's buffer

Andrew Eikum aeikum at codeweavers.com
Tue Apr 17 08:51:58 PDT 2012


Hi,

I'm trying to take a record stream which has been recording for some
time, and empty its buffer. I'm especially interested in causing the
return value from pa_stream_readable_size() to become 0.

I've attached a test program here which uses pa_stream_flush(). The
documentation for pa_stream_flush() says, "This discards any audio in
the buffer," but it doesn't actually seem to work for record streams.

Any hints?

Andrew
-------------- next part --------------
A non-text attachment was scrubbed...
Name: pulse_capture_flush.c
Type: text/x-csrc
Size: 5720 bytes
Desc: not available
URL: <http://lists.freedesktop.org/archives/pulseaudio-discuss/attachments/20120417/a86020cf/attachment-0001.c>


More information about the pulseaudio-discuss mailing list