author | mickeyl <mickeyl> | 2004-04-04 13:54:40 (UTC) |
---|---|---|
committer | mickeyl <mickeyl> | 2004-04-04 13:54:40 (UTC) |
commit | 16cf79e90b5217f8d4bfce2a0fa817ae4b73db36 (patch) (side-by-side diff) | |
tree | 0701eae15aa606a0211a2fccfde0eafdac69357c /noncore/multimedia/tonleiter/tonleiterdatahelper.cpp | |
parent | 8d2d2664e5f544b8292806e617deb7a0e4170dc0 (diff) | |
download | opie-16cf79e90b5217f8d4bfce2a0fa817ae4b73db36.zip opie-16cf79e90b5217f8d4bfce2a0fa817ae4b73db36.tar.gz opie-16cf79e90b5217f8d4bfce2a0fa817ae4b73db36.tar.bz2 |
convert to Opie Debugging Framework
Diffstat (limited to 'noncore/multimedia/tonleiter/tonleiterdatahelper.cpp') (more/less context) (ignore whitespace changes)
-rw-r--r-- | noncore/multimedia/tonleiter/tonleiterdatahelper.cpp | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/noncore/multimedia/tonleiter/tonleiterdatahelper.cpp b/noncore/multimedia/tonleiter/tonleiterdatahelper.cpp index d904a71..285d2c1 100644 --- a/noncore/multimedia/tonleiter/tonleiterdatahelper.cpp +++ b/noncore/multimedia/tonleiter/tonleiterdatahelper.cpp @@ -13,49 +13,49 @@ int Note::getOctaveOfNote(int note) QString Note::getNameOfNote(int note) { int octave=getOctaveOfNote(note); return notenames[note-12*octave]; } //**************************************************************************** int Note::getNoteFromName(QString name,int octave) { int notevalue=0; for(int a=0;a<12;a++) { if(name==notenames[a]) { notevalue=a; break; } } return notevalue+12*octave; } //**************************************************************************** int Note::octaveOfBaseNote(int base,int note) { int normnote = (note>=base) ? note-base : (12-base)+note; int octave=getOctaveOfNote(normnote); - //qDebug("note %d of %d base is norm %d -> ocatve %d",note,base,normnote,octave); + //odebug << "note " << note << " of " << base << " base is norm " << normnote << " -> ocatve " << octave << "" << oendl; return octave; } //**************************************************************************** //**************************************************************************** Instrument::Instrument() { name="UNDEFINED"; frets=0; } //**************************************************************************** Instrument::Instrument(QString name,int frets,QValueList<int> strings) :name(name),frets(frets),strings(strings) { } //**************************************************************************** Instrument::~Instrument() { } //**************************************************************************** int Instrument::noOfStrings() { return (int)strings.count(); } //**************************************************************************** @@ -110,35 +110,35 @@ int Scale::noOfHaltones() return (int)halftones.count(); } //**************************************************************************** int Scale::getHalfTone(int id) { if(id>=0 && id<noOfHaltones()) return halftones[id]; else return 0; } //**************************************************************************** QString Scale::scaleName() { return name; } //**************************************************************************** bool Scale::noteInScale(int base,int note) { int octave=Note::getOctaveOfNote(note); note-=12*octave; int normnote = (note>=base) ? note-base : (12-base)+note; if(halftones.contains(normnote)>0) { - //qDebug("OK : base : %d, note %d -> norm %d",base,note,normnote); + //odebug << "OK : base : " << base << ", note " << note << " -> norm " << normnote << "" << oendl; return true; } else { - //qDebug("BAD : base : %d, note %d -> norm %d",base,note,normnote); + //odebug << "BAD : base : " << base << ", note " << note << " -> norm " << normnote << "" << oendl; return false; } } //**************************************************************************** //**************************************************************************** |