Geom Software - C++ Programming and Geometry Libraries
Fade2.5D Documentation pages v1.58
CutAndFill.h
1 // Copyright (C) Geom Software e.U, Bernhard Kornberger, Graz/Austria
2 //
3 // This file is part of the Fade2D library. The student license is free
4 // of charge and covers personal non-commercial research. Licensees
5 // holding a commercial license may use this file in accordance with
6 // the Commercial License Agreement.
7 //
8 // This software is provided AS IS with NO WARRANTY OF ANY KIND,
9 // INCLUDING THE WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS
10 // FOR A PARTICULAR PURPOSE.
11 //
12 // Please contact the author if any conditions of this licensing are
13 // not clear to you.
14 //
15 // Author: Bernhard Kornberger, bkorn (at) geom.at
16 // http://www.geom.at
17 #pragma once
18 #include "common.h"
19 #include "MsgBase.h"
20 
21 #include "CAF_Component.h"
22 
23 #if GEOM_PSEUDO3D==GEOM_TRUE
24  namespace GEOM_FADE25D {
25 
26 class Zone2; // FWD;
27 class CutAndFillImpl; // FWD
28 class Visualizer2; // FWD
29 class Fade_2D; // FWD
41 class CLASS_DECLSPEC CutAndFill
42 {
43 public:
52  CutAndFill(Zone2* pZoneBefore,Zone2* pZoneAfter,double ignoreThreshold=1e-4);
53  CutAndFill();
54  ~CutAndFill();
55 
65  void getDiffZone( Zone2*& pDiffZone,
66  std::map<Point2*,std::pair<double,double> >& mVtx2BeforeAfter);
67 
81  void subscribe(MsgType msgType,MsgBase* pMsg);
82 
89  void unsubscribe(MsgType msgType,MsgBase* pMsg);
90 
102  size_t getNumberOfComponents() const;
103 
108  CAF_Component* getComponent(size_t ith) const;
109 
112  void go();
113 
122  void show(Visualizer2* pVis) const;
123 
124 protected:
125 
126  CutAndFillImpl* pCAFI;
127 private:
128  CutAndFill(const CutAndFill& ){}
129 };
130 
131 } // Namespace Fade25D only
132 
133 #elif GEOM_PSEUDO3D==GEOM_FALSE
134 #else
135  #error GEOM_PSEUDO3D is not defined
136 #endif
137 
138 
MsgBase
Definition: MsgBase.h:46
Zone2 is an exactly defined area of a triangulation.
Definition: Zone2.h:48
Cut-And-Fill.
Definition: CutAndFill.h:41
Definition: Bbox2.h:23
Point.
Definition: Point2.h:39
CAF_Component stands for CUT AND FILL COMPONENT. It represents a connected area of the surface...
Definition: CAF_Component.h:58
Visualizer2 is a general Postscript writer. It draws the objects Point2, Segment2, Triangle2, Circle2 and Label.
Definition: Visualizer2.h:51