Halcon之select_shape_xld是支持多个参数过滤的

简介: Halcon之select_shape_xld是支持多个参数过滤的

例如:


select_shape_xld (Edges, SelectedXLD, ['compactness','contlength'], 'and', [1,30], [5,200])


select_shape_xld (Contours, SelectedXLD, ['width', 'height'], 'and', [400, 40], [99999, 99999])


* Image Acquisition
list_files ('C:/Users/Administrator/Desktop/', ['files','follow_links'], ImageFiles)
tuple_regexp_select (ImageFiles, ['\\.(tif|tiff|gif|bmp|jpg|jpeg|jp2|png|pcx|pgm|ppm|pbm|xwd|ima|hobj)$','ignore_case'], ImageFiles)
for Index := 0 to |ImageFiles| - 1 by 1
    read_image (Image, ImageFiles[Index])
    * Image Acquisition 01: Do something
    edges_sub_pix (Image, Edges, 'canny', 5, 5, 40)
    select_shape_xld (Edges, SelectedXLD, ['compactness','contlength'], 'and', [1,30], [5,200])
    smallest_rectangle2_xld (SelectedXLD, Row, Column, Phi, Length1, Length2)
    gen_rectangle2_contour_xld (Rectangle, Row, Column, Phi, Length1, Length2)
    dev_display (Image)
    dev_display (Rectangle)
    stop ()
endfor
相关文章
halcon的灰度变换(图像增强)
halcon的灰度变换(图像增强)
1786 1
|
存储 数据采集 数据可视化
Open3d系列 | 1. Open3d实现点云数据读写、点云配准、点云法向量计算
Open3d系列 | 1. Open3d实现点云数据读写、点云配准、点云法向量计算
18334 1
Open3d系列 | 1. Open3d实现点云数据读写、点云配准、点云法向量计算
Halcon找圆系列(1)如何检测圆形
Halcon找圆系列(1)如何检测圆形
3507 0
Halcon找圆系列(1)如何检测圆形
|
算法 数据可视化
Halcon边缘检测和线条检测(1),文章含自适应/动态二值化等算子
Halcon边缘检测和线条检测(1),文章含自适应/动态二值化等算子
2568 0
|
算法
halcon系列之直线拟合和圆形拟合算子
halcon系列之直线拟合和圆形拟合算子
2974 0
[Halcon&几何] 直线的垂线与延长线的计算
[Halcon&几何] 直线的垂线与延长线的计算
1206 1
[3D&Halcon] 3D重要算子及简单处理点云模型求高度示例讲解
[3D&Halcon] 3D重要算子及简单处理点云模型求高度示例讲解
2702 0
|
编解码 对象存储 UED
[Halcon&标定] 单相机标定
[Halcon&标定] 单相机标定
4000 2
[Halcon&图像] 图像、区域和轮廓相互转化
[Halcon&图像] 图像、区域和轮廓相互转化
985 1
|
文字识别 Python
Halcon 学习笔记五:几何定位+仿射变换+测量
Halcon 学习笔记五:几何定位+仿射变换+测量
2868 0