Exemplo n.º 1
0
        //make cells inside the floor
        public static List <Cell> PlaceCellsInsideOutline(List <Point2d> outLinePts, double dim = 1)
        {
            List <Cell> cellList    = GridObject.CellsInsidePoly(outLinePts, dim);
            List <Cell> cellNewList = new List <Cell>();

            for (int i = 0; i < cellList.Count; i++)
            {
                Point2d center    = cellList[i].CenterPoint;
                Point2d centerNew = new Point2d(center.X + (dim / 2), center.Y + (dim / 2));
                Cell    cl        = new Cell(centerNew, dim, dim, i, true);
                cellNewList.Add(cl);
            }
            return(cellNewList);
        }