You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
@m4b Currently, that's how it works (48000 only) but I'm starting to re-think that decision (it should work at any sample rate). In the meantime, fon::Stream can be used to resample the audio if it must be 44100.
@m4b It was a simplification I did when changing the API. In the new twang, all of the oscillators are independent of each other and do not share state with the Synth, like they did in the previous version. The Synth used to store sample rate, and decide how much to move the frequency counter based on that. Now there's no frequency counter, so no way for the oscillators to know what the sample rate is, so I made them all assume 48000. I should be able to change it, once I figure out #16. There might be another way to support other sample rates before that, but it needs some thought.
I'm hitting this assert here: https://docs.rs/twang/latest/src/twang/synth.rs.html#54
Is this intended? I have a sample rate of 44100 coming from default cpal config, is it a requirement the sample rate is 48000, if i want to do, e.g.:
The text was updated successfully, but these errors were encountered: