SUPER-SAMPLED!
Since I completed this homework after I completed Homework 6, I decided to incorporate the super-sampling and bilinear interpolation techniques I developed for that assignment into this one.
Below you'll find that some transformations have up to three images listed. I developed my super-sampling algorithm to work with multiple convolution filter files, and so I conducted several experiments to see how the different filters responded under different circumstances.
Filters
Here are some representations of the convolution kernels of the filters I used for super-sampling. Imagine that the pixel we are going to sample lies at the centermost element in the filter. The numbers indicate the relative weighting that each of the sample point's color values will have in the final color value of the pixel.
For operations that shrink or "minify" image elements, such as scale, perspective and skew, increasing the samples of the output pixels can help include more of the original input pixel information that would have otherwise been lost in the shrinkage.
Triangle 3 Filter
1 2 1
2 4 2
1 2 1
Bell Filter
1 4 10 16 19 16 10 4 1
4 16 40 64 76 64 40 16 4
10 40 100 160 190 160 100 40 10
16 64 160 256 304 256 160 64 16
19 76 190 304 361 304 190 76 19
16 64 160 256 304 256 160 64 16
10 40 100 160 190 160 100 40 10
4 16 40 64 76 64 40 16 4
1 4 10 16 19 16 10 4 1
However, as you might imagine, calculating 81 sample coordinates per pixel significantly increases image processing time, especially for larger images. As you'll notice in the images below, there's not much difference in appearance between the triangle and bell filter outputs, however actual calculation time was painfully long, in some cases approaching a minute per image.
r -20
s .8 1.2
p .0001 .0003
h .4 .1
