コード例 #1
0
ファイル: MainModel.cs プロジェクト: nebosite/Skynet
        //-------------------------------------------------------------------------------------
        /// <summary>
        /// Constructor
        /// </summary>
        //-------------------------------------------------------------------------------------
        public MainModel(IChartPlotter plotter)
        {
            _chartPlotter = plotter;

            _heatMap = new Heatmap(_heatmapWidth, _heatmapHeight, 0);
            _heatMap.Render();
            _heatMapThread = new Thread(HeatMapWorker);
            _heatMapThread.Start();

            // New York City
            MeasurementLatitude = 40.728053;
            MeasurementLongitude = -73.996552;
            SamplingIntervalSeconds = 300;

            SatelliteGenerators = new SatelliteGenerationBase[]
            {
                new SatelliteGeneratorEvenlySpaced(),
                new SatelliteGeneratorRandom()
            };

            _selectedGenerator = SatelliteGenerators[0];

            Satellites = new ObservableCollection<SatelliteModel>();
            HeatmapEnabled = false;
            PrimeCoverage = 10;

            Scale = .00001;
            CenterX = 350;
            CenterY = 150;
            TimeDilation = 10;
            FieldOfView = 10;

            SatelliteCount = 300;
            RegenerateSatellites();
        }