DGtal  1.1.0
SurfaceMesh.h
1 
17 #pragma once
18 
31 #if defined(SurfaceMesh_RECURSES)
32 #error Recursive header files inclusion detected in SurfaceMesh.h
33 #else // defined(SurfaceMesh_RECURSES)
34 
35 #define SurfaceMesh_RECURSES
36 
37 #if !defined SurfaceMesh_h
38 
39 #define SurfaceMesh_h
40 
42 // Inclusions
43 #include <iostream>
44 #include <sstream>
45 #include <string>
46 #include "DGtal/base/Common.h"
47 #include "DGtal/base/IntegerSequenceIterator.h"
48 #include "DGtal/helpers/StdDefs.h"
49 
50 namespace DGtal
51 {
53  // template class SurfaceMesh
90  template < typename TRealPoint, typename TRealVector >
91  struct SurfaceMesh
92  {
93  typedef TRealPoint RealPoint;
94  typedef TRealVector RealVector;
96 
99 
100  typedef typename RealVector::Component Scalar;
101  typedef std::vector<Scalar> Scalars;
103  typedef std::size_t Size;
105  typedef std::size_t Index;
106  typedef Index Face;
107  typedef Index Edge;
108  typedef Index Vertex;
109  typedef std::pair< Edge, Scalar > WeightedEdge;
110  typedef std::pair< Face, Scalar > WeightedFace;
112  typedef std::vector< Vertex > Vertices;
114  typedef std::vector< Edge > Edges;
115  typedef std::vector< WeightedEdge > WeightedEdges;
116  typedef std::vector< Face > Faces;
117  typedef std::vector< WeightedFace > WeightedFaces;
118  typedef std::pair< Vertex, Vertex > VertexPair;
119 
120  // Required by CUndirectedSimpleLocalGraph
121  typedef std::set<Vertex> VertexSet;
122  template <typename Value> struct VertexMap {
123  typedef typename std::map<Vertex, Value> Type;
124  };
125 
126  // Required by CUndirectedSimpleGraph
127 
130 
131  //---------------------------------------------------------------------------
132  public:
135 
137  ~SurfaceMesh() = default;
147  SurfaceMesh() = default;
150  SurfaceMesh( const Self& other ) = default;
153  SurfaceMesh( Self&& other ) = default;
157  Self& operator=( const Self& other ) = default;
158 
177  template <typename RealPointIterator, typename VerticesIterator>
178  SurfaceMesh( RealPointIterator itPos, RealPointIterator itPosEnd,
179  VerticesIterator itVertices, VerticesIterator itVerticesEnd );
180 
201  template <typename RealPointIterator, typename VerticesIterator>
202  bool init( RealPointIterator itPos, RealPointIterator itPosEnd,
203  VerticesIterator itVertices, VerticesIterator itVerticesEnd );
204 
206  void clear();
207 
209 
210  //---------------------------------------------------------------------------
211  public:
214 
217  template <typename RealVectorIterator>
218  bool setVertexNormals( RealVectorIterator itN, RealVectorIterator itNEnd );
219 
222  template <typename RealVectorIterator>
223  bool setFaceNormals( RealVectorIterator itN, RealVectorIterator itNEnd );
224 
229 
234 
239 
245 
249  template <typename AnyRing>
251  ( const std::vector<AnyRing>& vvalues ) const;
252 
256  template <typename AnyRing>
258  ( const std::vector<AnyRing>& fvalues ) const;
259 
263  ( const std::vector<RealVector>& vuvectors ) const;
264 
268  ( const std::vector<RealVector>& fuvectors ) const;
269 
271 
272  //---------------------------------------------------------------------------
273  public:
276 
278  Size nbVertices() const
279  { return myIncidentFaces.size(); }
280 
282  Size nbEdges() const
283  { return myEdgeVertices.size(); }
284 
286  Size nbFaces() const
287  { return myIncidentVertices.size(); }
288 
292  long Euler() const
293  { return nbVertices() - nbEdges() + nbFaces(); }
294 
300  Edge makeEdge( Vertex i, Vertex j ) const;
301 
305  const Vertices& incidentVertices( Face f ) const
306  { return myIncidentVertices[ f ]; }
307 
311  const Faces& incidentFaces( Vertex v ) const
312  { return myIncidentFaces[ v ]; }
313 
316  const Faces& neighborFaces( Face f ) const
317  { return myNeighborFaces[ f ]; }
318 
321  const Vertices& neighborVertices( Vertex v ) const
322  { return myNeighborVertices[ v ]; }
323 
327  const VertexPair& edgeVertices( Edge e ) const
328  { return myEdgeVertices[ e ]; }
329 
333  const Faces& edgeFaces( Edge e ) const
334  { return myEdgeFaces[ e ]; }
335 
344  const Faces& edgeRightFaces( Edge e ) const
345  { return myEdgeRightFaces[ e ]; }
346 
355  const Faces& edgeLeftFaces( Edge e ) const
356  { return myEdgeLeftFaces[ e ]; }
357 
360  const std::vector< Vertices >& allIncidentVertices() const
361  { return myIncidentVertices; }
362 
365  const std::vector< Faces >& allIncidentFaces() const
366  { return myIncidentFaces; }
367 
369  const std::vector< Faces >& allNeighborFaces() const
370  { return myNeighborFaces; }
371 
373  const std::vector< Vertices >& allNeighborVertices() const
374  { return myNeighborVertices; }
375 
379  const std::vector< VertexPair >& allEdgeVertices() const
380  { return myEdgeVertices; }
381 
384  const std::vector< Faces >& allEdgeFaces() const
385  { return myEdgeFaces; }
386 
394  const std::vector< Faces >& allEdgeRightFaces() const
395  { return myEdgeRightFaces; }
396 
404  const std::vector< Faces >& allEdgeLeftFaces() const
405  { return myEdgeLeftFaces; }
406 
408 
409  //---------------------------------------------------------------------------
410  public:
413 
436 
438 
439  // ----------------------- Undirected simple graph services ----------------------
440  public:
443 
447  Size size() const
448  { return nbVertices(); }
449 
457  { return 8; }
458 
464  Size degree( const Vertex & v ) const
465  { return myNeighborVertices[ v ].size(); }
466 
477  template <typename OutputIterator>
478  void
479  writeNeighbors( OutputIterator &it ,
480  const Vertex & v ) const
481  {
482  for ( auto&& nv : myNeighborVertices[ v ] )
483  *it++ = nv;
484  }
485 
502  template <typename OutputIterator, typename VertexPredicate>
503  void
504  writeNeighbors( OutputIterator &it ,
505  const Vertex & v,
506  const VertexPredicate & pred) const
507  {
508  for ( auto&& nv : myNeighborVertices[ v ] )
509  if ( pred( nv ) ) *it++ = nv;
510  }
511 
514  { return ConstIterator( 0 ); }
515 
518  { return ConstIterator( nbVertices() ); }
519 
521 
522  //---------------------------------------------------------------------------
523  public:
526 
528  const std::vector< RealPoint >& positions() const
529  { return myPositions; }
530 
535  { return myPositions[ v ]; }
536 
540  const RealPoint& position( Vertex v ) const
541  { return myPositions[ v ]; }
542 
544  const std::vector< RealVector >& vertexNormals() const
545  { return myVertexNormals; }
546 
548  std::vector< RealVector >& vertexNormals()
549  { return myVertexNormals; }
550 
555  { return myVertexNormals[ v ]; }
556 
560  const RealVector& vertexNormal( Vertex v ) const
561  { return myVertexNormals[ v ]; }
562 
564  const std::vector< RealVector >& faceNormals() const
565  { return myFaceNormals; }
566 
568  std::vector< RealVector >& faceNormals()
569  { return myFaceNormals; }
570 
575  { return myFaceNormals[ f ]; }
576 
580  const RealVector& faceNormal( Face f ) const
581  { return myFaceNormals[ f ]; }
582 
585 
589  Scalar localWindow( Face f ) const;
590 
595 
600 
604 
608 
611  Scalar faceArea( Index f ) const;
612 
617 
641 
657  std::tuple< Vertices, WeightedEdges, WeightedFaces >
659 
674 
689 
700 
702 
703  // ----------------------- Interface --------------------------------------
704  public:
705 
710  void selfDisplay ( std::ostream & out ) const;
711 
716  bool isValid() const;
717 
718  // ------------------------- Protected Datas ------------------------------
719  protected:
721  std::vector< Vertices > myIncidentVertices;
723  std::vector< Faces > myIncidentFaces;
725  std::vector< RealPoint > myPositions;
727  std::vector< RealVector > myVertexNormals;
729  std::vector< RealVector > myFaceNormals;
731  std::vector< Faces > myNeighborFaces;
733  std::vector< Vertices > myNeighborVertices;
735  std::vector< VertexPair > myEdgeVertices;
737  std::vector< Faces > myEdgeFaces;
743  std::vector< Faces > myEdgeRightFaces;
749  std::vector< Faces > myEdgeLeftFaces;
750 
751  // ------------------------- Private Datas --------------------------------
752  private:
753 
754 
755  // ------------------------- Internals ------------------------------------
756  protected:
757 
761  void computeEdges();
762 
764  static Scalar rand01()
765  { return (Scalar) rand() / (Scalar) RAND_MAX; }
766 
767  }; // end of class SurfaceMesh
768 
775  template < typename TRealPoint, typename TRealVector >
776  std::ostream&
777  operator<< ( std::ostream & out,
778  const SurfaceMesh<TRealPoint, TRealVector> & object );
779 
780 } // namespace DGtal
781 
783 // Includes inline functions.
784 #include "SurfaceMesh.ih"
785 // //
787 
788 #endif // !defined SurfaceMesh_h
789 
790 #undef SurfaceMesh_RECURSES
791 #endif // else defined(SurfaceMesh_RECURSES)
DGtal::SurfaceMesh::Vertex
Index Vertex
Definition: SurfaceMesh.h:108
DGtal::SurfaceMesh::getMaxWeights
Scalars getMaxWeights(Index v) const
DGtal::SurfaceMesh::computeFaceUnitVectorsFromVertexUnitVectors
std::vector< RealVector > computeFaceUnitVectorsFromVertexUnitVectors(const std::vector< RealVector > &vuvectors) const
DGtal::SurfaceMesh::Scalar
RealVector::Component Scalar
Definition: SurfaceMesh.h:100
DGtal::SurfaceMesh::Self
SurfaceMesh< RealPoint, RealVector > Self
Definition: SurfaceMesh.h:95
DGtal::SurfaceMesh::vertexNormal
RealVector & vertexNormal(Vertex v)
Definition: SurfaceMesh.h:554
DGtal::SurfaceMesh::writeNeighbors
void writeNeighbors(OutputIterator &it, const Vertex &v, const VertexPredicate &pred) const
Definition: SurfaceMesh.h:504
DGtal::SurfaceMesh::clear
void clear()
Clears everything. The object is empty.
DGtal::SurfaceMesh::position
RealPoint & position(Vertex v)
Definition: SurfaceMesh.h:534
DGtal::SurfaceMesh::computeNeighbors
void computeNeighbors()
Computes neighboring information.
DGtal::SurfaceMesh::RealVector
TRealVector RealVector
Definition: SurfaceMesh.h:94
DGtal::SurfaceMesh::WeightedFaces
std::vector< WeightedFace > WeightedFaces
Definition: SurfaceMesh.h:117
DGtal::SurfaceMesh::faceNormals
const std::vector< RealVector > & faceNormals() const
Definition: SurfaceMesh.h:564
DGtal::SurfaceMesh::degree
Size degree(const Vertex &v) const
Definition: SurfaceMesh.h:464
DGtal::SurfaceMesh::allEdgeFaces
const std::vector< Faces > & allEdgeFaces() const
Definition: SurfaceMesh.h:384
DGtal::SurfaceMesh::Euler
long Euler() const
Definition: SurfaceMesh.h:292
DGtal::SurfaceMesh::computeFaceNormalsFromVertexNormals
void computeFaceNormalsFromVertexNormals()
DGtal::SurfaceMesh::WeightedFace
std::pair< Face, Scalar > WeightedFace
Definition: SurfaceMesh.h:110
DGtal::SurfaceMesh::computeVertexValuesFromFaceValues
std::vector< AnyRing > computeVertexValuesFromFaceValues(const std::vector< AnyRing > &fvalues) const
DGtal::SurfaceMesh::SurfaceMesh
SurfaceMesh(Self &&other)=default
DGtal::SurfaceMesh::allNeighborVertices
const std::vector< Vertices > & allNeighborVertices() const
Definition: SurfaceMesh.h:373
DGtal::SurfaceMesh::VertexPair
std::pair< Vertex, Vertex > VertexPair
Definition: SurfaceMesh.h:118
DGtal::Dimension
DGtal::uint32_t Dimension
Definition: Common.h:133
DGtal::SurfaceMesh::allIncidentFaces
const std::vector< Faces > & allIncidentFaces() const
Definition: SurfaceMesh.h:365
DGtal::SurfaceMesh
Aim: Represents an embedded mesh as faces and a list of vertices. Vertices may be shared among faces ...
Definition: SurfaceMesh.h:92
DGtal::SurfaceMesh::computeManifoldBoundaryEdges
Edges computeManifoldBoundaryEdges() const
DGtal::SurfaceMesh::edgeInclusionRatio
Scalar edgeInclusionRatio(RealPoint p, Scalar r, Index e) const
DGtal::IntegerSequenceIterator
Aim: It is a simple class that mimics a (non mutable) iterator over integers. You can increment it,...
Definition: IntegerSequenceIterator.h:69
DGtal::SurfaceMesh::myFaceNormals
std::vector< RealVector > myFaceNormals
For each face, its normal vector.
Definition: SurfaceMesh.h:729
DGtal::SurfaceMesh::myNeighborVertices
std::vector< Vertices > myNeighborVertices
For each vertex, its range of neighbor vertices (no particular order)
Definition: SurfaceMesh.h:733
DGtal::SurfaceMesh::myEdgeVertices
std::vector< VertexPair > myEdgeVertices
For each edge, its two vertices.
Definition: SurfaceMesh.h:735
DGtal::SurfaceMesh::end
ConstIterator end() const
Definition: SurfaceMesh.h:517
DGtal::SurfaceMesh::computeManifoldInnerEdges
Edges computeManifoldInnerEdges() const
DGtal::SurfaceMesh::vertexInclusionRatio
Scalar vertexInclusionRatio(RealPoint p, Scalar r, Index v) const
DGtal::SurfaceMesh::begin
ConstIterator begin() const
Definition: SurfaceMesh.h:513
DGtal::SurfaceMesh::positions
const std::vector< RealPoint > & positions() const
Definition: SurfaceMesh.h:528
DGtal::SurfaceMesh::nbVertices
Size nbVertices() const
Definition: SurfaceMesh.h:278
DGtal::SurfaceMesh::averageEdgeLength
Scalar averageEdgeLength() const
DGtal::SurfaceMesh::makeEdge
Edge makeEdge(Vertex i, Vertex j) const
DGtal::PointVector::Component
TEuclideanRing Component
Type for Vector elements.
Definition: PointVector.h:614
DGtal::SurfaceMesh::computeFacesInclusionsInBall
WeightedFaces computeFacesInclusionsInBall(Scalar r, Index f) const
DGtal::SurfaceMesh::ConstIterator
IntegerSequenceIterator< Vertex > ConstIterator
Non mutable iterator for visiting vertices.
Definition: SurfaceMesh.h:129
DGtal::SurfaceMesh::size
Size size() const
Definition: SurfaceMesh.h:447
DGtal::SurfaceMesh::myEdgeFaces
std::vector< Faces > myEdgeFaces
For each edge, its faces (one, two, or more if non manifold)
Definition: SurfaceMesh.h:737
DGtal::SurfaceMesh::Faces
std::vector< Face > Faces
Definition: SurfaceMesh.h:116
DGtal::SurfaceMesh::Vertices
std::vector< Vertex > Vertices
The type that defines a list/range of vertices (e.g. to define faces)
Definition: SurfaceMesh.h:112
DGtal::SurfaceMesh::SurfaceMesh
SurfaceMesh(RealPointIterator itPos, RealPointIterator itPosEnd, VerticesIterator itVertices, VerticesIterator itVerticesEnd)
DGtal::SurfaceMesh::incidentFaces
const Faces & incidentFaces(Vertex v) const
Definition: SurfaceMesh.h:311
DGtal::SurfaceMesh::computeNonManifoldEdges
Edges computeNonManifoldEdges() const
DGtal::SurfaceMesh::edgeLeftFaces
const Faces & edgeLeftFaces(Edge e) const
Definition: SurfaceMesh.h:355
DGtal::SurfaceMesh::faceNormal
RealVector & faceNormal(Face f)
Definition: SurfaceMesh.h:574
DGtal::SurfaceMesh::computeVertexNormalsFromFaceNormals
void computeVertexNormalsFromFaceNormals()
DGtal::SurfaceMesh::myIncidentFaces
std::vector< Faces > myIncidentFaces
For each vertex, its range of incident faces.
Definition: SurfaceMesh.h:723
DGtal::SurfaceMesh::Edge
Index Edge
Definition: SurfaceMesh.h:107
DGtal::SurfaceMesh::VertexSet
std::set< Vertex > VertexSet
Definition: SurfaceMesh.h:121
DGtal::SurfaceMesh::~SurfaceMesh
~SurfaceMesh()=default
Default destructor.
DGtal::SurfaceMesh::nbEdges
Size nbEdges() const
Definition: SurfaceMesh.h:282
DGtal::SurfaceMesh::SurfaceMesh
SurfaceMesh()=default
DGtal::SurfaceMesh::setFaceNormals
bool setFaceNormals(RealVectorIterator itN, RealVectorIterator itNEnd)
DGtal::SurfaceMesh::neighborFaces
const Faces & neighborFaces(Face f) const
Definition: SurfaceMesh.h:316
DGtal::SurfaceMesh::myIncidentVertices
std::vector< Vertices > myIncidentVertices
For each face, its range of incident vertices.
Definition: SurfaceMesh.h:721
DGtal
DGtal is the top-level namespace which contains all DGtal functions and types.
Definition: ClosedIntegerHalfPlane.h:49
DGtal::SurfaceMesh::Edges
std::vector< Edge > Edges
The type that defines a list/range of faces.
Definition: SurfaceMesh.h:114
DGtal::SurfaceMesh::isValid
bool isValid() const
DGtal::SurfaceMesh::computeVertexNormalsFromFaceNormalsWithMaxWeights
void computeVertexNormalsFromFaceNormalsWithMaxWeights()
DGtal::SurfaceMesh::edgeVertices
const VertexPair & edgeVertices(Edge e) const
Definition: SurfaceMesh.h:327
DGtal::SurfaceMesh::faceCentroid
RealPoint faceCentroid(Index f) const
DGtal::SurfaceMesh::faceInclusionRatio
Scalar faceInclusionRatio(RealPoint p, Scalar r, Index f) const
DGtal::SurfaceMesh::setVertexNormals
bool setVertexNormals(RealVectorIterator itN, RealVectorIterator itNEnd)
DGtal::SurfaceMesh::faceArea
Scalar faceArea(Index f) const
DGtal::SurfaceMesh::rand01
static Scalar rand01()
Definition: SurfaceMesh.h:764
DGtal::SurfaceMesh::computeVertexUnitVectorsFromFaceUnitVectors
std::vector< RealVector > computeVertexUnitVectorsFromFaceUnitVectors(const std::vector< RealVector > &fuvectors) const
DGtal::SurfaceMesh::computeCellsInclusionsInBall
std::tuple< Vertices, WeightedEdges, WeightedFaces > computeCellsInclusionsInBall(Scalar r, Index f) const
DGtal::SurfaceMesh::perturbateWithAdaptiveUniformRandomNoise
void perturbateWithAdaptiveUniformRandomNoise(Scalar p)
DGtal::SurfaceMesh::WeightedEdge
std::pair< Edge, Scalar > WeightedEdge
Definition: SurfaceMesh.h:109
DGtal::SurfaceMesh::writeNeighbors
void writeNeighbors(OutputIterator &it, const Vertex &v) const
Definition: SurfaceMesh.h:479
DGtal::SurfaceMesh::computeEdges
void computeEdges()
Computes edge information.
DGtal::operator<<
std::ostream & operator<<(std::ostream &out, const ClosedIntegerHalfPlane< TSpace > &object)
DGtal::SurfaceMesh::Scalars
std::vector< Scalar > Scalars
Definition: SurfaceMesh.h:101
DGtal::SurfaceMesh::computeManifoldInnerUnconsistentEdges
Edges computeManifoldInnerUnconsistentEdges() const
DGtal::SurfaceMesh::Face
Index Face
Definition: SurfaceMesh.h:106
DGtal::PointVector::dimension
static const Dimension dimension
Copy of the static dimension of the Point/Vector.
Definition: PointVector.h:626
DGtal::SurfaceMesh::faceNormals
std::vector< RealVector > & faceNormals()
Definition: SurfaceMesh.h:568
DGtal::SurfaceMesh::allEdgeVertices
const std::vector< VertexPair > & allEdgeVertices() const
Definition: SurfaceMesh.h:379
DGtal::SurfaceMesh::computeManifoldInnerConsistentEdges
Edges computeManifoldInnerConsistentEdges() const
DGtal::SurfaceMesh::computeFaceValuesFromVertexValues
std::vector< AnyRing > computeFaceValuesFromVertexValues(const std::vector< AnyRing > &vvalues) const
DGtal::SurfaceMesh::allNeighborFaces
const std::vector< Faces > & allNeighborFaces() const
Definition: SurfaceMesh.h:369
DGtal::SurfaceMesh::perturbateWithUniformRandomNoise
void perturbateWithUniformRandomNoise(Scalar p)
DGtal::SurfaceMesh::dimension
static const Dimension dimension
Definition: SurfaceMesh.h:97
DGtal::SurfaceMesh::selfDisplay
void selfDisplay(std::ostream &out) const
DGtal::SurfaceMesh::localWindow
Scalar localWindow(Face f) const
DGtal::SurfaceMesh::neighborVertices
const Vertices & neighborVertices(Vertex v) const
Definition: SurfaceMesh.h:321
DGtal::SurfaceMesh::computeFaceNormalsFromPositions
void computeFaceNormalsFromPositions()
DGtal::SurfaceMesh::bestCapacity
Size bestCapacity() const
Definition: SurfaceMesh.h:456
DGtal::SurfaceMesh::allEdgeLeftFaces
const std::vector< Faces > & allEdgeLeftFaces() const
Definition: SurfaceMesh.h:404
DGtal::SurfaceMesh::VertexMap
Definition: SurfaceMesh.h:122
DGtal::SurfaceMesh::vertexNormals
const std::vector< RealVector > & vertexNormals() const
Definition: SurfaceMesh.h:544
DGtal::SurfaceMesh::VertexMap::Type
std::map< Vertex, Value > Type
Definition: SurfaceMesh.h:123
DGtal::SurfaceMesh::myEdgeLeftFaces
std::vector< Faces > myEdgeLeftFaces
Definition: SurfaceMesh.h:749
DGtal::SurfaceMesh::RealPoint
TRealPoint RealPoint
Definition: SurfaceMesh.h:93
DGtal::SurfaceMesh::Size
std::size_t Size
The type for counting elements.
Definition: SurfaceMesh.h:103
DGtal::SurfaceMesh::myPositions
std::vector< RealPoint > myPositions
For each vertex, its position.
Definition: SurfaceMesh.h:725
DGtal::SurfaceMesh::operator=
Self & operator=(const Self &other)=default
DGtal::SurfaceMesh::edgeRightFaces
const Faces & edgeRightFaces(Edge e) const
Definition: SurfaceMesh.h:344
DGtal::SurfaceMesh::edgeFaces
const Faces & edgeFaces(Edge e) const
Definition: SurfaceMesh.h:333
DGtal::SurfaceMesh::position
const RealPoint & position(Vertex v) const
Definition: SurfaceMesh.h:540
DGtal::SurfaceMesh::allIncidentVertices
const std::vector< Vertices > & allIncidentVertices() const
Definition: SurfaceMesh.h:360
DGtal::SurfaceMesh::vertexNormals
std::vector< RealVector > & vertexNormals()
Definition: SurfaceMesh.h:548
DGtal::SurfaceMesh::vertexNormal
const RealVector & vertexNormal(Vertex v) const
Definition: SurfaceMesh.h:560
DGtal::SurfaceMesh::edgeCentroid
RealPoint edgeCentroid(Index e) const
DGtal::SurfaceMesh::myEdgeRightFaces
std::vector< Faces > myEdgeRightFaces
Definition: SurfaceMesh.h:743
DGtal::SurfaceMesh::faceNormal
const RealVector & faceNormal(Face f) const
Definition: SurfaceMesh.h:580
DGtal::SurfaceMesh::allEdgeRightFaces
const std::vector< Faces > & allEdgeRightFaces() const
Definition: SurfaceMesh.h:394
DGtal::SurfaceMesh::incidentVertices
const Vertices & incidentVertices(Face f) const
Definition: SurfaceMesh.h:305
DGtal::SurfaceMesh::WeightedEdges
std::vector< WeightedEdge > WeightedEdges
Definition: SurfaceMesh.h:115
DGtal::SurfaceMesh::init
bool init(RealPointIterator itPos, RealPointIterator itPosEnd, VerticesIterator itVertices, VerticesIterator itVerticesEnd)
DGtal::SurfaceMesh::nbFaces
Size nbFaces() const
Definition: SurfaceMesh.h:286
DGtal::SurfaceMesh::myVertexNormals
std::vector< RealVector > myVertexNormals
For each vertex, its normal vector.
Definition: SurfaceMesh.h:727
DGtal::SurfaceMesh::SurfaceMesh
SurfaceMesh(const Self &other)=default
DGtal::SurfaceMesh::BOOST_STATIC_ASSERT
BOOST_STATIC_ASSERT((dimension==3))
DGtal::SurfaceMesh::myNeighborFaces
std::vector< Faces > myNeighborFaces
For each face, its range of neighbor faces (no particular order)
Definition: SurfaceMesh.h:731
DGtal::SurfaceMesh::Index
std::size_t Index
The type used for numbering vertices and faces.
Definition: SurfaceMesh.h:105