[pulseaudio-discuss] Question about streams...
tanuk at iki.fi
Mon Apr 2 21:24:46 PDT 2012
On Tue, 2012-04-03 at 08:59 +1000, Jean-Yves Avenard wrote:
> Hi there..
> According to the Pulse documentation, there are 3 types of streams:
> Playback streams - Data flows from the client to the server.
> Record streams - Data flows from the server to the client.
> Upload streams - Similar to playback streams, but the data is
> stored in the sample cache. See Sample Cache for more information
> about controlling the sample cache.
> In the documentation for pa_stream_get_latency, one can read:
> "In case the stream is a monitoring stream the result can be negative,
> i.e. the captured samples are not yet played. In this case *negative
> is set to 1."
> So... What is a monitoring stream in this context?
It's a record stream that records what's being played to a sink or
records the contents of some single playback stream. With record streams
in general, the latency tells how long ago the audio reached the sound
card input, but with monitoring streams it tells how long ago the sound
reached the sound card's *output*. With monitoring streams the latency
can be negative if your application gets the audio before it reaches the
sound card output.
> In a typical user application playing audio via pulse, (e.g. a
> playback streams) can pa_stream_get_latency ever return a negative
> latency ?
More information about the pulseaudio-discuss