文章来源地址https://www.toymoban.com/news/detail-511595.html
dev_set_draw ('margin')
read_image (Image, 'Desktop/k.tiff')
xPitch:=0.05
yPitch:=0.05
get_image_size (Image, Width, Height)
min_max_gray (Image, Image, 0, Min, Max, Range)
threshold (Image, Region,Min+1, Max)//剔除无效点
reduce_domain (Image, Region, zMap)
gen_image_surface_first_order (xMap, 'real', 0, xPitch, 0, 0, 0, Width, Height)
gen_image_surface_first_order (yMap, 'real', yPitch, 0, 0, 0, 0, Width, Height)
gen_rectangle1 (ROI, 1768.53, 1748.95, 2371.5, 1905.26)
xyz_to_object_model_3d (xMap, yMap, zMap, ObjectModel3D)
visualize_object_model_3d (WindowHandle, ObjectModel3D, [], [], \
['lut','color_attrib','disp_pose'], \
['color1','coord_z','true'], [], [], [], PoseOut)
reduce_object_model_3d_by_view (ROI, ObjectModel3D, [], [], ObjectModel3DReduced)
paraName:=['primitive_type','fitting_algorithm']
paraVal:=['plane','least_squares_tukey']
fit_primitives_object_model_3d (ObjectModel3DReduced, paraName, paraVal, planeFitted)
distance_object_model_3d (ObjectModel3DReduced, planeFitted, [], 0, [], [])
get_object_model_3d_params (ObjectModel3DReduced, '&distance', pointsDis)
flatness:=abs(max(pointsDis)-min(pointsDis))
文章来源:https://www.toymoban.com/news/detail-511595.html
到了这里,关于Halcon3d 点云计算平面度的文章就介绍完了。如果您还想了解更多内容,请在右上角搜索TOY模板网以前的文章或继续浏览下面的相关文章,希望大家以后多多支持TOY模板网!