Skip to content

Commit 01ebcd9

Browse files
committed
fix: spelling
1 parent 6d093c8 commit 01ebcd9

File tree

2 files changed

+5
-4
lines changed

2 files changed

+5
-4
lines changed

src/node/channel_splitter.rs

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -147,7 +147,8 @@ impl ChannelSplitterNode {
147147
context.base().register(move |registration| {
148148
assert_valid_number_of_channels(options.number_of_outputs);
149149

150-
// if channel count has been explicitely set, we need to check its value against number of outputs
150+
// if channel count has been explicitly set, we need to check
151+
// its value against number of outputs
151152
if options.audio_node_options.channel_count != DEFAULT_NUMBER_OF_OUTPUTS {
152153
assert_valid_channel_count(
153154
options.audio_node_options.channel_count,

src/node/oscillator.rs

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,7 @@ use super::{
1414
TABLE_LENGTH_USIZE,
1515
};
1616

17-
fn get_fase_incr(freq: f32, detune: f32, sample_rate: f64) -> f64 {
17+
fn get_phase_incr(freq: f32, detune: f32, sample_rate: f64) -> f64 {
1818
let computed_freq = freq as f64 * (detune as f64 / 1200.).exp2();
1919
let clamped = computed_freq.clamp(-sample_rate / 2., sample_rate / 2.);
2020
clamped / sample_rate
@@ -411,7 +411,7 @@ impl AudioProcessor for OscillatorRenderer {
411411
}
412412

413413
if frequency_values.len() == 1 && detune_values.len() == 1 {
414-
let phase_incr = get_fase_incr(frequency_values[0], detune_values[0], sample_rate);
414+
let phase_incr = get_phase_incr(frequency_values[0], detune_values[0], sample_rate);
415415
channel_data
416416
.iter_mut()
417417
.for_each(|output| self.generate_sample(output, phase_incr, &mut current_time, dt));
@@ -421,7 +421,7 @@ impl AudioProcessor for OscillatorRenderer {
421421
.zip(frequency_values.iter().cycle())
422422
.zip(detune_values.iter().cycle())
423423
.for_each(|((output, &f), &d)| {
424-
let phase_incr = get_fase_incr(f, d, sample_rate);
424+
let phase_incr = get_phase_incr(f, d, sample_rate);
425425
self.generate_sample(output, phase_incr, &mut current_time, dt)
426426
});
427427
}

0 commit comments

Comments
 (0)