Implemented PitchDetector::setSampleRate method.