|
|
@@ -78,6 +78,54 @@ func main() {
|
|
|
}
|
|
|
```
|
|
|
|
|
|
+Downsizing Samples
|
|
|
+-------
|
|
|
+
|
|
|
+Downsizing is not as simple as it might look like. Images have to be filtered before they are scaled down, otherwise aliasing might occur.
|
|
|
+Filtering is highly subjective: Applying too much will blur the whole image, too little will make aliasing become apparent.
|
|
|
+Resize tries to provide sane defaults that should suffice in most cases.
|
|
|
+
|
|
|
+### Artificial sample
|
|
|
+
|
|
|
+Original image
|
|
|
+
|
|
|
+
|
|
|
+<table>
|
|
|
+<tr>
|
|
|
+<th><img src="http://nfnt.github.com/img/rings_300_NearestNeighbor.png" /><br>Nearest-Neighbor</th>
|
|
|
+<th><img src="http://nfnt.github.com/img/rings_300_Bilinear.png" /><br>Bilinear</th>
|
|
|
+</tr>
|
|
|
+<tr>
|
|
|
+<th><img src="http://nfnt.github.com/img/rings_300_Bicubic.png" /><br>Bicubic</th>
|
|
|
+<th><img src="http://nfnt.github.com/img/rings_300_MitchellNetravali.png" /><br>Mitchell-Netravali</th>
|
|
|
+</tr>
|
|
|
+<tr>
|
|
|
+<th><img src="http://nfnt.github.com/img/rings_300_Lanczos2.png" /><br>Lanczos2</th>
|
|
|
+<th><img src="http://nfnt.github.com/img/rings_300_Lanczos3.png" /><br>Lanczos3</th>
|
|
|
+</tr>
|
|
|
+</table>
|
|
|
+
|
|
|
+### Real-Life sample
|
|
|
+
|
|
|
+Original image
|
|
|
+
|
|
|
+
|
|
|
+<table>
|
|
|
+<tr>
|
|
|
+<th><img src="http://nfnt.github.com/img/IMG_3694_300_NearestNeighbor.png" /><br>Nearest-Neighbor</th>
|
|
|
+<th><img src="http://nfnt.github.com/img/IMG_3694_300_Bilinear.png" /><br>Bilinear</th>
|
|
|
+</tr>
|
|
|
+<tr>
|
|
|
+<th><img src="http://nfnt.github.com/img/IMG_3694_300_Bicubic.png" /><br>Bicubic</th>
|
|
|
+<th><img src="http://nfnt.github.com/img/IMG_3694_300_MitchellNetravali.png" /><br>Mitchell-Netravali</th>
|
|
|
+</tr>
|
|
|
+<tr>
|
|
|
+<th><img src="http://nfnt.github.com/img/IMG_3694_300_Lanczos2.png" /><br>Lanczos2</th>
|
|
|
+<th><img src="http://nfnt.github.com/img/IMG_3694_300_Lanczos3.png" /><br>Lanczos3</th>
|
|
|
+</tr>
|
|
|
+</table>
|
|
|
+
|
|
|
+
|
|
|
License
|
|
|
-------
|
|
|
|