The auto focus and exposure in the stock iOS camera app gets faster and more accurate with each update. When shifting the frame to a new subject, the iPhone camera will automatically readjust these parameters and the white balance accordingly. Video is no different, with adjustments taking place while recording. There are some situations where a change in focus can be distracting, or an exposure shift detracts from the scene.
For this reason, ever since iOS 5 the built-in Camera app makes it possible to lock both the autofocus and auto exposure. AE/AF lock mode can be entered manually and will stay in effect during a photo session until it's switched off, or the Camera app is reopened. This means that multiple photos can be snapped without a change in the focus or exposure settings, regardless of what's in the frame.
To turn on AE/AF lock mode open the Camera app and frame a new photo. Tapping the screen will normally focus on that spot in the frame. To lock the focus, simply hold down in one place until the square, yellow target flashes.
Once engaged, AE/AF LOCK appears in a yellow message in the camera frame. This feature can be helpful when recording a panorama, to keep the focus and exposure locked while turning around 360 degrees.