Copyright | (C) 2015 Oleg Grenrus |
---|---|
License | BSD3 |
Maintainer | Oleg Grenrus <oleg.grenrus@iki.fi> |
Safe Haskell | None |
Language | Haskell2010 |
Scale pictures using Discrete Cosine Transform.
- scale :: (Int, Int) -> Image PixelRGBA8 -> Image PixelRGBA8
- scaleWithKernel :: (Int, Int) -> (Int -> Int -> Double) -> Image PixelRGBA8 -> Image PixelRGBA8
Documentation
:: (Int, Int) | Output width, height |
-> Image PixelRGBA8 | Input image |
-> Image PixelRGBA8 | Output image |
Scale the image using DCT transform.
:: (Int, Int) | Output width, height |
-> (Int -> Int -> Double) | kernel |
-> Image PixelRGBA8 | Input image |
-> Image PixelRGBA8 | Output image |
Scale the image using DCT transform.
Convolute result image with a symmetric kernel. See https://en.wikipedia.org/wiki/Symmetric_convolution
Identity kernel:
k 0 0 = 1 k _ _ = 0
Sharpen:
k 0 0 = 1.75 k 0 1 = -0.125 k 1 0 = -0.125 k 1 1 = -0.0625 k _ _ = 0