Verovio
Source code documentation
vrv::Transposer Class Reference

Public Member Functions

void SetMaxAccid (int maxAccid)
 
int GetMaxAccid ()
 
void SetBase40 ()
 
void SetBase600 ()
 
int GetBase ()
 
bool SetTransposition (int transVal)
 
bool SetTransposition (const std::string &transString)
 
bool SetTransposition (const TransPitch &fromPitch, const std::string &toString)
 
bool SetTransposition (int keyFifths, int semitones)
 
bool SetTransposition (int keyFifths, const std::string &semitones)
 
int GetTranspositionIntervalClass ()
 
std::string GetTranspositionIntervalName ()
 
void Transpose (TransPitch &pitch)
 
int Transpose (int iPitch)
 
void Transpose (TransPitch &pitch, int transVal)
 
void Transpose (TransPitch &pitch, const std::string &transString)
 
std::string GetIntervalName (const TransPitch &p1, const TransPitch &p2)
 
std::string GetIntervalName (int intervalClass)
 
int GetInterval (const std::string &intervalName)
 
int TransPitchToIntegerPitch (const TransPitch &pitch)
 
TransPitch IntegerPitchToTransPitch (int ipitch)
 
int GetInterval (const TransPitch &p1, const TransPitch &p2)
 
std::string SemitonesToIntervalName (int keyFifths, int semitones)
 
int SemitonesToIntervalClass (int keyFifths, int semitones)
 
int IntervalToSemitones (int intervalClass)
 
int IntervalToSemitones (const std::string &intervalName)
 
int IntervalToCircleOfFifths (const std::string &transString)
 
int IntervalToCircleOfFifths (int transval)
 
std::string CircleOfFifthsToIntervalName (int fifths)
 
int CircleOfFifthsToIntervalClass (int fifths)
 
bool GetKeyTonic (const std::string &keyTonic, TransPitch &tonic)
 
TransPitch CircleOfFifthsToMajorTonic (int fifths)
 
TransPitch CircleOfFifthsToMinorTonic (int fifths)
 
TransPitch CircleOfFifthsToDorianTonic (int fifths)
 
TransPitch CircleOfFifthsToPhrygianTonic (int fifths)
 
TransPitch CircleOfFifthsToLydianTonic (int fifths)
 
TransPitch CircleOfFifthsToMixolydianTonic (int fifths)
 
TransPitch CircleOfFifthsToLocrianTonic (int fifths)
 
std::string DiatonicChromaticToIntervalName (int diatonic, int chromatic)
 
int DiatonicChromaticToIntervalClass (int diatonic, int chromatic)
 
void IntervalToDiatonicChromatic (int &diatonic, int &chromatic, int intervalClass)
 
void IntervalToDiatonicChromatic (int &diatonic, int &chromatic, const std::string &intervalName)
 
int PerfectUnisonClass ()
 
int MinorSecondClass ()
 
int MajorSecondClass ()
 
int MinorThirdClass ()
 
int MajorThirdClass ()
 
int PerfectFourthClass ()
 
int PerfectFifthClass ()
 
int MinorSixthClass ()
 
int MajorSixthClass ()
 
int MinorSeventhClass ()
 
int MajorSeventhClass ()
 
int PerfectOctaveClass ()
 
int GetCPitchClass ()
 
int GetDPitchClass ()
 
int GetEPitchClass ()
 
int GetFPitchClass ()
 
int GetGPitchClass ()
 
int GetAPitchClass ()
 
int GetBPitchClass ()
 

Static Public Member Functions

static bool IsValidIntervalName (const std::string &name)
 
static bool IsValidKeyTonic (const std::string &name)
 
static bool IsValidSemitones (const std::string &name)
 

Protected Attributes

int m_base
 
int m_maxAccid
 
int m_transpose
 
std::vector< int > m_diatonicMapping
 
const std::vector< int > m_diatonic2semitone { 0, 2, 4, 5, 7, 9, 11 }
 

The documentation for this class was generated from the following file: