47 #ifndef vpCameraParameters_H 48 #define vpCameraParameters_H 52 #include <visp3/core/vpColVector.h> 53 #include <visp3/core/vpConfig.h> 54 #include <visp3/core/vpDebug.h> 55 #include <visp3/core/vpMatrix.h> 265 perspectiveProjWithoutDistortion,
266 perspectiveProjWithDistortion,
268 ProjWithKannalaBrandtDistortion
277 vpCameraParameters(
double px,
double py,
double u0,
double v0,
double kud,
double kdu);
278 vpCameraParameters(
double px,
double py,
double u0,
double v0,
const std::vector<double> &distortion_coefficients);
287 void initFromCalibrationMatrix(
const vpMatrix &_K);
288 void initFromFov(
const unsigned int &w,
const unsigned int &h,
const double &hfov,
const double &vfov);
289 void initPersProjWithoutDistortion(
double px,
double py,
double u0,
double v0);
290 void initPersProjWithDistortion(
double px,
double py,
double u0,
double v0,
double kud,
double kdu);
291 void initProjWithKannalaBrandtDistortion(
double px,
double py,
double u0,
double v0,
const std::vector<double> &distortion_coefficients);
302 void computeFov(
const unsigned int &w,
const unsigned int &h);
314 vpTRACE(
"Warning: The FOV is not computed, getHorizontalFovAngle() " 315 "won't be significant.");
330 vpTRACE(
"Warning: The FOV is not computed, getVerticalFovAngle() won't " 351 vpTRACE(
"Warning: The FOV is not computed, getFovNormals() won't be " 357 inline double get_px()
const {
return px; }
360 inline double get_py()
const {
return py; }
361 inline double get_u0()
const {
return u0; }
362 inline double get_v0()
const {
return v0; }
367 inline vpCameraParametersProjType
get_projModel()
const {
return projModel; }
372 void printParameters();
373 friend VISP_EXPORT std::ostream &operator<<(std::ostream &os,
const vpCameraParameters &cam);
376 static const double DEFAULT_U0_PARAMETER;
377 static const double DEFAULT_V0_PARAMETER;
378 static const double DEFAULT_PX_PARAMETER;
379 static const double DEFAULT_PY_PARAMETER;
380 static const double DEFAULT_KUD_PARAMETER;
381 static const double DEFAULT_KDU_PARAMETER;
382 static const vpCameraParametersProjType DEFAULT_PROJ_TYPE;
388 std::vector<double> m_dist_coefs;
395 std::vector<vpColVector> fovNormals;
397 double inv_px, inv_py;
399 vpCameraParametersProjType projModel;
Implementation of a matrix and operations on matrices.
double getHorizontalFovAngle() const
double get_px_inverse() const
bool isFovComputed() const
double get_py_inverse() const
vpCameraParametersProjType
Generic class defining intrinsic camera parameters.
std::vector< double > getKannalaBrandtDistortionCoefficients() const
vpCameraParametersProjType get_projModel() const
std::vector< vpColVector > getFovNormals() const
double getVerticalFovAngle() const