Pitch shifter / transposer comparison
Hi,
I'm in the process of making a polyphonic vocal harmonizer, so the first step was to compare different ways of doing real-time pitch shifting, as there is quite a bunch of approaches in Max for this, and it's always hard to choose a tool without real world comparison with its competitors.
That's why I made this little patch I wanted to share as I though it might be helpful to some of you.
The comparison includes:
pitchshift~
a gen~ patch from the examples
pfft~ gizmo~
retune~
supervp.trans~ from the SuperVP package available for free on forum.ircam (require a free account).
psych~ from the Max Sound Box freely available on the ircam forum as well
There's a kslider/midi entry so you can choose which note to transpose to. That mean's there is also some pitch detection (using retune~) and the required math for each object to output the same note (some of them take a frequency ratio, others an amount of cents, and others just the desired frequency).
In my case I found that psych~ is the best compromise, with consistent quality across a wide shifting range, relatively low latency and CPU usage. It's very close to retune~ (maybe the same PSOLA algorithm under the hood?), but with a bit more control. However it seems quite buggy if you start to use different kinds of pitch controls (using combination of trans, pitch and freq messages) and polyphony.
Supervp.trans~ sounds better in my opinion, is much more flexible for fine tuning the result, but its hard to keep a low latency with comfortable window size for low ends. Also, I couldn't have more than 3 instances of it (using mc.poly~) without CPU overload and hearing cracklings, while the same laptop can handle 24 instances of retune~ or psych~ with ease.
For the seek of completion, this topic has already been discussed, like here with some sadly offline patches, or there with some tapein/out~ based patches - not included in my patch. There are also shifter~ from Tristan Jehan, grainstretch~ and diracLE~ byTimo Rozendal, and Real Time Pitch shifter (1999!) by Nobuyasu Sakonda, but they're all outdated.
What's your favorite, for which use case?
Do you think of any other object I might have not heard of?
At the end, my goal is more or less to reproduce what's Ircam's Virtual Choir is capable of, but with more control on voice behavior, especially to create some chaos and control each separate voice group in different manner. From its description it uses PSOLA, so psych~ or retune~ should be the closest in term of pitch shifting algorithm. The last feature I'm struggling to implement is maybe the most important one: "intelligent" accompaniment chord choosing regarding the selected scale, range limit and current input pitch. It's off-topic but if you have some resources about this I would be grateful! (I am already looking at Lobjects with fuzzy logic, and ml.star machine learning, but it's a steep step to take).
Thanks for reading about my journey.
EDIT
Adding options suggested in this posts answers:
VST:
AUPitch (mac, part of macOS)
Quikquak Pitchwheel (mac, win, 50£)
If you are on Mac, and you don't need PC compatibility, make sure you try the AUPitch vst~.
I use both and prefer to keep cross compatibility for now. Thanks for the tool though. I never really considered using vsts inside of Max, but why not!
If vst~ is an option, have a look at the QuikQuak Pitchwheel plugin. Very good pitch shifter with a lot of features you probably want. Mac and PC. All parameters are controllable.
Thanks Peter, adding it to the list. Quite expensive for me though, I will stay with as much free resources as I can for now.
Thanks for posting this. I'm interested in your patch, as I'm looking at pitch shifting options as well for a patch I'm building, but the "copy patch" link's not working for me. :(
Weird, it works on my side. Maybe try to click "show text" underneath the copy button, then select the code (from the first "-" to the last) and copy it manually?
What about groove~ build in shifting? Thanks for sharing this!
Ok sorry, groove is not a realtime shifter.