Class documentation of Concepts

Loading...
Searching...
No Matches
meshEPS.hh
Go to the documentation of this file.
1
6#ifndef graphMeshEPS_hh
7#define graphMeshEPS_hh
8
9#include <string>
10#include "basics/typedefs.hh"
12#include "basics/exceptions.hh"
13#include "space/postProcess.hh"
14
15namespace concepts {
16 // forward declartions
17 class Mesh2;
18} // namespace concepts
19
20namespace graphics {
21
22 using concepts::Real;
23
24 // *************************************************************** MeshEPS **
25
38 template<class F = Real>
39 class MeshEPS {
40 public:
44 MeshEPS(concepts::Mesh& msh, std::string filename,
45 const Real scale = 100, const Real greyscale = 1.0,
46 const unsigned int nPoints = 20);
47
51 MeshEPS(concepts::Space<F>& spc, std::string filename,
52 const Real scale = 100, const Real greyscale = 1.0,
53 const unsigned int nPoints = 20);
54 private:
57
59 concepts::Mesh* msh_;
60 };
61
68// template<class F>
69 MeshEPS<Real> drawMeshEPS(concepts::Mesh& msh, std::string filename,
70 const Real scale = 100, const Real greyscale = 1.0,
71 const unsigned int nPoints = 2);
72
79 template<class F>
80 MeshEPS<F> drawMeshEPS(concepts::Space<F>& spc, std::string filename,
81 const Real scale = 100, const Real greyscale = 1.0,
82 const unsigned int nPoints = 20);
83
84 // *********************************************************** MeshEPSCell **
85
97 template<class F>
99 public:
107 MeshEPSCell(std::ostream& os, concepts::Mesh2& msh,
108 const Real scale = 100, const Real greyscale = 1.0,
109 const unsigned int nPoints = 20);
110
118 MeshEPSCell(std::ostream& os, concepts::Space<F>& spc,
119 const Real scale = 100, const Real greyscale = 1.0,
120 const unsigned int nPoints = 20);
121
122 virtual void operator() (const concepts::Element<Real>& elm);
123 virtual void operator() (const concepts::Cell& cell);
124 void offsetMin(const concepts::Real2d& x);
125 void maxMax(const concepts::Real2d& x);
126 private:
128 std::ostream& os_;
129
131 Real scale_;
132
134 Real greyscale_;
135
137 concepts::Real2d offset_;
138
140 concepts::Real2d max_;
141
143 unsigned int nPoints_;
144
145 void EPSheader_(const concepts::Real2d max, std::ostream& os) const;
146 };
147
148} // namespace graphics
149
150#endif // graphMeshEPS_hh
MeshEPSCell(std::ostream &os, concepts::Mesh2 &msh, const Real scale=100, const Real greyscale=1.0, const unsigned int nPoints=20)
MeshEPSCell(std::ostream &os, concepts::Space< F > &spc, const Real scale=100, const Real greyscale=1.0, const unsigned int nPoints=20)
MeshEPS(concepts::Space< F > &spc, std::string filename, const Real scale=100, const Real greyscale=1.0, const unsigned int nPoints=20)
MeshEPS(concepts::Mesh &msh, std::string filename, const Real scale=100, const Real greyscale=1.0, const unsigned int nPoints=20)
double Real
Definition typedefs.hh:39
MeshEPS< Real > drawMeshEPS(concepts::Mesh &msh, std::string filename, const Real scale=100, const Real greyscale=1.0, const unsigned int nPoints=2)