Researchers at the University of Waterloo have developed a faster and more accurate way to take and merge photos. The result is the ability to take sections of each photo to create a single picture where all elements are in focus.

“If you’re taking a picture of a field of flowers with mountains in the distance, you focus on the flowers and take a shot, then you focus out a tiny bit and take another shot, and so on," said Peter van Beek, a professor at Waterloo’s David R. Cheriton School of Computer Science. "You take enough shots until you’ve captured enough photos to put them together and create a photo where every element of that scene in focus.”

Flowers

The top photograph of flowers is a single image with a narrow plane of focus where only the orange flower at the bottom centre is in sharp focus. The bottom photo is an all-in-focus image created by focus stacking a series of images, each with a slightly different plane of focus, using the algorithm developed by University of Waterloo's Professor Peter van Beek and his students.

The computational process to combine the photos is called photo stacking. Many photo-editing applications can blend a series of images into a single composite picture, but images have to be carefully selected one by one, and the process is manual.

“The difficulty in doing this manually selecting images is that it’s slow and people tend to take far too many pictures,” van Beek said. “Or, conversely, sometimes the photographer is rushed and misses taking a few pictures that are critical for the composite image to be in focus. Taking too many pictures is time-consuming and taking too few means the resulting image won’t be sharp.”

Many computer scientists have investigated this problem and have mainly concentrated on developing techniques that improve combining the set of images into a single photo.

Van Beek and his team of undergraduate research assistants — David Choi, Aliya Pazylbekova and Wuhan Zhou — have instead put their efforts toward improving image capturing and selection processes, so fewer images need to be taken to create a single image where everything is in focus.

“You specify what you want in focus, press the shutter, then the algorithm selects the images to be focus stacked,” van Beek explains. “Our algorithm requires 4.5 times fewer images on average — a reduction that would significantly cut the time needed to capture the set of pictures.”

The study, Improved Image Selection for Focus Stacking in Digital Photography, was presented at the 24th IEEE International Conference on Image Processing.

Read more

Waterloo News

Media? 

Contact media relations to learn more about this or other stories.