zw版【转发·台湾nvp系列Delphi例程】HALCON TestSubsetRegio
zw版【转发·台湾nvp系列Delphi例程】HALCON TestSubsetRegio

procedure TForm1.Button1Click(Sender: TObject);
var
rg0 : array[0..1] of HRegionX;
rg1 : array[0..1] of HRegionX;
win : HWindowX;
i : Integer;
img : HImageX;
sys : HSystemX;
IsSubset : OleVariant;
w, h : OleVariant;
ht : HTupleX;
begin
sys := CoHSystemX.Create;
sys.SetSystem('clip_region', 'false');
ht := CoHTupleX.Create;
img := CoHImageX.Create;
img.ReadImage('meningg6');
w := img.GetImageSize(h);
win := HWindowXCtrl1.HalconWindow;
win.SetPart(0, 0, h - 1, w - 1);
win.SetDraw('margin');
win.SetColored(12);
win.ClearWindow;
for i := 0 to 1 do
begin
rg0 := CoHRegionX.Create;
rg1 := CoHRegionX.Create;
end;
rg0[0].GenRectangle1(80, 200, 150, 400);
rg0[1].GenCircle(300, 300, 100);
rg1[0].GenRectangle1(100, 250, 120, 350);
rg1[1].GenCircle(350, 350, 60);
rg0[0] := rg0[0].ConcatObj(rg0[1]);
rg1[0] := rg1[0].ConcatObj(rg1[1]);
img.DispObj(win);
rg0[0].DispObj(win);
rg1[0].DispObj(win);
win.SetColor('white');
IsSubset := rg1[0].TestSubsetRegion(rg0[0]);
for i := 0 to ht.TupleLength(IsSubset) - 1 do
begin
win.SetTposition(30 * i, 10);
win.WriteString(ht.TupleSelect(IsSubset, i));
end;
end;
zw版【转发·台湾nvp系列Delphi例程】HALCON TestSubsetRegio的更多相关文章
- zw版【转发·台湾nvp系列Delphi例程】HALCON DirectShow (Delphi Prism)
zw版[转发·台湾nvp系列Delphi例程]HALCON DirectShow (Delphi Prism) namespace DirectShow_Prism;interfaceuses Sys ...
- zw版【转发·台湾nvp系列Delphi例程】HALCON HImage与Bitmap格式转换
zw版[转发·台湾nvp系列Delphi例程]HALCON HImage与Bitmap格式转换 (Delphi Prism)namespace HImage_Bitmap_Prism;interfac ...
- zw版【转发·台湾nvp系列Delphi例程】.NET调用HALCON COM控件内存释放模式
zw版[转发·台湾nvp系列Delphi例程].NET调用HALCON COM控件内存释放模式 ------------------------------------方法一 :Imports Sys ...
- zw版【转发·台湾nvp系列Delphi例程】HALCON HWindow Overlayer 1
zw版[转发·台湾nvp系列Delphi例程]HALCON HWindow Overlayer 1 ------------------------------------HALCON HWindow ...
- zw版【转发·台湾nvp系列Delphi例程】HALCON DirectFile
zw版[转发·台湾nvp系列Delphi例程]HALCON DirectFile unit Unit1;interfaceuses Windows, Messages, SysUtils, Varia ...
- zw版【转发·台湾nvp系列Delphi例程】HALCON DirectShow
zw版[转发·台湾nvp系列Delphi例程]HALCON DirectShow unit Unit1;interfaceuses Windows, Messages, SysUtils, Varia ...
- zw版【转发·台湾nvp系列Delphi例程】Delphi 使用 HALCON库件COM控件数据格式转换
zw版[转发·台湾nvp系列Delphi例程]Delphi 使用 HALCON库件COM控件数据格式转换 Delphi 使用 HALCON库件COM控件数据格式转换,与IHObjectX接口有关 va ...
- zw版【转发·台湾nvp系列Delphi例程】HALCON AddNoiseWhite
zw版[转发·台湾nvp系列Delphi例程]HALCON AddNoiseWhite unit Unit1;interfaceuses Windows, Messages, SysUtils, Va ...
- zw版【转发·台湾nvp系列Delphi例程】HALCON CheckDifference
zw版[转发·台湾nvp系列Delphi例程]HALCON CheckDifference unit Unit1;interfaceuses Windows, Messages, SysUtils, ...
- zw版【转发·台湾nvp系列Delphi例程】HALCON BinThreshold
zw版[转发·台湾nvp系列Delphi例程]HALCON BinThreshold unit Unit1;interfaceuses Windows, Messages, SysUtils, Var ...
随机推荐
- apache与weblogic 的整合
web服务器与应用服务器的整合中,apache与weblogic 的整合算的上最普遍也是最基础的整合了 今天配置了一下: apache 2.0 weblogic 8.1 1.将weblogic中的mo ...
- lua垃圾回收机制
一.检测lua内存泄漏: 注:使用“collectgarbage("collect")”,局部变量v被回收,my_list没有被回收. 注:局部变量v占用的内存被回收. 注:将my ...
- Oracle12cWindows安装、介绍及简单使用(图文)
1.下载 地址为:http://www.oracle.com/technetwork/cn/database/enterprise-edition/downloads/index.html 含企业版和 ...
- Kindeditor放置两个调用readonly错误
开始 需要调用Kindeditor中的readonly的方法,但是一直提示edit is undefined 而editor.readonly(true)又只对第一个对象有效 所以只能换换形式,干脆将 ...
- LeetCode——Intersection of Two Linked Lists
Description: Write a program to find the node at which the intersection of two singly linked lists b ...
- jhipser微服务架构介绍
内容提要 本文涉及以下内容: 微服务架构介绍 spring cloud介绍 jhipster架构介绍 微服务架构介绍 微服务概念 微服务和SOA很相似,都是按照业务功能把系统拆分成一个一个的服务.比如 ...
- Eclipse常用快捷键 及 不格式化注释
eclipse不格式化注释 - [自写] 2007-08-15 刚才在Eclipse3.2上写东西,我写好的注释,整整齐齐的,我一格式化代码,就变得七七八八的了. 试着在Perferences ...
- java的list集合操作List<T>转化List<Long>
java的list集合操作List<T>转化List<Long> package com.google.common.collect; import com.google.co ...
- 微信小程序 --- 设置页面的标题
第一种方式:修改 page.json文件 { "navigationBarTitleText": "豆瓣 - 电影" } 第二种方式:使用 JS 修改: wx. ...
- aliyun oss 文件上传 java.net.SocketTimeoutException Read timed out 问题分析及解决
upload ClientException Read timed out com.aliyun.openservices.ClientException: Read timed out ...