Points&Forces (core)
Software tools facilitating the task of surveying architecture
a_pmat.h
Go to the documentation of this file.
1 /*
2 Copyright 2010-2019 Pierre SMARS (smars@yuntech.edu.tw)
3 This program is free software: you can redistribute it and/or modify
4 it under the terms of the GNU General Public License as published by
5 the Free Software Foundation, either version 2 of the License, or
6 (at your option) any later version.
7 
8 This program is distributed in the hope that it will be useful,
9 but WITHOUT ANY WARRANTY; without even the implied warranty of
10 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
11 GNU General Public License for more details.
12 
13 You should have received a copy of the GNU General Public License
14 along with this program. If not, see <http://www.gnu.org/licenses/>.
15 */
16 #ifndef _VE_PMAT_H_
17 #define _VE_PMAT_H_
18 
19 #include "a_intern.h"
20 #include "a_pos.h"
21 #include "a_2dh.h"
22 #include "a_3dh.h"
23 
24 // .NAME a_pmat
25 // .SECTION Author
26 // Pierre Smars
27 
28 #include <iostream>
29 
31 class a_pmat : public a_mat
32 {
33 public:
34  inline a_pmat() : a_mat(3,4) {for (int i = 0; i<3; i++) (*this)(i,i)=1.; }
35  a_pmat(const a_intern& cam);
36  a_pmat(const a_mat& m);
37  a_pmat& operator=(const a_mat& m);
38  static const std::string help();
39  void intern(const a_intern& in);
40  void parallel() {(*this)(2,2)=0.;(*this)(2,3)=1.;}
41  void move(const a_pos& m);
42  a_2dh project(const a_3dh& p3d) const;
43 };
44 
45 #endif
an homogeneous 2d matrix class
Definition: a_2dh.h:30
an homogeneous 3d matrix class
Definition: a_3dh.h:30
intern calibration matrix
Definition: a_intern.h:29
Definition: a_mat.h:42
a projection matrix
Definition: a_pmat.h:32
void parallel()
Definition: a_pmat.h:40
a_pmat & operator=(const a_mat &m)
Definition: a_pmat.cxx:54
static const std::string help()
Definition: a_pmat.cxx:20
void move(const a_pos &m)
Definition: a_pmat.cxx:75
a_pmat()
Definition: a_pmat.h:34
a_2dh project(const a_3dh &p3d) const
Definition: a_pmat.cxx:83
void intern(const a_intern &in)
Definition: a_pmat.cxx:66
position matrix
Definition: a_pos.h:31