Sound Interrupts with mplayer/snd_hda on 8-STABLE amd64

Alexander Motin mav at
Tue Jan 19 10:22:34 UTC 2010

Thomas Hummel wrote:
> On Tue, Jan 19, 2010 at 10:56 AM, Alexander Motin <mav at
> <mailto:mav at>> wrote:
>     Some applications may control sound buffer size by themselves.
> Right. However, buffering an mp3 file should work out of the box in
> 2010, shouldn't it ? ;-)
> But what's weird, is that mplayer, with which the problem occurs, uses
> ffmpeg as a backend. But the same file played directly with ffplay
> (which comes with ffmpeg) works perfectly.
> However, I think ffplay uses sdl instead of oss.

SDL is just a wrapper around OSS. OSS is the only real sound interface.
But SDL may add some additional buffering and processing.

> Am I correct in assuming the following architecture layers :
> Amarok : xine -> oss -> snd_hda
> xine -> oss -> snd_hda
> mplayer -> ffmpeg -> oss|sdl -> snd_hda
> vlc -> oss -> snd_hda
> ?

mplayer uses OSS directly in my case. Not sure about SDL there.

> Can you think of some debug options in mplayer or vlc which could help
> me isolating the problem ?
> Or could it be related to the SMP architecture of my system (quad core
> intel) ?

I think it could be related to scheduling, but on such a powerful system
it is surprising.

AFAIR /dev/sndstat reports number of underruns occured. Have you tried
to look there?

Alexander Motin

More information about the freebsd-multimedia mailing list