public void Set(string nameCellStructure, int numStates, string nameNeighborhoodFunc)
        {
            _settings.NumStates            = numStates;
            _settings.CellStructure        = CellStructure.Get(nameCellStructure);
            _settings.NeighborhoodFunction = NeighborhoodFunction.Get(nameNeighborhoodFunc);

            UpdateUi();
        }
Пример #2
0
 public CellularAutomataSettings(int states)
 {
     _numStates        = states;
     _cellStructure    = new HexSixCell();
     _funcMapNeighbors = new AliveCellCount();
 }
Пример #3
0
 public Cells(CellStructure cellStruct, DiscreteProbabilityDistribution<int> stateDistribution)
 {
     _cellStruct = cellStruct;
     _ary = Util.GetRandomInt2dArray(cellStruct.Columns, cellStruct.Rows, stateDistribution);
 }
Пример #4
0
 public Cells(CellStructure cellStruct)
 {
     _cellStruct = cellStruct;
     _ary = new int[cellStruct.Columns, cellStruct.Rows];
 }
Пример #5
0
 public Cells(CellStructure cellStruct, DiscreteProbabilityDistribution <int> stateDistribution)
 {
     _cellStruct = cellStruct;
     _ary        = Util.GetRandomInt2dArray(cellStruct.Columns, cellStruct.Rows, stateDistribution);
 }
Пример #6
0
 public Cells(CellStructure cellStruct)
 {
     _cellStruct = cellStruct;
     _ary        = new int[cellStruct.Columns, cellStruct.Rows];
 }
 private void comboCellStructure_SelectedIndexChanged(object sender, EventArgs e)
 {
     _settings.CellStructure = CellStructure.Get(comboCellStructure.SelectedIndex);
     OnChanged();
 }