Fake Miniatures

Introduction

In this project, I simulated tilt shift effect, artificially narrowed down the depth of field and thus created the illusion that the subject is a miniature.

Focus Line and DOF

I actually manually defined the masks (target Depth of Field). See some examples below (they are the masks for the first three images in the result section):

Blurring

Then I find the rectangle that contains the mask defined in the previous part, and blur the image increasingly towards outside. I achieve this by defining a stack of images with increasing blurring factor, and masking the blurry images with the rectangle of increasing size.

Results

Original

Miniature (source: Internet)

Original

Miniature (source: Internet)

Original

Miniature (source: Internet)

Original

Miniature (source: me)

Original

Miniature (source: me)

Original

Miniature (source: me)

Seam Carving

Method

In this project, I shrink the images by taking out seams by its order, until I resize it to the ideal size. Each seam has exactly one pixel in each column and each row. I assign energy value to each pixel by taking its derivative both horizontally and vertically. Then I accumulate the energy from top to bottom, and find the lowest importance seam, and remove it. This is done so to keep the pixels with high energy values. I shrink images vertically by first transposing the image, then shrink it horizontally, then transposing it back.

Results

Original

Good

Original

Good

Original

Good

Original

Good

Original

Good

Original

Good

Original

Good

Original

Bad: The black shadow was not given enough energy value.

Original

Bad: The white sunlight was not given enough energy value.

Learning:

Through this project, I learned how computer approaches images. Though we can easily tell that a black area or a white area contains certain information, the energy function does not reflect those information, and the computer can thus mistake those pixels as "less important."