[pulseaudio-discuss] [PATCH] client: Don't update smoother while corked

Colin Guthrie gmane at colin.guthr.ie
Wed Jan 12 01:25:42 PST 2011


'Twas brillig, and Arun Raghavan at 11/01/11 18:39 did gyre and gimble:
> On Tue, 2011-01-11 at 23:58 +0530, Arun Raghavan wrote:
>> This prevents the smoother attached to the stream clock from being
>> updated while the stream is corked, which in turn ensures that once
>> corking is completed, pa_stream_get_time() always returns the same value
>> until the stream is uncorked - i.e., the clock does not advance when the
>> client believes that it will not.
>>
>> The actual call to pa_smoother_put() happens on things like stream
>> suspend/unsuspend, which trigger timing updates. This changes the
>> smoother coefficients, which means that a call to pa_smoother_get() for
>> the same value of 'x' can return different values before and after a
>> timing update.
> 
> To add some background, this is required to fix a problem that was
> uncovered by the GStreamer pulsesink. We compensate for the clock
> advancing while the stream is paused. The incorrect change in stream
> time triggers this compensation and we get a short gap in playback. More
> details at [1] for the interested.

Seems sensible to me from your description.

I'll pull it in when I get a moment.

Col.


-- 

Colin Guthrie
gmane(at)colin.guthr.ie
http://colin.guthr.ie/

Day Job:
  Tribalogic Limited [http://www.tribalogic.net/]
Open Source:
  Mageia Contributor [http://www.mageia.org/]
  PulseAudio Hacker [http://www.pulseaudio.org/]
  Trac Hacker [http://trac.edgewall.org/]




More information about the pulseaudio-discuss mailing list