Given two points to define a square, subdivide the square into an nxm grid.