Пример #1
0
        public void CreateYAxisTexture()
        {
            _timeSpan = _dataPoints.Length;

            _guiChartOptions = new GuiChartOptions(_axesNames, ChartType, ChartLines, TickMarks, Scale, _dataPoints, _timeSpan, RepDuration);
            _guiChart = new GuiChart("Title", new Vector2(1024, 780), Vector2.Zero, _guiChartOptions);

            Texture2D testing = _guiChart.CreateYAxisTitleTexture(_game, _contentManager, _spriteBatch);

            FileStream fs = File.Open(@"c:\school\Chart_Y-Axis.png", FileMode.Create);
            testing.SaveAsPng(fs, testing.Width, testing.Height);
            fs.Close();

            Assert.IsNotNull(testing);
            Assert.Pass("GuiChart.CreateYAxisTitleTexture passed.");
        }