遍历文件夹与文件选择与XLD(halcon)
来源:互联网 发布:科摩多手机安全软件 编辑:程序博客网 时间:2024/06/05 11:21
读取多图:
1,申明一个数组,分别保存路径
ImagePath:=[] ImagePath[0]:='D:/1.bmp' ImagePath[1]:='D:/2.bmp' ImagePath[2]:='D:/3.bmp' for i:=0 to 2 by 1 read_image(Image,ImagePath[i]) endfor
2,for 循环
for i:=1 to 3 by 1 read_image(Image,'D:/’+'i'+'.bmp') endfor
3,遍历法
list_files( : : Directory, Options : Files)
文件格式筛选tuple_regexp_select( : : Data, Expression : Selection)
代码部分:
list_files ('C:/Users/Public/Pictures/Sample Pictures', 'files', Files)
tuple_regexp_select (Files, ['\\.(bmp|jpg)$','ignore_case'], ImageFiles)
* 依次读取图片
for Index := 0 to |ImageFiles| - 1 by 1
read_image (Image, ImageFiles[Index])
wait_seconds (1)
binomial_filter (Image, ImageBinomial, 5, 5)
wait_seconds (1)
endfor
二 不规则区域的转换:
shape_trans(region,regiontrans,type)
convex hull凸包围(由外向内包围)
outer_circle 外圆(能够包括对象的半径最小的圆形)
inner_circle 内圆
rectangle1 正矩形
rectangle2 最小包围矩形
inner_rectangle1 最大内矩形三 图型变量XLD(eXtended Line Descriptions)
XLD代表亚像素级别的轮廓或者多边形
threshold_sub_pix(inputimage, output,requirement) gen_contour_region_xld(inputRegion,output,...)
XLD的选择操作(select_shape_xld/selet_contours_xld):
select_shape_xld(XLD:SelectedXLD:Features,Operation,Min,Max:) select_contours_xld(Contours:SelectedContours:Feature,Min1,Max1,Min2,Max2:)
计算xld的面积以及中心位置:
area_center_xld(XLD:::Area,row,column,pointOrder)
xld的合并操作:
union_colliner_contours_xld: 合并同一直线的xld union_cocircular_contours_xld: 合并同圆的xld union_adjacent_contours_xld: 合并相邻的xld
xld的转换操作与region类似:
shape_trans_xld(XLD:XLDTrans:Type:)
有上面几个类型
Xld的分割操作(segment_contours_xld)
把初始xld分割成直线,直线和圆,直线和椭圆
segment_contours_xld(Contours: ContoursSplit: Mode,SmoothCont, MaxLineDist1, MaxLineDist2:)
fit_rectangle2_contour_xld
Xld 的拟合操作(fit_***_contour_xld) 把不完整的形状拟合完整
fit_line_contour_xld
fit_circle_contour_xld
fit_ellipse_contour_xld
fit_circle_contour_xld
fit_ellipse_contour_xld
0 0
- 遍历文件夹与文件选择与XLD(halcon)
- halcon学习笔记——遍历文件夹与文件选择
- halcon学习笔记——遍历文件夹与文件选择
- halcon学习笔记——(1)遍历文件夹与文件选择
- vb 遍历文件夹 与遍历文件
- vb 遍历文件夹 与遍历文件
- python-遍历文件夹与递归遍历文件
- Halcon 通過xld檢測貼片
- IO:文件夹的遍历选择与数组、集合的综合
- 打开会话框选择文件与选择文件夹
- 选择文件夹并遍历里面的文件
- 【Linux】遍历某一目录,判断文件与文件夹,main参数
- 在C#中选择文件夹与文件的方法
- php遍历目录与文件夹
- halcon学习笔记——(11)Image,region,xld初步
- halcon学习笔记——(11)Image,region,xld初步
- halcon学习笔记——(11)Image,region,xld初步
- Halcon 通过xld检测贴片
- 欢迎使用CSDN-markdown编辑器
- 设计电影类将海报的内容打印出来
- android-自定义View(一)
- Creat_local_deformable_model_xld.hdev例程相关学习
- [LeetCode][Java] Remove Duplicates from Sorted Array II
- 遍历文件夹与文件选择与XLD(halcon)
- WebService --WSDL文档解析
- 算法导论 第十九章:斐波拉契堆
- M.anisotropic_diffusion.hdev例程相关学习(不规则扩散平滑)
- gson常用用法小结
- 在TXT文件中查找指定字符串并显示指定字符串所在行的内容
- OC_可见度,方法
- TextView 去掉自适应默认的fontpadding
- decode_bar_code_rectangle2.hdev相关例程学习(解码)