mirror of
https://github.com/zebrajr/opencv.git
synced 2025-12-06 12:19:50 +01:00
Merge pull request #27574 from asmorkalov:as/interactive_calibration_flags
More intrinsic calibration flags in integractive calibration tool
This commit is contained in:
commit
7835c214eb
|
|
@ -118,6 +118,9 @@ namespace calib
|
|||
double solverEps;
|
||||
int solverMaxIters;
|
||||
bool fastSolving;
|
||||
bool rationalModel;
|
||||
bool thinPrismModel;
|
||||
bool tiltedModel;
|
||||
double filterAlpha;
|
||||
|
||||
internalParameters()
|
||||
|
|
@ -125,6 +128,9 @@ namespace calib
|
|||
solverEps = 1e-7;
|
||||
solverMaxIters = 30;
|
||||
fastSolving = false;
|
||||
rationalModel = false;
|
||||
thinPrismModel = false;
|
||||
tiltedModel = false;
|
||||
filterAlpha = 0.1;
|
||||
}
|
||||
};
|
||||
|
|
|
|||
|
|
@ -134,6 +134,10 @@ int main(int argc, char** argv)
|
|||
|
||||
int calibrationFlags = 0;
|
||||
if(intParams.fastSolving) calibrationFlags |= cv::CALIB_USE_QR;
|
||||
if(intParams.rationalModel) calibrationFlags |= cv::CALIB_RATIONAL_MODEL;
|
||||
if(intParams.thinPrismModel) calibrationFlags |= cv::CALIB_THIN_PRISM_MODEL;
|
||||
if(intParams.tiltedModel) calibrationFlags |= cv::CALIB_TILTED_MODEL;
|
||||
|
||||
cv::Ptr<calibController> controller(new calibController(globalData, calibrationFlags,
|
||||
parser.get<bool>("ft"), capParams.minFramesNum));
|
||||
cv::Ptr<calibDataController> dataController(new calibDataController(globalData, capParams.maxFramesNum,
|
||||
|
|
|
|||
|
|
@ -49,6 +49,9 @@ bool calib::parametersController::loadFromFile(const std::string &inputFileName)
|
|||
readFromNode(reader["solver_eps"], mInternalParameters.solverEps);
|
||||
readFromNode(reader["solver_max_iters"], mInternalParameters.solverMaxIters);
|
||||
readFromNode(reader["fast_solver"], mInternalParameters.fastSolving);
|
||||
readFromNode(reader["rational_model"], mInternalParameters.rationalModel);
|
||||
readFromNode(reader["thin_prism_model"], mInternalParameters.thinPrismModel);
|
||||
readFromNode(reader["tiltedModel"], mInternalParameters.tiltedModel);
|
||||
readFromNode(reader["frame_filter_conv_param"], mInternalParameters.filterAlpha);
|
||||
|
||||
bool retValue =
|
||||
|
|
|
|||
Loading…
Reference in New Issue
Block a user