1. A digital camera, comprising a sensor array having image pixels for capturing image data during an exposure period, and focus-detection pixels for determining focus information in a first mode of operation; wherein the digital camera is adapted for obtaining brightness related data from the focus-detection pixels in a second mode of operation during capturing of an image by means of the image pixels, the digital camera further comprising a controller adapted for determining the exposure period based on the brightness related data obtained from the focus-detection pixels while capturing said image from the image pixels.