工控编程吧
标题:
halcon elliptic_axis_gray函数介绍
[打印本页]
作者:
qq263946146
时间:
2019-5-9 11:26
标题:
halcon elliptic_axis_gray函数介绍
elliptic_axis_gray(Regions, Image : : : Ra, Rb, Phi)
elliptic_axis_gray计算Regions外接椭圆轴长和方向,
Regions可为元组类型,
长轴,短轴,相对x-axis的方向
Phi(弧度单位)被计算出。
计算过程类似于elliptic_axis。唯一的区别是,在elliptic_axis_gray中使用的是灰度值矩,而不是区域矩。
灰度值矩是从输入图像图像中提取出来的。有关灰度值矩的定义,请参见area_center_gray。
例程
read_image (Image, 'monkey')
threshold (Image, Region, 128, 255)
connection (Region, ConnectedRegions)
select_shape (ConnectedRegions, SelectedRegions, ['area','anisometry'], 'and', [500,1], [2000,1.7])
area_center (SelectedRegions, AreaRegion, RowRegion, ColumnRegion)
area_center_gray (SelectedRegions, Image, AreaGray, RowGray, ColumnGray)
elliptic_axis (SelectedRegions, RaRegion, RbRegion, PhiRegion)
elliptic_axis_gray (SelectedRegions, Image, RaGray, RbGray, PhiGray)
欢迎光临 工控编程吧 (https://www.gkbc8.com/)
Powered by Discuz! X3.4