예제 #1
0
        public void CreateScoreWithFlats()
        {
            ScoreFactory sf    = new ScoreFactory();
            IScore       score = sf.CreateScore(true);

            score.Measures.Add(sf.CreateMeasure(4, false));
            score.Measures.Add(sf.CreateMeasure(3, false));
            score.Measures[0].Notes.Add(sf.CreateNote(0, 13, 4));
            score.Measures[0].Notes.Add(sf.CreateNote(2, 14, 4));
            score.Measures[0].Notes.Add(sf.CreateNote(4, 15, 4));
            score.Measures[0].Notes.Add(sf.CreateNote(14, 39, 4));
            score.Measures[0].Notes.Add(sf.CreateNote(14, 40, 4));
            score.Measures[1].Notes.Add(sf.CreateNote(0, 42, 4));
            ScoreWriter sw  = new ScoreWriter(score, 6);
            Image       img = sw.RenderPage(0);

            img.Save("c:\\tmp\\flatScore.bmp");
            Assert.IsNotNull(img);
        }
예제 #2
0
        public void CreateOddBarScore()
        {
            ScoreFactory sf    = new ScoreFactory();
            IScore       score = sf.CreateScore();

            score.Measures.Add(sf.CreateMeasure(4, false));
            score.Measures.Add(sf.CreateMeasure(3, false));
            score.Measures.Add(sf.CreateMeasure(4, false));
            score.Measures.Add(sf.CreateMeasure(3, false));
            score.Measures.Add(sf.CreateMeasure(3, false));
            score.Measures.Add(sf.CreateMeasure(4, false));
            ScoreWriter sw  = new ScoreWriter(score, 6);
            Image       img = sw.RenderPage(0);

            img.Save("c:\\tmp\\varBarScore.bmp");
            Assert.IsNotNull(img);
        }