From: Takashi Iwai Subject: Re: a11y: howto reduce latency with alsa's dmix plugin? Date: Mon, 31 Aug 2009 17:12:23 +0200 Message-ID: References: <20090823095517.GA27741@halim> Mime-Version: 1.0 (generated by SEMI 1.14.6 - "Maruoka") Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Return-path: Received: from mx2.suse.de (cantor2.suse.de [195.135.220.15]) by alsa0.perex.cz (Postfix) with ESMTP id 7A26C24734 for ; Mon, 31 Aug 2009 17:12:23 +0200 (CEST) In-Reply-To: <20090823095517.GA27741@halim> List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: alsa-devel-bounces@alsa-project.org Errors-To: alsa-devel-bounces@alsa-project.org To: Halim Sahin Cc: alsa-devel@alsa-project.org List-Id: alsa-devel@alsa-project.org At Sun, 23 Aug 2009 09:55:18 +0000 (UTC), Halim Sahin wrote: > > Hello, > Is there a way to reduce latency on audiocard if the dmix plugin is in > use? > I am asking because there is a strange problem with asistive > technologies which are outputing through alsa. > E. G. speech-dispatcher takes almost a half sec to stop the > speech-synthesizer. > If the user navigates quickly through menus, there are simultane outputs > at a time. > (tested with an usb logitech headset, snd-intel8x0 based card, > snd-hda-intel). > The same problem can be reproduced by running mplayer with alsa output > driver and pressing > quickly left/right arrow. > You should hear several samples at a time. > > Using an sblive card which doesn't use dmix doesn't have such problems. > > Using the dmix plugin should audio much faster to avoid this problem. It's a bit hard to guess. This could be the difference of PCM drain implementation between hw and dmix, but a half second is still too long. Could you prepare a small test case to reproduce the buggy behavior? thanks, Takashi