0

I am using an AKMIDINode linked to an AKOscillatorBank. I would like that each time a note is played by AKOscillatorBank, the phase of the wavetable is randomly selected. It seams that AudioKit do not provide a such feature. I had a quick look at the C++ implementation, deep to AKBankDSPKernel, bit it is not clear to me how independent the synthesis of different notes on a single oscillator are.

Would it be possible to overload in swift part of AKOscillatorBank to make each midi note use a different offset when looking at the AKTable ?

This feature can drastically improve the sounding of the attack of a chord when using "warms" wave table and slow/inexistant attack time, especially sawtooth. It will greatly improve the sound of my product.

Kaushik Makwana
  • 1,329
  • 2
  • 14
  • 24
Jeremy Cochoy
  • 2,480
  • 2
  • 24
  • 39

1 Answers1

1

The oscillator bank kernel contains a NoteState struct which holds the oscillator state for each voice, I believe. I suppose you could use a sp_tabread_compute to read the samples from a wavetable (as in AKPhaseDistortionOscillator) and randomize its offset in the noteOn function.

Corné
  • 21
  • 2