In one step of image evaluations I need to apply a gaussian blur to pixel data. I do this by folding each pixel with a gaussian folding matrix. This is no problem unless I try to do this with pixels at the border of the image since for example on the left border I can't include the pixels to the left in my folding calculation. There are multiple ways around this that I can think of:
- Don't blur pixels without a complete set of neighbours.
- Ignore the neighbours that aren't there.
- Use the center pixel instead of the pixels that are missing.
- Use the pixel at the other side of the image.
Case 2 isn't right in my opinion because it destroys the normalization of the whole folding matrix. I can't use 4. in my case and it doesn't really make sense anyways.
So my question is: How should this problem be handled?