示例#1
0
 public SimplifiedMeasure(Measure measure, WriterInfo info)
 {
     BPM        = measure.Bpm;
     NumBeats   = measure.TimeSignature.NumberOfBeats;
     BeatLength = (int)measure.TimeSignature.BeatType;
     Chords     = createChords(measure, info);
 }
示例#2
0
        public SimplifiedNote(Note note, WriterInfo info)
        {
            Fret    = note.Fret;
            String  = note.String;
            Effects = createEffects(note, info);

            info.readInSimplifiedNote(this, note);
        }
示例#3
0
 public static SimplifiedChord createSimplifiedChord(Chord chord, WriterInfo info)
 {
     if (chord is NoteChord)
     {
         return(new SimplifiedNoteChord(chord as NoteChord, info));
     }
     else
     {
         return(new SimplifiedChord(chord));
     }
 }
示例#4
0
        public SimplifiedMeasure[] createMeasures(Part part, WriterInfo info)
        {
            var arr   = new SimplifiedMeasure[part.ModelCollection.Count()];
            int index = 0;

            foreach (Measure measure in part.ModelCollection.Items())
            {
                arr[index] = new SimplifiedMeasure(measure, info);
                index++;
            }

            return(arr);
        }
示例#5
0
        public SimplifiedNote[] createNotes(NoteChord chord, WriterInfo info)
        {
            var arr   = new SimplifiedNote[chord.ModelCollection.Count()];
            int index = 0;

            foreach (Note note in chord.ModelCollection.Items())
            {
                arr[index] = new SimplifiedNote(note, info);
                index++;
            }

            return(arr);
        }
示例#6
0
        public SimplifiedChord[] createChords(Measure measure, WriterInfo info)
        {
            var arr   = new SimplifiedChord[measure.ModelCollection.Count()];
            int index = 0;

            foreach (Chord chord in measure.ModelCollection.Items())
            {
                arr[index] = SimplifiedChord.createSimplifiedChord(chord, info);
                index++;
            }

            return(arr);
        }
示例#7
0
        public SimplifiedPart(Part part, WriterInfo info)
        {
            SongName       = part.SongInfo.SongName;
            ArtistName     = part.SongInfo.ArtistName;
            AlbumName      = part.SongInfo.AlbumName;
            InstrumentType = (int)part.InstrumentInfo.Type;
            NumStrings     = part.InstrumentInfo.Strings;

            BPM        = part.DefaultBPM;
            NumBeats   = part.TimeSignature.NumberOfBeats;
            BeatLength = (int)part.TimeSignature.BeatType;

            Measures = createMeasures(part, info);
            Effects  = info.getMultiEffects();
        }
示例#8
0
        public SimplifiedEffect[] createEffects(Note note, WriterInfo info)
        {
            int num_single_effects = note.ModelCollection.getItemsMatchingCondition(e => !(e is IMultiEffect)).Count();
            var arr   = new SimplifiedEffect[num_single_effects];
            int index = 0;

            foreach (var effect in note.ModelCollection.Items())
            {
                var s_effect = SimplifiedEffect.createSimplifiedEffect(effect, info);
                if (s_effect != null)
                {
                    arr[index] = s_effect;
                    index++;
                }
            }
            return(arr);
        }
示例#9
0
 public static SimplifiedEffect createSimplifiedEffect(IEffect effect, WriterInfo info)
 {
     if (effect is IMultiEffect)
     {
         info.createSimplifiedMultiEffect(effect as IMultiEffect);
     }
     else if (effect is PalmMute)
     {
         return(new SimplifiedPalmMute());
     }
     else if (effect is Bend)
     {
         return(new SimplifiedBend(effect as Bend));
     }
     else if (effect is PinchHarmonic)
     {
         return(new SimplifiedPinchHarmonic());
     }
     else if (effect is Vibrato)
     {
         return(new SimplifiedVibrato(effect as Vibrato));
     }
     return(null);
 }
示例#10
0
 public SimplifiedNoteChord(NoteChord chord, WriterInfo info)
     : base(chord)
 {
     Notes = createNotes(chord, info);
 }