0
0

I’m using an oscillator sound to create a simple tone with a property driving the pitch. Everything works, but if I change the pitch quickly, I can hear rapid discrete pitches, rather than a continuous range. The device that I’m developing on doesn’t have an oscillator or synthesizer, so this appears the best I can do for now. I assume that fmod is changing the pitch by doing an FFT and shifting the data, which would explain the discrete tones. Probably the duration of a single FFT block. Is there a better way to get a rapidly changing tone that I can change programmatically?

  • You must to post comments
0
0

It doesn’t use FFT, but it only changes once per mix.
On windows, the DSP system is updated every 1024 samples by default.
This is about 21ms. You can use System::setDSPBufferSize to change this, and make the dsp buffer size smaller.
Make sure the dspbuffersize and dspnumbuffer values multiply to the same value though.
By default it is 1024 samples * 4 = 4096 total.
You could change it to 256 * 16 = 4096 total.
You would get better granularity with 256, going from 20ms to 5ms.
You can go lower, but note the smaller the buffer size is, the higher the CPU usage will become.

  • You must to post comments
Showing 1 result
Your Answer

Please first to submit.