From alsa-devel-owner@alsa.jcu.cz  Thu Feb 25 16:01:56 1999
Received: from faui45.informatik.uni-erlangen.de (root@faui45.informatik.uni-erlangen.de [131.188.2.45])
	by marvin.jcu.cz (8.9.1a/8.9.1) with ESMTP id QAA05121
	for <alsa-devel@alsa.jcu.cz>; Thu, 25 Feb 1999 16:00:19 +0100
Received: from servww1.ww.uni-erlangen.de (servww1.ww.uni-erlangen.de [131.188.142.2])
	by faui45.informatik.uni-erlangen.de (8.9.1/8.1.49-FAU) with SMTP id QAA10118
	for <alsa-devel%alsa.jcu.cz@faui45.informatik.uni-erlangen.de>; Thu, 25 Feb 1999 16:00:17 +0100 (MET)
Received: from hong.ww.uni-erlangen.de by ww.uni-erlangen.de with SMTP;
	id AA09807 (1.37.109.4/7.3m-FAU); Thu, 25 Feb 99 15:59:58 +0100
Message-Id: <9902251459.AA09807@servww1.ww.uni-erlangen.de>
Received: by hong (sSMTP sendmail emulation); Thu, 25 Feb 1999 16:01:48 +0100
From: "Takashi Iwai" <iwai@ww.uni-erlangen.de>
To: alsa-devel@alsa.jcu.cz
Subject: Re: Instrument abstract layer 
In-Reply-To: <Pine.LNX.3.96.990225123513.6433B-100000@entry.jcu.cz>
References: <199902242004.PAA07486@renoir.op.net>
	<Pine.LNX.3.96.990225123513.6433B-100000@entry.jcu.cz>
Date: Thu, 25 Feb 1999 16:01:48 +0100
Reply-To: alsa-devel@alsa.jcu.cz
Sender: alsa-devel-owner@alsa.jcu.cz
Precedence: list

>>>>> On Thu, 25 Feb 1999 12:45:53 +0100 (CET), Jaroslav Kysela
<perex@jcu.cz> said: 

> Other information (groups of patches and samples) will be specific for
> the lowlevel driver (or hardware). I don't know if the sequencer must
> cover with some universal way to control of these things. For
> example things like sample (wave) sharing must be done in the lowlevel
> driver.

Just an idea:
For example, we can run a user-client for sample loading like a kind
of daemon.  Applications send only requests for preset, bank and etc
for this client, then it will load the relevant samples to the
corresponding sequencer port.  Since this is a user client, it can
handle sample files easily.  The other normal events will be passed
through this client without any change. 
Of course, if your application needs to deal with sample loading by
itself, it can access to the sequencer port directly.
Or, another type of client can be considered, which works like a
convertor from different sample format (like sox).  The data will be
sent through this client, and applications don't need to know it.
However, it's not good for large samples because it always duplicates
the data.

BTW, what plan do you have for data transfer between sequencer and
lowlevel driver?  I thought that a new callback would be easiest way.
The callback is called with buffer pointer of user-space, so that the
lowlevel driver can read the data directly from user-space.
The demerit of this method is that this will eventually stop the whole 
sequencer operation during sample loading -- it's relatively long
time...

-- 
Takashi Iwai / iwai@ww.uni-erlangen.de
Department of Materials Science
Friedrich-Alexander-University Erlangen-Nuernberg

