Add missing checkerboard calibration pattern warning

This commit is contained in:
manongjohn 2022-03-05 00:09:45 -05:00
parent de2bb599cf
commit 8cda9a8252

View file

@ -4113,7 +4113,14 @@ void StopMotionController::captureCalibrationRefImage(cv::Mat &image) {
bool found = cv::findChessboardCorners( bool found = cv::findChessboardCorners(
image, m_stopMotion->m_calibration.boardSize, corners, image, m_stopMotion->m_calibration.boardSize, corners,
cv::CALIB_CB_ADAPTIVE_THRESH | cv::CALIB_CB_FILTER_QUADS); cv::CALIB_CB_ADAPTIVE_THRESH | cv::CALIB_CB_FILTER_QUADS);
if (found) { if (!found) {
TFilePath patternFp = ToonzFolder::getLibraryFolder() +
"camera calibration" + "checkerboard.tif";
DVGui::warning(
tr("Unable to find complete checkerboard pattern. Check pattern "
"position and camera settings.\n\nPrint and use %1 to calibrate.")
.arg(patternFp.getQString()));
} else {
// compute corners in detail // compute corners in detail
cv::cornerSubPix( cv::cornerSubPix(
image, corners, cv::Size(11, 11), cv::Size(-1, -1), image, corners, cv::Size(11, 11), cv::Size(-1, -1),