Posts: 2,020
Threads: 24
Joined: Jun 2002
yeah, i saw it, it's really fantastic. i dont think i understand teh effect though (mine is a run-of-the-mill "blur upwards" routine
)
i]"I know what you're thinking. Did he fire six shots or only five? Well, to tell you the truth, in all this excitement, I've kinda lost track myself. But being as this is a .44 Magnum ... you've got to ask yourself one question: 'Do I feel lucky?' Well, do ya punk?"[/i] - Dirty Harry
Posts: 6,419
Threads: 74
Joined: Mar 2002
MIne is also an 1 pixel shifted blur, but with these issues:
* 1st of all, I read 9 dots (the center dot and the 8 that surround it), which are added and divided by 8, not by 9, so it isn't an average.
* The secret is not overwriting the source image instantly. A new image is built from the original, and then that image overwrites the original 1 pixel up.
This is called "convolution". In a convolution, you calculate each pixel of a new image (transformed image) applying a matrix to a group of pixels centered in the current one and measuring the same than the matrix in the original image. Applying means doing a multiplication of each matrix member to each pixel, adding all the values, saturating the result (so it doesn't exceed 255) and writing with that value the new pixel. The twist is that we are shifting the pixels 1 position up.