I need to make a blur effect on an image by pressing a key. I need to have a 3x3 square of pixels averaged for the red green and blue values then replace the center pixel for each color still replaced by the average number. Then I need to replace the pixels on a copy of the pic. and carry throughout the pic. the border pixels can't be included because there aren't pixels to average outside the pic. I can't get a working if/for loop to do what I need it to.