The Renaissance turned painting into a branch of optics. Brunelleschi's demonstration of linear perspective (~1415–1420), codified in Leon Battista Alberti's 1435 treatise, let artists project a three-dimensional world onto a flat surface with mathematical precision. For the first time, a picture obeyed rules a machine could one day follow.
Artists also reached for actual machines. The camera obscura — a darkened room or box that projects the scene outside through a tiny hole — let painters trace reality directly, and many Old Masters almost certainly used it. The image was right there on the wall; the only thing missing was a way to make it stay.
Chemistry supplied the answer. In the 1820s Nicéphore Niépce fixed the first permanent photograph; in 1839 Louis Daguerre's daguerreotype made the process practical and stunned the world. Suddenly an image could be captured with no hand drawing it at all. The machine had begun, for the very first time, to make pictures by itself.