[pulseaudio-discuss] pacmd list-sink-inputs "requested latency" value

Lennart Poettering lennart at poettering.net
Mon Jan 4 13:27:56 PST 2010


On Fri, 01.01.10 18:30, Cristian Morales Vega (cmorve69 at yahoo.es) wrote:

> Hi,
> 
> I'm trying to understand the output from pacmd.
> My problem is that pacmd list-sinks outputs: "configured latency: 0,00
> ms; range is 56,00 .. 371,52 ms" (no client connected)
> And when running the test program from the bottom of this message,
> pacmd list-sink-inputs always outputs "requested latency: 56,00 ms".
> 
> Testing randomly I found that changing "tlength =
> pa_usec_to_bytes(atoi(argv[3]) * 1e3, &ss)," for ".tlength = 2 *
> pa_usec_to_bytes(atoi(argv[3]) * 1e3, &ss)," I always get 20 ms less
> than what I would expect. So "./pulse-test 48000 2 120" makes pacmd
> list-sink-inputs return "requested latency: 100,00 ms".

The overall latency of your stream (which you specify with tlength)
consists of a per-stream server side buffer plus the hw buffer plus
some extra room in the middle for moving blocks between those
buffers. That means that if you set tlength to some value the hw
buffer size will be set to some smaller value than that.

Lennart

-- 
Lennart Poettering                        Red Hat, Inc.
lennart [at] poettering [dot] net
http://0pointer.net/lennart/           GnuPG 0x1A015CC4



More information about the pulseaudio-discuss mailing list