18 #ifndef mitkCameraIntrinsics_h
19 #define mitkCameraIntrinsics_h
23 #include <itkDataObject.h>
24 #include <itkFastMutexLock.h>
26 #include <vnl/vnl_matrix_fixed.h>
28 #include <MitkCameraCalibrationExports.h>
52 itkFactorylessNewMacro(Self);
72 vnl_matrix_fixed<mitk::ScalarType, 3, 3> GetVnlCameraMatrix()
const;
78 vnl_matrix_fixed<mitk::ScalarType, 3, 4> GetVnlCameraMatrix3x4()
const;
85 void SetValid(
bool valid);
86 cv::Mat GetCameraMatrix()
const;
87 cv::Mat GetDistorsionCoeffs();
88 cv::Mat GetDistorsionCoeffs()
const;
89 void ToXML(TiXmlElement* elem)
const override;
90 std::string ToString()
const;
91 std::string GetString();
92 double GetFocalLengthX()
const;
93 double GetFocalLengthY()
const;
94 double GetPrincipalPointX()
const;
95 double GetPrincipalPointY()
const;
99 vnl_vector_fixed<mitk::ScalarType, 2> GetFocalPointAsVnlVector()
const;
100 vnl_vector_fixed<mitk::ScalarType, 2> GetPrincipalPointAsVnlVector()
const;
105 void SetCameraMatrix(
const vnl_matrix_fixed<mitk::ScalarType, 3, 3>&
108 void SetIntrinsics(
const cv::Mat& _CameraMatrix
109 ,
const cv::Mat& _DistorsionCoeffs);
111 void SetFocalLength(
double x,
double y );
112 void SetPrincipalPoint(
double x,
double y );
113 void SetDistorsionCoeffs(
double k1,
double k2,
double p1,
double p2 );
119 void FromXML(TiXmlElement* elem)
override;
120 void FromGMLCalibrationXML(TiXmlElement* elem);
121 std::string ToOctaveString(
const std::string& varName=
"CameraIntrinsics");
141 MITKCAMERACALIBRATION_EXPORT std::ostream&
operator<<
144 #endif // mitkCameraIntrinsics_h
itk::SmartPointer< Self > Pointer
class representing camera intrinsics and related functions
DataCollection - Class to facilitate loading/accessing structured data.
itk::FastMutexLock::Pointer m_Mutex
#define mitkClassMacroItkParent(className, SuperClassName)
cv::Mat m_DistorsionCoeffs
interface for all classes able to write themselves to XML files
int mitkCameraIntrinsicsTest(int argc, char *argv[])