How do I perform a normal convolution?
filter2D does something really weird. When I use a 1x1 kernel with a value of [1] on a floating point black and white image I don't get the same image back. Instead I get a different matrix with a lot of infinite values. What is this voodoo magic and how do I perform a convolution like it is defined in wikipedia?
Are you trying to write a convolution method by yourself?
Do you have code to share regarding this identity convolution? Please do.
I tried this and it works on a 8UC1 format image:
I figured it out but this wonderful forum website won't let me post it. OpenCV was not dealing with floating point values that were too high properly and would convert them to infinity despite the matrix format not changing.