コード例 #1
0
 public void AddPlayed(TimedBeatId beat, IMatchResultsCollector results)
 {
     if (!patternBeats.Beats.IsEmpty)
     {
         var diff = beat.T - patternBeats.Beats.Next.T;
         if (Math.Abs(diff) <= settings.MaxMatchingTime)
         {
             var match = new BeatsMatch(patternBeats.Beats.RemoveNext(), beat, Accuracy(diff));
             results.Match(match);
             return;
         }
     }
     playedBeats.Add(beat);
 }
コード例 #2
0
 public void AddBeat(ISoundId sound, TimedBeatId beat, Velocity v)
 {
     //todo: pass sound information to matcher
     perInstrumentMatchers[sound.Instrument].AddPlayed(beat, resultsCollector);
 }
コード例 #3
0
ファイル: BeatTimesList.cs プロジェクト: Drumbits/DrumTrainer
 public void Add(TimedBeatId beat)
 {
     times.Enqueue(beat);
 }