ECOGEN 6.0
Evolutive, Compressible, Open, Genuine, Easy, N-phase
Loading...
Searching...
No Matches
Face.h
Go to the documentation of this file.
1//
2// ,---. ,--, .---. ,--, ,---. .-. .-.
3// | .-' .' .') / .-. ) .' .' | .-' | \| |
4// | `-. | |(_) | | |(_) | | __ | `-. | | |
5// | .-' \ \ | | | | \ \ ( _) | .-' | |\ |
6// | `--. \ `-. \ `-' / \ `-) ) | `--. | | |)|
7// /( __.' \____\ )---' )\____/ /( __.' /( (_)
8// (__) (_) (__) (__) (__)
9// Official webSite: https://code-mphi.github.io/ECOGEN/
10//
11// This file is part of ECOGEN.
12//
13// ECOGEN is the legal property of its developers, whose names
14// are listed in the copyright file included with this source
15// distribution.
16//
17// ECOGEN is free software: you can redistribute it and/or modify
18// it under the terms of the GNU General Public License as published
19// by the Free Software Foundation, either version 3 of the License,
20// or (at your option) any later version.
21//
22// ECOGEN is distributed in the hope that it will be useful,
23// but WITHOUT ANY WARRANTY; without even the implied warranty of
24// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
25// GNU General Public License for more details.
26//
27// You should have received a copy of the GNU General Public License
28// along with ECOGEN (file LICENSE).
29// If not, see <http://www.gnu.org/licenses/>.
30
31#ifndef FACE_H
32#define FACE_H
33
34#include "../Maths/Coord.h"
35#include "../Errors.h"
36
37class Face;
38
39#include "Element.h"
40
41class Face
42{
43 public:
44 Face();
45 virtual ~Face();
46
47 //Accesseurs
48 const Coord& getNormal() const { return m_normal; };
49 const Coord& getTangent() const { return m_tangent; };
50 const Coord& getBinormal() const { return m_binormal; };
51 const double& getSurface() const { return m_surface; };
52 const Coord& getPos() const { return m_position; };
53
54 virtual void setSurface(const double& /*surface*/) { Errors::errorMessage("setSurface not available for requested face"); };
55 virtual void initializeOthers(const double& /*surface*/, const Coord& /*normal*/, const Coord& /*tangent*/, const Coord& /*binormal*/)
56 {
57 Errors::errorMessage("initializeOthers not available for requested face");
58 }
59 virtual void setPos(const double& /*X*/, const double& /*Y*/, const double& /*Z*/)
60 {
61 Errors::errorMessage("setPos not available for requested face");
62 };
63 virtual void setNormal(const double& /*X*/, const double& /*Y*/, const double& /*Z*/)
64 {
65 Errors::errorMessage("setNormal not available for requested face");
66 };
67 virtual void setTangent(const double& /*X*/, const double& /*Y*/, const double& /*Z*/)
68 {
69 Errors::errorMessage("setTangent not available for requested face");
70 };
71 virtual void setBinormal(const double& /*X*/, const double& /*Y*/, const double& /*Z*/)
72 {
73 Errors::errorMessage("setBinormal not available for requested face");
74 };
75 virtual void setSize(const double& /*sizeX*/, const double& /*sizeY*/, const double& /*sizeZ*/)
76 {
77 Errors::errorMessage("setSize not available for requested face");
78 };
79 virtual void setSize(const Coord& /*size*/) { Errors::errorMessage("setSize not available for requested face"); };
80
81 double distance(Element* e);
82
83 virtual void printInfo() const { Errors::errorMessage("AfficheInfos not available for requested face"); };
84
85 virtual const double& getSizeX()
86 {
87 Errors::errorMessage("getSizeX not available for requested face");
89 };
90 virtual const double& getSizeY()
91 {
92 Errors::errorMessage("getSizeY not available for requested face");
94 };
95 virtual const double& getSizeZ()
96 {
97 Errors::errorMessage("getSizeZ not available for requested face");
99 };
100 virtual const Coord& getSize()
101 {
102 Errors::errorMessage("getSize not available for requested face");
103 return Coord::defaultCoord;
104 };
105
106 //Pour methode AMR
108 {
109 Errors::errorMessage("creerNouvelleFace not available for requested face");
110 return 0;
111 };
112
113 protected:
115 double m_surface;
119};
120
121#endif // FACE_H
Class for a coordinate system object such as coordinates of the vertex or a vector.
Definition Coord.h:43
static const Coord defaultCoord
Default Coord object (const version).
Definition Coord.h:55
Definition Element.h:47
static void errorMessage(const std::string &message_)
Definition Errors.cpp:56
static constexpr double defaultDouble
Definition Errors.h:99
Definition Face.h:42
virtual void setNormal(const double &, const double &, const double &)
Definition Face.h:63
Coord m_normal
Definition Face.h:116
virtual Face * creerNouvelleFace()
Definition Face.h:107
virtual void setSize(const Coord &)
Definition Face.h:79
virtual ~Face()
Definition Face.cpp:39
virtual void printInfo() const
Definition Face.h:83
const Coord & getBinormal() const
Definition Face.h:50
virtual const double & getSizeZ()
Definition Face.h:95
virtual void setBinormal(const double &, const double &, const double &)
Definition Face.h:71
virtual const double & getSizeX()
Definition Face.h:85
virtual void setSurface(const double &)
Definition Face.h:54
double distance(Element *e)
Definition Face.cpp:43
const Coord & getTangent() const
Definition Face.h:49
virtual void setTangent(const double &, const double &, const double &)
Definition Face.h:67
virtual void setSize(const double &, const double &, const double &)
Definition Face.h:75
Coord m_position
Definition Face.h:114
virtual void setPos(const double &, const double &, const double &)
Definition Face.h:59
virtual void initializeOthers(const double &, const Coord &, const Coord &, const Coord &)
Definition Face.h:55
Coord m_tangent
Definition Face.h:117
const Coord & getNormal() const
Definition Face.h:48
const Coord & getPos() const
Definition Face.h:52
virtual const Coord & getSize()
Definition Face.h:100
virtual const double & getSizeY()
Definition Face.h:90
Coord m_binormal
Definition Face.h:118
double m_surface
Definition Face.h:115
const double & getSurface() const
Definition Face.h:51
Face()
Definition Face.cpp:35