Controlled Generation of Two-Dimensional Patterns through Probabilistic Cellular Automata: the Case of Percolation Beds