From 20c08eab7355112ffee6389861dcd64e4f4faf65 Mon Sep 17 00:00:00 2001 From: elenagvo Date: Fri, 17 Nov 2017 15:13:04 +0300 Subject: [PATCH] change border type for medianBlur to BORDER_ISOLATED --- modules/imgproc/src/smooth.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/modules/imgproc/src/smooth.cpp b/modules/imgproc/src/smooth.cpp index 1332fb668d..c9c24a292a 100644 --- a/modules/imgproc/src/smooth.cpp +++ b/modules/imgproc/src/smooth.cpp @@ -3162,7 +3162,7 @@ void cv::medianBlur( InputArray _src0, OutputArray _dst, int ksize ) } else { - cv::copyMakeBorder( src0, src, 0, 0, ksize/2, ksize/2, BORDER_REPLICATE ); + cv::copyMakeBorder( src0, src, 0, 0, ksize/2, ksize/2, BORDER_REPLICATE|BORDER_ISOLATED); int cn = src0.channels(); CV_Assert( src.depth() == CV_8U && (cn == 1 || cn == 3 || cn == 4) );