qemu-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Qemu-devel] [PATCH 2/3] make latency configurable


From: Martin Schrodt
Subject: Re: [Qemu-devel] [PATCH 2/3] make latency configurable
Date: Fri, 15 Mar 2019 09:24:39 +0100
User-agent: Mozilla/5.0 (X11; Linux x86_64; rv:60.0) Gecko/20100101 Thunderbird/60.5.3

Hi,

On 3/15/19 8:53 AM, Gerd Hoffmann wrote:
>   Hi,
> 
>>          r = pa_stream_connect_playback (stream, dev, attr,
>>                                          PA_STREAM_INTERPOLATE_TIMING
>> -#ifdef PA_STREAM_ADJUST_LATENCY
>>                                          |PA_STREAM_ADJUST_LATENCY
>> -#endif
> 
> Unrelated change, separate commit please.
> 
> Which pulse version added this define, and how old is it?
> (should be answered in the commit message).

I'll just put it in again. Flag was added in PA 0.9.11 (December 2014),
so we can probably assume that it's there anyway, and if some poor chap
decides to compile against prehistoric PA, it won't break if we leave it in.

> 
>> -    /*
>> -     * qemu audio tick runs at 100 Hz (by default), so processing
>> -     * data chunks worth 10 ms of sound should be a good fit.
>> -     */
>> -    ba.tlength = pa_usec_to_bytes (10 * 1000, &ss);
>> -    ba.minreq = pa_usec_to_bytes (5 * 1000, &ss);
>> +    ba.tlength = pa_usec_to_bytes (ppdo->latency, &ss);
>> +    ba.minreq = -1;
> 
> Please explain this in the commit message.

Commit messages have been revamped in V2 and V3 of the patch.

> 
>> -        pdo->buffer_length = dev->timer_period * 4;
>> +        pdo->buffer_length = dev->timer_period * 9 / 2;
> 
> Likewise.

Will clean this up.

> 
>> +# @latency: latency you want PulseAudio to archieve in microseconds
>> +#           (default 15000)
> 
> Is there a good reason to make this configurable?

Yes, to squeeze out some milliseconds of latency, where the emulation is
tuned to do so (properly isolate emulation threads, propably lower
timer-period...)

> 
> cheers,
>   Gerd
> 




reply via email to

[Prev in Thread] Current Thread [Next in Thread]