博客
关于我
强烈建议你试试无所不能的chatGPT,快点击我
halcon 图片加载和设置XY轴滑动块的先后顺序
阅读量:4354 次
发布时间:2019-06-07

本文共 1760 字,大约阅读时间需要 5 分钟。

//必须先加载图片,然后执行
hWndControl.setGUICompRangeX( new int[]{ XTrackBar.Minimum,                                                         XTrackBar.Maximum},                                                      XTrackBar.Value );            hWndControl.setGUICompRangeY( new int[]{ YTrackBar.Minimum,                                                        YTrackBar.Maximum},                                                      YTrackBar.Maximum-YTrackBar.Value);
private void SmartWindow1Form_Load(object sender, System.EventArgs e)        {            hWndControl = new HWndCtrl(viewPort);            Init();        }                private void Init()        {            String fileName = @"E:\Halcon\patras";            HImage image;            try            {                image   = new HImage(fileName);            }            catch(HOperatorException)            {                MessageBox.Show("Problem occured while reading file!",                                 "SmartWindow1",                                MessageBoxButtons.OK,                                 MessageBoxIcon.Information);                return;            }                        hWndControl.addIconicVar(image);            hWndControl.repaint();                        hWndControl.setGUICompRangeX( new int[]{ XTrackBar.Minimum,                                                         XTrackBar.Maximum},                                                      XTrackBar.Value );            hWndControl.setGUICompRangeY( new int[]{ YTrackBar.Minimum,                                                        YTrackBar.Maximum},                                                      YTrackBar.Maximum-YTrackBar.Value);         }

 

转载于:https://www.cnblogs.com/qq1151219115/p/9293325.html

你可能感兴趣的文章
改变和恢复view的方向
查看>>
C#调用金数据API
查看>>
Convert Sorted List to Binary Search Tree
查看>>
Leetcode:Unique Binary Search Trees
查看>>
D3.js 绘制散点图
查看>>
HTML—链接
查看>>
将进程设置为守护进程
查看>>
用连接池提高Servlet访问数据库的效率
查看>>
luogu P1494 [国家集训队]小Z的袜子 ( 普 通 )
查看>>
树的数据结构
查看>>
MyEclipse导入Color Theme
查看>>
Vue开发微信H5 微信分享签名失败问题解决方案
查看>>
Linux - 配置SSH免密通信 - “ssh-keygen”的基本用法
查看>>
Python(2.7.6) glob - 匹配指定模式的文件
查看>>
HTTP - 持久连接
查看>>
添加路由时啥时候是dev啥时候是gw
查看>>
redis 中文字符显示
查看>>
登录日志分析常用查询
查看>>
Codeforces Round #228 (Div. 1) 388B Fox and Minimal path
查看>>
【nosql实现企业网站系列之一】mongodb的安装
查看>>