annotate base/Pitch.h @ 64:6cb2b3cd5356

* Refactor FFT a little bit so as to separate construction and processing rather than have a single static method -- will make it easier to use a different implementation * pull in KissFFT implementation (not hooked up yet)
author cannam
date Wed, 13 May 2009 09:19:12 +0000
parents d7116e3183f8
children e5907ae6de17
rev   line source
cannam@0 1 /* -*- c-basic-offset: 4 indent-tabs-mode: nil -*- vi:set ts=8 sts=4 sw=4: */
cannam@0 2
cannam@0 3 /*
cannam@0 4 QM DSP library
cannam@0 5 Centre for Digital Music, Queen Mary, University of London.
cannam@0 6 This file Copyright 2006 Chris Cannam.
cannam@0 7 All rights reserved.
cannam@0 8 */
cannam@0 9
cannam@0 10 #ifndef _PITCH_H_
cannam@0 11 #define _PITCH_H_
cannam@0 12
cannam@0 13 class Pitch
cannam@0 14 {
cannam@0 15 public:
cannam@0 16 static float getFrequencyForPitch(int midiPitch,
cannam@0 17 float centsOffset = 0,
cannam@0 18 float concertA = 440.0);
cannam@0 19
cannam@0 20 static int getPitchForFrequency(float frequency,
cannam@0 21 float *centsOffsetReturn = 0,
cannam@0 22 float concertA = 440.0);
cannam@0 23 };
cannam@0 24
cannam@0 25
cannam@0 26 #endif