IPSDK  4_1_0_2
IPSDK : Image Processing Software Development Kit
HuMomentsUtils.h
Go to the documentation of this file.
1 // HuMomentsUtils.h:
3 // -----------------
4 //
14 
15 #ifndef __IPSDKGEOMETRY_HUMOMENTSUTILS_H__
16 #define __IPSDKGEOMETRY_HUMOMENTSUTILS_H__
17 
20 #include <IPSDKGeometry/Measure/2d/HuMomentsMsr2d.h>
22 
23 namespace ipsdk {
24 namespace geom {
25 
28 
33 shapeHuDistance(const ipsdk::geom::HuMoments2dO3& huMoments1, const ipsdk::geom::HuMoments2dO3& huMoments2, const eShapeHuDistanceType& distanceType);
35 shapeHuDistance(const Shape2d& shape1, const Shape2d& shape2, const eShapeHuDistanceType& distanceType, const ipsdk::ipBool bProcessHoles);
36 
39 IPSDKGEOMETRY_API MatchShapeInfo
40 matchShape(const Shape2dPtr shape, const std::vector<Shape2dPtr>& vShape2dColl, const eShapeHuDistanceType& distanceType, const ipsdk::ipBool bProcessHoles);
41 
47 matchShape(const Shape2dPtr shape, const std::vector<Shape2dPtr>& vShape2dColl, const eShapeHuDistanceType& distanceType, const ipsdk::ipBool bProcessHoles, const ipsdk::ipReal64 threshold);
48 
50 IPSDKGEOMETRY_API MatchShapesInfo
51 matchShapes(const Shape2dPtr shape, const std::vector<Shape2dPtr>& vShape2dColl, const eShapeHuDistanceType& distanceType, const ipsdk::ipBool bProcessHoles);
53 matchShapes(const Shape2dPtr shape, const std::vector<Shape2dPtr>& vShape2dColl, const eShapeHuDistanceType& distanceType, const ipsdk::ipBool bProcessHoles, UInt32Vector& vIdx, Real64Vector& vDistances);
54 
55 
60 matchShapes(const Shape2dPtr shape, const std::vector<Shape2dPtr>& vShape2dColl, const eShapeHuDistanceType& distanceType, const ipsdk::ipBool bProcessHoles, const ipsdk::ipReal64 threshold);
62 matchShapes(const Shape2dPtr shape, const std::vector<Shape2dPtr>& vShape2dColl, const eShapeHuDistanceType& distanceType, const ipsdk::ipBool bProcessHoles, const ipsdk::ipReal64 threshold, UInt32Vector& vIdx);
63 
66 
67 } // end of namespace geom
68 } // end of namespace ipsdk
69 
70 #endif // __IPSDKGEOMETRY_HUMOMENTSUTILS_H__
IPSDKGEOMETRY_API MatchShapeInfo matchShape(const Shape2dPtr shape, const std::vector< Shape2dPtr > &vShape2dColl, const eShapeHuDistanceType &distanceType, const ipsdk::ipBool bProcessHoles)
fonction matching a shape with another shape contained in the collection vShape2dColl Returns the ind...
Main namespace for IPSDK library.
Definition: AlgorithmFunctionEfficiency.h:22
IPSDKGEOMETRY_API MatchShapesInfo matchShapes(const Shape2dPtr shape, const std::vector< Shape2dPtr > &vShape2dColl, const eShapeHuDistanceType &distanceType, const ipsdk::ipBool bProcessHoles)
fonction computing the distances between a shape and all shapes in the collection vShape2dColl ...
std::vector< ipUInt32 > UInt32Vector
stl vector collections
Definition: BaseCollections.h:33
std::vector< ipReal64 > Real64Vector
stl vector collections
Definition: BaseCollections.h:37
eShapeHuDistanceType
Definition: HuMomentsTypes.h:30
boost::shared_ptr< Shape2d > Shape2dPtr
shared pointer to Shape2d
Definition: Shape2dTypes.h:30
double ipReal64
Base types definition.
Definition: BaseTypes.h:57
Types defined for Hu moments based shape matching.
Definition of import/export macro for library.
#define IPSDKGEOMETRY_API
Import/Export macro for library IPSDKGeometry.
Definition: IPSDKGeometryExports.h:25
IPSDKGEOMETRY_API ipsdk::ipReal64 shapeHuDistance(const ipsdk::geom::HuMoments2dO3 &huMoments1, const ipsdk::geom::HuMoments2dO3 &huMoments2, const eShapeHuDistanceType &distanceType)
fonction computing the distance between two shapes More the distance has a low value, more the shapes are similar
bool ipBool
Base types definition.
Definition: BaseTypes.h:47
Moments of order up to 3 on a 2d shape.
Definition: HuMoments2dO3.h:30
Predefined types for shape 2d management.
uint32_t ipUInt32
Base types definition.
Definition: BaseTypes.h:53