Пример #1
0
        public Interval GetIntervalUp(Note lowerNote, IntervalType intervalType)
        {
            //initialize master note carousel...
            GetMasterNote(lowerNote.MasterNoteType);

            //turn, turn, turn
            for (int i = 0; i < (int)intervalType.MasterIntervalType; i++)
            {
                _masterNote = _masterNote.StepUp.Upper;
            }

            //NoteType of resulting masternote is the note we want.
            Note upperNote = new Note(_masterNote.MasterNoteType);

            //Calculate Accidentials
            int availableSteps = GetStepCountBetween(lowerNote.MasterNoteType, upperNote.MasterNoteType);
            int requiredSteps  = intervalType.HalfStepCount;

            int resultingAccidentials = requiredSteps - (availableSteps - (int)lowerNote.Accidentials);

            upperNote.Accidentials = (Accidentials)resultingAccidentials;

            return(new Interval(lowerNote, upperNote));
        }
Пример #2
0
 public Interval(IntervalType intervalType, Note upperNote)
 {
 }
Пример #3
0
 public Interval(Note lowerNote, IntervalType intervalType)
 {
     //get the master note row to calculate upper note
     MasterNoteRow masterNoteRow = new MasterNoteRow();
 }