HDeformableSurfaceMatchingResult.h 6.2 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153
  1. /***********************************************************
  2. * File generated by the HALCON-Compiler hcomp version 20.11
  3. * Usage: Interface to C++
  4. *
  5. * Software by: MVTec Software GmbH, www.mvtec.com
  6. ***********************************************************/
  7. #ifndef HCPP_HDEFORMABLESURFACEMATCHINGRESULT
  8. #define HCPP_HDEFORMABLESURFACEMATCHINGRESULT
  9. namespace HalconCpp
  10. {
  11. // Represents an instance of a deformable surface matching result.
  12. class LIntExport HDeformableSurfaceMatchingResult : public HHandle
  13. {
  14. public:
  15. // Create an uninitialized instance
  16. HDeformableSurfaceMatchingResult():HHandle() {}
  17. // Copy constructor
  18. HDeformableSurfaceMatchingResult(const HDeformableSurfaceMatchingResult& source) : HHandle(source) {}
  19. // Copy constructor
  20. HDeformableSurfaceMatchingResult(const HHandle& handle);
  21. // Create HDeformableSurfaceMatchingResult from handle, taking ownership
  22. explicit HDeformableSurfaceMatchingResult(Hlong handle);
  23. bool operator==(const HHandle& obj) const
  24. {
  25. return HHandleBase::operator==(obj);
  26. }
  27. bool operator!=(const HHandle& obj) const
  28. {
  29. return HHandleBase::operator!=(obj);
  30. }
  31. protected:
  32. // Verify matching semantic type ('deformable_surface_matching_result')!
  33. virtual void AssertType(Hphandle handle) const;
  34. public:
  35. /***************************************************************************
  36. * Operators *
  37. ***************************************************************************/
  38. // Get details of a result from deformable surface based matching.
  39. HTuple GetDeformableSurfaceMatchingResult(const HTuple& ResultName, const HTuple& ResultIndex) const;
  40. // Get details of a result from deformable surface based matching.
  41. HTuple GetDeformableSurfaceMatchingResult(const HString& ResultName, Hlong ResultIndex) const;
  42. // Get details of a result from deformable surface based matching.
  43. HTuple GetDeformableSurfaceMatchingResult(const char* ResultName, Hlong ResultIndex) const;
  44. #ifdef _WIN32
  45. // Get details of a result from deformable surface based matching.
  46. HTuple GetDeformableSurfaceMatchingResult(const wchar_t* ResultName, Hlong ResultIndex) const;
  47. #endif
  48. // Free the memory of a deformable surface matching result.
  49. static void ClearDeformableSurfaceMatchingResult(const HDeformableSurfaceMatchingResultArray& DeformableSurfaceMatchingResult);
  50. // Free the memory of a deformable surface matching result.
  51. void ClearDeformableSurfaceMatchingResult() const;
  52. // Refine the position and deformation of a deformable surface model in a 3D scene.
  53. static HTuple RefineDeformableSurfaceModel(const HDeformableSurfaceModel& DeformableSurfaceModel, const HObjectModel3D& ObjectModel3D, double RelSamplingDistance, const HObjectModel3D& InitialDeformationObjectModel3D, const HTuple& GenParamName, const HTuple& GenParamValue, HDeformableSurfaceMatchingResultArray* DeformableSurfaceMatchingResult);
  54. // Refine the position and deformation of a deformable surface model in a 3D scene.
  55. double RefineDeformableSurfaceModel(const HDeformableSurfaceModel& DeformableSurfaceModel, const HObjectModel3D& ObjectModel3D, double RelSamplingDistance, const HObjectModel3D& InitialDeformationObjectModel3D, const HString& GenParamName, const HString& GenParamValue);
  56. // Refine the position and deformation of a deformable surface model in a 3D scene.
  57. double RefineDeformableSurfaceModel(const HDeformableSurfaceModel& DeformableSurfaceModel, const HObjectModel3D& ObjectModel3D, double RelSamplingDistance, const HObjectModel3D& InitialDeformationObjectModel3D, const char* GenParamName, const char* GenParamValue);
  58. #ifdef _WIN32
  59. // Refine the position and deformation of a deformable surface model in a 3D scene.
  60. double RefineDeformableSurfaceModel(const HDeformableSurfaceModel& DeformableSurfaceModel, const HObjectModel3D& ObjectModel3D, double RelSamplingDistance, const HObjectModel3D& InitialDeformationObjectModel3D, const wchar_t* GenParamName, const wchar_t* GenParamValue);
  61. #endif
  62. // Find the best match of a deformable surface model in a 3D scene.
  63. static HTuple FindDeformableSurfaceModel(const HDeformableSurfaceModel& DeformableSurfaceModel, const HObjectModel3D& ObjectModel3D, double RelSamplingDistance, const HTuple& MinScore, const HTuple& GenParamName, const HTuple& GenParamValue, HDeformableSurfaceMatchingResultArray* DeformableSurfaceMatchingResult);
  64. // Find the best match of a deformable surface model in a 3D scene.
  65. double FindDeformableSurfaceModel(const HDeformableSurfaceModel& DeformableSurfaceModel, const HObjectModel3D& ObjectModel3D, double RelSamplingDistance, double MinScore, const HTuple& GenParamName, const HTuple& GenParamValue);
  66. };
  67. // forward declarations and types for internal array implementation
  68. template<class T> class HSmartPtr;
  69. template<class T> class HHandleBaseArrayRef;
  70. typedef HHandleBaseArrayRef<HDeformableSurfaceMatchingResult> HDeformableSurfaceMatchingResultArrayRef;
  71. typedef HSmartPtr< HDeformableSurfaceMatchingResultArrayRef > HDeformableSurfaceMatchingResultArrayPtr;
  72. // Represents multiple tool instances
  73. class LIntExport HDeformableSurfaceMatchingResultArray : public HHandleBaseArray
  74. {
  75. public:
  76. // Create empty array
  77. HDeformableSurfaceMatchingResultArray();
  78. // Create array from native array of tool instances
  79. HDeformableSurfaceMatchingResultArray(HDeformableSurfaceMatchingResult* classes, Hlong length);
  80. // Copy constructor
  81. HDeformableSurfaceMatchingResultArray(const HDeformableSurfaceMatchingResultArray &tool_array);
  82. // Destructor
  83. virtual ~HDeformableSurfaceMatchingResultArray();
  84. // Assignment operator
  85. HDeformableSurfaceMatchingResultArray &operator=(const HDeformableSurfaceMatchingResultArray &tool_array);
  86. // Clears array and all tool instances
  87. virtual void Clear();
  88. // Get array of native tool instances
  89. const HDeformableSurfaceMatchingResult* Tools() const;
  90. // Get number of tools
  91. virtual Hlong Length() const;
  92. // Create tool array from tuple of handles
  93. virtual void SetFromTuple(const HTuple& handles);
  94. // Get tuple of handles for tool array
  95. virtual HTuple ConvertToTuple() const;
  96. protected:
  97. // Smart pointer to internal data container
  98. HDeformableSurfaceMatchingResultArrayPtr *mArrayPtr;
  99. };
  100. }
  101. #endif