Csound Csound-dev Csound-tekno Search About

reshaping envelopes

Date1998-04-30 23:17
Frombruce quaglia
Subjectreshaping envelopes
	Here's a simple one, (at least I'm guessing it is):

	I'd like to find a simple and effective way to apply the
	envelope of one signal to another without effecting frequency
	spectrum. Both signals are .wav files using soundin. I 
	expected I could use follow but I can't find a way to use
	its output, kr, with anything but a generator like oscil.
	So far I have ok results using balance, but it strikes me
	that there is a better way to do this. The specific thing
	I'm trying to do at the moment is to apply the envelope
	of a sample of ocean waves to another soundfile which happens
	to be a relatively regular texture of granulated sounds. 
	(BTW- I'm still using 3.47, just in case there are any new opcodes
	that handle this better in .48). It seems simple enough, I 
	just haven't had occaision to do this before and would like
	advice on better ways to do it. Thanks....

	Bruce Quaglia
	University of Utah
	bruce.quaglia@m.cc.utah.edu


Date1998-04-30 23:52
FromErik Spjut
SubjectRe: reshaping envelopes
At 4:17 PM -0600 4/30/98, bruce quaglia wrote:
>	I'd like to find a simple and effective way to apply the
>	envelope of one signal to another without effecting frequency
>	spectrum.So far I have ok results using balance, but it strikes me
>	that there is a better way to do this.

This sort of thing is exactly what balance is for. If it doesn't seem
right, try adjusting ihp from the default of 10. I find something in the
range of 12 to 18 usually works best. Also make sure kr=sr. Balance adjusts
its scaling factor once per control frame (ps jpff et al., Life would be
much easier if balance updated every sample instead of every frame).
Without kr = sr you get amplitude jumps and buzzing at a frequency of kr.

-------------------------------------------------------------------------------
Erik Spjut (rhymes with cute) - Acting Director,The Center for Design Education
and/or Associate Professor of Engineering
Harvey Mudd College, Claremont, CA 91711  USA
Erik_Spjut@hmc.edu      Ph & Voice mail (909) 607-3890      Fax (909) 621-8967


Date1998-05-01 17:16
Fromjpff@maths.bath.ac.uk
SubjectRe: reshaping envelopes
I thought that the follow opcode was for this kind of reshaping.  Have
not used it for a while though.
=John ff