hey ive been following two examples using the Ess audio library
two of the examples are nearly identical, except that one works and runs correctly, where as the other complains that the Amplify(float) constructor is undefined... I have put the library in the sketchbook libraries folder. im new to this stuff so im sure it is a simple mistake, but i cannot find for the life of me what the difference is that makes one work and the other not. here are the two examples:
first one (works):
Code:// Example by Krister Olsson
import krister.Ess.*;
AudioChannel myChannel;
Amplify myAmplify;
void setup() {
size(256,200);
// start up Ess
Ess.start(this);
// load "cell.aif" into a new AudioChannel
myChannel=new AudioChannel("cell.aif");
// amplify first 2 seconds 25%
myAmplify=new Amplify(.25);
myAmplify.filter(myChannel,0,myChannel.frames(2000));
// amplify next 2 seconds 300%
myAmplify.percent=3;
myAmplify.filter(myChannel,myChannel.frames(2000),myChannel.frames(2000));
// play
myChannel.play();
}
void draw() {
}
// we are done, clean up Ess
public void stop() {
Ess.stop();
super.stop();
}
second one (error: The constructor Amplify(float) is undefined)
Code:// Example by Krister Olsson
import krister.Ess.*;
AudioChannel myChannel;
Amplify myAmplify;
void setup() {
size(256,200);
// start up Ess
Ess.start(this);
// load "cell.aif" into a new AudioChannel
myChannel=new AudioChannel("cell.aif");
// amplify first 2 seconds 25%
myAmplify=new Amplify(.25); /* <-- THIS IS THE LINE GIVING THE ERROR */
myAmplify.filter(myChannel,0,myChannel.frames(2000));
// play
myChannel.play();
}
void draw() {
}
// we are done, clean up Ess
public void stop() {
Ess.stop();
super.stop();
}
i have tried closing processing completely, and starting again and opening the two examples again, but the same problem keeps occuring!
thanks for your help in advance, sorry if its a trivial problem but it really has stumped me and i want to know why it occurs...