xc
ThreePoints3d.h
1 // -*-c++-*-
2 //----------------------------------------------------------------------------
3 // xc utils library; general purpose classes and functions.
4 //
5 // Copyright (C) Luis C. Pérez Tato
6 //
7 // XC utils is free software: you can redistribute it and/or modify
8 // it under the terms of the GNU General Public License as published by
9 // the Free Software Foundation, either version 3 of the License, or
10 // (at your option) any later version.
11 //
12 // This software is distributed in the hope that it will be useful, but
13 // WITHOUT ANY WARRANTY; without even the implied warranty of
14 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
15 // GNU General Public License for more details.
16 //
17 // You should have received a copy of the GNU General Public License
18 // along with this program.
19 // If not, see <http://www.gnu.org/licenses/>.
20 //----------------------------------------------------------------------------
21 //ThreePoints3d.h
22 
23 #ifndef THREEPOINTS3D_H
24 #define THREEPOINTS3D_H
25 
26 #include "../pos_vec/Pos3d.h"
27 
28 
30 //
32 class ThreePoints3d : public ProtoGeom
33  {
34  Pos3d _org;
35  Pos3d _p1;
36  Pos3d _p2;
37  protected:
38  //void salva_miembros(std::ostream &os,const std::string &indent) const;
39  public:
40  ThreePoints3d(void): ProtoGeom() {}
41  ThreePoints3d(const Pos3d &p1,const Pos3d &p2,const Pos3d &p3): ProtoGeom()
42  { ThreePoints3d(p1,p2,p3); }
43  const Pos3d &Org(void) const
44  { return _org; }
45  const Pos3d &P1(void) const
46  { return _p1; }
47  const Pos3d &P2(void) const
48  { return _p2; }
49  };
50 
51 #endif
ProtoGeom(void)
False when solution is not possible: intersection of parallel planes.
Definition: ProtoGeom.cc:33
Base class for geometry objects.
Definition: ProtoGeom.h:33
Posición en tres dimensiones.
Definition: Pos3d.h:44
Data structure that stores three points.
Definition: ThreePoints3d.h:32