🤖 AIによる機械翻訳(非公式) — これは OpenCV 5.0.0 公式リファレンス(英語)を AI (Claude) で自動翻訳したものです。訳に誤りを含む場合があります。正確な情報は 公式英語版(原文) を参照してください。

クラス FastLineDetector


  • public class FastLineDetector extends Algorithm
    CITE: Lee14 に記載されている FLD (Fast Line Detector) アルゴリズムを実装したクラス。
    • コンストラクタの詳細

      • FastLineDetector

        protected FastLineDetector​(long addr)
    • メソッドの詳細

      • detect

        public void detect​(Mat image,
                           Mat lines)
        Finds lines in the input image. This is the output of the default parameters of the algorithm on the above shown image. ![image](pics/corridor_fld.jpg)
        引数:
        image - グレースケール (CV_8UC1) の入力画像。ROIのみを選択する必要がある場合は次のように使用する: `fld_ptr->detect(image(roi), lines, ...); lines += Scalar(roi.x, roi.y, roi.x, roi.y);`
        lines - 直線の始点と終点を指定する Vec4f 要素のベクトル。Vec4f は (x1, y1, x2, y2) で、点1が始点、点2が終点である。返される直線は、より明るい側が左になるように向き付けられている。
      • drawSegments

        public void drawSegments​(Mat image,
                                 Mat lines,
                                 boolean draw_arrow,
                                 Scalar linecolor,
                                 int linethickness)
        Draws the line segments on a given image.
        引数:
        image - 線が描画される画像。線が見つかった画像以上の大きさである必要がある。
        lines - 描画する必要のある線のベクトル。
        draw_arrow - true の場合、矢印の先端が描画される。
        linecolor - 線の色。
        linethickness - 線の太さ。
      • drawSegments

        public void drawSegments​(Mat image,
                                 Mat lines,
                                 boolean draw_arrow,
                                 Scalar linecolor)
        Draws the line segments on a given image.
        引数:
        image - 線が描画される画像。線が見つかった画像以上の大きさである必要がある。
        lines - 描画する必要のある線のベクトル。
        draw_arrow - true の場合、矢印の先端が描画される。
        linecolor - 線の色。
      • drawSegments

        public void drawSegments​(Mat image,
                                 Mat lines,
                                 boolean draw_arrow)
        Draws the line segments on a given image.
        引数:
        image - 線が描画される画像。線が見つかった画像以上の大きさである必要がある。
        lines - 描画する必要のある線のベクトル。
        draw_arrow - true の場合、矢印の先端が描画される。
      • drawSegments

        public void drawSegments​(Mat image,
                                 Mat lines)
        Draws the line segments on a given image.
        引数:
        image - 線が描画される画像。線が見つかった画像以上の大きさである必要がある。
        lines - 描画する必要のある線のベクトル。