mirror of
https://github.com/eggplantlwj/VisionEdit.git
synced 2026-03-26 01:36:35 +08:00
版本初始化,建立主窗体页面
This commit is contained in:
6
HalconWindowTest/App.config
Normal file
6
HalconWindowTest/App.config
Normal file
@@ -0,0 +1,6 @@
|
||||
<?xml version="1.0" encoding="utf-8" ?>
|
||||
<configuration>
|
||||
<startup>
|
||||
<supportedRuntime version="v4.0" sku=".NETFramework,Version=v4.5.2" />
|
||||
</startup>
|
||||
</configuration>
|
||||
BIN
HalconWindowTest/HalconWindow/Config/Circle.cs
Normal file
BIN
HalconWindowTest/HalconWindow/Config/Circle.cs
Normal file
Binary file not shown.
BIN
HalconWindowTest/HalconWindow/Config/CircularArc.cs
Normal file
BIN
HalconWindowTest/HalconWindow/Config/CircularArc.cs
Normal file
Binary file not shown.
BIN
HalconWindowTest/HalconWindow/Config/HObjectWithColor.cs
Normal file
BIN
HalconWindowTest/HalconWindow/Config/HObjectWithColor.cs
Normal file
Binary file not shown.
BIN
HalconWindowTest/HalconWindow/Config/Line.cs
Normal file
BIN
HalconWindowTest/HalconWindow/Config/Line.cs
Normal file
Binary file not shown.
BIN
HalconWindowTest/HalconWindow/Config/Rectangle1.cs
Normal file
BIN
HalconWindowTest/HalconWindow/Config/Rectangle1.cs
Normal file
Binary file not shown.
BIN
HalconWindowTest/HalconWindow/Config/Rectangle2.cs
Normal file
BIN
HalconWindowTest/HalconWindow/Config/Rectangle2.cs
Normal file
Binary file not shown.
BIN
HalconWindowTest/HalconWindow/Config/SerializeHelper.cs
Normal file
BIN
HalconWindowTest/HalconWindow/Config/SerializeHelper.cs
Normal file
Binary file not shown.
73
HalconWindowTest/HalconWindow/HWindow_Final.Designer.cs
generated
Normal file
73
HalconWindowTest/HalconWindow/HWindow_Final.Designer.cs
generated
Normal file
@@ -0,0 +1,73 @@
|
||||
namespace HalconWindowTest.HalconWindow
|
||||
{
|
||||
partial class HWindow_Final
|
||||
{
|
||||
/// <summary>
|
||||
/// 必需的设计器变量。
|
||||
/// </summary>
|
||||
private System.ComponentModel.IContainer components = null;
|
||||
|
||||
/// <summary>
|
||||
/// 清理所有正在使用的资源。
|
||||
/// </summary>
|
||||
/// <param name="disposing">如果应释放托管资源,为 true;否则为 false。</param>
|
||||
protected override void Dispose(bool disposing)
|
||||
{
|
||||
if (disposing && (components != null))
|
||||
{
|
||||
components.Dispose();
|
||||
}
|
||||
base.Dispose(disposing);
|
||||
}
|
||||
|
||||
#region 组件设计器生成的代码
|
||||
|
||||
/// <summary>
|
||||
/// 设计器支持所需的方法 - 不要修改
|
||||
/// 使用代码编辑器修改此方法的内容。
|
||||
/// </summary>
|
||||
private void InitializeComponent()
|
||||
{
|
||||
this.m_CtrlHStatusLabelCtrl = new System.Windows.Forms.Label();
|
||||
this.mCtrl_HWindow = new HalconDotNet.HWindowControl();
|
||||
this.SuspendLayout();
|
||||
//
|
||||
// m_CtrlHStatusLabelCtrl
|
||||
//
|
||||
this.m_CtrlHStatusLabelCtrl.AutoSize = true;
|
||||
this.m_CtrlHStatusLabelCtrl.Location = new System.Drawing.Point(14, 533);
|
||||
this.m_CtrlHStatusLabelCtrl.Name = "m_CtrlHStatusLabelCtrl";
|
||||
this.m_CtrlHStatusLabelCtrl.Size = new System.Drawing.Size(41, 12);
|
||||
this.m_CtrlHStatusLabelCtrl.TabIndex = 1;
|
||||
this.m_CtrlHStatusLabelCtrl.Text = "label1";
|
||||
//
|
||||
// mCtrl_HWindow
|
||||
//
|
||||
this.mCtrl_HWindow.BackColor = System.Drawing.Color.Black;
|
||||
this.mCtrl_HWindow.BorderColor = System.Drawing.Color.Black;
|
||||
this.mCtrl_HWindow.Dock = System.Windows.Forms.DockStyle.Fill;
|
||||
this.mCtrl_HWindow.ImagePart = new System.Drawing.Rectangle(0, 0, 640, 480);
|
||||
this.mCtrl_HWindow.Location = new System.Drawing.Point(0, 0);
|
||||
this.mCtrl_HWindow.Name = "mCtrl_HWindow";
|
||||
this.mCtrl_HWindow.Size = new System.Drawing.Size(629, 558);
|
||||
this.mCtrl_HWindow.TabIndex = 2;
|
||||
this.mCtrl_HWindow.WindowSize = new System.Drawing.Size(629, 558);
|
||||
//
|
||||
// HWindow_Final
|
||||
//
|
||||
this.AutoScaleDimensions = new System.Drawing.SizeF(6F, 12F);
|
||||
this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font;
|
||||
this.Controls.Add(this.m_CtrlHStatusLabelCtrl);
|
||||
this.Controls.Add(this.mCtrl_HWindow);
|
||||
this.Name = "HWindow_Final";
|
||||
this.Size = new System.Drawing.Size(629, 558);
|
||||
this.ResumeLayout(false);
|
||||
this.PerformLayout();
|
||||
|
||||
}
|
||||
|
||||
#endregion
|
||||
private System.Windows.Forms.Label m_CtrlHStatusLabelCtrl;
|
||||
private HalconDotNet.HWindowControl mCtrl_HWindow;
|
||||
}
|
||||
}
|
||||
433
HalconWindowTest/HalconWindow/HWindow_Final.cs
Normal file
433
HalconWindowTest/HalconWindow/HWindow_Final.cs
Normal file
@@ -0,0 +1,433 @@
|
||||
using System;
|
||||
using System.Windows.Forms;
|
||||
using HalconDotNet;
|
||||
|
||||
namespace HalconWindowTest.HalconWindow
|
||||
{
|
||||
public partial class HWindow_Final : UserControl
|
||||
{
|
||||
#region 私有变量定义.
|
||||
|
||||
private HWindow /**/ hv_window; //halcon窗体控件的句柄 this.mCtrl_HWindow.HalconWindow;
|
||||
private ContextMenuStrip /**/ hv_MenuStrip; //右键菜单控件
|
||||
// 窗体控件右键菜单内容
|
||||
ToolStripMenuItem fit_strip;
|
||||
ToolStripMenuItem saveImg_strip;
|
||||
ToolStripMenuItem saveWindow_strip;
|
||||
ToolStripMenuItem barVisible_strip;
|
||||
ToolStripMenuItem histogram_strip;
|
||||
|
||||
private HImage /**/ hv_image; //缩放时操作的图片 此处千万不要使用hv_image = new HImage(),不然在生成控件dll的时候,会导致无法序列化,去你妈隔壁,还好老子有版本控制,不然都找不到这种恶心问题
|
||||
private int /**/ hv_imageWidth, hv_imageHeight; //图片宽,高
|
||||
private string /**/ str_imgSize; //图片尺寸大小 5120X3840
|
||||
private HTuple str_channel; //通道数
|
||||
private bool /**/ drawModel = false; //绘制模式下,不允许缩放和鼠标右键菜单
|
||||
|
||||
public ViewWindow.ViewWindow viewWindow; /**/ //ViewWindow
|
||||
public HWindowControl hWindowControl; /**/ // 当前halcon窗口
|
||||
|
||||
#endregion
|
||||
|
||||
|
||||
/// <summary>
|
||||
/// 初始化控件
|
||||
/// </summary>
|
||||
public HWindow_Final()
|
||||
{
|
||||
InitializeComponent();
|
||||
//
|
||||
viewWindow = new ViewWindow.ViewWindow(mCtrl_HWindow);
|
||||
hWindowControl = this.mCtrl_HWindow;
|
||||
hv_window = this.mCtrl_HWindow.HalconWindow;
|
||||
|
||||
// 设定鼠标按下时图标的形状
|
||||
// 'arrow' 'default' 'crosshair' 'text I-beam' 'Slashed circle' 'Size All'
|
||||
// 'Size NESW' 'Size S' 'Size NWSE' 'Size WE' 'Vertical Arrow' 'Hourglass'
|
||||
//
|
||||
// hv_window.SetMshape("Hourglass");
|
||||
|
||||
fit_strip = new ToolStripMenuItem("适应窗口");
|
||||
fit_strip.Click += new EventHandler((s, e) => DispImageFit(mCtrl_HWindow));
|
||||
|
||||
barVisible_strip = new ToolStripMenuItem("显示StatusBar");
|
||||
barVisible_strip.CheckOnClick = true;
|
||||
barVisible_strip.CheckedChanged += new EventHandler(barVisible_strip_CheckedChanged);
|
||||
m_CtrlHStatusLabelCtrl.Visible = false;
|
||||
mCtrl_HWindow.Height = this.Height;
|
||||
|
||||
saveImg_strip = new ToolStripMenuItem("保存原始图像");
|
||||
saveImg_strip.Click += new EventHandler((s, e) => SaveImage());
|
||||
|
||||
saveWindow_strip = new ToolStripMenuItem("保存窗口缩略图");
|
||||
saveWindow_strip.Click += new EventHandler((s, e) => SaveWindowDump());
|
||||
|
||||
histogram_strip = new ToolStripMenuItem("显示直方图(H)");
|
||||
histogram_strip.CheckOnClick = true;
|
||||
histogram_strip.Checked = false;
|
||||
|
||||
hv_MenuStrip = new ContextMenuStrip();
|
||||
hv_MenuStrip.Items.Add(fit_strip);
|
||||
hv_MenuStrip.Items.Add(barVisible_strip);
|
||||
hv_MenuStrip.Items.Add(new ToolStripSeparator());
|
||||
hv_MenuStrip.Items.Add(saveImg_strip);
|
||||
hv_MenuStrip.Items.Add(saveWindow_strip);
|
||||
|
||||
barVisible_strip.Enabled = true;
|
||||
fit_strip.Enabled = false;
|
||||
histogram_strip.Enabled = false;
|
||||
saveImg_strip.Enabled = false;
|
||||
saveWindow_strip.Enabled = false;
|
||||
|
||||
mCtrl_HWindow.ContextMenuStrip = hv_MenuStrip;
|
||||
mCtrl_HWindow.SizeChanged += new EventHandler((s, e) => DispImageFit(mCtrl_HWindow));
|
||||
|
||||
}
|
||||
|
||||
|
||||
/// <summary>
|
||||
/// 绘制模式下,不允许缩放和鼠标右键菜单
|
||||
/// </summary>
|
||||
public bool DrawModel
|
||||
{
|
||||
get { return drawModel; }
|
||||
set
|
||||
{
|
||||
//缩放控制
|
||||
viewWindow.setDrawModel(value);
|
||||
//绘制模式 不现实右键
|
||||
if (value == true)
|
||||
{
|
||||
|
||||
mCtrl_HWindow.ContextMenuStrip = null;
|
||||
}
|
||||
else
|
||||
{
|
||||
//恢复
|
||||
mCtrl_HWindow.ContextMenuStrip = hv_MenuStrip;
|
||||
}
|
||||
drawModel = value;
|
||||
}
|
||||
}
|
||||
private bool _EditModel = true;//绘制的图形是否可以编辑
|
||||
public bool EditModel
|
||||
{
|
||||
get
|
||||
{
|
||||
return _EditModel;
|
||||
}
|
||||
set
|
||||
{
|
||||
viewWindow.setEditModel(value);
|
||||
_EditModel = value;
|
||||
}
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// 设置image,初始化控件参数
|
||||
/// </summary>
|
||||
public HImage Image
|
||||
{
|
||||
get
|
||||
{
|
||||
return this.hv_image;
|
||||
}
|
||||
set
|
||||
{
|
||||
if (value != null)
|
||||
{
|
||||
if (this.hv_image != null)
|
||||
{
|
||||
this.hv_image.Dispose();
|
||||
}
|
||||
|
||||
this.hv_image = value;
|
||||
hv_image.GetImageSize(out hv_imageWidth, out hv_imageHeight);
|
||||
HOperatorSet.CountChannels(hv_image, out str_channel);
|
||||
str_imgSize = String.Format("{0}X{1}", hv_imageWidth, hv_imageHeight);
|
||||
// str_channel = string.Format("C{0}", str_channel);
|
||||
|
||||
//DispImageFit(mCtrl_HWindow);
|
||||
try
|
||||
{
|
||||
barVisible_strip.Enabled = true;
|
||||
fit_strip.Enabled = true;
|
||||
histogram_strip.Enabled = true;
|
||||
saveImg_strip.Enabled = true;
|
||||
saveWindow_strip.Enabled = true;
|
||||
}
|
||||
catch (Exception)
|
||||
{
|
||||
}
|
||||
|
||||
viewWindow.displayImage(hv_image);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// 获得halcon窗体控件的句柄
|
||||
/// </summary>
|
||||
public IntPtr HWindowHalconID
|
||||
{
|
||||
get { return this.mCtrl_HWindow.HalconID; }
|
||||
}
|
||||
|
||||
public HWindowControl getHWindowControl()
|
||||
{
|
||||
return this.mCtrl_HWindow;
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// 状态条 显示/隐藏 CheckedChanged事件
|
||||
/// </summary>
|
||||
/// <param name="sender"></param>
|
||||
/// <param name="e"></param>
|
||||
void barVisible_strip_CheckedChanged(object sender, EventArgs e)
|
||||
{
|
||||
ToolStripMenuItem strip = sender as ToolStripMenuItem;
|
||||
|
||||
this.SuspendLayout();
|
||||
|
||||
if (strip.Checked)
|
||||
{
|
||||
m_CtrlHStatusLabelCtrl.Visible = true;
|
||||
//mCtrl_HWindow.Height = this.Height - m_CtrlHStatusLabelCtrl.Height - m_CtrlHStatusLabelCtrl.Margin.Top - m_CtrlHStatusLabelCtrl.Margin.Bottom;
|
||||
mCtrl_HWindow.HMouseMove += HWindowControl_HMouseMove;
|
||||
}
|
||||
else
|
||||
{
|
||||
m_CtrlHStatusLabelCtrl.Visible = false;
|
||||
//mCtrl_HWindow.Height = this.Height;
|
||||
mCtrl_HWindow.HMouseMove -= HWindowControl_HMouseMove;
|
||||
}
|
||||
|
||||
//DispImageFit(mCtrl_HWindow);
|
||||
|
||||
this.ResumeLayout(false);
|
||||
this.PerformLayout();
|
||||
}
|
||||
|
||||
public void showStatusBar()
|
||||
{
|
||||
barVisible_strip.Checked = true;
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// 保存窗体截图到本地
|
||||
/// </summary>
|
||||
private void SaveWindowDump()
|
||||
{
|
||||
SaveFileDialog sfd = new SaveFileDialog();
|
||||
sfd.Filter = "PNG图像|*.png|所有文件|*.*";
|
||||
|
||||
if (sfd.ShowDialog() == DialogResult.OK)
|
||||
{
|
||||
if (String.IsNullOrEmpty(sfd.FileName))
|
||||
return;
|
||||
|
||||
//截取窗口图
|
||||
HOperatorSet.DumpWindow(HWindowHalconID, "png best", sfd.FileName);
|
||||
}
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// 保存原始图片到本地
|
||||
/// </summary>
|
||||
private void SaveImage()
|
||||
{
|
||||
SaveFileDialog sfd = new SaveFileDialog();
|
||||
sfd.Filter = "BMP图像|*.bmp|所有文件|*.*";
|
||||
|
||||
if (sfd.ShowDialog() == DialogResult.OK)
|
||||
{
|
||||
if (String.IsNullOrEmpty(sfd.FileName))
|
||||
{
|
||||
return;
|
||||
}
|
||||
|
||||
HOperatorSet.WriteImage(hv_image, "bmp", 0, sfd.FileName);
|
||||
}
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// 图片适应大小显示在窗体
|
||||
/// </summary>
|
||||
/// <param name="hw_Ctrl">halcon窗体控件</param>
|
||||
private void DispImageFit(HWindowControl hw_Ctrl)
|
||||
{
|
||||
|
||||
try
|
||||
{
|
||||
this.viewWindow.resetWindowImage();
|
||||
}
|
||||
catch (Exception)
|
||||
{
|
||||
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
/// <summary>
|
||||
/// 鼠标在空间窗体里滑动,显示鼠标所在位置的灰度值
|
||||
/// </summary>
|
||||
/// <param name="sender"></param>
|
||||
/// <param name="e"></param>
|
||||
private void HWindowControl_HMouseMove(object sender, HMouseEventArgs e)
|
||||
{
|
||||
|
||||
if (hv_image != null)
|
||||
{
|
||||
try
|
||||
{
|
||||
int button_state;
|
||||
double positionX, positionY;
|
||||
string str_value;
|
||||
string str_position;
|
||||
bool _isXOut = true, _isYOut = true;
|
||||
HTuple channel_count;
|
||||
|
||||
HOperatorSet.CountChannels(hv_image, out channel_count);
|
||||
|
||||
hv_window.GetMpositionSubPix(out positionY, out positionX, out button_state);
|
||||
str_position = String.Format("R: {0:0000.0}, C: {1:0000.0}", positionY, positionX);
|
||||
|
||||
_isXOut = (positionX < 0 || positionX >= hv_imageWidth);
|
||||
_isYOut = (positionY < 0 || positionY >= hv_imageHeight);
|
||||
|
||||
if (!_isXOut && !_isYOut)
|
||||
{
|
||||
if ((int)channel_count == 1)
|
||||
{
|
||||
int grayVal;
|
||||
grayVal = hv_image.GetGrayval((int)positionY, (int)positionX);
|
||||
str_value = String.Format("V: {0:000}", grayVal);
|
||||
}
|
||||
else if ((int)channel_count == 3)
|
||||
{
|
||||
double grayValRed, grayValGreen, grayValBlue;
|
||||
|
||||
HImage _RedChannel, _GreenChannel, _BlueChannel;
|
||||
|
||||
_RedChannel = hv_image.AccessChannel(1);
|
||||
_GreenChannel = hv_image.AccessChannel(2);
|
||||
_BlueChannel = hv_image.AccessChannel(3);
|
||||
|
||||
grayValRed = _RedChannel.GetGrayval((int)positionY, (int)positionX);
|
||||
grayValGreen = _GreenChannel.GetGrayval((int)positionY, (int)positionX);
|
||||
grayValBlue = _BlueChannel.GetGrayval((int)positionY, (int)positionX);
|
||||
|
||||
_RedChannel.Dispose();
|
||||
_GreenChannel.Dispose();
|
||||
_BlueChannel.Dispose();
|
||||
|
||||
str_value = String.Format("V: ({0:000.0}, {1:000.0}, {2:000.0})", grayValRed, grayValGreen, grayValBlue);
|
||||
}
|
||||
else
|
||||
{
|
||||
str_value = "";
|
||||
}
|
||||
m_CtrlHStatusLabelCtrl.Text = str_channel + " " + str_imgSize + " " + str_position + " " + str_value;
|
||||
}
|
||||
}
|
||||
catch (Exception ex)
|
||||
{
|
||||
//不处理
|
||||
}
|
||||
}
|
||||
|
||||
}
|
||||
public void ClearWindow()
|
||||
{
|
||||
try
|
||||
{
|
||||
this.Invoke(new Action(
|
||||
() =>
|
||||
{
|
||||
//this.hv_image = null;
|
||||
m_CtrlHStatusLabelCtrl.Visible = false;
|
||||
barVisible_strip.Enabled = false;
|
||||
fit_strip.Enabled = false;
|
||||
histogram_strip.Enabled = false;
|
||||
saveImg_strip.Enabled = false;
|
||||
saveWindow_strip.Enabled = false;
|
||||
|
||||
mCtrl_HWindow.HalconWindow.ClearWindow();
|
||||
viewWindow.ClearWindow();
|
||||
|
||||
}
|
||||
));
|
||||
}
|
||||
catch (Exception ex)
|
||||
{
|
||||
Console.WriteLine(ex.ToString());
|
||||
}
|
||||
|
||||
|
||||
}
|
||||
|
||||
|
||||
/// <summary>
|
||||
/// Hobject转换为的临时Himage,显示背景图
|
||||
/// </summary>
|
||||
/// <param name="hobject">传递Hobject,必须为图像</param>
|
||||
public void HobjectToHimage(HObject hobject)
|
||||
{
|
||||
if (hobject == null || !hobject.IsInitialized())
|
||||
{
|
||||
ClearWindow();
|
||||
return;
|
||||
}
|
||||
|
||||
this.Image = new HImage(hobject);
|
||||
|
||||
}
|
||||
|
||||
#region 缩放后,再次显示传入的HObject
|
||||
|
||||
|
||||
/// <summary>
|
||||
/// 默认红颜色显示
|
||||
/// </summary>
|
||||
/// <param name="hObj">传入的region.xld,image</param>
|
||||
public void DispObj(HObject hObj)
|
||||
{
|
||||
|
||||
lock (this)
|
||||
{
|
||||
viewWindow.displayHobject(hObj, null);
|
||||
}
|
||||
|
||||
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// 重新开辟内存保存 防止被传入的HObject在其他地方dispose后,不能重现
|
||||
/// </summary>
|
||||
/// <param name="hObj">传入的region.xld,image</param>
|
||||
/// <param name="color">颜色</param>
|
||||
public void DispObj(HObject hObj, string color)
|
||||
{
|
||||
|
||||
lock (this)
|
||||
{
|
||||
viewWindow.displayHobject(hObj, color);
|
||||
}
|
||||
|
||||
|
||||
}
|
||||
|
||||
|
||||
#endregion
|
||||
|
||||
/// <summary>
|
||||
/// 鼠标离开事件
|
||||
/// </summary>
|
||||
/// <param name="sender"></param>
|
||||
/// <param name="e"></param>
|
||||
private void mCtrl_HWindow_MouseLeave(object sender, EventArgs e)
|
||||
{
|
||||
//避免鼠标离开窗口,再返回的时候,图表随着鼠标移动
|
||||
viewWindow.mouseleave();
|
||||
}
|
||||
}
|
||||
}
|
||||
123
HalconWindowTest/HalconWindow/HWindow_Final.resx
Normal file
123
HalconWindowTest/HalconWindow/HWindow_Final.resx
Normal file
@@ -0,0 +1,123 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<root>
|
||||
<!--
|
||||
Microsoft ResX Schema
|
||||
|
||||
Version 2.0
|
||||
|
||||
The primary goals of this format is to allow a simple XML format
|
||||
that is mostly human readable. The generation and parsing of the
|
||||
various data types are done through the TypeConverter classes
|
||||
associated with the data types.
|
||||
|
||||
Example:
|
||||
|
||||
... ado.net/XML headers & schema ...
|
||||
<resheader name="resmimetype">text/microsoft-resx</resheader>
|
||||
<resheader name="version">2.0</resheader>
|
||||
<resheader name="reader">System.Resources.ResXResourceReader, System.Windows.Forms, ...</resheader>
|
||||
<resheader name="writer">System.Resources.ResXResourceWriter, System.Windows.Forms, ...</resheader>
|
||||
<data name="Name1"><value>this is my long string</value><comment>this is a comment</comment></data>
|
||||
<data name="Color1" type="System.Drawing.Color, System.Drawing">Blue</data>
|
||||
<data name="Bitmap1" mimetype="application/x-microsoft.net.object.binary.base64">
|
||||
<value>[base64 mime encoded serialized .NET Framework object]</value>
|
||||
</data>
|
||||
<data name="Icon1" type="System.Drawing.Icon, System.Drawing" mimetype="application/x-microsoft.net.object.bytearray.base64">
|
||||
<value>[base64 mime encoded string representing a byte array form of the .NET Framework object]</value>
|
||||
<comment>This is a comment</comment>
|
||||
</data>
|
||||
|
||||
There are any number of "resheader" rows that contain simple
|
||||
name/value pairs.
|
||||
|
||||
Each data row contains a name, and value. The row also contains a
|
||||
type or mimetype. Type corresponds to a .NET class that support
|
||||
text/value conversion through the TypeConverter architecture.
|
||||
Classes that don't support this are serialized and stored with the
|
||||
mimetype set.
|
||||
|
||||
The mimetype is used for serialized objects, and tells the
|
||||
ResXResourceReader how to depersist the object. This is currently not
|
||||
extensible. For a given mimetype the value must be set accordingly:
|
||||
|
||||
Note - application/x-microsoft.net.object.binary.base64 is the format
|
||||
that the ResXResourceWriter will generate, however the reader can
|
||||
read any of the formats listed below.
|
||||
|
||||
mimetype: application/x-microsoft.net.object.binary.base64
|
||||
value : The object must be serialized with
|
||||
: System.Runtime.Serialization.Formatters.Binary.BinaryFormatter
|
||||
: and then encoded with base64 encoding.
|
||||
|
||||
mimetype: application/x-microsoft.net.object.soap.base64
|
||||
value : The object must be serialized with
|
||||
: System.Runtime.Serialization.Formatters.Soap.SoapFormatter
|
||||
: and then encoded with base64 encoding.
|
||||
|
||||
mimetype: application/x-microsoft.net.object.bytearray.base64
|
||||
value : The object must be serialized into a byte array
|
||||
: using a System.ComponentModel.TypeConverter
|
||||
: and then encoded with base64 encoding.
|
||||
-->
|
||||
<xsd:schema id="root" xmlns="" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:msdata="urn:schemas-microsoft-com:xml-msdata">
|
||||
<xsd:import namespace="http://www.w3.org/XML/1998/namespace" />
|
||||
<xsd:element name="root" msdata:IsDataSet="true">
|
||||
<xsd:complexType>
|
||||
<xsd:choice maxOccurs="unbounded">
|
||||
<xsd:element name="metadata">
|
||||
<xsd:complexType>
|
||||
<xsd:sequence>
|
||||
<xsd:element name="value" type="xsd:string" minOccurs="0" />
|
||||
</xsd:sequence>
|
||||
<xsd:attribute name="name" use="required" type="xsd:string" />
|
||||
<xsd:attribute name="type" type="xsd:string" />
|
||||
<xsd:attribute name="mimetype" type="xsd:string" />
|
||||
<xsd:attribute ref="xml:space" />
|
||||
</xsd:complexType>
|
||||
</xsd:element>
|
||||
<xsd:element name="assembly">
|
||||
<xsd:complexType>
|
||||
<xsd:attribute name="alias" type="xsd:string" />
|
||||
<xsd:attribute name="name" type="xsd:string" />
|
||||
</xsd:complexType>
|
||||
</xsd:element>
|
||||
<xsd:element name="data">
|
||||
<xsd:complexType>
|
||||
<xsd:sequence>
|
||||
<xsd:element name="value" type="xsd:string" minOccurs="0" msdata:Ordinal="1" />
|
||||
<xsd:element name="comment" type="xsd:string" minOccurs="0" msdata:Ordinal="2" />
|
||||
</xsd:sequence>
|
||||
<xsd:attribute name="name" type="xsd:string" use="required" msdata:Ordinal="1" />
|
||||
<xsd:attribute name="type" type="xsd:string" msdata:Ordinal="3" />
|
||||
<xsd:attribute name="mimetype" type="xsd:string" msdata:Ordinal="4" />
|
||||
<xsd:attribute ref="xml:space" />
|
||||
</xsd:complexType>
|
||||
</xsd:element>
|
||||
<xsd:element name="resheader">
|
||||
<xsd:complexType>
|
||||
<xsd:sequence>
|
||||
<xsd:element name="value" type="xsd:string" minOccurs="0" msdata:Ordinal="1" />
|
||||
</xsd:sequence>
|
||||
<xsd:attribute name="name" type="xsd:string" use="required" />
|
||||
</xsd:complexType>
|
||||
</xsd:element>
|
||||
</xsd:choice>
|
||||
</xsd:complexType>
|
||||
</xsd:element>
|
||||
</xsd:schema>
|
||||
<resheader name="resmimetype">
|
||||
<value>text/microsoft-resx</value>
|
||||
</resheader>
|
||||
<resheader name="version">
|
||||
<value>2.0</value>
|
||||
</resheader>
|
||||
<resheader name="reader">
|
||||
<value>System.Resources.ResXResourceReader, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
|
||||
</resheader>
|
||||
<resheader name="writer">
|
||||
<value>System.Resources.ResXResourceWriter, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
|
||||
</resheader>
|
||||
<metadata name="mCtrl_HWindow.LayoutBitmap" type="System.Resources.ResXNullRef, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
|
||||
<value />
|
||||
</metadata>
|
||||
</root>
|
||||
BIN
HalconWindowTest/HalconWindow/Model/GraphicsContext.cs
Normal file
BIN
HalconWindowTest/HalconWindow/Model/GraphicsContext.cs
Normal file
Binary file not shown.
BIN
HalconWindowTest/HalconWindow/Model/HObjectEntry.cs
Normal file
BIN
HalconWindowTest/HalconWindow/Model/HObjectEntry.cs
Normal file
Binary file not shown.
BIN
HalconWindowTest/HalconWindow/Model/HWndCtrl.cs
Normal file
BIN
HalconWindowTest/HalconWindow/Model/HWndCtrl.cs
Normal file
Binary file not shown.
BIN
HalconWindowTest/HalconWindow/Model/IViewWindow.cs
Normal file
BIN
HalconWindowTest/HalconWindow/Model/IViewWindow.cs
Normal file
Binary file not shown.
BIN
HalconWindowTest/HalconWindow/Model/ROI.cs
Normal file
BIN
HalconWindowTest/HalconWindow/Model/ROI.cs
Normal file
Binary file not shown.
BIN
HalconWindowTest/HalconWindow/Model/ROICircle.cs
Normal file
BIN
HalconWindowTest/HalconWindow/Model/ROICircle.cs
Normal file
Binary file not shown.
BIN
HalconWindowTest/HalconWindow/Model/ROICircularArc.cs
Normal file
BIN
HalconWindowTest/HalconWindow/Model/ROICircularArc.cs
Normal file
Binary file not shown.
BIN
HalconWindowTest/HalconWindow/Model/ROIController.cs
Normal file
BIN
HalconWindowTest/HalconWindow/Model/ROIController.cs
Normal file
Binary file not shown.
BIN
HalconWindowTest/HalconWindow/Model/ROILine.cs
Normal file
BIN
HalconWindowTest/HalconWindow/Model/ROILine.cs
Normal file
Binary file not shown.
BIN
HalconWindowTest/HalconWindow/Model/ROIRectangle1.cs
Normal file
BIN
HalconWindowTest/HalconWindow/Model/ROIRectangle1.cs
Normal file
Binary file not shown.
BIN
HalconWindowTest/HalconWindow/Model/ROIRectangle2.cs
Normal file
BIN
HalconWindowTest/HalconWindow/Model/ROIRectangle2.cs
Normal file
Binary file not shown.
BIN
HalconWindowTest/HalconWindow/Model/RoiData.cs
Normal file
BIN
HalconWindowTest/HalconWindow/Model/RoiData.cs
Normal file
Binary file not shown.
310
HalconWindowTest/HalconWindow/ViewWindow.cs
Normal file
310
HalconWindowTest/HalconWindow/ViewWindow.cs
Normal file
@@ -0,0 +1,310 @@
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Linq;
|
||||
using System.Text;
|
||||
using HalconDotNet;
|
||||
|
||||
namespace ViewWindow
|
||||
{
|
||||
public class ViewWindow : Model.IViewWindow
|
||||
{
|
||||
public Model.HWndCtrl _hWndControl;
|
||||
|
||||
private Model.ROIController _roiController;
|
||||
|
||||
|
||||
public ViewWindow(HWindowControl window)
|
||||
{
|
||||
this._hWndControl = new Model.HWndCtrl(window);
|
||||
this._roiController = new Model.ROIController();
|
||||
this._hWndControl.setROIController(this._roiController);
|
||||
this._hWndControl.setViewState(Model.HWndCtrl.MODE_VIEW_NONE);
|
||||
}
|
||||
|
||||
//清空所有显示内容
|
||||
public void ClearWindow()
|
||||
{
|
||||
//清空显示image
|
||||
_hWndControl.clearList();
|
||||
//清空hobjectList
|
||||
_hWndControl.clearHObjectList();
|
||||
}
|
||||
public void displayImage(HObject img)
|
||||
{
|
||||
//添加背景图片
|
||||
this._hWndControl.addImageShow(img);
|
||||
//清空roi容器,不让roi显示
|
||||
this._roiController.reset();
|
||||
//显示图片
|
||||
this._roiController.resetWindowImage();
|
||||
|
||||
|
||||
//this._hWndControl.resetWindow();
|
||||
// this._hWndControl.resetAll();
|
||||
//this._hWndControl.repaint();
|
||||
}
|
||||
public void notDisplayRoi()
|
||||
{
|
||||
|
||||
this._roiController.reset();
|
||||
//显示图片
|
||||
this._roiController.resetWindowImage();
|
||||
|
||||
}
|
||||
//获取当前窗口显示的roi数量
|
||||
public int getRoiCount()
|
||||
{
|
||||
return _roiController.ROIList.Count;
|
||||
}
|
||||
//是否开启缩放事件
|
||||
public void setDrawModel(bool flag)
|
||||
{
|
||||
_hWndControl.drawModel = flag;
|
||||
}
|
||||
//是否开启编辑事件
|
||||
public void setEditModel(bool flag)
|
||||
{
|
||||
_roiController.EditModel = flag;
|
||||
// _hWndControl.drawModel = flag;
|
||||
}
|
||||
public void resetWindowImage()
|
||||
{
|
||||
this._hWndControl.resetWindow();
|
||||
this._roiController.resetWindowImage();
|
||||
}
|
||||
|
||||
public void mouseleave()
|
||||
{
|
||||
_hWndControl.raiseMouseup();
|
||||
}
|
||||
|
||||
public void zoomWindowImage()
|
||||
{
|
||||
this._roiController.zoomWindowImage();
|
||||
}
|
||||
|
||||
public void moveWindowImage()
|
||||
{
|
||||
this._roiController.moveWindowImage();
|
||||
}
|
||||
|
||||
public void noneWindowImage()
|
||||
{
|
||||
this._roiController.noneWindowImage();
|
||||
}
|
||||
|
||||
public void genRect1(double row1, double col1, double row2, double col2, ref List<Model.ROI> rois)
|
||||
{
|
||||
this._roiController.genRect1(row1, col1, row2, col2, ref rois);
|
||||
}
|
||||
|
||||
public void genRect2(double row, double col, double phi, double length1, double length2, ref List<Model.ROI> rois)
|
||||
{
|
||||
this._roiController.genRect2(row, col, phi, length1, length2, ref rois);
|
||||
}
|
||||
|
||||
public void genCircle(double row, double col, double radius, ref List<Model.ROI> rois)
|
||||
{
|
||||
this._roiController.genCircle(row, col, radius, ref rois);
|
||||
}
|
||||
public void genCircularArc(double row, double col, double radius, double startPhi, double extentPhi, string direct,ref List<Model.ROI> rois)
|
||||
{
|
||||
this._roiController.genCircularArc(row, col, radius, startPhi, extentPhi,direct,ref rois);
|
||||
}
|
||||
public void genLine(double beginRow, double beginCol, double endRow, double endCol, ref List<Model.ROI> rois)
|
||||
{
|
||||
this._roiController.genLine(beginRow, beginCol, endRow, endCol, ref rois);
|
||||
}
|
||||
|
||||
public List<double> smallestActiveROI(out string name, out int index)
|
||||
{
|
||||
List<double> resual = this._roiController.smallestActiveROI(out name,out index);
|
||||
return resual;
|
||||
}
|
||||
|
||||
public Model.ROI smallestActiveROI(out List<double> data, out int index)
|
||||
{
|
||||
Model.ROI roi = this._roiController.smallestActiveROI(out data, out index);
|
||||
return roi;
|
||||
}
|
||||
|
||||
public void selectROI(int index)
|
||||
{
|
||||
this._roiController.selectROI(index);
|
||||
}
|
||||
|
||||
public void selectROI( List<Model.ROI> rois, int index)
|
||||
{
|
||||
//this._roiController.selectROI(index);
|
||||
if ((rois.Count > index)&&(index>=0))
|
||||
{
|
||||
this._hWndControl.resetAll();
|
||||
this._hWndControl.repaint();
|
||||
|
||||
HTuple m_roiData = null;
|
||||
m_roiData = rois[index].getModelData();
|
||||
|
||||
switch (rois[index].Type)
|
||||
{
|
||||
case "ROIRectangle1":
|
||||
|
||||
if (m_roiData != null)
|
||||
{
|
||||
this._roiController.displayRect1(rois[index].Color, m_roiData[0].D, m_roiData[1].D, m_roiData[2].D, m_roiData[3].D);
|
||||
}
|
||||
break;
|
||||
case "ROIRectangle2":
|
||||
|
||||
if (m_roiData != null)
|
||||
{
|
||||
this._roiController.displayRect2(rois[index].Color, m_roiData[0].D, m_roiData[1].D, m_roiData[2].D, m_roiData[3].D, m_roiData[4].D);
|
||||
}
|
||||
break;
|
||||
case "ROICircle":
|
||||
|
||||
if (m_roiData != null)
|
||||
{
|
||||
this._roiController.displayCircle(rois[index].Color, m_roiData[0].D, m_roiData[1].D, m_roiData[2].D);
|
||||
}
|
||||
break;
|
||||
case "ROICircularArc":
|
||||
|
||||
if (m_roiData != null)
|
||||
{
|
||||
this._roiController.displayCircularArc(rois[index].Color, m_roiData[0].D, m_roiData[1].D, m_roiData[2].D, m_roiData[3].D, m_roiData[4].D);
|
||||
}
|
||||
break;
|
||||
case "ROILine":
|
||||
|
||||
if (m_roiData != null)
|
||||
{
|
||||
this._roiController.displayLine(rois[index].Color, m_roiData[0].D, m_roiData[1].D, m_roiData[2].D, m_roiData[3].D);
|
||||
}
|
||||
break;
|
||||
default:
|
||||
break;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
public void displayROI(List<Model.ROI> rois)
|
||||
{
|
||||
if (rois == null)
|
||||
{
|
||||
return;
|
||||
}
|
||||
//this._hWndControl.resetAll();
|
||||
//this._hWndControl.repaint();
|
||||
|
||||
foreach (var roi in rois)
|
||||
{
|
||||
HTuple m_roiData = null;
|
||||
m_roiData = roi.getModelData();
|
||||
|
||||
switch (roi.Type)
|
||||
{
|
||||
case "ROIRectangle1":
|
||||
|
||||
if (m_roiData != null)
|
||||
{
|
||||
this._roiController.displayRect1(roi.Color, m_roiData[0].D, m_roiData[1].D, m_roiData[2].D, m_roiData[3].D);
|
||||
}
|
||||
break;
|
||||
case "ROIRectangle2":
|
||||
|
||||
if (m_roiData != null)
|
||||
{
|
||||
this._roiController.displayRect2(roi.Color, m_roiData[0].D, m_roiData[1].D, m_roiData[2].D, m_roiData[3].D, m_roiData[4].D);
|
||||
|
||||
}
|
||||
break;
|
||||
case "ROICircle":
|
||||
|
||||
if (m_roiData != null)
|
||||
{
|
||||
this._roiController.displayCircle(roi.Color, m_roiData[0].D, m_roiData[1].D, m_roiData[2].D);
|
||||
}
|
||||
break;
|
||||
case "ROILine":
|
||||
|
||||
if (m_roiData != null)
|
||||
{
|
||||
this._roiController.displayLine(roi.Color, m_roiData[0].D, m_roiData[1].D, m_roiData[2].D, m_roiData[3].D);
|
||||
}
|
||||
break;
|
||||
default:
|
||||
break;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
public void removeActiveROI(ref List<Model.ROI> rois)
|
||||
{
|
||||
this._roiController.removeActiveROI(ref rois);
|
||||
}
|
||||
|
||||
public void setActiveRoi(int index)
|
||||
{
|
||||
this._roiController.activeROIidx = index;
|
||||
}
|
||||
public void saveROI(List<Model.ROI> rois, string fileNmae)
|
||||
{
|
||||
List<Model.RoiData> m_RoiData = new List<Model.RoiData>();
|
||||
for (int i = 0; i < rois.Count; i++)
|
||||
{
|
||||
m_RoiData.Add(new Model.RoiData(i, rois[i]));
|
||||
}
|
||||
|
||||
Config.SerializeHelper.Save(m_RoiData, fileNmae);
|
||||
}
|
||||
|
||||
public void loadROI(string fileName, out List<Model.ROI> rois)
|
||||
{
|
||||
rois = new List<Model.ROI>();
|
||||
List<Model.RoiData> m_RoiData = new List<Model.RoiData>();
|
||||
m_RoiData = (List<Model.RoiData>)Config.SerializeHelper.Load(m_RoiData.GetType(), fileName);
|
||||
for (int i = 0; i < m_RoiData.Count; i++)
|
||||
{
|
||||
switch (m_RoiData[i].Name)
|
||||
{
|
||||
case "Rectangle1":
|
||||
this._roiController.genRect1(m_RoiData[i].Rectangle1.Row1, m_RoiData[i].Rectangle1.Column1,
|
||||
m_RoiData[i].Rectangle1.Row2, m_RoiData[i].Rectangle1.Column2, ref rois);
|
||||
rois.Last().Color = m_RoiData[i].Rectangle1.Color;
|
||||
break;
|
||||
case "Rectangle2":
|
||||
this._roiController.genRect2(m_RoiData[i].Rectangle2.Row, m_RoiData[i].Rectangle2.Column,
|
||||
m_RoiData[i].Rectangle2.Phi, m_RoiData[i].Rectangle2.Lenth1, m_RoiData[i].Rectangle2.Lenth2, ref rois);
|
||||
rois.Last().Color = m_RoiData[i].Rectangle2.Color;
|
||||
break;
|
||||
case "Circle":
|
||||
this._roiController.genCircle(m_RoiData[i].Circle.Row, m_RoiData[i].Circle.Column, m_RoiData[i].Circle.Radius, ref rois);
|
||||
rois.Last().Color = m_RoiData[i].Circle.Color;
|
||||
break;
|
||||
case "Line":
|
||||
this._roiController.genLine(m_RoiData[i].Line.RowBegin, m_RoiData[i].Line.ColumnBegin,
|
||||
m_RoiData[i].Line.RowEnd, m_RoiData[i].Line.ColumnEnd, ref rois);
|
||||
rois.Last().Color = m_RoiData[i].Line.Color;
|
||||
break;
|
||||
default:
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
||||
this._hWndControl.resetAll();
|
||||
this._hWndControl.repaint();
|
||||
}
|
||||
|
||||
#region 专门用于 显示region 和xld的方法
|
||||
public void displayHobject(HObject obj,string color)
|
||||
{
|
||||
_hWndControl.DispObj(obj, color);
|
||||
|
||||
}
|
||||
public void displayHobject(HObject obj)
|
||||
{
|
||||
_hWndControl.DispObj(obj, null);
|
||||
}
|
||||
#endregion
|
||||
}
|
||||
}
|
||||
147
HalconWindowTest/HalconWindowTest.csproj
Normal file
147
HalconWindowTest/HalconWindowTest.csproj
Normal file
@@ -0,0 +1,147 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<Project ToolsVersion="14.0" DefaultTargets="Build" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
|
||||
<Import Project="$(MSBuildExtensionsPath)\$(MSBuildToolsVersion)\Microsoft.Common.props" Condition="Exists('$(MSBuildExtensionsPath)\$(MSBuildToolsVersion)\Microsoft.Common.props')" />
|
||||
<PropertyGroup>
|
||||
<Configuration Condition=" '$(Configuration)' == '' ">Debug</Configuration>
|
||||
<Platform Condition=" '$(Platform)' == '' ">AnyCPU</Platform>
|
||||
<ProjectGuid>{4ADC75AE-59C7-4D36-B675-A6CE51B6F5BA}</ProjectGuid>
|
||||
<OutputType>WinExe</OutputType>
|
||||
<AppDesignerFolder>Properties</AppDesignerFolder>
|
||||
<RootNamespace>HalconWindowTest</RootNamespace>
|
||||
<AssemblyName>HalconWindowTest</AssemblyName>
|
||||
<TargetFrameworkVersion>v4.5.2</TargetFrameworkVersion>
|
||||
<FileAlignment>512</FileAlignment>
|
||||
<AutoGenerateBindingRedirects>true</AutoGenerateBindingRedirects>
|
||||
</PropertyGroup>
|
||||
<PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Debug|AnyCPU' ">
|
||||
<PlatformTarget>x64</PlatformTarget>
|
||||
<DebugSymbols>true</DebugSymbols>
|
||||
<DebugType>full</DebugType>
|
||||
<Optimize>false</Optimize>
|
||||
<OutputPath>bin\Debug\</OutputPath>
|
||||
<DefineConstants>DEBUG;TRACE</DefineConstants>
|
||||
<ErrorReport>prompt</ErrorReport>
|
||||
<WarningLevel>4</WarningLevel>
|
||||
</PropertyGroup>
|
||||
<PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Release|AnyCPU' ">
|
||||
<PlatformTarget>AnyCPU</PlatformTarget>
|
||||
<DebugType>pdbonly</DebugType>
|
||||
<Optimize>true</Optimize>
|
||||
<OutputPath>bin\Release\</OutputPath>
|
||||
<DefineConstants>TRACE</DefineConstants>
|
||||
<ErrorReport>prompt</ErrorReport>
|
||||
<WarningLevel>4</WarningLevel>
|
||||
</PropertyGroup>
|
||||
<PropertyGroup Condition="'$(Configuration)|$(Platform)' == 'Debug|x64'">
|
||||
<DebugSymbols>true</DebugSymbols>
|
||||
<OutputPath>bin\x64\Debug\</OutputPath>
|
||||
<DefineConstants>DEBUG;TRACE</DefineConstants>
|
||||
<DebugType>full</DebugType>
|
||||
<PlatformTarget>AnyCPU</PlatformTarget>
|
||||
<ErrorReport>prompt</ErrorReport>
|
||||
<CodeAnalysisRuleSet>MinimumRecommendedRules.ruleset</CodeAnalysisRuleSet>
|
||||
<Prefer32Bit>true</Prefer32Bit>
|
||||
</PropertyGroup>
|
||||
<PropertyGroup Condition="'$(Configuration)|$(Platform)' == 'Release|x64'">
|
||||
<OutputPath>bin\x64\Release\</OutputPath>
|
||||
<DefineConstants>TRACE</DefineConstants>
|
||||
<Optimize>true</Optimize>
|
||||
<DebugType>pdbonly</DebugType>
|
||||
<PlatformTarget>x64</PlatformTarget>
|
||||
<ErrorReport>prompt</ErrorReport>
|
||||
<CodeAnalysisRuleSet>MinimumRecommendedRules.ruleset</CodeAnalysisRuleSet>
|
||||
<Prefer32Bit>true</Prefer32Bit>
|
||||
</PropertyGroup>
|
||||
<ItemGroup>
|
||||
<Reference Include="halcondotnet, Version=19.5.0.0, Culture=neutral, PublicKeyToken=4973bed59ddbf2b8, processorArchitecture=MSIL">
|
||||
<SpecificVersion>False</SpecificVersion>
|
||||
<HintPath>C:\Program Files\MVTec\HALCON-19.05-Progress\bin\dotnet20\halcondotnet.dll</HintPath>
|
||||
</Reference>
|
||||
<Reference Include="PresentationCore" />
|
||||
<Reference Include="PresentationFramework" />
|
||||
<Reference Include="System" />
|
||||
<Reference Include="System.Core" />
|
||||
<Reference Include="System.Design" />
|
||||
<Reference Include="System.Runtime.Serialization.Formatters.Soap" />
|
||||
<Reference Include="System.Xml.Linq" />
|
||||
<Reference Include="System.Data.DataSetExtensions" />
|
||||
<Reference Include="System.Data" />
|
||||
<Reference Include="System.Deployment" />
|
||||
<Reference Include="System.Drawing" />
|
||||
<Reference Include="System.Net.Http" />
|
||||
<Reference Include="System.Windows.Forms" />
|
||||
<Reference Include="System.Xml" />
|
||||
<Reference Include="WindowsBase" />
|
||||
</ItemGroup>
|
||||
<ItemGroup>
|
||||
<Compile Include="HalconWindow\Config\Circle.cs" />
|
||||
<Compile Include="HalconWindow\Config\CircularArc.cs" />
|
||||
<Compile Include="HalconWindow\Config\HObjectWithColor.cs" />
|
||||
<Compile Include="HalconWindow\Config\Line.cs" />
|
||||
<Compile Include="HalconWindow\Config\Rectangle1.cs" />
|
||||
<Compile Include="HalconWindow\Config\Rectangle2.cs" />
|
||||
<Compile Include="HalconWindow\Config\SerializeHelper.cs" />
|
||||
<Compile Include="HalconWindow\Model\GraphicsContext.cs" />
|
||||
<Compile Include="HalconWindow\Model\HObjectEntry.cs" />
|
||||
<Compile Include="HalconWindow\Model\HWndCtrl.cs" />
|
||||
<Compile Include="HalconWindow\Model\IViewWindow.cs" />
|
||||
<Compile Include="HalconWindow\Model\ROI.cs" />
|
||||
<Compile Include="HalconWindow\Model\ROICircle.cs" />
|
||||
<Compile Include="HalconWindow\Model\ROICircularArc.cs" />
|
||||
<Compile Include="HalconWindow\Model\ROIController.cs" />
|
||||
<Compile Include="HalconWindow\Model\RoiData.cs" />
|
||||
<Compile Include="HalconWindow\Model\ROILine.cs" />
|
||||
<Compile Include="HalconWindow\Model\ROIRectangle1.cs" />
|
||||
<Compile Include="HalconWindow\Model\ROIRectangle2.cs" />
|
||||
<Compile Include="HalconWindow\HWindow_Final.cs">
|
||||
<SubType>UserControl</SubType>
|
||||
</Compile>
|
||||
<Compile Include="HalconWindow\HWindow_Final.Designer.cs">
|
||||
<DependentUpon>HWindow_Final.cs</DependentUpon>
|
||||
</Compile>
|
||||
<Compile Include="HalconWindow\ViewWindow.cs" />
|
||||
<Compile Include="MainForm.cs">
|
||||
<SubType>Form</SubType>
|
||||
</Compile>
|
||||
<Compile Include="MainForm.Designer.cs">
|
||||
<DependentUpon>MainForm.cs</DependentUpon>
|
||||
</Compile>
|
||||
<Compile Include="Program.cs" />
|
||||
<Compile Include="Properties\AssemblyInfo.cs" />
|
||||
<EmbeddedResource Include="HalconWindow\HWindow_Final.resx">
|
||||
<DependentUpon>HWindow_Final.cs</DependentUpon>
|
||||
</EmbeddedResource>
|
||||
<EmbeddedResource Include="MainForm.resx">
|
||||
<DependentUpon>MainForm.cs</DependentUpon>
|
||||
</EmbeddedResource>
|
||||
<EmbeddedResource Include="Properties\Resources.resx">
|
||||
<Generator>ResXFileCodeGenerator</Generator>
|
||||
<LastGenOutput>Resources.Designer.cs</LastGenOutput>
|
||||
<SubType>Designer</SubType>
|
||||
</EmbeddedResource>
|
||||
<Compile Include="Properties\Resources.Designer.cs">
|
||||
<AutoGen>True</AutoGen>
|
||||
<DependentUpon>Resources.resx</DependentUpon>
|
||||
</Compile>
|
||||
<None Include="Properties\Settings.settings">
|
||||
<Generator>SettingsSingleFileGenerator</Generator>
|
||||
<LastGenOutput>Settings.Designer.cs</LastGenOutput>
|
||||
</None>
|
||||
<Compile Include="Properties\Settings.Designer.cs">
|
||||
<AutoGen>True</AutoGen>
|
||||
<DependentUpon>Settings.settings</DependentUpon>
|
||||
<DesignTimeSharedInput>True</DesignTimeSharedInput>
|
||||
</Compile>
|
||||
</ItemGroup>
|
||||
<ItemGroup>
|
||||
<None Include="App.config" />
|
||||
</ItemGroup>
|
||||
<Import Project="$(MSBuildToolsPath)\Microsoft.CSharp.targets" />
|
||||
<!-- To modify your build process, add your task inside one of the targets below and uncomment it.
|
||||
Other similar extension points exist, see Microsoft.Common.targets.
|
||||
<Target Name="BeforeBuild">
|
||||
</Target>
|
||||
<Target Name="AfterBuild">
|
||||
</Target>
|
||||
-->
|
||||
</Project>
|
||||
58
HalconWindowTest/MainForm.Designer.cs
generated
Normal file
58
HalconWindowTest/MainForm.Designer.cs
generated
Normal file
@@ -0,0 +1,58 @@
|
||||
namespace HalconWindowTest
|
||||
{
|
||||
partial class MainForm
|
||||
{
|
||||
/// <summary>
|
||||
/// Required designer variable.
|
||||
/// </summary>
|
||||
private System.ComponentModel.IContainer components = null;
|
||||
|
||||
/// <summary>
|
||||
/// Clean up any resources being used.
|
||||
/// </summary>
|
||||
/// <param name="disposing">true if managed resources should be disposed; otherwise, false.</param>
|
||||
protected override void Dispose(bool disposing)
|
||||
{
|
||||
if (disposing && (components != null))
|
||||
{
|
||||
components.Dispose();
|
||||
}
|
||||
base.Dispose(disposing);
|
||||
}
|
||||
|
||||
#region Windows Form Designer generated code
|
||||
|
||||
/// <summary>
|
||||
/// Required method for Designer support - do not modify
|
||||
/// the contents of this method with the code editor.
|
||||
/// </summary>
|
||||
private void InitializeComponent()
|
||||
{
|
||||
this.panel1 = new System.Windows.Forms.Panel();
|
||||
this.SuspendLayout();
|
||||
//
|
||||
// panel1
|
||||
//
|
||||
this.panel1.Location = new System.Drawing.Point(27, 53);
|
||||
this.panel1.Name = "panel1";
|
||||
this.panel1.Size = new System.Drawing.Size(366, 483);
|
||||
this.panel1.TabIndex = 0;
|
||||
//
|
||||
// MainForm
|
||||
//
|
||||
this.AutoScaleDimensions = new System.Drawing.SizeF(6F, 12F);
|
||||
this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font;
|
||||
this.ClientSize = new System.Drawing.Size(807, 600);
|
||||
this.Controls.Add(this.panel1);
|
||||
this.Name = "MainForm";
|
||||
this.Text = "MainForm";
|
||||
this.Load += new System.EventHandler(this.MainForm_Load);
|
||||
this.ResumeLayout(false);
|
||||
|
||||
}
|
||||
|
||||
#endregion
|
||||
|
||||
private System.Windows.Forms.Panel panel1;
|
||||
}
|
||||
}
|
||||
26
HalconWindowTest/MainForm.cs
Normal file
26
HalconWindowTest/MainForm.cs
Normal file
@@ -0,0 +1,26 @@
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.ComponentModel;
|
||||
using System.Data;
|
||||
using System.Drawing;
|
||||
using System.Linq;
|
||||
using System.Text;
|
||||
using System.Threading.Tasks;
|
||||
using System.Windows.Forms;
|
||||
using HalconWindowTest.HalconWindow;
|
||||
|
||||
namespace HalconWindowTest
|
||||
{
|
||||
public partial class MainForm : Form
|
||||
{
|
||||
public MainForm()
|
||||
{
|
||||
InitializeComponent();
|
||||
}
|
||||
|
||||
private void MainForm_Load(object sender, EventArgs e)
|
||||
{
|
||||
this.panel1.Controls.Add(new HWindow_Final());
|
||||
}
|
||||
}
|
||||
}
|
||||
120
HalconWindowTest/MainForm.resx
Normal file
120
HalconWindowTest/MainForm.resx
Normal file
@@ -0,0 +1,120 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<root>
|
||||
<!--
|
||||
Microsoft ResX Schema
|
||||
|
||||
Version 2.0
|
||||
|
||||
The primary goals of this format is to allow a simple XML format
|
||||
that is mostly human readable. The generation and parsing of the
|
||||
various data types are done through the TypeConverter classes
|
||||
associated with the data types.
|
||||
|
||||
Example:
|
||||
|
||||
... ado.net/XML headers & schema ...
|
||||
<resheader name="resmimetype">text/microsoft-resx</resheader>
|
||||
<resheader name="version">2.0</resheader>
|
||||
<resheader name="reader">System.Resources.ResXResourceReader, System.Windows.Forms, ...</resheader>
|
||||
<resheader name="writer">System.Resources.ResXResourceWriter, System.Windows.Forms, ...</resheader>
|
||||
<data name="Name1"><value>this is my long string</value><comment>this is a comment</comment></data>
|
||||
<data name="Color1" type="System.Drawing.Color, System.Drawing">Blue</data>
|
||||
<data name="Bitmap1" mimetype="application/x-microsoft.net.object.binary.base64">
|
||||
<value>[base64 mime encoded serialized .NET Framework object]</value>
|
||||
</data>
|
||||
<data name="Icon1" type="System.Drawing.Icon, System.Drawing" mimetype="application/x-microsoft.net.object.bytearray.base64">
|
||||
<value>[base64 mime encoded string representing a byte array form of the .NET Framework object]</value>
|
||||
<comment>This is a comment</comment>
|
||||
</data>
|
||||
|
||||
There are any number of "resheader" rows that contain simple
|
||||
name/value pairs.
|
||||
|
||||
Each data row contains a name, and value. The row also contains a
|
||||
type or mimetype. Type corresponds to a .NET class that support
|
||||
text/value conversion through the TypeConverter architecture.
|
||||
Classes that don't support this are serialized and stored with the
|
||||
mimetype set.
|
||||
|
||||
The mimetype is used for serialized objects, and tells the
|
||||
ResXResourceReader how to depersist the object. This is currently not
|
||||
extensible. For a given mimetype the value must be set accordingly:
|
||||
|
||||
Note - application/x-microsoft.net.object.binary.base64 is the format
|
||||
that the ResXResourceWriter will generate, however the reader can
|
||||
read any of the formats listed below.
|
||||
|
||||
mimetype: application/x-microsoft.net.object.binary.base64
|
||||
value : The object must be serialized with
|
||||
: System.Runtime.Serialization.Formatters.Binary.BinaryFormatter
|
||||
: and then encoded with base64 encoding.
|
||||
|
||||
mimetype: application/x-microsoft.net.object.soap.base64
|
||||
value : The object must be serialized with
|
||||
: System.Runtime.Serialization.Formatters.Soap.SoapFormatter
|
||||
: and then encoded with base64 encoding.
|
||||
|
||||
mimetype: application/x-microsoft.net.object.bytearray.base64
|
||||
value : The object must be serialized into a byte array
|
||||
: using a System.ComponentModel.TypeConverter
|
||||
: and then encoded with base64 encoding.
|
||||
-->
|
||||
<xsd:schema id="root" xmlns="" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:msdata="urn:schemas-microsoft-com:xml-msdata">
|
||||
<xsd:import namespace="http://www.w3.org/XML/1998/namespace" />
|
||||
<xsd:element name="root" msdata:IsDataSet="true">
|
||||
<xsd:complexType>
|
||||
<xsd:choice maxOccurs="unbounded">
|
||||
<xsd:element name="metadata">
|
||||
<xsd:complexType>
|
||||
<xsd:sequence>
|
||||
<xsd:element name="value" type="xsd:string" minOccurs="0" />
|
||||
</xsd:sequence>
|
||||
<xsd:attribute name="name" use="required" type="xsd:string" />
|
||||
<xsd:attribute name="type" type="xsd:string" />
|
||||
<xsd:attribute name="mimetype" type="xsd:string" />
|
||||
<xsd:attribute ref="xml:space" />
|
||||
</xsd:complexType>
|
||||
</xsd:element>
|
||||
<xsd:element name="assembly">
|
||||
<xsd:complexType>
|
||||
<xsd:attribute name="alias" type="xsd:string" />
|
||||
<xsd:attribute name="name" type="xsd:string" />
|
||||
</xsd:complexType>
|
||||
</xsd:element>
|
||||
<xsd:element name="data">
|
||||
<xsd:complexType>
|
||||
<xsd:sequence>
|
||||
<xsd:element name="value" type="xsd:string" minOccurs="0" msdata:Ordinal="1" />
|
||||
<xsd:element name="comment" type="xsd:string" minOccurs="0" msdata:Ordinal="2" />
|
||||
</xsd:sequence>
|
||||
<xsd:attribute name="name" type="xsd:string" use="required" msdata:Ordinal="1" />
|
||||
<xsd:attribute name="type" type="xsd:string" msdata:Ordinal="3" />
|
||||
<xsd:attribute name="mimetype" type="xsd:string" msdata:Ordinal="4" />
|
||||
<xsd:attribute ref="xml:space" />
|
||||
</xsd:complexType>
|
||||
</xsd:element>
|
||||
<xsd:element name="resheader">
|
||||
<xsd:complexType>
|
||||
<xsd:sequence>
|
||||
<xsd:element name="value" type="xsd:string" minOccurs="0" msdata:Ordinal="1" />
|
||||
</xsd:sequence>
|
||||
<xsd:attribute name="name" type="xsd:string" use="required" />
|
||||
</xsd:complexType>
|
||||
</xsd:element>
|
||||
</xsd:choice>
|
||||
</xsd:complexType>
|
||||
</xsd:element>
|
||||
</xsd:schema>
|
||||
<resheader name="resmimetype">
|
||||
<value>text/microsoft-resx</value>
|
||||
</resheader>
|
||||
<resheader name="version">
|
||||
<value>2.0</value>
|
||||
</resheader>
|
||||
<resheader name="reader">
|
||||
<value>System.Resources.ResXResourceReader, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
|
||||
</resheader>
|
||||
<resheader name="writer">
|
||||
<value>System.Resources.ResXResourceWriter, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
|
||||
</resheader>
|
||||
</root>
|
||||
22
HalconWindowTest/Program.cs
Normal file
22
HalconWindowTest/Program.cs
Normal file
@@ -0,0 +1,22 @@
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Linq;
|
||||
using System.Threading.Tasks;
|
||||
using System.Windows.Forms;
|
||||
|
||||
namespace HalconWindowTest
|
||||
{
|
||||
static class Program
|
||||
{
|
||||
/// <summary>
|
||||
/// 应用程序的主入口点。
|
||||
/// </summary>
|
||||
[STAThread]
|
||||
static void Main()
|
||||
{
|
||||
Application.EnableVisualStyles();
|
||||
Application.SetCompatibleTextRenderingDefault(false);
|
||||
Application.Run(new MainForm());
|
||||
}
|
||||
}
|
||||
}
|
||||
36
HalconWindowTest/Properties/AssemblyInfo.cs
Normal file
36
HalconWindowTest/Properties/AssemblyInfo.cs
Normal file
@@ -0,0 +1,36 @@
|
||||
using System.Reflection;
|
||||
using System.Runtime.CompilerServices;
|
||||
using System.Runtime.InteropServices;
|
||||
|
||||
// 有关程序集的一般信息由以下
|
||||
// 控制。更改这些特性值可修改
|
||||
// 与程序集关联的信息。
|
||||
[assembly: AssemblyTitle("HalconWindowTest")]
|
||||
[assembly: AssemblyDescription("")]
|
||||
[assembly: AssemblyConfiguration("")]
|
||||
[assembly: AssemblyCompany("")]
|
||||
[assembly: AssemblyProduct("HalconWindowTest")]
|
||||
[assembly: AssemblyCopyright("Copyright © 2019")]
|
||||
[assembly: AssemblyTrademark("")]
|
||||
[assembly: AssemblyCulture("")]
|
||||
|
||||
//将 ComVisible 设置为 false 将使此程序集中的类型
|
||||
//对 COM 组件不可见。 如果需要从 COM 访问此程序集中的类型,
|
||||
//请将此类型的 ComVisible 特性设置为 true。
|
||||
[assembly: ComVisible(false)]
|
||||
|
||||
// 如果此项目向 COM 公开,则下列 GUID 用于类型库的 ID
|
||||
[assembly: Guid("4adc75ae-59c7-4d36-b675-a6ce51b6f5ba")]
|
||||
|
||||
// 程序集的版本信息由下列四个值组成:
|
||||
//
|
||||
// 主版本
|
||||
// 次版本
|
||||
// 生成号
|
||||
// 修订号
|
||||
//
|
||||
//可以指定所有这些值,也可以使用“生成号”和“修订号”的默认值,
|
||||
// 方法是按如下所示使用“*”: :
|
||||
// [assembly: AssemblyVersion("1.0.*")]
|
||||
[assembly: AssemblyVersion("1.0.0.0")]
|
||||
[assembly: AssemblyFileVersion("1.0.0.0")]
|
||||
71
HalconWindowTest/Properties/Resources.Designer.cs
generated
Normal file
71
HalconWindowTest/Properties/Resources.Designer.cs
generated
Normal file
@@ -0,0 +1,71 @@
|
||||
//------------------------------------------------------------------------------
|
||||
// <auto-generated>
|
||||
// 此代码由工具生成。
|
||||
// 运行时版本: 4.0.30319.42000
|
||||
//
|
||||
// 对此文件的更改可能导致不正确的行为,如果
|
||||
// 重新生成代码,则所做更改将丢失。
|
||||
// </auto-generated>
|
||||
//------------------------------------------------------------------------------
|
||||
|
||||
namespace HalconWindowTest.Properties
|
||||
{
|
||||
|
||||
|
||||
/// <summary>
|
||||
/// 强类型资源类,用于查找本地化字符串等。
|
||||
/// </summary>
|
||||
// 此类是由 StronglyTypedResourceBuilder
|
||||
// 类通过类似于 ResGen 或 Visual Studio 的工具自动生成的。
|
||||
// 若要添加或删除成员,请编辑 .ResX 文件,然后重新运行 ResGen
|
||||
// (以 /str 作为命令选项),或重新生成 VS 项目。
|
||||
[global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Resources.Tools.StronglyTypedResourceBuilder", "4.0.0.0")]
|
||||
[global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
|
||||
[global::System.Runtime.CompilerServices.CompilerGeneratedAttribute()]
|
||||
internal class Resources
|
||||
{
|
||||
|
||||
private static global::System.Resources.ResourceManager resourceMan;
|
||||
|
||||
private static global::System.Globalization.CultureInfo resourceCulture;
|
||||
|
||||
[global::System.Diagnostics.CodeAnalysis.SuppressMessageAttribute("Microsoft.Performance", "CA1811:AvoidUncalledPrivateCode")]
|
||||
internal Resources()
|
||||
{
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// 返回此类使用的缓存 ResourceManager 实例。
|
||||
/// </summary>
|
||||
[global::System.ComponentModel.EditorBrowsableAttribute(global::System.ComponentModel.EditorBrowsableState.Advanced)]
|
||||
internal static global::System.Resources.ResourceManager ResourceManager
|
||||
{
|
||||
get
|
||||
{
|
||||
if ((resourceMan == null))
|
||||
{
|
||||
global::System.Resources.ResourceManager temp = new global::System.Resources.ResourceManager("HalconWindowTest.Properties.Resources", typeof(Resources).Assembly);
|
||||
resourceMan = temp;
|
||||
}
|
||||
return resourceMan;
|
||||
}
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// 覆盖当前线程的 CurrentUICulture 属性
|
||||
/// 使用此强类型的资源类的资源查找。
|
||||
/// </summary>
|
||||
[global::System.ComponentModel.EditorBrowsableAttribute(global::System.ComponentModel.EditorBrowsableState.Advanced)]
|
||||
internal static global::System.Globalization.CultureInfo Culture
|
||||
{
|
||||
get
|
||||
{
|
||||
return resourceCulture;
|
||||
}
|
||||
set
|
||||
{
|
||||
resourceCulture = value;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
117
HalconWindowTest/Properties/Resources.resx
Normal file
117
HalconWindowTest/Properties/Resources.resx
Normal file
@@ -0,0 +1,117 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<root>
|
||||
<!--
|
||||
Microsoft ResX Schema
|
||||
|
||||
Version 2.0
|
||||
|
||||
The primary goals of this format is to allow a simple XML format
|
||||
that is mostly human readable. The generation and parsing of the
|
||||
various data types are done through the TypeConverter classes
|
||||
associated with the data types.
|
||||
|
||||
Example:
|
||||
|
||||
... ado.net/XML headers & schema ...
|
||||
<resheader name="resmimetype">text/microsoft-resx</resheader>
|
||||
<resheader name="version">2.0</resheader>
|
||||
<resheader name="reader">System.Resources.ResXResourceReader, System.Windows.Forms, ...</resheader>
|
||||
<resheader name="writer">System.Resources.ResXResourceWriter, System.Windows.Forms, ...</resheader>
|
||||
<data name="Name1"><value>this is my long string</value><comment>this is a comment</comment></data>
|
||||
<data name="Color1" type="System.Drawing.Color, System.Drawing">Blue</data>
|
||||
<data name="Bitmap1" mimetype="application/x-microsoft.net.object.binary.base64">
|
||||
<value>[base64 mime encoded serialized .NET Framework object]</value>
|
||||
</data>
|
||||
<data name="Icon1" type="System.Drawing.Icon, System.Drawing" mimetype="application/x-microsoft.net.object.bytearray.base64">
|
||||
<value>[base64 mime encoded string representing a byte array form of the .NET Framework object]</value>
|
||||
<comment>This is a comment</comment>
|
||||
</data>
|
||||
|
||||
There are any number of "resheader" rows that contain simple
|
||||
name/value pairs.
|
||||
|
||||
Each data row contains a name, and value. The row also contains a
|
||||
type or mimetype. Type corresponds to a .NET class that support
|
||||
text/value conversion through the TypeConverter architecture.
|
||||
Classes that don't support this are serialized and stored with the
|
||||
mimetype set.
|
||||
|
||||
The mimetype is used for serialized objects, and tells the
|
||||
ResXResourceReader how to depersist the object. This is currently not
|
||||
extensible. For a given mimetype the value must be set accordingly:
|
||||
|
||||
Note - application/x-microsoft.net.object.binary.base64 is the format
|
||||
that the ResXResourceWriter will generate, however the reader can
|
||||
read any of the formats listed below.
|
||||
|
||||
mimetype: application/x-microsoft.net.object.binary.base64
|
||||
value : The object must be serialized with
|
||||
: System.Serialization.Formatters.Binary.BinaryFormatter
|
||||
: and then encoded with base64 encoding.
|
||||
|
||||
mimetype: application/x-microsoft.net.object.soap.base64
|
||||
value : The object must be serialized with
|
||||
: System.Runtime.Serialization.Formatters.Soap.SoapFormatter
|
||||
: and then encoded with base64 encoding.
|
||||
|
||||
mimetype: application/x-microsoft.net.object.bytearray.base64
|
||||
value : The object must be serialized into a byte array
|
||||
: using a System.ComponentModel.TypeConverter
|
||||
: and then encoded with base64 encoding.
|
||||
-->
|
||||
<xsd:schema id="root" xmlns="" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:msdata="urn:schemas-microsoft-com:xml-msdata">
|
||||
<xsd:element name="root" msdata:IsDataSet="true">
|
||||
<xsd:complexType>
|
||||
<xsd:choice maxOccurs="unbounded">
|
||||
<xsd:element name="metadata">
|
||||
<xsd:complexType>
|
||||
<xsd:sequence>
|
||||
<xsd:element name="value" type="xsd:string" minOccurs="0" />
|
||||
</xsd:sequence>
|
||||
<xsd:attribute name="name" type="xsd:string" />
|
||||
<xsd:attribute name="type" type="xsd:string" />
|
||||
<xsd:attribute name="mimetype" type="xsd:string" />
|
||||
</xsd:complexType>
|
||||
</xsd:element>
|
||||
<xsd:element name="assembly">
|
||||
<xsd:complexType>
|
||||
<xsd:attribute name="alias" type="xsd:string" />
|
||||
<xsd:attribute name="name" type="xsd:string" />
|
||||
</xsd:complexType>
|
||||
</xsd:element>
|
||||
<xsd:element name="data">
|
||||
<xsd:complexType>
|
||||
<xsd:sequence>
|
||||
<xsd:element name="value" type="xsd:string" minOccurs="0" msdata:Ordinal="1" />
|
||||
<xsd:element name="comment" type="xsd:string" minOccurs="0" msdata:Ordinal="2" />
|
||||
</xsd:sequence>
|
||||
<xsd:attribute name="name" type="xsd:string" msdata:Ordinal="1" />
|
||||
<xsd:attribute name="type" type="xsd:string" msdata:Ordinal="3" />
|
||||
<xsd:attribute name="mimetype" type="xsd:string" msdata:Ordinal="4" />
|
||||
</xsd:complexType>
|
||||
</xsd:element>
|
||||
<xsd:element name="resheader">
|
||||
<xsd:complexType>
|
||||
<xsd:sequence>
|
||||
<xsd:element name="value" type="xsd:string" minOccurs="0" msdata:Ordinal="1" />
|
||||
</xsd:sequence>
|
||||
<xsd:attribute name="name" type="xsd:string" use="required" />
|
||||
</xsd:complexType>
|
||||
</xsd:element>
|
||||
</xsd:choice>
|
||||
</xsd:complexType>
|
||||
</xsd:element>
|
||||
</xsd:schema>
|
||||
<resheader name="resmimetype">
|
||||
<value>text/microsoft-resx</value>
|
||||
</resheader>
|
||||
<resheader name="version">
|
||||
<value>2.0</value>
|
||||
</resheader>
|
||||
<resheader name="reader">
|
||||
<value>System.Resources.ResXResourceReader, System.Windows.Forms, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
|
||||
</resheader>
|
||||
<resheader name="writer">
|
||||
<value>System.Resources.ResXResourceWriter, System.Windows.Forms, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
|
||||
</resheader>
|
||||
</root>
|
||||
30
HalconWindowTest/Properties/Settings.Designer.cs
generated
Normal file
30
HalconWindowTest/Properties/Settings.Designer.cs
generated
Normal file
@@ -0,0 +1,30 @@
|
||||
//------------------------------------------------------------------------------
|
||||
// <auto-generated>
|
||||
// This code was generated by a tool.
|
||||
// Runtime Version:4.0.30319.42000
|
||||
//
|
||||
// Changes to this file may cause incorrect behavior and will be lost if
|
||||
// the code is regenerated.
|
||||
// </auto-generated>
|
||||
//------------------------------------------------------------------------------
|
||||
|
||||
namespace HalconWindowTest.Properties
|
||||
{
|
||||
|
||||
|
||||
[global::System.Runtime.CompilerServices.CompilerGeneratedAttribute()]
|
||||
[global::System.CodeDom.Compiler.GeneratedCodeAttribute("Microsoft.VisualStudio.Editors.SettingsDesigner.SettingsSingleFileGenerator", "11.0.0.0")]
|
||||
internal sealed partial class Settings : global::System.Configuration.ApplicationSettingsBase
|
||||
{
|
||||
|
||||
private static Settings defaultInstance = ((Settings)(global::System.Configuration.ApplicationSettingsBase.Synchronized(new Settings())));
|
||||
|
||||
public static Settings Default
|
||||
{
|
||||
get
|
||||
{
|
||||
return defaultInstance;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
7
HalconWindowTest/Properties/Settings.settings
Normal file
7
HalconWindowTest/Properties/Settings.settings
Normal file
@@ -0,0 +1,7 @@
|
||||
<?xml version='1.0' encoding='utf-8'?>
|
||||
<SettingsFile xmlns="http://schemas.microsoft.com/VisualStudio/2004/01/settings" CurrentProfile="(Default)">
|
||||
<Profiles>
|
||||
<Profile Name="(Default)" />
|
||||
</Profiles>
|
||||
<Settings />
|
||||
</SettingsFile>
|
||||
BIN
HalconWindowTest/bin/Debug/HalconWindowTest.exe
Normal file
BIN
HalconWindowTest/bin/Debug/HalconWindowTest.exe
Normal file
Binary file not shown.
6
HalconWindowTest/bin/Debug/HalconWindowTest.exe.config
Normal file
6
HalconWindowTest/bin/Debug/HalconWindowTest.exe.config
Normal file
@@ -0,0 +1,6 @@
|
||||
<?xml version="1.0" encoding="utf-8" ?>
|
||||
<configuration>
|
||||
<startup>
|
||||
<supportedRuntime version="v4.0" sku=".NETFramework,Version=v4.5.2" />
|
||||
</startup>
|
||||
</configuration>
|
||||
BIN
HalconWindowTest/bin/Debug/HalconWindowTest.pdb
Normal file
BIN
HalconWindowTest/bin/Debug/HalconWindowTest.pdb
Normal file
Binary file not shown.
BIN
HalconWindowTest/bin/Debug/HalconWindowTest.vshost.exe
Normal file
BIN
HalconWindowTest/bin/Debug/HalconWindowTest.vshost.exe
Normal file
Binary file not shown.
@@ -0,0 +1,6 @@
|
||||
<?xml version="1.0" encoding="utf-8" ?>
|
||||
<configuration>
|
||||
<startup>
|
||||
<supportedRuntime version="v4.0" sku=".NETFramework,Version=v4.5.2" />
|
||||
</startup>
|
||||
</configuration>
|
||||
BIN
HalconWindowTest/bin/Debug/halcondotnet.dll
Normal file
BIN
HalconWindowTest/bin/Debug/halcondotnet.dll
Normal file
Binary file not shown.
61480
HalconWindowTest/bin/Debug/halcondotnet.xml
Normal file
61480
HalconWindowTest/bin/Debug/halcondotnet.xml
Normal file
File diff suppressed because it is too large
Load Diff
BIN
HalconWindowTest/bin/x64/Debug/HalconWindowTest.exe
Normal file
BIN
HalconWindowTest/bin/x64/Debug/HalconWindowTest.exe
Normal file
Binary file not shown.
@@ -0,0 +1,6 @@
|
||||
<?xml version="1.0" encoding="utf-8" ?>
|
||||
<configuration>
|
||||
<startup>
|
||||
<supportedRuntime version="v4.0" sku=".NETFramework,Version=v4.5.2" />
|
||||
</startup>
|
||||
</configuration>
|
||||
BIN
HalconWindowTest/bin/x64/Debug/HalconWindowTest.pdb
Normal file
BIN
HalconWindowTest/bin/x64/Debug/HalconWindowTest.pdb
Normal file
Binary file not shown.
BIN
HalconWindowTest/bin/x64/Debug/HalconWindowTest.vshost.exe
Normal file
BIN
HalconWindowTest/bin/x64/Debug/HalconWindowTest.vshost.exe
Normal file
Binary file not shown.
@@ -0,0 +1,6 @@
|
||||
<?xml version="1.0" encoding="utf-8" ?>
|
||||
<configuration>
|
||||
<startup>
|
||||
<supportedRuntime version="v4.0" sku=".NETFramework,Version=v4.5.2" />
|
||||
</startup>
|
||||
</configuration>
|
||||
@@ -0,0 +1,11 @@
|
||||
<?xml version="1.0" encoding="UTF-8" standalone="yes"?>
|
||||
<assembly xmlns="urn:schemas-microsoft-com:asm.v1" manifestVersion="1.0">
|
||||
<assemblyIdentity version="1.0.0.0" name="MyApplication.app"/>
|
||||
<trustInfo xmlns="urn:schemas-microsoft-com:asm.v2">
|
||||
<security>
|
||||
<requestedPrivileges xmlns="urn:schemas-microsoft-com:asm.v3">
|
||||
<requestedExecutionLevel level="asInvoker" uiAccess="false"/>
|
||||
</requestedPrivileges>
|
||||
</security>
|
||||
</trustInfo>
|
||||
</assembly>
|
||||
BIN
HalconWindowTest/bin/x64/Debug/halcondotnet.dll
Normal file
BIN
HalconWindowTest/bin/x64/Debug/halcondotnet.dll
Normal file
Binary file not shown.
61480
HalconWindowTest/bin/x64/Debug/halcondotnet.xml
Normal file
61480
HalconWindowTest/bin/x64/Debug/halcondotnet.xml
Normal file
File diff suppressed because it is too large
Load Diff
Binary file not shown.
Binary file not shown.
Binary file not shown.
BIN
HalconWindowTest/obj/Debug/HalconWindowTest.MainForm.resources
Normal file
BIN
HalconWindowTest/obj/Debug/HalconWindowTest.MainForm.resources
Normal file
Binary file not shown.
Binary file not shown.
@@ -0,0 +1,12 @@
|
||||
F:\VSCode\VisionEditTest\HalconWindowTest\bin\Debug\HalconWindowTest.exe.config
|
||||
F:\VSCode\VisionEditTest\HalconWindowTest\bin\Debug\HalconWindowTest.exe
|
||||
F:\VSCode\VisionEditTest\HalconWindowTest\bin\Debug\HalconWindowTest.pdb
|
||||
F:\VSCode\VisionEditTest\HalconWindowTest\obj\Debug\HalconWindowTest.MainForm.resources
|
||||
F:\VSCode\VisionEditTest\HalconWindowTest\obj\Debug\HalconWindowTest.Properties.Resources.resources
|
||||
F:\VSCode\VisionEditTest\HalconWindowTest\obj\Debug\HalconWindowTest.csproj.GenerateResource.Cache
|
||||
F:\VSCode\VisionEditTest\HalconWindowTest\obj\Debug\HalconWindowTest.exe
|
||||
F:\VSCode\VisionEditTest\HalconWindowTest\obj\Debug\HalconWindowTest.pdb
|
||||
F:\VSCode\VisionEditTest\HalconWindowTest\bin\Debug\halcondotnet.dll
|
||||
F:\VSCode\VisionEditTest\HalconWindowTest\bin\Debug\halcondotnet.xml
|
||||
F:\VSCode\VisionEditTest\HalconWindowTest\obj\Debug\HalconWindowTest.HalconWindow.HWindow_Final.resources
|
||||
F:\VSCode\VisionEditTest\HalconWindowTest\obj\Debug\HalconWindowTest.csprojResolveAssemblyReference.cache
|
||||
Binary file not shown.
Binary file not shown.
BIN
HalconWindowTest/obj/Debug/HalconWindowTest.exe
Normal file
BIN
HalconWindowTest/obj/Debug/HalconWindowTest.exe
Normal file
Binary file not shown.
BIN
HalconWindowTest/obj/Debug/HalconWindowTest.pdb
Normal file
BIN
HalconWindowTest/obj/Debug/HalconWindowTest.pdb
Normal file
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
@@ -0,0 +1,13 @@
|
||||
F:\VSCode\VisionEditTest\HalconWindowTest\bin\x64\Debug\HalconWindowTest.exe.config
|
||||
F:\VSCode\VisionEditTest\HalconWindowTest\bin\x64\Debug\HalconWindowTest.exe
|
||||
F:\VSCode\VisionEditTest\HalconWindowTest\bin\x64\Debug\HalconWindowTest.pdb
|
||||
F:\VSCode\VisionEditTest\HalconWindowTest\bin\x64\Debug\halcondotnet.dll
|
||||
F:\VSCode\VisionEditTest\HalconWindowTest\obj\x64\Debug\HalconWindowTest.MainForm.resources
|
||||
F:\VSCode\VisionEditTest\HalconWindowTest\obj\x64\Debug\HalconWindowTest.Properties.Resources.resources
|
||||
F:\VSCode\VisionEditTest\HalconWindowTest\obj\x64\Debug\HalconWindowTest.csproj.GenerateResource.Cache
|
||||
F:\VSCode\VisionEditTest\HalconWindowTest\obj\x64\Debug\HalconWindowTest.exe
|
||||
F:\VSCode\VisionEditTest\HalconWindowTest\obj\x64\Debug\HalconWindowTest.pdb
|
||||
F:\VSCode\VisionEditTest\HalconWindowTest\obj\x64\Debug\HalconWindowTest.HalconWindow.HWindow_Final.resources
|
||||
F:\VSCode\VisionEditTest\HalconWindowTest\bin\x64\Debug\halcondotnet.xml
|
||||
F:\VSCode\VisionEditTest\HalconWindowTest\obj\x64\Debug\HalconWindowTest.HalconWindow.FormHalconWindow.resources
|
||||
F:\VSCode\VisionEditTest\HalconWindowTest\obj\x64\Debug\HalconWindowTest.csprojResolveAssemblyReference.cache
|
||||
Binary file not shown.
Binary file not shown.
BIN
HalconWindowTest/obj/x64/Debug/HalconWindowTest.exe
Normal file
BIN
HalconWindowTest/obj/x64/Debug/HalconWindowTest.exe
Normal file
Binary file not shown.
BIN
HalconWindowTest/obj/x64/Debug/HalconWindowTest.pdb
Normal file
BIN
HalconWindowTest/obj/x64/Debug/HalconWindowTest.pdb
Normal file
Binary file not shown.
Reference in New Issue
Block a user