Hybrid Images

Aaron Hsu

Code

Given 2 images, we try to align them by some measurement of selected features (e.g. pair of eyes, horizon, etc.) so that we may blend the two images together. We take one image and apply a low-pass filter while a high-pass filter will be applied to the other image. This way, image 1 (low-passed) is blended too in a sense, "remove" its prominent features while image 2's more prominent features are extracted. When you combine these features from the filters, the high-frequency prominent features from image 2 are blended in with image 1. Because a lot of image 1's details are blurred out, the final image gives the illusion that both images are blending together. Usually, from up-close we can see the combined effects as image 2 details are present in the picture. However, from a distance, the farther you stand away from the view, it will look more and more like image 1 as the details from image 2 gradually disappear. My images mostly work on grayscale photos while trying to use color has been sort of a problem as the color channels don't align very well. When working with colored images, it seems that the coloring doesn't work as well with just using low-passing or high-passing filters as opposed to using both. The high-filtering of images in color doesn't give a great illusion-y effect on the combined resulting image. You can also observe the gaussian and laplacian pyramids of each set of images. As we get coarser (sub-sampling increases), we can see that the final image gets more and more like the blended low-pass filtered image 1.

Oak Tree

Summer Oak Tree vs. Winter Oak Tree

image 1 image 2 hybrid image hybrid image with color attempt
image 1 image 1 low-pass image 2 image 2 high-pass hybrid iamge

This is the pyramid. The first row is our Gaussian pyramid of our hybrid image, while our second row is our Laplacian. The last (third) row is our original hybrid image. At each column, the images get coarser and coarser as you look to the right. The subsampling is increased by a factor of 2, and as the pyramid levels get coarser, in this case, the Gaussian looks more and more like the original blended low-pass image while the Laplacian resembles the original high-pass image. Unfortunately, the pixels of the original image aren't too high, so it gets a little blocky at the coarser levels.
We can see that the winter oak tree (our low-pass image) kind of acts as a skeleton. The summer oak tree envelops the rest of the image with high-detailed leaves, giving the winter oak tree a blended in shape. Unfortunately, due to color-channel complications, the green from the leaves do not show up very well... If I had a little more time, I would most definitely improve the coloring as it's really cool to see!

A New Joker

Heath Ledger as Joker vs. Christian Bale

Let's try to see what it looks like if Christian Bale played Joker from the Dark Knight series. This is definitely my favorite!
image 1 image 2 Christian bale as dominant face Joker as dominant face (just for fun)
image 1 image 1 low-pass image 2 image 2 high-pass hybrid image


From these images, unfortunately not all of joker's make up is there on Christian bale's face! That's because when we apply a high-pass filter over joker's face, the shaded dark borders surrounding his eyes are not picked up as prominent details. However, what we do see are all the scars and wrinkles from joker's face which are definitely a critical part of his mask. When we apply those features onto Christian Bale, you can definitely see the more sinister/creepy side of him. His smile is no longer there in the hybrid image - it turns into a cold frown just like the joker image. In the pyramid, you can see that as we get to coarser levels, the hybrid image slowly resembles the original low-pass image (Christian Bale) as all of his Joker features gradually disappear from the sub-sampling. On the other hand, when we have Joker as the dominant face, it's really hard to see Christian Bale under all of that. This is probably due to the prominent features of Joker's face simply overpowering an un-make-uped Christian Bale's face - even when the Joker is blended a lot. However, you can still see glimpses of somebody else's face - but it's not obvious that it'll be Christian Bale.

"Dolphin and Whale!!!" ~ South Park

Dolphin + Orca

Morphing Attempt
image 1 image 2 Dolphin and Whale
image 1 image 1 low-pass image 2 image 2 high-pass hybrid image


These two images were kind of tough to match, align and blend as the features of a killer whale are extremely prominent. The black and white skin pattern of a killer whale are simply so prominent that they'll overpower the coloring of a dolphin no matter how much you blend the killer whale. A dolphin's skin color is a light shade of gray and passing a high-frequency filter will only outline the shape. As a result, you can see the outline of the dolphin up close, but far away (don't have to step back too much), you can only make out the killer whale and not the dolphin anymore. To align these images I used the upper fin and the side fins of both marine mammals.