Package boofcv.alg.distort.spherical
Class EquirectangularDistortBase_F32
- java.lang.Object
-
- boofcv.alg.distort.spherical.EquirectangularDistortBase_F32
-
- All Implemented Interfaces:
boofcv.struct.distort.PixelTransform<georegression.struct.point.Point2D_F32>
- Direct Known Subclasses:
CameraToEquirectangular_F32,CylinderToEquirectangular_F32,EquirectangularRotate_F32
public abstract class EquirectangularDistortBase_F32 extends java.lang.Object implements boofcv.struct.distort.PixelTransform<georegression.struct.point.Point2D_F32>Base class for all distortions from an equirectangular image. The output image precomputes pointing vectors from a canonical view. The source pixel is then computed by rotating each vector and computing the longitude and latitude.
-
-
Constructor Summary
Constructors Constructor Description EquirectangularDistortBase_F32()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description voidcompute(int x, int y, georegression.struct.point.Point2D_F32 out)Input is in pinhole camera pixel coordinates.protected voiddeclareVectors(int width, int height)Declares storage for precomputed pointing vectors to output imageorg.ejml.data.FMatrixRMajgetRotation()EquirectangularTools_F32getTools()voidsetConcurrent(EquirectangularDistortBase_F32 original)Set for concurrent code.voidsetDirection(float yaw, float pitch, float roll)Specifies the rotation offset from the canonical location using yaw and pitch.voidsetDirection(org.ejml.data.FMatrixRMaj R)Specifies direction using a rotation matrixvoidsetEquirectangularShape(int width, int height)Specify the shame of the equirectangular image
-
-
-
Method Detail
-
setEquirectangularShape
public void setEquirectangularShape(int width, int height)Specify the shame of the equirectangular image- Parameters:
width- equirectangular image widthheight- equirectangular image height
-
setConcurrent
public void setConcurrent(EquirectangularDistortBase_F32 original)
Set for concurrent code. Doesn't copy expensive model variables
-
setDirection
public void setDirection(float yaw, float pitch, float roll)Specifies the rotation offset from the canonical location using yaw and pitch.- Parameters:
yaw- Radian from -pi to pipitch- Radian from -pi/2 to pi/2roll- Radian from -pi to pi
-
setDirection
public void setDirection(org.ejml.data.FMatrixRMaj R)
Specifies direction using a rotation matrix- Parameters:
R- rotation matrix
-
declareVectors
protected void declareVectors(int width, int height)Declares storage for precomputed pointing vectors to output image- Parameters:
width- output image widthheight- output image height
-
compute
public void compute(int x, int y, georegression.struct.point.Point2D_F32 out)Input is in pinhole camera pixel coordinates. Output is in equirectangular coordinates- Specified by:
computein interfaceboofcv.struct.distort.PixelTransform<georegression.struct.point.Point2D_F32>- Parameters:
x- Pixel x-coordinate in rendered pinhole cameray- Pixel y-coordinate in rendered pinhole camera
-
getTools
public EquirectangularTools_F32 getTools()
-
getRotation
public org.ejml.data.FMatrixRMaj getRotation()
-
-