Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/adamski/pitch_detector
JUCE module for pitch estimation
https://github.com/adamski/pitch_detector
juce pitch-estimation
Last synced: 3 months ago
JSON representation
JUCE module for pitch estimation
- Host: GitHub
- URL: https://github.com/adamski/pitch_detector
- Owner: adamski
- Created: 2015-10-16T13:21:54.000Z (about 9 years ago)
- Default Branch: master
- Last Pushed: 2023-01-03T20:51:12.000Z (almost 2 years ago)
- Last Synced: 2024-05-12T06:33:47.573Z (6 months ago)
- Topics: juce, pitch-estimation
- Language: C++
- Size: 25.4 KB
- Stars: 131
- Watchers: 5
- Forks: 9
- Open Issues: 4
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
- awesome-juce - pitch_detector
README
# Pitch Detector
JUCE module for pitch estimationPitchYIN class based on the YIN implementation found in the [aubio](https://aubio.org) library
PitchMPM class adapted from the McLeod Pitch Method implementation in https://github.com/sevagh/pitch-detection
The updated version of the PitchMPM class now uses FFT for the auto-correlation function using the AudioFFT library (via the module wrapper at https://github.com/adamski/audio_fft). The previous time-based version is now in the `time-based` branch.
### Usage
**NOTE:** `bufferSize` should be a power of 2!
```cpp
// Class members
PitchMPM pitchMPM;
AudioSampleBuffer sampleBuffer;// Setup / prepare
pitchMPM.setBufferSize (bufferSize);
pitchMPM.setSampleRate (sampleRate);// Process
float newPitch = pitchMPM.getPitch (sampleBuffer.getReadPointer (0));
```### TODO
- [ ] Seperate time-based method into another class that can be used as an alternative to the FFT based method
- [ ] Add FFT based YIN implementation (not a priority, MPM works well for my needs - PR's welcome)
- [ ] Create base (virtual) `Pitch` class and add implementations as subclasses.
- [ ] Add other methods, e.g. Wavelet?
- [ ] Remove JUCE dependency from implementations so that they can be used on embedded platforms, e.g. Arduino/Teensy. Will also need 'pluggable' FFT methods for this to work.