use of boofcv.alg.distort.universal.LensDistortionUniversalOmni in project BoofCV by lessthanoptimal.
the class DisplayFisheyeCalibrationPanel method setCalibration.
public void setCalibration(CameraUniversalOmni fisheyeModel) {
BoofSwingUtil.checkGuiThread();
LensDistortionNarrowFOV pinholeDistort = new LensDistortionPinhole(pinholeModel);
fisheyeDistort = new LensDistortionUniversalOmni(fisheyeModel);
distorter = new NarrowToWidePtoP_F32(pinholeDistort, fisheyeDistort);
// Create the image distorter which will render the image
InterpolatePixel<Planar<GrayF32>> interp = FactoryInterpolation.createPixel(0, 255, InterpolationType.BILINEAR, BorderType.ZERO, imageFisheye.getImageType());
distortImage = FactoryDistort.distort(false, interp, imageFisheye.getImageType());
// Pass in the transform created above
distortImage.setModel(new PointToPixelTransform_F32(distorter));
setPinholeCenter(fisheyeModel.width / 2, fisheyeModel.height / 2);
renderPinhole();
}
use of boofcv.alg.distort.universal.LensDistortionUniversalOmni in project BoofCV by lessthanoptimal.
the class TestNarrowToWidePtoP_F32 method createModelWide.
public static LensDistortionWideFOV createModelWide() {
CameraUniversalOmni model = new CameraUniversalOmni(2);
model.fsetK(1.349e3f, 1.343e3f, 0, 480, 480, 960, 1080);
model.fsetMirror(3.61f);
model.fsetRadial(7.308e-1f, 1.855e1f);
model.fsetTangental(-1.288e-2f, -1.1342e-2f);
return new LensDistortionUniversalOmni(model);
}
Aggregations