From be4100605230868b5cc50cabee395613dbfb62cd Mon Sep 17 00:00:00 2001 From: Michele Di Giorgio Date: Mon, 6 Aug 2018 16:24:19 +0100 Subject: COMPMID-1481: CLCannyEdge still failing in some precommits Without the check introduced by this patch, all weak edges as marked as strong edges. Change-Id: I874ebf22c06707bd98bd11b9be93602bfcbafa7c Reviewed-on: https://eu-gerrit-1.euhpc.arm.com/142922 Tested-by: Jenkins Reviewed-by: Giorgio Arena --- src/core/CL/cl_kernels/canny.cl | 6 ++++++ 1 file changed, 6 insertions(+) (limited to 'src/core') diff --git a/src/core/CL/cl_kernels/canny.cl b/src/core/CL/cl_kernels/canny.cl index bb83eeef88..9bfa2f4d16 100644 --- a/src/core/CL/cl_kernels/canny.cl +++ b/src/core/CL/cl_kernels/canny.cl @@ -356,6 +356,12 @@ kernel void hysteresis( return; } + // Return if it is a MAYBE pixel. Such pixels will become edges if near a strong edge + if(val <= up_thr) + { + return; + } + // Init local stack 2 short2 stack_L2[hysteresis_local_stack_L2] = { 0 }; int L2_counter = 0; -- cgit v1.2.1