Go to the documentation of this file.00001
00002 #ifndef vpgl_camera_compute_h_
00003 #define vpgl_camera_compute_h_
00004
00005
00006
00007
00008
00009
00010
00011
00012 #include <vpgl/vpgl_perspective_camera.h>
00013 #include <vpgl/vpgl_proj_camera.h>
00014 #include <vpgl/vpgl_affine_camera.h>
00015 #include <vcl_vector.h>
00016 #include <vgl/vgl_fwd.h>
00017 #include <vnl/vnl_fwd.h>
00018
00019
00020 class vpgl_proj_camera_compute
00021 {
00022 public:
00023
00024
00025
00026 static bool compute( const vcl_vector< vgl_homg_point_2d<double> >& image_pts,
00027 const vcl_vector< vgl_homg_point_3d<double> >& world_pts,
00028 vpgl_proj_camera<double>& camera );
00029
00030
00031
00032 static bool compute( const vcl_vector< vgl_point_2d<double> >& image_pts,
00033 const vcl_vector< vgl_point_3d<double> >& world_pts,
00034 vpgl_proj_camera<double>& camera );
00035 private:
00036
00037 vpgl_proj_camera_compute();
00038 };
00039
00040
00041
00042 class vpgl_affine_camera_compute
00043 {
00044 public:
00045
00046
00047
00048 static bool compute( const vcl_vector< vgl_point_2d<double> >& image_pts,
00049 const vcl_vector< vgl_point_3d<double> >& world_pts,
00050 vpgl_affine_camera<double>& camera );
00051 private:
00052 vpgl_affine_camera_compute();
00053 };
00054
00055
00056
00057 class vpgl_perspective_camera_compute
00058 {
00059 public:
00060
00061
00062
00063 static bool compute( const vcl_vector< vgl_point_2d<double> >& image_pts,
00064 const vcl_vector< vgl_point_3d<double> >& world_pts,
00065 const vpgl_calibration_matrix<double>& K,
00066 vpgl_perspective_camera<double>& camera );
00067
00068
00069
00070
00071
00072
00073
00074
00075
00076
00077
00078 static bool compute_dlt ( const vcl_vector< vgl_point_2d<double> >& image_pts,
00079 const vcl_vector< vgl_point_3d<double> >& world_pts,
00080 vpgl_perspective_camera<double> &camera,
00081 double &err);
00082
00083
00084
00085
00086
00087
00088
00089 static bool compute( const vcl_vector< vgl_point_2d<double> >& image_pts,
00090 const vcl_vector< vgl_point_2d<double> >& ground_pts,
00091 vpgl_perspective_camera<double>& camera );
00092
00093 private:
00094 vpgl_perspective_camera_compute();
00095 };
00096
00097 #endif // vpgl_camera_compute_h_