-
-
Notifications
You must be signed in to change notification settings - Fork 1k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
TripleOscillator with hi-pass produces different output depending on the export settings #5749
Comments
Confirmed. I see this effect on all hi-pass filters with 2x oversampling and the bug is in lmms-1.2.2 too. |
TripleOscillator's noise oscillator is not band-limited, which makes the loudness of specific spectral region depend on the sampling rate. |
The samplerate conversion would explain a lot of the problems, but as far as I know no such thing happens during export or live playback unless oversampling is set. There is no "project sample rate", but the instruments themselves work at the samplerate specified for the current operation. The default 44.1kHz is only used during playback and is changed to the specified value when the export starts. Using jack, I changed the playback samplerate to 96kHz. The sound is correct when played live and the exported files are also the same as with 44.1. So I think there is no connection between playback and export in this sense. I put a Glame low-pass filter on the track and turned the cutoff frequency all the way up. The difference is inaudible but it makes the exported file correct, so I aggree that the main problem is 3osc making a non-bandlimited signal. Also tested with a saw wave, without the low-pass it's aliasing like hell, but sounds perfectly fine with low-pass on it. |
By "project sample rate" I meant It is true that TripleOsc ideally should not produce any content over ~20 kHz, and there is already #4397 which fixes the issue for all waveform types except noise. My point was that even if we make sure all LMMS native instruments are band-limited, there are still external plugins or other possible sources of signal that goes above 20 kHz. That's why I think the real problem could be in the way how sample rates are managed and converted -- if done properly, re-sampling to a different rate should not cause this sort of aliasing, even if it starts with signals that have high frequency content. |
Either TripleOscillator's noise generator or the Hi-pass filter has a bug, causing the exported file to sound differently with different export settings, which even includes whether you use the graphical interface or the command line.
I made a project file on which the problem comes out very clearly, and exported it with a few different settings, using both gui and cli. The interpolation was "sincmedium" on every file.
Here is the project and the exported wav files.
Affected versions: current master and most probably 1.2.2 too.
The text was updated successfully, but these errors were encountered: