|  | If I'm understanding you correctly, you can use a tablei to read from an f card of your choice and use the resulting normalized values (0-1) as multipliers on your output statement.
sr=44100
kr=441
ksmps=10
nchnls=1
instr 1
	ain1	soundin	p4,p5  (or whatever sound source you choose)
	aamp1	tablei,1
	out	ain1*aamp1
endin
* This score assumes that you want to start both samples at the same time
f1 0 655536 10 1         (whatever crossfade shape for sample1)
f2 0 655536 10 1         (whatever crossfade shape for sample2)
i1	0	1	999	0
i1	0	1	998	0
This is a rather crude example, but should work if you load your f-tables with whatever shapes you want to impose, and of course enough frames to cover the duration of crossfading sounds.  You could even use GEN01 and load it with a sample that has the crossfade shape you want...
Dustin Barlow
Omni Digital Systems
http://www.omnids.com
-----Original Message-----
From:	John Francis Beahan [SMTP:jfbeahan@cats.ucsc.edu]
Sent:	Tuesday, June 24, 1997 8:17 PM
To:	csound mail list
Subject:	realtime 
Here is the problem: We want to crossfade between two sampled sounds(i.e 
soft rain and hard rain) , but be able to control the fade-in and fade-out of
each sample in realtime.  
Ultimately, the objective is to have a large data set be the controlling 
factor of the crossfades. AS the data changes it should effect the sample 
sound.
Is there a way in csound to change the amplitude of a sound while it is 
playing in real-time by issueing individual amplitude commands without 
having to restart the sound.
thanx,  John Beahan 
 |