From f39d351d0490747ed3eb4a758f6ddd88263de111 Mon Sep 17 00:00:00 2001 From: AfterEight Date: Mon, 2 Feb 2015 14:59:52 +0100 Subject: [PATCH 1/2] Modified resetCvImage() in cap_ximea.cpp, so that the IplImage* frame is also updated after the resolution has changed via set(CV_CAP_PROP_FRAME_WIDTH, value)/set(CV_CAP_PROP_XI_DOWNSAMPLING, value) Conflicts: modules/highgui/src/cap_ximea.cpp --- modules/videoio/src/cap_ximea.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/modules/videoio/src/cap_ximea.cpp b/modules/videoio/src/cap_ximea.cpp index ccf49e45b..b876995f0 100644 --- a/modules/videoio/src/cap_ximea.cpp +++ b/modules/videoio/src/cap_ximea.cpp @@ -221,7 +221,7 @@ void CvCaptureCAM_XIMEA::resetCvImage() xiGetParamInt( hmv, XI_PRM_HEIGHT, &height); xiGetParamInt( hmv, XI_PRM_IMAGE_DATA_FORMAT, &format); - if( (int)image.width != width || (int)image.height != height || image.frm != (XI_IMG_FORMAT)format) + if( (int)image.width != frame->width || (int)image.height != frame->height || image.frm != (XI_IMG_FORMAT)format) { if(frame) cvReleaseImage(&frame); frame = NULL; From b73894b27197c98e341571666c1e4852e31961f7 Mon Sep 17 00:00:00 2001 From: lujia Date: Tue, 21 Apr 2015 02:32:27 -0400 Subject: [PATCH 2/2] bugfix_for_hog_detectMultiScale_with_weights --- modules/objdetect/src/hog.cpp | 1 + 1 file changed, 1 insertion(+) diff --git a/modules/objdetect/src/hog.cpp b/modules/objdetect/src/hog.cpp index 32a6a21b9..bbdc0beb2 100644 --- a/modules/objdetect/src/hog.cpp +++ b/modules/objdetect/src/hog.cpp @@ -1453,6 +1453,7 @@ void HOGDescriptor::detect(const Mat& img, Size winStride, Size padding, const std::vector& locations) const { hits.clear(); + weights.clear(); if( svmDetector.empty() ) return;