read_image (Image, ‘C:/Users/PC01/Desktop/timg.jpg’)
*得到轮廓
threshold_sub_pix (Image, Border, 128)
*得到亚像素边缘
edges_sub_pix (Image, Edges, ‘canny’, 1, 20, 40)
*选择特定形状的轮廓
select_shape_xld (Edges, SelectedXLD, ‘area’, ‘and’, 3000, 99999)
*选择多种特征要求的图像
select_contours_xld (SelectedXLD, SelectedContours, ‘contour_length’, 0.5, 200, -0.5, 0.5)
halcon轮廓选择
最新推荐文章于 2024-08-02 23:26:41 发布