Skip to content

Instantly share code, notes, and snippets.

@jordoh
jordoh / grabcut.patch
Created October 7, 2011 16:17
Patch for grabCut asserts in OpenCV 2.3.1
*** ../modules/imgproc/src/grabcut.cpp 2011-09-12 11:43:02.000000000 -0700
--- ../modules/imgproc/src/grabcut.cpp 2011-10-05 10:59:40.646173736 -0700
***************
*** 119,125 ****
double res = 0;
if( coefs[ci] > 0 )
{
! CV_Assert( covDeterms[ci] > std::numeric_limits<double>::epsilon() );
Vec3d diff = color;
double* m = mean + 3*ci;