函数用于计算Region 的补码RegionComplement 。如果系统标志'clip_region'为'true'(这是默认值),则返回当前halcon处理的最大图像(参见reset_obj_db)和输入区域的差值。如果系统标志'clip_region'为'false'(请参阅set_system),那么输出的结果区域将无限大。为了...
Rgb1ToGray(ho_Image,&ho_Image1);//将RGB图像转换为灰度图像Threshold(ho_Image1,&ho_Region,80,90); Complement(ho_Region,&ho_RegionComplement);//区域的反选--获取参数1之外的区域GetImageSize(ho_Image1,&hv_Width, &hv_Height); SetWindowAttr("background_color","black"); OpenWindow(10,100,...
complement (Region, RegionComplement) *区域的补集--获取参数1之外的区域 get_image_size (Image1, Width, Height) dev_open_window(10,100,Width, Height,'black',WindowHandle) dev_display(Region) dev_open_window(10,100,Width, Height,'black',WindowHandle1) dev_display(RegionComplement) 1. 2. 3...
Using complement with 'clip_region' set to 'false' makes sense only to avoid fringe effects, e.g., if the area of interest is bigger or smaller than the image. For the latter case, the clipping would be set explicitly. If there is no reason to use the operator with 'clip_region'=...
complement(Operator) Name complement— Return the complement of a region. Signature Description complementdetermines the complement of the input region(s). If the system flag'clip_region'is'true', which is the default, the difference of the largest image processed so far (seereset_obj_db) and...
complement— Return the complement of a region. Signature Description complementdetermines the complement of the input region(s). If the system flag'clip_region'is'true', which is the default, the difference of the largest image processed so far (seereset_obj_db) and the input region is retu...
the clipping would be set explicitly. If there is no reason to use the operator with'clip_region'='false'but you need the flag for other operations of your program, it is recommended to temporarilly set the system flag to'true'and change it back to'false'after applyingcomplement. Otherwis...