Package boofcv.alg.geo.bundle.cameras
Class BundleUniversalOmni
- java.lang.Object
-
- boofcv.alg.geo.bundle.cameras.BundleUniversalOmni
-
- All Implemented Interfaces:
BundleAdjustmentCamera
public class BundleUniversalOmni extends java.lang.Object implements BundleAdjustmentCamera
Implementation ofCameraUniversalOmnifor bundle adjustment
-
-
Field Summary
Fields Modifier and Type Field Description doublecximage center (units: pixels)doublecyimage center (units: pixels)booleanfixedMirrordoublefxfocal length along x and y axis (units: pixels)doublefyfocal length along x and y axis (units: pixels)doublemirrorOffsetMirror offset distance.double[]radialradial distortion parameters: k1,...,kndoubleskewskew parameter, typically 0 (units: pixels)doublet1tangential distortion parametersdoublet2tangential distortion parametersbooleantangentialbooleanzeroSkew
-
Constructor Summary
Constructors Constructor Description BundleUniversalOmni(boolean zeroSkew, int numRadial, boolean includeTangential, boolean fixedMirror)BundleUniversalOmni(boolean zeroSkew, int numRadial, boolean includeTangential, double mirrorOffset)BundleUniversalOmni(CameraUniversalOmni intrinsic)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description voidconvert(CameraUniversalOmni out)voidgetIntrinsic(double[] parameters, int offset)Copies the intrinsic camera into the array.intgetIntrinsicCount()Returns the number of intrinsic parameters for this model.voidjacobian(double camX, double camY, double camZ, double[] inputX, double[] inputY, boolean computeIntrinsic, double[] calibX, double[] calibY)Computes the gradient for the projected pixel coordinate with partials for the input 3D point in camera reference frame and camera intrinsic parameters.voidproject(double x, double y, double z, georegression.struct.point.Point2D_F64 output)Project the 3D point in the camera reference frame onto the camera's image plane.voidsetIntrinsic(double[] parameters, int offset)Specifies the intrinsic camera parameters.voidsetK(org.ejml.data.DMatrixRMaj K)
-
-
-
Field Detail
-
fx
public double fx
focal length along x and y axis (units: pixels)
-
fy
public double fy
focal length along x and y axis (units: pixels)
-
skew
public double skew
skew parameter, typically 0 (units: pixels)
-
cx
public double cx
image center (units: pixels)
-
cy
public double cy
image center (units: pixels)
-
mirrorOffset
public double mirrorOffset
Mirror offset distance. ξ
-
radial
public double[] radial
radial distortion parameters: k1,...,kn
-
t1
public double t1
tangential distortion parameters
-
t2
public double t2
tangential distortion parameters
-
zeroSkew
public boolean zeroSkew
-
tangential
public boolean tangential
-
fixedMirror
public boolean fixedMirror
-
-
Constructor Detail
-
BundleUniversalOmni
public BundleUniversalOmni(boolean zeroSkew, int numRadial, boolean includeTangential, boolean fixedMirror)
-
BundleUniversalOmni
public BundleUniversalOmni(boolean zeroSkew, int numRadial, boolean includeTangential, double mirrorOffset)
-
BundleUniversalOmni
public BundleUniversalOmni(CameraUniversalOmni intrinsic)
-
-
Method Detail
-
convert
public void convert(CameraUniversalOmni out)
-
setK
public void setK(org.ejml.data.DMatrixRMaj K)
-
setIntrinsic
public void setIntrinsic(double[] parameters, int offset)Description copied from interface:BundleAdjustmentCameraSpecifies the intrinsic camera parameters.- Specified by:
setIntrinsicin interfaceBundleAdjustmentCamera- Parameters:
parameters- Array containing the parametersoffset- Location of first index in the array which the parameters are stored
-
getIntrinsic
public void getIntrinsic(double[] parameters, int offset)Description copied from interface:BundleAdjustmentCameraCopies the intrinsic camera into the array.- Specified by:
getIntrinsicin interfaceBundleAdjustmentCamera- Parameters:
parameters- Array containing the parametersoffset- Location of first index in the array which the parameters are stored
-
project
public void project(double x, double y, double z, georegression.struct.point.Point2D_F64 output)Description copied from interface:BundleAdjustmentCameraProject the 3D point in the camera reference frame onto the camera's image plane.- Specified by:
projectin interfaceBundleAdjustmentCamera- Parameters:
x- 3D point in camera reference framey- 3D point in camera reference framez- 3D point in camera reference frameoutput- Storage for projected point.
-
jacobian
public void jacobian(double camX, double camY, double camZ, @Nonnull double[] inputX, @Nonnull double[] inputY, boolean computeIntrinsic, @Nullable double[] calibX, @Nullable double[] calibY)Description copied from interface:BundleAdjustmentCameraComputes the gradient for the projected pixel coordinate with partials for the input 3D point in camera reference frame and camera intrinsic parameters.[x',y']is the projected pixel coordinate of the 3D point in camera reference frame.- Specified by:
jacobianin interfaceBundleAdjustmentCamera- Parameters:
camX- (Input) 3D point in camera reference framecamY- (Input) 3D point in camera reference framecamZ- (Input) 3D point in camera reference frameinputX- (Output) Partial of projected x' relative to input camera point.[@x'/@camX, @ x' / @ camY, @ x' / @ camZ]length 3inputY- (Output) Partial of projected y' relative to input camera point.[@y'/@camX, @ y' / @ camY, @ y' / @ camZ]length 3computeIntrinsic- If true the calibX and calibY is computed. Otherwise they are ignored and can be nullcalibX- (Output) Partial of projected x' relative to calibration parameters. length NcalibY- (Output) Partial of projected y' relative to calibration parameters. length N
-
getIntrinsicCount
public int getIntrinsicCount()
Description copied from interface:BundleAdjustmentCameraReturns the number of intrinsic parameters for this model. If the camera is known then the number of parameters is zero- Specified by:
getIntrinsicCountin interfaceBundleAdjustmentCamera- Returns:
- number of intrinsic parameters.
-
-