Skip to content

Commit 19b5e41

Browse files
committed
Add check for undistortion in sfm
1 parent 9b3c886 commit 19b5e41

File tree

1 file changed

+5
-0
lines changed

1 file changed

+5
-0
lines changed

src/aliceVision/sfm/bundle/BundleAdjustmentCeres.cpp

+5
Original file line numberDiff line numberDiff line change
@@ -204,6 +204,11 @@ ceres::CostFunction* createCostFunctionFromIntrinsics(const IntrinsicBase* intri
204204
if (undistortion)
205205
{
206206
obsUndistorted.x = undistortion->undistort(observation.x);
207+
208+
if (intrinsicDistortionPtr->getDistortion() != nullptr)
209+
{
210+
throw std::runtime_error("Distortion should not be there when undistortion exists");
211+
}
207212
}
208213
}
209214

0 commit comments

Comments
 (0)