EdgeDrawing.h 3.6 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149
  1. //
  2. // This file is auto-generated. Please don't modify it!
  3. //
  4. #pragma once
  5. #ifdef __cplusplus
  6. //#import "opencv.hpp"
  7. #import "opencv2/ximgproc.hpp"
  8. #import "opencv2/ximgproc/edge_drawing.hpp"
  9. #else
  10. #define CV_EXPORTS
  11. #endif
  12. #import <Foundation/Foundation.h>
  13. #import "Algorithm.h"
  14. @class EdgeDrawingParams;
  15. @class IntVector;
  16. @class Mat;
  17. @class Point2i;
  18. // C++: enum GradientOperator (cv.ximgproc.EdgeDrawing.GradientOperator)
  19. typedef NS_ENUM(int, GradientOperator) {
  20. EdgeDrawing_PREWITT NS_SWIFT_NAME(PREWITT) = 0,
  21. EdgeDrawing_SOBEL NS_SWIFT_NAME(SOBEL) = 1,
  22. EdgeDrawing_SCHARR NS_SWIFT_NAME(SCHARR) = 2,
  23. EdgeDrawing_LSD NS_SWIFT_NAME(LSD) = 3
  24. };
  25. NS_ASSUME_NONNULL_BEGIN
  26. // C++: class EdgeDrawing
  27. /**
  28. * Class implementing the ED (EdgeDrawing) CITE: topal2012edge, EDLines CITE: akinlar2011edlines, EDPF CITE: akinlar2012edpf and EDCircles CITE: akinlar2013edcircles algorithms
  29. *
  30. * Member of `Ximgproc`
  31. */
  32. CV_EXPORTS @interface EdgeDrawing : Algorithm
  33. #ifdef __cplusplus
  34. @property(readonly)cv::Ptr<cv::ximgproc::EdgeDrawing> nativePtrEdgeDrawing;
  35. #endif
  36. #ifdef __cplusplus
  37. - (instancetype)initWithNativePtr:(cv::Ptr<cv::ximgproc::EdgeDrawing>)nativePtr;
  38. + (instancetype)fromNative:(cv::Ptr<cv::ximgproc::EdgeDrawing>)nativePtr;
  39. #endif
  40. #pragma mark - Methods
  41. //
  42. // void cv::ximgproc::EdgeDrawing::detectEdges(Mat src)
  43. //
  44. /**
  45. * Detects edges in a grayscale image and prepares them to detect lines and ellipses.
  46. *
  47. * @param src 8-bit, single-channel, grayscale input image.
  48. */
  49. - (void)detectEdges:(Mat*)src NS_SWIFT_NAME(detectEdges(src:));
  50. //
  51. // void cv::ximgproc::EdgeDrawing::getEdgeImage(Mat& dst)
  52. //
  53. /**
  54. * returns Edge Image prepared by detectEdges() function.
  55. *
  56. * @param dst returns 8-bit, single-channel output image.
  57. */
  58. - (void)getEdgeImage:(Mat*)dst NS_SWIFT_NAME(getEdgeImage(dst:));
  59. //
  60. // void cv::ximgproc::EdgeDrawing::getGradientImage(Mat& dst)
  61. //
  62. /**
  63. * returns Gradient Image prepared by detectEdges() function.
  64. *
  65. * @param dst returns 16-bit, single-channel output image.
  66. */
  67. - (void)getGradientImage:(Mat*)dst NS_SWIFT_NAME(getGradientImage(dst:));
  68. //
  69. // vector_vector_Point cv::ximgproc::EdgeDrawing::getSegments()
  70. //
  71. /**
  72. * Returns std::vector<std::vector<Point>> of detected edge segments, see detectEdges()
  73. */
  74. - (NSArray<NSArray<Point2i*>*>*)getSegments NS_SWIFT_NAME(getSegments());
  75. //
  76. // vector_int cv::ximgproc::EdgeDrawing::getSegmentIndicesOfLines()
  77. //
  78. /**
  79. * Returns for each line found in detectLines() its edge segment index in getSegments()
  80. */
  81. - (IntVector*)getSegmentIndicesOfLines NS_SWIFT_NAME(getSegmentIndicesOfLines());
  82. //
  83. // void cv::ximgproc::EdgeDrawing::detectLines(Mat& lines)
  84. //
  85. /**
  86. * Detects lines.
  87. *
  88. * @param lines output Vec<4f> contains the start point and the end point of detected lines.
  89. * NOTE: you should call detectEdges() before calling this function.
  90. */
  91. - (void)detectLines:(Mat*)lines NS_SWIFT_NAME(detectLines(lines:));
  92. //
  93. // void cv::ximgproc::EdgeDrawing::detectEllipses(Mat& ellipses)
  94. //
  95. /**
  96. * Detects circles and ellipses.
  97. *
  98. * @param ellipses output Vec<6d> contains center point and perimeter for circles, center point, axes and angle for ellipses.
  99. * NOTE: you should call detectEdges() before calling this function.
  100. */
  101. - (void)detectEllipses:(Mat*)ellipses NS_SWIFT_NAME(detectEllipses(ellipses:));
  102. //
  103. // void cv::ximgproc::EdgeDrawing::setParams(EdgeDrawing_Params parameters)
  104. //
  105. /**
  106. * sets parameters.
  107. *
  108. * this function is meant to be used for parameter setting in other languages than c++ like python.
  109. * @param parameters Parameters of the algorithm
  110. */
  111. - (void)setParams:(EdgeDrawingParams*)parameters NS_SWIFT_NAME(setParams(parameters:));
  112. @end
  113. NS_ASSUME_NONNULL_END