private void GenerateTutorialClips() { ChordProgression chordProgression = chordProgressionLibrary.GetFirstChordProgression(); Rhythm rhythm = GetRandomEnum <Rhythm>(); Tempo tempo = GetRandomEnum <Tempo>(); Key key = GetRandomEnum <Key>(); for (int i = 0; i < loopCount; i++) { for (int j = 0; j < 2; j++) { MusicalChange change = GetRandomMusicalChange(); if (change == MusicalChange.Tempo) { tempo = GetRandomEnumOtherThan(tempo); } else { rhythm = GetRandomEnumOtherThan(rhythm); } int chordIndex = 0; for (int k = 0; k < 4; k++) { PercussionMusicClip percussionClip = percussionClipLibrary.GetRandomClipWithRhythmAndTempo(rhythm, tempo); InputMusicClip inputClip = inputClipLibrary.GetClipWithInstrumentAndChord( Instrument.ElectricGuitar, KeyNotationToChordHelper.GetChord(key, chordProgression.chords[chordIndex])); MusicClip clip = new MusicClip(percussionClip, inputClip, null); musicMixer.QueueClip(clip); chordIndex++; } } } }
private void QueueClips() { activeClipSet = clipSetProvider.GetFirstClipSet(); for (int i = 0; i < activeClipSet.ClipCount; i++) { musicMixer.QueueClip(activeClipSet.MusicClips[i]); } for (int j = 0; j < clipSetsPerSong - 1; j++) { activeClipSet = clipSetProvider.GetNextClipSet(clipResults.ToArray()); for (int i = 0; i < activeClipSet.ClipCount; i++) { musicMixer.QueueClip(activeClipSet.MusicClips[i]); } } }