// 代表一个旋转的矩形,包含矩形的中心,矩形的大小,旋转的角度。
class CV_EXPORTS RotatedRect
{
public:
    //! various constructors
    RotatedRect();
    RotatedRect(const Point2f& center, const Size2f& size, float angle);
    RotatedRect(const CvBox2D& box);
    //! returns 4 vertices of the rectangle
    void points(Point2f pts[]) const;
    //! returns the minimal up-right rectangle containing the rotated rectangle
    Rect boundingRect() const;
    //! conversion to the old-style CvBox2D structure
    operator CvBox2D() const;
    Point2f center; //< the rectangle mass center
    Size2f size;    //< width and height of the rectangle
    float angle;    //< the rotation angle. When the angle is 0, 90, 180, 270 etc., the rectangle becomes an up-right rectangle.
};




相关文章:

  • 2022-01-03
  • 2021-07-25
  • 2022-12-23
  • 2021-11-23
  • 2021-05-04
  • 2021-10-24
猜你喜欢
  • 2021-12-10
  • 2022-12-23
  • 2021-09-15
  • 2021-05-27
  • 2021-06-19
  • 2021-08-17
  • 2021-12-17
相关资源
相似解决方案