IPSDK  4_1_0_2
IPSDK : Image Processing Software Development Kit
GeometryMeasure3dSrcMacros.h
Go to the documentation of this file.
1 // GeometryMeasure3dSrcMacros.h:
3 // -----------------------------
4 //
14 
15 #ifndef __IPSDKGEOMETRY_GEOMETRYMEASURE3DSRCMACROS_H__
16 #define __IPSDKGEOMETRY_GEOMETRYMEASURE3DSRCMACROS_H__
17 
21 #include <IPSDKGeometry/Entity/3d/Point/Point3d.h>
22 #include <IPSDKGeometry/Entity/3d/Vector/Vector3d.h>
23 #include <IPSDKGeometry/Entity/3d/BoundingBox/BoundingBox3d.h>
24 #include <IPSDKGeometry/Entity/3d/PointCloud/PointCloud3d.h>
25 #include <IPSDKGeometry/Entity/3d/Sphere/Sphere3d.h>
26 #include <IPSDKGeometry/Entity/3d/Triangle/Triangle3d.h>
27 #include <IPSDKGeometry/Entity/3d/Ellipsoid/Ellipsoid3d.h>
28 #include <IPSDKGeometry/Entity/3d/Cube/Cube3d.h>
29 #include <IPSDKGeometry/Entity/3d/Cuboid/Cuboid3d.h>
30 #include <IPSDKGeometry/Entity/3d/MeshWithHoles/MeshWithHoles3d.h>
31 #include <IPSDKGeometry/Entity/3d/Shape/Shape3d.h>
32 
35 
38 #define IPSDK_IMPLEMENT_GEOMETRY_MEASURE_3D(libraryName, namespaceSeq, className, version) \
39  IPSDK_IMPLEMENT_SERIAL_WITH_COPY(libraryName, namespaceSeq, className, version) \
40  bool className::measure(const BaseGeometryEntity3d& entity, DataType& result) const \
41  { \
42  return entity.visit(*this, result); \
43  } \
44  className::DataType className::measure(const BaseGeometryEntity3d& entity) \
45  { \
46  DataType result; \
47  className measureObject; \
48  IPSDKGEOMETRY_CHECK(measureObject.measure(entity, result) == true, \
49  [eMeasureMessage::eMeasureFailed] % \
50  measureObject.getMeasure3dType().str() % \
51  entity.getEntity3dType().str()); \
52  return result; \
53  }
54 
57 
60 #define IPSDK_REGISTER_GEOMETRY_MEASURE_3D_MACRO(r, classInfo, type) \
61  template IPSDKGEOMETRY_API bool \
62  BOOST_PP_SEQ_ELEM(0, classInfo)::process<type>( \
63  const BOOST_PP_SEQ_ELEM(1, classInfo)<type>& entity, \
64  BOOST_PP_SEQ_ELEM(0, classInfo)::DataType& result) const;
65 
68 #define IPSDK_REGISTER_GEOMETRY_MEASURE_3D(className, entityType, typeSeq) \
69  BOOST_PP_SEQ_FOR_EACH(IPSDK_REGISTER_GEOMETRY_MEASURE_3D_MACRO, \
70  (className)(entityType), typeSeq);
71 
74 
75 #endif // __IPSDKGEOMETRY_GEOMETRYMEASURE3DSRCMACROS_H__
Logger api for library IPSDKGeometry.
Log messages description.
Source part of macros set for class serialization.