/[svn]/linuxsampler/trunk/src/common/RTMath.cpp
ViewVC logotype

Diff of /linuxsampler/trunk/src/common/RTMath.cpp

Parent Directory Parent Directory | Revision Log Revision Log | View Patch Patch

revision 318 by schoenebeck, Tue Apr 27 09:21:58 2004 UTC revision 319 by schoenebeck, Mon Dec 13 00:46:42 2004 UTC
# Line 22  Line 22 
22    
23  #include "RTMath.h"  #include "RTMath.h"
24    
25  float  RTMath::CentsToFreqTable[MAX_PITCH * 1200 * 2 + 1]; // +-1200 cents per octave  float  RTMathBase::CentsToFreqTable[MAX_PITCH * 1200 * 2 + 1]; // +-1200 cents per octave
26  float* RTMath::pCentsToFreqTable(InitCentsToFreqTable());  float* RTMathBase::pCentsToFreqTable(InitCentsToFreqTable());
27    
28  /**  /**
29   * Will automatically be called once to initialize the 'Cents to frequency   * Will automatically be called once to initialize the 'Cents to frequency
30   * ratio' table.   * ratio' table.
31   */   */
32  float* RTMath::InitCentsToFreqTable() {  float* RTMathBase::InitCentsToFreqTable() {
33      float* pMiddleOfTable = &CentsToFreqTable[MAX_PITCH * 1200];      float* pMiddleOfTable = &CentsToFreqTable[MAX_PITCH * 1200];
34      for (int i = -1200; i <= 1200; i++) {      for (int i = -1200; i <= 1200; i++) {
35          pMiddleOfTable[i] = pow(TWELVEHUNDREDTH_ROOT_OF_TWO, i);          pMiddleOfTable[i] = pow(TWELVEHUNDREDTH_ROOT_OF_TWO, i);

Legend:
Removed from v.318  
changed lines
  Added in v.319

  ViewVC Help
Powered by ViewVC