Commit c674d3cf authored by Ilya Lavrenov's avatar Ilya Lavrenov

fixed ocl::norm (with NORM_RELATIVE specified) when norm(src2) == 0

parent 957c85e9
......@@ -688,7 +688,7 @@ double cv::ocl::norm(const oclMat &src1, const oclMat &src2, int normType)
break;
}
if (isRelative)
r = r / norm(src2, normType);
r = r / (norm(src2, normType) + DBL_EPSILON);
return r;
}
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment