CS194-26 Computational Photography:
Lightfield Cameras

Dante Tam

In this assignment, we work with the concept of a lightfield, a 4D series of images captured across a plane which faces the object. There are quite a few simple algorithms that achieve visually expressive effects from simple photographs.


For depth refocusing, we take some images from the grid with individual unique coordinates (u,v), find their distance from the center (u' = u - c_u, v' = v - c_v), shift individual images by C(u', v'), for some experimental scalar C in [-3.0, -2.9, ..., 0, 0.1], and average all the results.


For aperture adjustment, we take a subset of images closest to the center, with a distance threshold from [0, ..., 8], and average them. Using more images from the grid mimics a larger aperture, since intuitively, the grid selection itself represents the size of a physical aperture.


Depth Refocusing




Near Focus (C = -2.8), Far Focus (C = 0)




Aperture Adjustment




High Aperature (like f/4, using all images), Low Aperture (like f/32, using few images)