Home   Information   Classes   Download   Usage   Mail List   Requirements   Links   Tutorial


Modal Class Reference

STK resonance model instrument. More...

#include <Modal.h>

Inheritance diagram for Modal:

Instrmnt Stk ModalBar List of all members.

Public Member Functions

 Modal (int modes=4)
 Class constructor, taking the desired number of modes to create.

virtual ~Modal ()
 Class destructor.

void clear ()
 Reset and clear all internal state.

virtual void setFrequency (MY_FLOAT frequency)
 Set instrument parameters for a particular frequency.

void setRatioAndRadius (int modeIndex, MY_FLOAT ratio, MY_FLOAT radius)
 Set the ratio and radius for a specified mode filter.

void setMasterGain (MY_FLOAT aGain)
 Set the master gain.

void setDirectGain (MY_FLOAT aGain)
 Set the direct gain.

void setModeGain (int modeIndex, MY_FLOAT gain)
 Set the gain for a specified mode filter.

virtual void strike (MY_FLOAT amplitude)
 Initiate a strike with the given amplitude (0.0 - 1.0).

void damp (MY_FLOAT amplitude)
 Damp modes with a given decay factor (0.0 - 1.0).

void noteOn (MY_FLOAT frequency, MY_FLOAT amplitude)
 Start a note with the given frequency and amplitude.

void noteOff (MY_FLOAT amplitude)
 Stop a note with the given amplitude (speed of decay).

virtual MY_FLOAT tick ()
 Compute one output sample.

virtual void controlChange (int number, MY_FLOAT value)=0
 Perform the control change specified by number and value (0.0 - 128.0).


Detailed Description

STK resonance model instrument.

This class contains an excitation wavetable, an envelope, an oscillator, and N resonances (non-sweeping BiQuad filters), where N is set during instantiation.

by Perry R. Cook and Gary P. Scavone, 1995 - 2002.

Definition at line 23 of file Modal.h.


The documentation for this class was generated from the following file:
The Synthesis ToolKit in C++ (STK)
©1995-2004 Perry R. Cook and Gary P. Scavone. All Rights Reserved.