Implement auto focus.

Issue #12 close.