Skip to content

Commit

Permalink
Fix FIR scaling on reload
Browse files Browse the repository at this point in the history
  • Loading branch information
HEnquist committed Sep 17, 2020
1 parent d681b24 commit 1f19837
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 1 deletion.
1 change: 1 addition & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,7 @@ Bugfixes:
- Fix websocket `exit` command.
- Correct response of `setconfigname` websocket command.
- Fix buffer underrun soon after starting Alsa playback.
- Correct scaling of FIR coefficients when reloading config.


## 0.3.1
Expand Down
2 changes: 1 addition & 1 deletion src/fftconv.rs
Original file line number Diff line number Diff line change
Expand Up @@ -167,7 +167,7 @@ impl Filter for FFTConv {

for (n, coeff) in coeffs.iter().enumerate() {
coeffs_padded[n / self.npoints][n % self.npoints] =
coeff / (2.0 * self.npoints as PrcFmt);
coeff / (self.npoints as PrcFmt);
}

for (segment, segment_f) in coeffs_padded.iter_mut().zip(coeffs_f.iter_mut()) {
Expand Down

0 comments on commit 1f19837

Please sign in to comment.