[MPlayer-dev-eng] [PATCH] Add audio support for sndio API.
Alexandre Ratchov
alex at caoua.org
Fri Dec 27 00:47:55 CET 2013
On Tue, Dec 24, 2013 at 10:01:21AM +0100, Reimar Döffinger wrote:
> On 20.12.2013, at 12:09, Alexandre Ratchov <alex at caoua.org> wrote:
> > On Fri, Dec 20, 2013 at 12:06:38PM +0100, Reimar Döffinger wrote:
> >>
> >> If that is a valid implementation of the API then the close
> >> function is broken instead. It must wait until the data has been
> >> played, otherwise we'd end up playing consecutive files over each
> >> other.
> >
> > sure; and this has been fixed few years ago.
>
> You mean when the close() behaviour changed to wait?
Yes.
> I understood what you said like this: the previous behaviour was
> valid and correct as well, and it might be possible it might be
> changed "back" again (at least to something similar to the old
> behaviour).
That would be a regression, as this would produce the artefact you
described (quick start/stop cycles play over each other, which is a
bug).
> In that case our close function should ideally try to deal with
> such a behaviour.
Ideally we shouldn't depend on how long sio_stop() or other
functions take to return. Assuming no samples will be lost and that
streams won't play over each over is safe.
> If however you say it was an actual sndio bug that is fixed and
> API promises a close() open() sequence doesn't result in both
> streams being played on top of each other that would be
> different.
This is a bug, as this causes an audible artefact; furthermore this
used to cause many other problems (resouce exhaustion during fast
start/stop cycles, volume miscalculation, etc).
> I'll take a last look hopefully soon, but I think it's time to
> commit what we have now.
Excellent!
-- Alexandre
More information about the MPlayer-dev-eng
mailing list