CS 194-26 Image Manipulation and Computational Photography

Project 5: Lightfield Camera

Mher Mnatsakanyan (cs194-26-aac)

Overview

The goal of this project is to use simple operations like shifting and averaging to achieve depth refocusing and aperture adjustment on the Stanford Light Field Archive dataset. The dataset has multiple images over a plane where cameras are located in 17x17 grid and capture the near and far objects from different perspective over the plane.

Depth Refocusing

In this part of the project, we use shifting and averaging operations to get an effect of depth refocusing. For the near objects, we want to shift all the images within some radius to have the same location in the images, but the far objects can have different locations. The difference of locations of the far objects leads to the blurriness in the averaged image, while the preserving the same location for the nearby objects gives us a sharp, in focus, image. In this part, I fixed the middle grid camera location and adjusted the other camera images on the grid based on the radius from the center grid and a scaling factor. The scaling factor, which indicates how much do we want to shift the images, can results to different levels of blurriness on the far objects. For instance, you can see images below for different values of alpha. The radius is fixed in this part and is equal to 25.

Chess, alpha = 0

Chess, alpha = 2

Chess, alpha = 4

You can see the depth refocusing animation below.

Depth Refocusing, Chess and Flower

Aperture Adjustment

In this part of project, we want to achieve aperture adjustment effect on the images. For this, instead of varying the scaling factor and keeping radius fixed, we change the radius, for instance from 0 to 10, and keep the scaling factor fixed, in this case just 1. Here are some results from the flower dataset.

Flower, radius = 0

Flower, radius = 5

Flower, radius = 9

And here are the animations.

Aperture Adjustment, Chess and Flower