strange gaussianBlur result offset of kernel multiplication unwantedly padded. <p>You can see the result in the image below. The original image is just a grey pixel, the result should be that but blurred. </p> <p>Opencv is not using the immediate neighboring pixels for the Gaussian Blur, I'm guessing it's doing some sort of internal padding. Why it is doing so I have no idea, my initial guess would be that it assumes that the vector has more than one channel, which is not the case. Here is how i create the cv::Mats for calculation and how i call cv::gausianBlurr</p> <pre><code>std::vector&lt;float&gt; sobelCopy (sobel); cv::Mat sobel_mat_copy(height, width, CV_32F, sobelCopy.data()); cv::Mat sobel_mat(height, width, CV_32F, sobel.data()); cv::GaussianBlur(sobel_mat_copy, sobel_mat, cv::Size(3,3), 0.0, 0.0, cv::BORDER_CONSTANT); </code></pre> <p>Image <a href="https://i.stack.imgur.com/cr9fF.png" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/cr9fF.png" alt="Resulting image"></a></p>