Project 5: Light Fields

Ashley Chen

Depth Refocusing

In this assignment I downloaded images from the Stanford Light Field Archive, which includes photos of the same scene taken from slightly different positions in a 17 x 17 light grid. If you average all of the photos, the back of the photo looks more in focus than the front because further away items move less from the perspective of the camera when the camera moves, in comparison to closer ones. So, to change the focus, I shifted all the photos by their respective u,v values (as encoded in the file names) multiplied by a constant C and then averaged that result. This will give the impression that the camera was focused on a certain part of the photo when you took the picture. I played around with values of C until I found some that worked well for this picture.



C = -1



C = 0



C = 0.2



C = 0.5



C = 0.75



C = 1



C = 1.5



C = 2



C = 3



C = 4

Here is a gif of the changing focuses:

Aperture Adjustment

Now, to imitate the effect of changing the aperture size, we average a subset of images. The smaller the subset, the smaller the aperture. I varied the radius, and as the radius grows, the scene becomes blurrier as it would if the aperture were larger.



R = 1



R = 2



R = 3



R = 4



R = 5



R = 8



R = 10

Self Reflection

This project was really interesting and I learned more about how cameras actually capture light and what it means for a resulting image to adjust the aperture of a camera. I also didn't know about this technique for post processing the focus of a scene (although it seems a bit tedious). It was cool to see how we could easily implement these techniques ourselves given the data set.