IGeometry.hpp
1 #pragma once
2 
3 
4 #include "DM/config.hpp"
5 #include "DM/Handle.hpp"
6 #include "DM/ObjectBase.hpp"
7 #include "DM/ScopSemantic.hpp"
8 
9 DM_NAMESPACE_BEGIN
10 
11 enum struct GeometryType
12 {
13  null, ///< undefined geometry
14  point, ///< point type
15  polyline, ///< polyline type
16  polygon, ///< polygon type
17  window, ///< window type (2D)
18  box, ///< box type (3D)
19  circle, ///< circle (2D)
20  sphere, ///< sphere (3D)
21  cylinder, ///< cylinder (3D)
22  pointSet ///< 3d point set (3D)
23 };
24 
25 /// \brief Base class of all geometry objects
26 class DM_API IGeometry : public ObjectBase
27 {
28 public:
29  virtual ~IGeometry() {}
30 
31  /// get geometry type (kind of runtime type information)
32  virtual GeometryType type() const = 0;
33 
34  /// sets the special topographic semantic of an geometry objects (not supported by all geometry types yet)
35  virtual void setScopSemantic(ScopSemantic scopSem) = 0;
36  /// returns the special topographic semantic of an geometry object
37  virtual ScopSemantic getScopSemantic() const = 0;
38 
39 
40  /// get an object copy
41  virtual IGeometry* clone() const = 0;
42 };
43 
45 
46 
47 DM_NAMESPACE_END
@ window
window type (2D)
@ sphere
sphere (3D)
@ polyline
polyline type
GeometryType
Definition: IGeometry.hpp:11
@ pointSet
3d point set (3D)
ScopSemantic
the scop semantic describes a kind of topographic semantic
Definition: ScopSemantic.hpp:8
@ polygon
polygon type
Base class of all geometry objects.
Definition: IGeometry.hpp:26
@ box
box type (3D)
Smart pointer class using reference counting with support for DM objects (see ObjectBase)
Definition: Handle.hpp:75
Definition: M/c++_api/inc/DM/ObjectBase.hpp:8