Ensures that the input arguments are valid

If 'lambda <= 0' or 'kappa <= 1.0', the stop condition for the solver is never met because beta would not be increasing.
pull/2276/head
Nicolas Abril 6 years ago committed by Nicolas Abril
parent 1a15cbc9ae
commit 2932420933
  1. 2
      modules/ximgproc/src/l0_smooth.cpp

@ -252,6 +252,8 @@ namespace cv
CV_Assert(!S.empty());
CV_Assert(S.depth() == CV_8U || S.depth() == CV_16U
|| S.depth() == CV_32F || S.depth() == CV_64F);
CV_Assert(lambda > 0.0);
CV_Assert(kappa > 1.0);
dst.create(src.size(), src.type());

Loading…
Cancel
Save