How focus works ...

TODD VORENKAMP, EXPLORA, B&H:

"Before there was autofocus, there was focus. The camera is a light-tight box that is used to expose a photosensitive surface (film or digital sensor) to light. In order to focus the light onto the surface, most cameras (and your own eyes) use a lens to direct the light. Why did I say, Most? Well, there are many types of cameras around that do not rely on lenses to focus light. The pinhole camera is a box with a tiny hole on one end and a photosensitive surface on the other. Light comes through the tiny opening and is projected onto the rear wall of the box. A search of the Internet or your local library will reveal that scientists and engineers are currently working on developing lens-less cameras that are never out of focus and avoid the unfortunate characteristics imparted to light when it passes through glass or plastic lenses. For the time being, however, nearly all of us are using cameras that focus light through a lens."

Read it, here.