From e59912f803c73d62ce08c3b10885a43392a17626 Mon Sep 17 00:00:00 2001 From: StevenPuttemans Date: Thu, 21 Nov 2013 14:07:53 +0100 Subject: [PATCH] Applied fix mentioned in bugreport 3370. Seems to solve the issue. --- apps/traincascade/imagestorage.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/apps/traincascade/imagestorage.cpp b/apps/traincascade/imagestorage.cpp index 0f749f9b01..078b0d02cb 100644 --- a/apps/traincascade/imagestorage.cpp +++ b/apps/traincascade/imagestorage.cpp @@ -67,7 +67,7 @@ bool CvCascadeImageReader::NegReader::nextImg() _offset.x = min( (int)round % winSize.width, src.cols - winSize.width ); _offset.y = min( (int)round / winSize.width, src.rows - winSize.height ); if( !src.empty() && src.type() == CV_8UC1 - && offset.x >= 0 && offset.y >= 0 ) + && _offset.x >= 0 && _offset.y >= 0 ) break; }