saebekassebil / teoria

Javascript taught Music Theory
http://saebekassebil.github.io/teoria
MIT License
1.32k stars 114 forks source link

Interval direction is incorrect on d-2 #40

Closed saebekassebil closed 11 years ago

saebekassebil commented 11 years ago

A downwards diminished second (which is 0 semitones and enharmonic to a unison), returns its direction as 'up':

teoria.interval('d-2').direction() === 'up'

Although this is far out, this should be corrected, so that the direction of an interval always sticks no matter how silly it is.

The current usage of #semitones() to measure direction is flawed and should be fixed.