Skip to content

Commit 17987e7

Browse files
authored
rename masterVolume to outputVolume (#610)
rename masterVolume to outputVolume and rename Master to Main
1 parent 282274a commit 17987e7

File tree

52 files changed

+156
-156
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

52 files changed

+156
-156
lines changed

examples/Compressor/sketch.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -50,7 +50,7 @@ function setup() {
5050

5151
compressor = new p5.Compressor();
5252

53-
// Disconnect soundfile from master output.
53+
// Disconnect soundfile from main output.
5454
// Then, connect it to the filter, so that we only hear the filtered sound
5555
soundFile.disconnect();
5656
compressor.process(soundFile);

examples/FFT_frequency_spectrum/sketch.js

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -44,8 +44,7 @@ function setup() {
4444
p = createP(description);
4545
var p2 = createP('Draw the array returned by FFT.analyze( ). This represents the frequency spectrum, from lowest to highest frequencies.');
4646

47-
// set the master volume;
48-
masterVolume(.5);
47+
outputVolume(0.5);
4948
}
5049

5150
function draw() {

examples/Filter_BandPass/sketch.js

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -19,7 +19,7 @@ function setup() {
1919

2020
noise = new p5.Noise();
2121

22-
noise.disconnect(); // Disconnect soundfile from master output...
22+
noise.disconnect(); // Disconnect soundfile from main output...
2323
filter.process(noise); // ...and connect to filter so we'll only hear BandPass.
2424
noise.start();
2525

@@ -58,4 +58,4 @@ function draw() {
5858
function updateDescription() {
5959
description = 'Playing! Press any key to pause. Filter Frequency = ' + filterFreq + ' Filter Width = ' + filterWidth;
6060
p.html(description);
61-
}
61+
}

examples/Filter_LowPass/sketch.js

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -27,7 +27,7 @@ function setup() {
2727

2828
filter = new p5.LowPass();
2929

30-
// Disconnect soundfile from master output.
30+
// Disconnect soundFile from main output.
3131
// Then, connect it to the filter, so that we only hear the filtered sound
3232
soundFile.disconnect();
3333
soundFile.connect(filter);
@@ -68,4 +68,4 @@ function draw() {
6868
function updateDescription() {
6969
description = 'Filter Frequency = ' + filterFreq + ' Filter Res = ' + filterRes;
7070
p.html(description);
71-
}
71+
}

examples/Reverb_convolve/sketch.js

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -30,7 +30,7 @@ function preload() {
3030
}
3131

3232
function setup() {
33-
// disconnect from master output...
33+
// disconnect from main output...
3434
sound.disconnect();
3535
// ... and process with cVerb so that we only hear the reverb
3636
cVerb.process(sound);
@@ -53,4 +53,4 @@ function mousePressed() {
5353

5454
// display the current Impulse Response name (the filepath)
5555
p.html('Convolution Impulse Response: ' + cVerb.impulses[currentIR].name);
56-
}
56+
}

examples/Reverb_convolve_FFT/sketch.js

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -36,7 +36,7 @@ function setup() {
3636
createCanvas(710, 400);
3737
rawImpulse = loadSound('../files/' + cVerb.impulses[currentIR].name);
3838

39-
// disconnect from master output...
39+
// disconnect from main output...
4040
sound.disconnect();
4141
// ... and process with cVerb
4242
// so that we only hear the reverb
@@ -84,4 +84,4 @@ function mousePressed() {
8484

8585
function keyPressed() {
8686
rawImpulse.play();
87-
}
87+
}

examples/amplitude_analysis/sketch.js

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -79,10 +79,10 @@ function keyPressed(e) {
7979

8080
function mouseClicked() {
8181
if (mouseX > 0 && mouseX < width && mouseY > 0 && mouseY < height) {
82-
if ( getMasterVolume() == 0) {
83-
masterVolume(0, 1);
82+
if ( getOutputVolume() == 0) {
83+
outputVolume(0, 1);
8484
} else {
85-
masterVolume(0.1),1;
85+
outputVolume(0.1),1;
8686
}
8787
}
8888
}

examples/distortion/sketch.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,7 @@ function setup() {
1717
env.setADSR(0.01, 0.2, 0.1, 0.3);
1818
env.setRange(1.0, 0.0);
1919

20-
osc = new p5.SawOsc(); // connects to master output by default
20+
osc = new p5.SawOsc(); // connects to main output by default
2121
osc.start(0);
2222
osc.freq(220);
2323
osc.amp(env);

examples/envAmpFreq/sketch.js

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,7 @@ function setup() {
1616
freqEnv.setRange(300, 5000);
1717

1818

19-
osc = new p5.Oscillator(); // connects to master output by default
19+
osc = new p5.Oscillator(); // connects to main output by default
2020
osc.start(0);
2121
osc.freq(220);
2222
// osc.freq(env.scale(0,1,800,300));
@@ -32,4 +32,4 @@ function mousePressed() {
3232
function mouseReleased() {
3333
env.triggerRelease();
3434
freqEnv.triggerRelease();
35-
}
35+
}

examples/envExp/sketch.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -47,7 +47,7 @@ function setup() {
4747
myPart.start();
4848
fft = new p5.FFT();
4949
fft.setInput(osc);
50-
masterVolume(0);
50+
outputVolume(0);
5151
endPoint = width / numWaveforms;
5252
noStroke();
5353
background(20);

0 commit comments

Comments
 (0)