Exemple #1
0
        /// <summary>
        /// Creates an ABC player. Uses static properties DefaultOctave and DefaultAccidentalPropagation and strict=true if
        /// arguments are left blank.
        /// </summary>
        public ABCPlayer(bool strict = true, int?octave = null, AccidentalPropagation?accidentalProp = null)
            : base()
        {
            AutoDetectLotro  = true;
            settings         = new ABCSettings();
            settings.MaxSize = 1024 * 12;

            this.strict = strict;
            accidentals = new Dictionary <string, int>();
            tiedNotes   = new Dictionary <string, int>();

            if (octave.HasValue)
            {
                this.octave = octave.Value;
            }
            else
            {
                this.octave = DefaultOctave;
            }

            if (accidentalProp.HasValue)
            {
                this.accidentalPropagation = accidentalProp.Value;
            }
            else
            {
                this.accidentalPropagation = DefaultAccidentalPropagation;
            }
        }
Exemple #2
0
        /// <summary>
        /// Creates an ABC player. Uses static properties DefaultOctave and DefaultAccidentalPropagation and strict=true if
        /// arguments are left blank.
        /// </summary>
        private ABCConverter()
        {
            accidentals = new Dictionary <string, int>();
            tiedNotes   = new Dictionary <string, int>();

            this.octave = DefaultOctave;
            this.accidentalPropagation = DefaultAccidentalPropagation;
        }
 protected EnhancedABCPlayer(bool strict = false, int?octave = null, AccidentalPropagation?accidentalProp = null)
 {
     AutoDetectLotro = true;
     Settings        = new ABCSettings {
         MaxSize = 12288
     };
     this.strict           = strict;
     accidentals           = new Dictionary <string, int>();
     tiedNotes             = new Dictionary <string, int>();
     this.octave           = octave ?? ABCPlayer.DefaultOctave;
     accidentalPropagation = accidentalProp ?? ABCPlayer.DefaultAccidentalPropagation;
 }
Exemple #4
0
        /// <summary>
        /// Creates an ABC player. Uses static properties DefaultOctave and DefaultAccidentalPropagation and strict=true if
        /// arguments are left blank.
        /// </summary>
        public ABCPlayer(bool strict = true, int? octave = null, AccidentalPropagation? accidentalProp = null)
            : base()
        {
            AutoDetectLotro = true;
            settings = new ABCSettings();
            settings.MaxSize = 1024 * 12;

            this.strict = strict;
            accidentals = new Dictionary<string, int>();
            tiedNotes = new Dictionary<string, int>();

            if (octave.HasValue)
                this.octave = octave.Value;
            else
                this.octave = DefaultOctave;

            if (accidentalProp.HasValue)
                this.accidentalPropagation = accidentalProp.Value;
            else
                this.accidentalPropagation = DefaultAccidentalPropagation;
        }