mirror of
https://github.com/processing/processing4.git
synced 2026-06-16 04:26:26 +02:00
bugfixed
This commit is contained in:
@@ -32,7 +32,7 @@ public void draw() {
|
||||
|
||||
// rms.analyze() return a value between 0 and 1. To adjust
|
||||
// the scaling and mapping of an ellipse we scale from 0 to 0.5
|
||||
scale=int(map(rms.process(), 0, 0.5, 1, 350));
|
||||
scale=int(map(rms.analyze(), 0, 0.5, 1, 350));
|
||||
noStroke();
|
||||
|
||||
fill(255,0,150);
|
||||
|
||||
@@ -41,6 +41,6 @@ public void draw() {
|
||||
{
|
||||
// The result of the FFT is normalized
|
||||
// draw the line for frequency band i scaling it up by 5 to get more amplitude.
|
||||
line( i, height, i, height - spec[i]*height*5 );
|
||||
line( i, height, i, height - spectrum[i]*height*5 );
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user