mirror of
https://github.com/opencv/opencv.git
synced 2025-06-07 17:44:04 +08:00
apps: fix interactive calibration
This commit is contained in:
parent
9f2edc1135
commit
49e0126b8e
@ -224,8 +224,10 @@ void calib::calibDataController::filterFrames()
|
|||||||
cv::Mat newErrorsVec = cv::Mat((int)numberOfFrames - 1, 1, CV_64F);
|
cv::Mat newErrorsVec = cv::Mat((int)numberOfFrames - 1, 1, CV_64F);
|
||||||
std::copy(mCalibData->perViewErrors.ptr<double>(0),
|
std::copy(mCalibData->perViewErrors.ptr<double>(0),
|
||||||
mCalibData->perViewErrors.ptr<double>((int)worstElemIndex), newErrorsVec.ptr<double>(0));
|
mCalibData->perViewErrors.ptr<double>((int)worstElemIndex), newErrorsVec.ptr<double>(0));
|
||||||
std::copy(mCalibData->perViewErrors.ptr<double>((int)worstElemIndex + 1), mCalibData->perViewErrors.ptr<double>((int)numberOfFrames),
|
if((int)worstElemIndex < (int)numberOfFrames-1) {
|
||||||
|
std::copy(mCalibData->perViewErrors.ptr<double>((int)worstElemIndex + 1), mCalibData->perViewErrors.ptr<double>((int)numberOfFrames),
|
||||||
newErrorsVec.ptr<double>((int)worstElemIndex));
|
newErrorsVec.ptr<double>((int)worstElemIndex));
|
||||||
|
}
|
||||||
mCalibData->perViewErrors = newErrorsVec;
|
mCalibData->perViewErrors = newErrorsVec;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user