protected EffectsOnNote ReadEffectsOnNote() { EffectsOnNote effects = new EffectsOnNote(); byte header = ReadByte(); effects.Slide = (((header & 0x04) != 0)) ? Slide.FromAbove : Slide.NoSlide; effects.HammerOnPullOff = (header & 0x02) != 0; if ((header & 0x01) != 0) { effects.Bend = ReadBend(); } if ((header & 0x10) != 0) { effects.GraceNote = ReadGraceNote(); } return(effects); }
protected EffectsOnNote ReadEffectsOnNote() { EffectsOnNote effects = new EffectsOnNote(); byte header1 = ReadByte(); byte header2 = ReadByte(); // Bend present if ((header1 & 0x01) != 0) { effects.Bend = ReadBend(); } // Interpretation of the FIRST header // Grace note present) if ((header1 & 0x10) != 0) { effects.GraceNote = ReadGraceNote(); } // Tremolo picking present if ((header2 & 0x04) != 0) { effects.TremoloPicking = ReadEnum <Duration>(); } // Slide from the current note present if ((header2 & 0x08) != 0) { //var slide = ReadEnum<Slide>(); effects.Slide = ReadEnum <Slide>(); } // Harmonic note present..this causes the Effects on Beat to be set if ((header2 & 0x10) != 0) { /*effects.Harmonic = ReadEnum<Harmonic>(); * if (effects.Harmonic == Harmonic.Artificial) * Skip(3); * else if (effects.Harmonic == Harmonic.Tapped) * Skip(1);*/ var type = ReadByte(); if (type == 1) { effects.Harmonic = Harmonic.Natural; } else if (type == 2) { Skip(3); effects.Harmonic = Harmonic.Artificial; } else if (type == 3) { Skip(1); effects.Harmonic = Harmonic.Tapped; } else if (type == 4) { effects.Harmonic = Harmonic.Pitch; } else if (type == 5) { effects.Harmonic = Harmonic.Semi; } } // Trill present if ((header2 & 0x20) != 0) { effects.Trill = ReadTrill(); } // Let-ring present effects.LetRing = (header1 & 0x08) != 0; // hammer-on or a pull-off from the current note present effects.HammerOnPullOff = (header1 & 0x02) != 0; // Interpretation of the SECOND header // Left-hand vibrato present..this causes the Effects on Beat to be set effects.LeftHandVibrato = (header2 & 0x40) != 0; // Palm Mute present effects.PalmMute = (header2 & 0x02) != 0; // Note played staccato effects.Staccato = (header2 & 0x01) != 0; return(effects); }
protected EffectsOnNote ReadEffectsOnNote() { EffectsOnNote effects = new EffectsOnNote(); byte header1 = ReadByte(); byte header2 = ReadByte(); // Bend present if ((header1 & 0x01) != 0) { effects.Bend = ReadBend(); } // Interpretation of the FIRST header // Grace note present) if ((header1 & 0x10) != 0) { effects.GraceNote = ReadGraceNote(); } // Tremolo picking present if ((header2 & 0x04) != 0) { effects.TremoloPicking = ReadEnum <Duration>(); } // Slide from the current note present if ((header2 & 0x08) != 0) { effects.Slide = ReadEnum <Slide>(); } // Harmonic note present..this causes the Effects on Beat to be set if ((header2 & 0x10) != 0) { effects.Harmonic = ReadEnum <Harmonic>(); } // Trill present if ((header2 & 0x20) != 0) { effects.Trill = ReadTrill(); } // Let-ring present effects.LetRing = (header1 & 0x08) != 0; // hammer-on or a pull-off from the current note present effects.HammerOnPullOff = (header1 & 0x02) != 0; // Interpretation of the SECOND header // Left-hand vibrato present..this causes the Effects on Beat to be set effects.LeftHandVibrato = (header2 & 0x40) != 0; // Palm Mute present effects.PalmMute = (header2 & 0x02) != 0; // Note played staccato effects.Staccato = (header2 & 0x01) != 0; return(effects); }
protected EffectsOnNote ReadEffectsOnNote() { EffectsOnNote effects = new EffectsOnNote(); byte header1 = ReadByte(); byte header2 = ReadByte(); // Bend present if ((header1 & 0x01) != 0) effects.Bend = ReadBend(); // Interpretation of the FIRST header // Grace note present) if ((header1 & 0x10) != 0) effects.GraceNote = ReadGraceNote(); // Tremolo picking present if ((header2 & 0x04) != 0) effects.TremoloPicking = ReadEnum<Duration>(); // Slide from the current note present if ((header2 & 0x08) != 0) effects.Slide = ReadEnum<Slide>(); // Harmonic note present..this causes the Effects on Beat to be set if ((header2 & 0x10) != 0) effects.Harmonic = ReadEnum<Harmonic>(); // Trill present if ((header2 & 0x20) != 0) effects.Trill = ReadTrill(); // Let-ring present effects.LetRing = (header1 & 0x08) != 0; // hammer-on or a pull-off from the current note present effects.HammerOnPullOff = (header1 & 0x02) != 0; // Interpretation of the SECOND header // Left-hand vibrato present..this causes the Effects on Beat to be set effects.LeftHandVibrato = (header2 & 0x40) != 0; // Palm Mute present effects.PalmMute = (header2 & 0x02) != 0; // Note played staccato effects.Staccato = (header2 & 0x01) != 0; return effects; }
protected EffectsOnNote ReadEffectsOnNote() { EffectsOnNote effects = new EffectsOnNote(); byte header = ReadByte(); effects.Slide = (((header & 0x04) != 0)) ? Slide.FromAbove : Slide.NoSlide; effects.HammerOnPullOff = (header & 0x02) != 0; if ((header & 0x01) != 0) effects.Bend = ReadBend(); if ((header & 0x10) != 0) effects.GraceNote = ReadGraceNote(); return effects; }
protected EffectsOnNote ReadEffectsOnNote() { EffectsOnNote effects = new EffectsOnNote(); byte header1 = ReadByte(); byte header2 = ReadByte(); // Bend present if ((header1 & 0x01) != 0) effects.Bend = ReadBend(); // Interpretation of the FIRST header // Grace note present) if ((header1 & 0x10) != 0) effects.GraceNote = ReadGraceNote(); // Tremolo picking present if ((header2 & 0x04) != 0) effects.TremoloPicking = ReadEnum<Duration>(); // Slide from the current note present if ((header2 & 0x08) != 0) { //var slide = ReadEnum<Slide>(); effects.Slide = ReadEnum<Slide>(); } // Harmonic note present..this causes the Effects on Beat to be set if ((header2 & 0x10) != 0) { /*effects.Harmonic = ReadEnum<Harmonic>(); if (effects.Harmonic == Harmonic.Artificial) Skip(3); else if (effects.Harmonic == Harmonic.Tapped) Skip(1);*/ var type = ReadByte(); if (type == 1) { effects.Harmonic = Harmonic.Natural; } else if (type == 2) { Skip(3); effects.Harmonic = Harmonic.Artificial; } else if (type == 3) { Skip(1); effects.Harmonic = Harmonic.Tapped; } else if (type == 4) { effects.Harmonic = Harmonic.Pitch; } else if (type == 5) { effects.Harmonic = Harmonic.Semi; } } // Trill present if ((header2 & 0x20) != 0) effects.Trill = ReadTrill(); // Let-ring present effects.LetRing = (header1 & 0x08) != 0; // hammer-on or a pull-off from the current note present effects.HammerOnPullOff = (header1 & 0x02) != 0; // Interpretation of the SECOND header // Left-hand vibrato present..this causes the Effects on Beat to be set effects.LeftHandVibrato = (header2 & 0x40) != 0; // Palm Mute present effects.PalmMute = (header2 & 0x02) != 0; // Note played staccato effects.Staccato = (header2 & 0x01) != 0; return effects; }