Pitch shift in cents?

Hi!
Is there a way to make the included pitch shifter work in cents instead of semitones, or is there something else I could use to get a detuning effect on an audio signal? Could I modify the pitch shifter library and make my own variant?

Based on the code it looks like it’s hardcoded to work in semi tones.

It’s probably possible to make a copy and modify it for your needs. I think the biggest hurdle is understanding if the ‘semitone_ratios_’ lookup table is needed. Maybe it’s for performance reasons?

I used the pitch shifter from here: Fix/pitch shift by stephenhensley · Pull Request #166 · electro-smith/DaisySP · GitHub

The set transpose function in the pitch shifter class accepts a float without quantizing it to semitones so you are not limited to just semitones (like if it were a integer). If there are 100 cents in a semitone, then setting the transpose to 1.01 would be 1 cent, 1.02 is 2 cents, etc

I have some code here that acts like the digitech ricochet in momentary mode

start at 0:42 for momentary mode where this is relevant

and it sets the transpose target constantly (as a float)

1 Like

Thx a lot! I´m getting in to this later today. Just hope I’ll figure out how to implement this in my own project written in daisyduino!

1 Like

I got it working with the edited library you pointed me to, much appreciated! The chains of the semitones now broken :slight_smile:

1 Like