From: Takashi Iwai Subject: Re: DSnoop Latency Date: Fri, 07 Oct 2005 15:36:06 +0200 Message-ID: References: <997BA7FD-4755-47D7-8AB9-1DBCB4FEE445@popwire.com> Mime-Version: 1.0 (generated by SEMI 1.14.6 - "Maruoka") Content-Type: text/plain; charset=US-ASCII Return-path: Received: from mx2.suse.de (mx2.suse.de [195.135.220.15]) by alsa.jcu.cz (ALSA's E-mail Delivery System) with ESMTP id 52F14135 for ; Fri, 7 Oct 2005 15:36:11 +0200 (MEST) In-Reply-To: <997BA7FD-4755-47D7-8AB9-1DBCB4FEE445@popwire.com> Sender: alsa-devel-admin@lists.sourceforge.net Errors-To: alsa-devel-admin@lists.sourceforge.net List-Unsubscribe: , List-Post: List-Help: List-Subscribe: , List-Archive: To: Kenth Andersson Cc: alsa-devel@alsa-project.org List-Id: alsa-devel@alsa-project.org At Fri, 7 Oct 2005 15:01:03 +0200, Kenth Andersson wrote: > > Hi, > > I'm using a M-Audio Delta 44 sound card which is 4 mono channels. I'm > using DSnoop > plugin to divide this 4 mono channels into two virtual sound cards, > cline1-2, each with a stereo configuration. > > My setup is as follows: > I got two live sound streams running, streaming sound over the network > from cline1 I'm capturing 8000 mono s16_le sound > from cline2 I'm capturing 22050 stereo s16_le sound > > I'm running this on a P4 3,2GHz HT Machine and it uses about 20% of CPU. First of all: which ALSA version? > My problem is that there are BIG latency in the stereo stream, why is > that? How BIG do you mean? Any objective number, even approximately? > I understand that dsnoop > has to do a sample rate conversion from input sample rate to both > 8000 and 22050, but it looks like this > conversion is very slow, without using all my CPU. I don't think it's the conversion layer. Or it might be the period-size misalignment problem. Try 24kHz on one side, for example (assuming that dmix slave is running on 48kHz). > 1. Anybody know anything about this, it it possible to prevent the > latency? > 2. Does anyone know of a better solution then dsnoop, that don't have > this latency? You mixed up two things: CPU usage and the latency. In theory, both have nothing to do with each other. The latecy of dsnoop depends on its configuration. Suppose you're using "dsnoop" PCM without extra setup, its period size is 1024 frames. This exactly defines the latency. Takashi ------------------------------------------------------- This SF.Net email is sponsored by: Power Architecture Resource Center: Free content, downloads, discussions, and more. http://solutions.newsforge.com/ibmarch.tmpl