public class CameraPinholeBrown extends CameraPinhole implements java.io.Serializable
Adds radial and tangential distortion to the intrinsic parameters of a pinhole camera.
Radial and Tangential Distortion:
xd = xn + xn[k1 r2 + ... + kn r2n] + dx
dxu = [ 2t1 u v + t2(r2 + 2u2)]
dxv = [ t1(r2 + 2v2) + 2 t2 u v]
r2 = u2 + v2
where xd is the distorted coordinates, xn=(u,v) is undistorted normalized image coordinates.
Pixel coordinates are found x = K*[u;v]
| Modifier and Type | Field and Description |
|---|---|
double[] |
radial
radial distortion parameters
|
double |
t1
tangential distortion parameters
|
double |
t2
tangential distortion parameters
|
cx, cy, fx, fy, serialVersionUID, skewheight, width| Constructor and Description |
|---|
CameraPinholeBrown()
Default constructor.
|
CameraPinholeBrown(CameraPinholeBrown param) |
CameraPinholeBrown(double fx,
double fy,
double skew,
double cx,
double cy,
int width,
int height) |
CameraPinholeBrown(int numRadial) |
| Modifier and Type | Method and Description |
|---|---|
<T extends CameraModel> |
createLike()
Creates a new camera model with zero values of the same type os this one
|
CameraPinholeBrown |
fsetK(double fx,
double fy,
double skew,
double cx,
double cy,
int width,
int height) |
CameraPinholeBrown |
fsetRadial(double... radial) |
CameraPinholeBrown |
fsetTangental(double t1,
double t2) |
double[] |
getRadial() |
double |
getT1() |
double |
getT2() |
boolean |
isDistorted()
If true then distortion parameters are specified.
|
boolean |
isDistorted(double tol) |
void |
print() |
void |
set(CameraPinhole param) |
void |
setRadial(double... radial) |
void |
setT1(double t1) |
void |
setT2(double t2) |
java.lang.String |
toString() |
getCx, getCy, getFx, getFy, getSkew, inside, isEquals, setCx, setCy, setFx, setFy, setSkewgetHeight, getWidth, setHeight, setWidthpublic double[] radial
public double t1
public double t2
public CameraPinholeBrown()
public CameraPinholeBrown(int numRadial)
public CameraPinholeBrown(CameraPinholeBrown param)
public CameraPinholeBrown(double fx,
double fy,
double skew,
double cx,
double cy,
int width,
int height)
public CameraPinholeBrown fsetK(double fx, double fy, double skew, double cx, double cy, int width, int height)
fsetK in class CameraPinholepublic CameraPinholeBrown fsetRadial(double... radial)
public CameraPinholeBrown fsetTangental(double t1, double t2)
public void set(CameraPinhole param)
set in class CameraPinholepublic boolean isDistorted()
public boolean isDistorted(double tol)
public double[] getRadial()
public void setRadial(double... radial)
public double getT1()
public void setT1(double t1)
public double getT2()
public void setT2(double t2)
public void print()
print in class CameraPinholepublic java.lang.String toString()
toString in class CameraPinholepublic <T extends CameraModel> T createLike()
CameraModelcreateLike in class CameraPinhole