1. A method for focusing video images, automatically, based on images taken during a focus sweep in which a focus cell is repositioned for each of the images, the method comprising: in an autofocus engine, given an edge detected image from a focus sweep and an associated position of a focus cell in the focus sweep, dividing the edge detected image into sub-images; for each sub-image, calculating a normalized edge detection strength of a subject sub-image; comparing the normalized edge detection strength of the subject sub-image to a threshold; determining, based on the comparison, an edge is present in the subject sub-image; calculating, based on the determinations of edges in the sub-images, an autofocus metric associated with the given position of the focus cell; and providing the autofocus metric together with autofocus metrics associated with other positions of the focus cell to focus video images.