2ee0bae58228032e469245e784c823693cdafe6f..46431fb658701489f8d5de4475b02df728c51f36
2026-03-18 chunxiaqiu
新增:读码器功能模块,集成华睿读码器并初步实现读码功能
46431f 对比 | 目录
2026-03-06 C3031
Merge branch 'master' of http://lanpucloud.cn:1111/r/~zhengyabo/LB_TyreAppe...
8db52b 对比 | 目录
2026-01-30 C3031
新增了图像增强算法及图像滤波算法
0ab0fd 对比 | 目录
2026-01-30 C3031
130802 对比 | 目录
2026-01-30 C3031
22ff83 对比 | 目录
2026-01-30 C3031
065674 对比 | 目录
2026-01-28 C3204
配方界面整合以及主界面布局。
693a61 对比 | 目录
2026-01-22 C3204
优化主界面显示为行列矩阵形式,实现鼠标左键双击对应窗体最大化,再次双击恢复之前布局。
72cf32 对比 | 目录
2026-01-19 C3204
合并冲突
833c76 对比 | 目录
2026-01-19 C3204
完善运动控制参数存储以及加载
046835 对比 | 目录
2026-01-19 C3204
user
fb4b86 对比 | 目录
2026-01-16 C3204
在运动控制界面添加可配置的PLC相关参数修复工具图像输入bug添加项目文件。在运动控制界面添加可配置的PLC相关参数。
4d0e64 对比 | 目录
2026-01-16 C3031
修改关闭按钮位置
28ddc7 对比 | 目录
2026-01-13 C3204
添加用户以及历史数据底层逻辑修复ProcessRunBll。
510dc6 对比 | 目录
2026-01-16 C3204
在运动控制界面添加可配置的PLC相关参数。
8ed1e9 对比 | 目录
2026-01-16 C3204
修复工具图像输入bug添加项目文件。
52e8ee 对比 | 目录
2026-01-16 C3204
添加运动控制菜单底层逻辑
76d741 对比 | 目录
2026-01-15 C3204
添加运动控制菜单
a987bb 对比 | 目录
2026-01-16 C3032
Merge branch 'feature/Camera3D'
919a8e 对比 | 目录
2026-01-15 C3204
修复图像采集工具使用CollectedImages
577926 对比 | 目录
2026-01-13 C3204
修复ProcessRunBll。
e066e3 对比 | 目录
已添加47个文件
已修改55个文件
10811 ■■■■ 文件已修改
LB_SmartVision/CSV/CsvDataHelperRecordProductData.cs 110 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
LB_SmartVision/CSV/CsvRecordProductDataMap.cs 25 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
LB_SmartVision/Forms/Pages/CommunicatorPage/CommunicatorForm.Designer.cs 2 ●●● 补丁 | 查看 | 原始文档 | blame | 历史
LB_SmartVision/Forms/Pages/CommunicatorPage/CommunicatorForm.cs 29 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
LB_SmartVision/Forms/Pages/CommunicatorPage/CommunicatorsEditPage.cs 10 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
LB_SmartVision/Forms/Pages/HistoricalDataPage/HistoricalDataEditPage.Designer.cs 8 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
LB_SmartVision/Forms/Pages/HistoricalDataPage/HistoricalDataEditPage.cs 119 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
LB_SmartVision/Forms/Pages/MotionControlPage/MotionControlForm.Designer.cs 694 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
LB_SmartVision/Forms/Pages/MotionControlPage/MotionControlForm.cs 158 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
LB_SmartVision/Forms/Pages/MotionControlPage/MotionControlForm.resx 2 ●●● 补丁 | 查看 | 原始文档 | blame | 历史
LB_SmartVision/Forms/Pages/MotionControlPage/RecordMotionControlData.cs 93 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
LB_SmartVision/Forms/Pages/ProcessPage/AllProcessesPage.cs 150 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
LB_SmartVision/Forms/Pages/ProcessPage/ProcessControl.Designer.cs 4 ●●● 补丁 | 查看 | 原始文档 | blame | 历史
LB_SmartVision/Forms/Pages/ProcessPage/ProcessControl.cs 40 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
LB_SmartVision/Forms/Pages/ProcessPage/ProcessPage.cs 16 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
LB_SmartVision/Forms/Pages/UserManagementPage/UserManagementEditPage.Designer.cs 79 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
LB_SmartVision/Forms/Pages/UserManagementPage/UserManagementEditPage.cs 159 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
LB_SmartVision/GlobalVar.cs 17 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
LB_SmartVision/LB_SmartVision.csproj 13 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
LB_SmartVision/ProcessRun/ProcessContext.cs 13 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
LB_SmartVision/ProcessRun/ProcessRunBll.cs 4 ●●● 补丁 | 查看 | 原始文档 | blame | 历史
LB_SmartVision/SQL/DatabaseRecordProductDataHelper.cs 2 ●●● 补丁 | 查看 | 原始文档 | blame | 历史
LB_SmartVision/VisionForm.Designer.cs 191 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
LB_SmartVision/VisionForm.cs 192 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
LB_SmartVision/VisionForm.resx 36 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
LB_SmartVisionCommon/ConfigManager.cs 10 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
LB_SmartVisionCommon/FilterData.cs 80 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
LB_SmartVisionCommon/FilterManager.cs 152 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
LB_SmartVisionCommon/ImageEnhancementData.cs 75 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
LB_SmartVisionCommon/ImageEnhancementManager.cs 155 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
LB_SmartVisionCommon/UserManager.cs 33 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
LB_VisionControl/UserHSmartWindowControl.Designer.cs 36 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
LB_VisionControl/UserHSmartWindowControl.cs 28 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
LB_VisionFlowNode/FlowPanel.cs 4 ●●● 补丁 | 查看 | 原始文档 | blame | 历史
LB_VisionFlowNode/IFlowContext.cs 11 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
LB_VisionProcesses/Alogrithms/BaseAlgorithm/TAlgorithm.cs 87 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
LB_VisionProcesses/Alogrithms/Halcon/2D/HBlobTool/HBlobTool.cs 11 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
LB_VisionProcesses/Alogrithms/Halcon/2D/HBlobTool/HBlobToolEdit.Designer.cs 603 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
LB_VisionProcesses/Alogrithms/Halcon/2D/HBlobTool/HBlobToolEdit.cs 2 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
LB_VisionProcesses/Alogrithms/Halcon/2D/HBlobTool/HBlobToolEdit.resx 4 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
LB_VisionProcesses/Alogrithms/Halcon/2D/HFilterTool/HFilterTool.cs 229 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
LB_VisionProcesses/Alogrithms/Halcon/2D/HFilterTool/HFilterToolEdit.Designer.cs 613 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
LB_VisionProcesses/Alogrithms/Halcon/2D/HFilterTool/HFilterToolEdit.cs 611 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
LB_VisionProcesses/Alogrithms/Halcon/2D/HFilterTool/HFilterToolEdit.resx 129 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
LB_VisionProcesses/Alogrithms/Halcon/2D/HFindCode2dTool/HFindCode2dTool.cs 24 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
LB_VisionProcesses/Alogrithms/Halcon/2D/HFindCode2dTool/HFindCode2dToolEdit.Designer.cs 262 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
LB_VisionProcesses/Alogrithms/Halcon/2D/HFindCode2dTool/HFindCode2dToolEdit.resx 11 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
LB_VisionProcesses/Alogrithms/Halcon/2D/HFindLineTool/HFindLineTool.cs 28 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
LB_VisionProcesses/Alogrithms/Halcon/2D/HFindLineTool/HFindLineToolEdit.Designer.cs 395 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
LB_VisionProcesses/Alogrithms/Halcon/2D/HFindLineTool/HFindLineToolEdit.resx 11 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
LB_VisionProcesses/Alogrithms/Halcon/2D/HFindModelTool/HFindModelTool.cs 22 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
LB_VisionProcesses/Alogrithms/Halcon/2D/HFindMultiModelTool/HFindMultiModelTool.cs 24 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
LB_VisionProcesses/Alogrithms/Halcon/2D/HImageEnhancementTool/HImageEnhancementTool.cs 223 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
LB_VisionProcesses/Alogrithms/Halcon/2D/HImageEnhancementTool/HImageEnhancementToolEdit.Designer.cs 594 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
LB_VisionProcesses/Alogrithms/Halcon/2D/HImageEnhancementTool/HImageEnhancementToolEdit.cs 574 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
LB_VisionProcesses/Alogrithms/Halcon/2D/HImageEnhancementTool/HImageEnhancementToolEdit.resx 129 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
LB_VisionProcesses/Alogrithms/VisualLargeModel/VisualSegmentationModel.cs 13 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
LB_VisionProcesses/BarcodeReaders/BarcodeReaderBase.cs 57 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
LB_VisionProcesses/BarcodeReaders/BarcodeReaderFactory.cs 27 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
LB_VisionProcesses/BarcodeReaders/BarcodeReaderForm.Designer.cs 255 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
LB_VisionProcesses/BarcodeReaders/BarcodeReaderForm.cs 265 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
LB_VisionProcesses/BarcodeReaders/BarcodeReaderForm.resx 120 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
LB_VisionProcesses/BarcodeReaders/Huayray/HRBarcodeReader.cs 216 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
LB_VisionProcesses/BarcodeReaders/IBarcodeReader.cs 118 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
LB_VisionProcesses/Cameras/HRCameras/HRCamera.cs 134 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
LB_VisionProcesses/Cameras/LBCameras/LBCamera.cs 149 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
LB_VisionProcesses/Communicators/BaseCommunicator.cs 14 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
LB_VisionProcesses/Communicators/CommunicatorConfig.cs 11 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
LB_VisionProcesses/Communicators/TCom/LocalMonitor.cs 4 ●●● 补丁 | 查看 | 原始文档 | blame | 历史
LB_VisionProcesses/Communicators/TCom/TCPClient.cs 4 ●●● 补丁 | 查看 | 原始文档 | blame | 历史
LB_VisionProcesses/Communicators/TCom/TCPServer.cs 4 ●●● 补丁 | 查看 | 原始文档 | blame | 历史
LB_VisionProcesses/Communicators/TCom/UARTPort.cs 4 ●●● 补丁 | 查看 | 原始文档 | blame | 历史
LB_VisionProcesses/Communicators/UserCommunicator/T306Command/T306CommandTool.cs 2 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
LB_VisionProcesses/LB_VisionProcesses.csproj 38 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
LB_VisionProcesses/ProcessEditForm.Designer.cs 22 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
LB_VisionProcesses/ProcessEditForm.cs 2 ●●● 补丁 | 查看 | 原始文档 | blame | 历史
LB_VisionProcesses/ProcessEditForm.resx 39 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
LB_VisionProcesses/Processes/BarcodeReaderProcess.cs 150 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
LB_VisionProcesses/ref/CLAllSerial_MD_VC120_v3_0.dll 补丁 | 查看 | 原始文档 | blame | 历史
LB_VisionProcesses/ref/CLProtocol_MD_VC120_v3_0.dll 补丁 | 查看 | 原始文档 | blame | 历史
LB_VisionProcesses/ref/CLSerCOM.dll 补丁 | 查看 | 原始文档 | blame | 历史
LB_VisionProcesses/ref/EasyID.dll 补丁 | 查看 | 原始文档 | blame | 历史
LB_VisionProcesses/ref/EasyIDSDK_Net.XML 1812 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
LB_VisionProcesses/ref/EasyIDSDK_Net.dll 补丁 | 查看 | 原始文档 | blame | 历史
LB_VisionProcesses/ref/GCBase_MD_VC120_v3_0.dll 补丁 | 查看 | 原始文档 | blame | 历史
LB_VisionProcesses/ref/GenApi_MD_VC120_v3_0.dll 补丁 | 查看 | 原始文档 | blame | 历史
LB_VisionProcesses/ref/GenCP_MD_VC120_v3_0.dll 补丁 | 查看 | 原始文档 | blame | 历史
LB_VisionProcesses/ref/ImageConvert.dll 补丁 | 查看 | 原始文档 | blame | 历史
LB_VisionProcesses/ref/ImageSave.dll 补丁 | 查看 | 原始文档 | blame | 历史
LB_VisionProcesses/ref/Log_MD_VC120_v3_0.dll 补丁 | 查看 | 原始文档 | blame | 历史
LB_VisionProcesses/ref/MVSDKmd.dll 补丁 | 查看 | 原始文档 | blame | 历史
LB_VisionProcesses/ref/MVlog4cppmd.dll 补丁 | 查看 | 原始文档 | blame | 历史
LB_VisionProcesses/ref/MathParser_MD_VC120_v3_0.dll 补丁 | 查看 | 原始文档 | blame | 历史
LB_VisionProcesses/ref/NodeMapData_MD_VC120_v3_0.dll 补丁 | 查看 | 原始文档 | blame | 历史
LB_VisionProcesses/ref/SDKLOG_default.properties 15 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
LB_VisionProcesses/ref/SharpnessDetection64.dll 补丁 | 查看 | 原始文档 | blame | 历史
LB_VisionProcesses/ref/VideoRender.dll 补丁 | 查看 | 原始文档 | blame | 历史
LB_VisionProcesses/ref/XmlParser_MD_VC120_v3_0.dll 补丁 | 查看 | 原始文档 | blame | 历史
LB_VisionProcesses/ref/clserVsp.dll 补丁 | 查看 | 原始文档 | blame | 历史
LB_VisionProcesses/ref/iImageProcessing64.dll 补丁 | 查看 | 原始文档 | blame | 历史
LB_VisionProcesses/ref/libwinpthread-1.dll 补丁 | 查看 | 原始文档 | blame | 历史
LB_VisionProcesses/ref/log4cpp_MD_VC120_v3_0.dll 补丁 | 查看 | 原始文档 | blame | 历史
LB_SmartVision/CSV/CsvDataHelperRecordProductData.cs
¶Ô±ÈÐÂÎļþ
@@ -0,0 +1,110 @@
using LB_SmartVision.SQL;
using LB_SmartVisionCommon;
using System;
using System.Collections.Generic;
using System.Globalization;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
using CsvHelper;
namespace LB_SmartVision.CSV
{
    internal class CsvDataHelperRecordProductData
    {
        /// <summary>
        /// å°†RecordProductDatas字典保存到CSV文件
        /// </summary>
        /// <param name="filePath">CSV文件路径</param>
        /// <param name="recordProductDatas">要保存的数据字典</param>
        public static void SaveToCsv(string filePath, List<RecordProductData> recordProductDatas)
        {
            try
            {
                using (var writer = new StreamWriter(filePath))
                using (var csv = new CsvWriter(writer, CultureInfo.InvariantCulture))
                {
                    csv.Context.RegisterClassMap<CsvRecordProductDataMap>();
                    // å°†å­—典转换为CsvRecord列表
                    var records = recordProductDatas.Select(kvp => new CsvRecordProductData
                    {
                        //DictionaryKey = kvp.Key,
                        ProductName = kvp.ProductName,
                        ProductSN = kvp.ProductSN,
                        InspectionOperator = kvp.InspectionOperator,
                        NGType = kvp.NGType,
                        NGSize = kvp.NGSize,
                        DetectionTime = kvp.DetectionTime,
                        CameraInspection = kvp.CameraInspection,
                    }).ToList();
                    for (int i = 0; i < records.Count; i++)
                    {
                        AsyncLogHelper.Warn("物料号或产品名称:" + records[i].ProductName + "\r\n" +
                     ",产品SN号:" + records[i].ProductSN + "\r\n" +
                     ",检测作业员:" + records[i].InspectionOperator + "\r\n" +
                     ",NG类型:" + records[i].NGType + " mm" + "\r\n" +
                     ",NG大小:" + records[i].NGSize + " mm" + "\r\n" +
                     ",检测时间:" + records[i].DetectionTime + "\r\n" +
                     ",检测相机:" + records[i].CameraInspection + " mm" + "\r\n" );
                    }
                    csv.WriteRecords(records);
                }
                LogHelper.Info($"数据成功保存到: {filePath}");
            }
            catch (Exception ex)
            {
                LogHelper.Error($"保存CSV文件时出错: {ex.Message}");
                //throw;
            }
            //Task.Factory.StartNew(() =>
            //{
            //});
        }
        /// <summary>
        /// ä»ŽCSV文件读取数据到RecordProductDatas字典
        /// </summary>
        /// <param name="filePath">CSV文件路径</param>
        /// <returns>读取的数据字典</returns>
        public static List<RecordProductData> LoadFromCsv(string filePath)
        {
            var recordProductDatas = new List<RecordProductData>();
            try
            {
                if (!File.Exists(filePath))
                {
                    LogHelper.Info($"文件不存在: {filePath}");
                    return recordProductDatas;
                }
                using (var reader = new StreamReader(filePath))
                using (var csv = new CsvReader(reader, CultureInfo.InvariantCulture))
                {
                    csv.Context.RegisterClassMap<CsvRecordProductDataMap>();
                    var records = csv.GetRecords<CsvRecordProductData>();
                    foreach (var record in records)
                    {
                        var productData = new RecordProductData
                        {
                            ProductName = record.ProductName,
                            ProductSN = record.ProductSN,
                            InspectionOperator = record.InspectionOperator,
                            NGType = record.NGType,
                            NGSize = record.NGSize,
                            DetectionTime = record.DetectionTime,
                            CameraInspection = record.CameraInspection,
                        };
                        recordProductDatas.Add(productData);
                    }
                }
                LogHelper.Info($"从 {filePath} æˆåŠŸè¯»å– {recordProductDatas.Count} æ¡è®°å½•");
            }
            catch (Exception ex)
            {
                LogHelper.Error($"读取CSV文件时出错: {ex.Message}");
                //throw;
            }
            return recordProductDatas;
        }
    }
}
LB_SmartVision/CSV/CsvRecordProductDataMap.cs
¶Ô±ÈÐÂÎļþ
@@ -0,0 +1,25 @@
using CsvHelper.Configuration;
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
namespace LB_SmartVision.CSV
{
    internal class CsvRecordProductDataMap:ClassMap<CsvRecordProductData>
    {
        public CsvRecordProductDataMap()
        {
            //Map(m => m.DictionaryKey).Name("记录时间");
            Map(m => m.ProductName).Name("物料号或产品名称");
            Map(m => m.ProductSN).Name("产品SN号");
            Map(m => m.InspectionOperator).Name("检测作业员");
            Map(m => m.NGType).Name("NG类型");
            Map(m => m.NGSize).Name("NG大小");
            Map(m => m.DetectionTime).Name("检测时间");
            Map(m => m.CameraInspection).Name("检测相机");
        }
    }
}
LB_SmartVision/Forms/Pages/CommunicatorPage/CommunicatorForm.Designer.cs
@@ -228,7 +228,7 @@
            lblAddress.Name = "lblAddress";
            lblAddress.Size = new Size(38, 18);
            lblAddress.TabIndex = 0;
            lblAddress.Text = "地址";
            lblAddress.Text = "变量地址";
            // 
            // lblIP
            // 
LB_SmartVision/Forms/Pages/CommunicatorPage/CommunicatorForm.cs
@@ -28,7 +28,6 @@
        {
            InitializeComponent();
            cmbType.Items.Clear();
            if (communicator != null && !string.IsNullOrEmpty(communicator.CommunicatorConnections["型号"]?.ToString()))
            {
                cmbType.Items.Add(communicator.CommunicatorConnections["型号"]?.ToString());
@@ -39,8 +38,9 @@
        {
            InitializeComponent();
            if (communicator == null)
            {
                return;
            }
            cmbIP.Enabled = false;
            txtIP.Enabled = false;
            txtPort.Enabled = false;
@@ -56,23 +56,20 @@
            this.Text = name;
            if (communicator is UARTPort)
            {
                //统计可用端口
                SerialPortStream temp = new SerialPortStream();
                string[] ArryPort = temp.GetPortNames();
                for (int i = 0; i < ArryPort.Length; i++)
                {
                    cmbIP.Items.Add(ArryPort[i]);
                }
                cmbIP.Text = communicator.CommunicatorConnections["地址"]?.ToString();
                txtPort.Text = communicator.CommunicatorConnections["端口"]?.ToString();
                txtIP.Visible = false;
                cmbIP.Visible = true;
                this.btnRuleSend.Visible = true;
                lblType.Visible = false;
                lblAddress.Visible = false;
                cmbType.Visible = false;
@@ -89,10 +86,7 @@
                txtPort.Text = communicator.CommunicatorConnections["端口"]?.ToString();
                txtIP.Visible = true;
                cmbIP.Visible = false;
                this.btnRuleSend.Visible = false;
                lblType.Visible = false;
                lblAddress.Visible = false;
                cmbType.Visible = false;
@@ -108,7 +102,6 @@
                txtIP.Text = communicator.CommunicatorConnections["地址"]?.ToString();
                txtPort.Text = communicator.CommunicatorConnections["端口"]?.ToString();
                cmbType.Items.Clear();
                if (!string.IsNullOrEmpty(communicator.CommunicatorConnections["型号"]?.ToString()))
                {
                    cmbType.Items.Add(communicator.CommunicatorConnections["型号"]?.ToString());
@@ -130,7 +123,6 @@
                txtIP.Visible = true;
                cmbIP.Visible = false;
                this.btnRuleSend.Visible = false;
                lblType.Visible = true;
                lblAddress.Visible = true;
                cmbType.Visible = true;
@@ -313,5 +305,18 @@
                communicatorChanged(communicator);
            }
        }
        private void cmbVarType_SelectedIndexChanged(object sender, EventArgs e)
        {
            //if (communicator != null && !communicator.CommunicatorConnections.Contains("变量类型"))
            //{
            //    communicator.CommunicatorConnections.Add("变量类型", cmbVarType.Text);
            //}
            //else if (communicator != null)
            //{
            //    communicator.CommunicatorConnections["变量类型"] = cmbVarType.Text;
            //    communicatorChanged(communicator);
            //}
        }
    }
}
LB_SmartVision/Forms/Pages/CommunicatorPage/CommunicatorsEditPage.cs
@@ -206,6 +206,16 @@
                if (GlobalVar.dicCommunicators.ContainsKey(oldName))
                    GlobalVar.dicCommunicators.TryRename(oldName, newName);
                foreach (var item in GlobalVar.dicMotionControlData.Keys)
                {
                    foreach (var item1 in GlobalVar.dicMotionControlData[item].Keys)
                    {
                        if (GlobalVar.dicMotionControlData[item][item1].CommunicatorsName.Contains(oldName))
                        {
                            GlobalVar.dicMotionControlData[item][item1].CommunicatorsName = newName;
                        }
                    }
                }
                flow.Refresh();
            }
LB_SmartVision/Forms/Pages/HistoricalDataPage/HistoricalDataEditPage.Designer.cs
@@ -283,14 +283,14 @@
            // 
            tableLayoutPanel4.Anchor = AnchorStyles.Top | AnchorStyles.Right;
            tableLayoutPanel4.ColumnCount = 2;
            tableLayoutPanel4.ColumnStyles.Add(new ColumnStyle(SizeType.Percent, 50F));
            tableLayoutPanel4.ColumnStyles.Add(new ColumnStyle(SizeType.Percent, 50F));
            tableLayoutPanel4.ColumnStyles.Add(new ColumnStyle(SizeType.Percent, 33.3333321F));
            tableLayoutPanel4.ColumnStyles.Add(new ColumnStyle(SizeType.Percent, 33.3333321F));
            tableLayoutPanel4.Controls.Add(btnHisDataFind, 0, 0);
            tableLayoutPanel4.Controls.Add(btnHisDataExport, 1, 0);
            tableLayoutPanel4.Location = new Point(657, 509);
            tableLayoutPanel4.Name = "tableLayoutPanel4";
            tableLayoutPanel4.RowCount = 1;
            tableLayoutPanel4.RowStyles.Add(new RowStyle(SizeType.Percent, 50F));
            tableLayoutPanel4.RowStyles.Add(new RowStyle(SizeType.Percent, 100F));
            tableLayoutPanel4.Size = new Size(200, 39);
            tableLayoutPanel4.TabIndex = 1;
            // 
@@ -312,6 +312,7 @@
            btnHisDataFind.Text = "查询";
            btnHisDataFind.TextColor = Color.White;
            btnHisDataFind.WarningColor = Color.FromArgb(230, 162, 60);
            btnHisDataFind.Click += btnHisDataFind_Click;
            // 
            // btnHisDataExport
            // 
@@ -341,6 +342,7 @@
            Name = "HistoricalDataEditPage";
            Size = new Size(866, 580);
            grpHisData.ResumeLayout(false);
            grpHisData.PerformLayout();
            tableLayoutPanel1.ResumeLayout(false);
            tableLayoutPanel2.ResumeLayout(false);
            tableLayoutPanel3.ResumeLayout(false);
LB_SmartVision/Forms/Pages/HistoricalDataPage/HistoricalDataEditPage.cs
@@ -1,9 +1,12 @@
using LB_SmartVisionCommon;
using LB_SmartVision.CSV;
using LB_SmartVision.SQL;
using LB_SmartVisionCommon;
using System;
using System.Collections.Generic;
using System.ComponentModel;
using System.Data;
using System.Drawing;
using System.Globalization;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
@@ -14,9 +17,13 @@
    public partial class HistoricalDataEditPage : UserControl
    {
        public Action<string, LogInfoType> LogInfo;
        // ä¿å­˜åŽŸå§‹æ•°æ®çš„åˆ—è¡¨
        private List<DataGridViewRow> originalRows = new List<DataGridViewRow>();
        private int row2OriginalHeight;
        private int row3OriginalHeight;
        List<RecordProductData> RecordProductDatas = new List<RecordProductData>();
        public HistoricalDataEditPage()
        {
            Name = "HistoricalDataEditPage";
@@ -37,30 +44,7 @@
        /// </summary>
        private void InitializeDataGridView()
        {
            // è®¾ç½®DataGridView列宽
            dataGridViewHD.ColumnCount = 4;
            int totalWidth = dataGridViewHD.ClientSize.Width;
            int columnCount = dataGridViewHD.ColumnCount;
            int columnWidth = totalWidth / columnCount;
            // è®¾ç½®æœ€å°å®½åº¦
            int minWidth = 100; // æœ€å°å®½åº¦
            if (columnWidth < minWidth)
            {
                columnWidth = minWidth;
            }
            for (int i = 0; i < columnCount; i++)
            {
                dataGridViewHD.Columns[i].Width = columnWidth;
            }
            // è®¾ç½®åˆ—标题
            dataGridViewHD.Columns[0].Name = "SN号";
            dataGridViewHD.Columns[1].Name = "时间";
            dataGridViewHD.Columns[2].Name = "NGç±»";
            dataGridViewHD.Columns[3].Name = "缺陷大小";
            this.dataGridViewHD.DataSource = RecordProductDatas;
            dataGridViewHD.AutoSizeColumnsMode = DataGridViewAutoSizeColumnsMode.Fill;
@@ -151,45 +135,68 @@
        {
            dateTimePickerEnd.MinDate = dateTimePickerStart.Value;
        }
        private void btnHisDataExport_Click(object sender, EventArgs e)
        public string OpenFileForSave()
        {
        }
        public void SaveToCSV(string filePath, int rowIndex)
        {
            // ä½¿ç”¨ StreamWriter æ¥å†™å…¥æ–‡ä»¶
            using (StreamWriter writer = new StreamWriter(filePath))
            using (SaveFileDialog saveFileDialog = new SaveFileDialog())
            {
                DataGridViewRow row = dataGridViewHD.Rows[rowIndex];
                // è®¾ç½®é»˜è®¤æ–‡ä»¶åå’Œæ‰©å±•名
                saveFileDialog.FileName = $"历史数据_{DateTime.Now:yyyyMMdd_HHmmss}";
                saveFileDialog.DefaultExt = "xlsx";
                int rowCount = 10;//10改为采集次数
                // è®¾ç½®æ–‡ä»¶è¿‡æ»¤å™¨
                saveFileDialog.Filter = "Excel文件 (*.xlsx)|*.xlsx|" +
                                        "CSV文件 (*.csv)|*.csv|" +
                                        "文本文件 (*.txt)|*.txt|" +
                                        "所有文件 (*.*)|*.*";
                writer.WriteLine("SN号, æ—¶é—´, NGç±», ç¼ºé™·å¤§å°");
                saveFileDialog.Title = "选择文件保存位置";
                saveFileDialog.RestoreDirectory = true;  // è®°ä½ä¸Šæ¬¡æ‰“开的目录
                saveFileDialog.OverwritePrompt = true;   // è¦†ç›–时提示
                // éåŽ†æ¯ä¸€è¡Œæ•°æ®
                for (int i = 0; i < rowCount; i++)
                if (saveFileDialog.ShowDialog() == DialogResult.OK)
                {
                    int batchSize = 4;
                    // å†™å…¥è¿™ä¸€æ‰¹æ¬¡çš„æ¯ä¸€åˆ—数据
                    for (int k = 0; k < batchSize; k++)
                    {
                        writer.Write($"{row.Cells[k].Value}");
                        // åœ¨å…ƒç´ ä¹‹é—´æ·»åŠ é€—å·ï¼Œé™¤éžè¿™æ˜¯æœ€åŽä¸€ä¸ªå…ƒç´ 
                        if (k < batchSize - 1)
                        {
                            writer.Write(",");
                        }
                    }
                    // å†™å…¥å®Œä¸€è¡ŒåŽï¼Œæ¢è¡Œ
                    writer.WriteLine();
                    string filePathHD = saveFileDialog.FileName;
                    return filePathHD;
                }
            }
            return null;
        }
        private void btnHisDataExport_Click(object sender, EventArgs e)
        {
            CsvDataHelperRecordProductData.SaveToCsv(OpenFileForSave(), RecordProductDatas);
        }
        private void btnHisDataFind_Click(object sender, EventArgs e)
        {
            DateTime startDate = dateTimePickerStart.Value.Date;
            DateTime endDate = dateTimePickerEnd.Value.Date;
            switch(comboBoxSearchBasis.SelectedIndex)
            {
                //依据日期查询
                case 0:
                    RecordProductDatas = RecordProductDataRepository.GetRecordsByTimeRange(DateTime.Parse(this.dateTimePickerStart.Value.ToString()), DateTime.Parse(this.dateTimePickerEnd.Value.ToString()));
                    break;
                //依据SN号查询
                case 1:
                    if(string.IsNullOrEmpty(textBoxSN.Text))
                    {
                        MessageBox.Show("请填写SN号!", "提示", MessageBoxButtons.OK, MessageBoxIcon.Warning);
                    }
                    else
                    {
                        RecordProductDatas = RecordProductDataRepository.GetRecordsByProductNumber(textBoxSN.Text);
                    }
                        break;
            }
            this.dataGridViewHD.DataSource = RecordProductDatas;
            this.dataGridViewHD.AutoGenerateColumns = true;
        }
    }
}
LB_SmartVision/Forms/Pages/MotionControlPage/MotionControlForm.Designer.cs
@@ -30,6 +30,7 @@
        {
            System.ComponentModel.ComponentResourceManager resources = new System.ComponentModel.ComponentResourceManager(typeof(MotionControlForm));
            uiGroupBoxMotionControl = new GroupBox();
            panel1 = new Panel();
            tableLayoutPanel3 = new TableLayoutPanel();
            tableLayoutPanel6 = new TableLayoutPanel();
            uiButtonCloseSoftGrab = new Button();
@@ -45,6 +46,12 @@
            textBoxAngSpeed = new TextBox();
            labelAngSpeed = new Label();
            textBoxPointSpeed = new TextBox();
            groupBoxPulseMotionSpeedAddress = new GroupBox();
            textBoxPulseMotionSpeedAddress = new TextBox();
            groupBoxAngularVelocityAddress = new GroupBox();
            textBoxAngularVelocityAddress = new TextBox();
            groupBoxCom = new GroupBox();
            cmbCom = new Sunny.UI.UIComboBox();
            tableLayoutPanel2 = new TableLayoutPanel();
            uiButtonIncreasePitchAngle = new Button();
            groupBoxPitchAnglePosition = new GroupBox();
@@ -62,26 +69,66 @@
            uiButtonDecreaseX = new Button();
            groupBoxXPosition = new GroupBox();
            textBoxXPosition = new TextBox();
            groupBoxYVarAddress = new GroupBox();
            textBoxYVarAddress = new TextBox();
            groupBoxXVarAddress = new GroupBox();
            textBoxXVarAddress = new TextBox();
            groupBoxZVarAddress = new GroupBox();
            textBoxZVarAddress = new TextBox();
            groupBoxWVarAddress = new GroupBox();
            textBoxWVarAddress = new TextBox();
            groupBoxYDetectLocation = new GroupBox();
            textBoxYDetectLocation = new TextBox();
            groupBoxZDetectLocation = new GroupBox();
            textBoxZDetectLocation = new TextBox();
            groupBoxWDetectLocation = new GroupBox();
            textBoxWDetectLocation = new TextBox();
            groupBoxXDetectLocation = new GroupBox();
            textBoxXDetectLocation = new TextBox();
            groupBoxXOriginalLocation = new GroupBox();
            textBoxXOriginalLocation = new TextBox();
            groupBoxYOriginalLocation = new GroupBox();
            textBoxYOriginalLocation = new TextBox();
            groupBoxZOriginalLocation = new GroupBox();
            textBoxZOriginalLocation = new TextBox();
            groupBoxWOriginalLocation = new GroupBox();
            textBoxWOriginalLocation = new TextBox();
            tableLayoutPanel1 = new TableLayoutPanel();
            textBox1 = new TextBox();
            textBoxSN = new TextBox();
            uiMarkLabelSN = new Label();
            tableLayoutPanel7 = new TableLayoutPanel();
            textBox2 = new TextBox();
            textBoxName = new TextBox();
            uiMarkLabelName = new Label();
            uiGroupBoxImage = new GroupBox();
            uiSplitContainer1 = new SplitContainer();
            themeForm1 = new ReaLTaiizor.Forms.ThemeForm();
            controlBox1 = new ReaLTaiizor.Controls.ControlBox();
            uiGroupBoxMotionControl.SuspendLayout();
            panel1.SuspendLayout();
            tableLayoutPanel3.SuspendLayout();
            tableLayoutPanel6.SuspendLayout();
            tableLayoutPanel5.SuspendLayout();
            tableLayoutPanel4.SuspendLayout();
            groupBoxPulseMotionSpeedAddress.SuspendLayout();
            groupBoxAngularVelocityAddress.SuspendLayout();
            groupBoxCom.SuspendLayout();
            tableLayoutPanel2.SuspendLayout();
            groupBoxPitchAnglePosition.SuspendLayout();
            groupBoxZPosition.SuspendLayout();
            groupBoxYPosition.SuspendLayout();
            groupBoxXPosition.SuspendLayout();
            groupBoxYVarAddress.SuspendLayout();
            groupBoxXVarAddress.SuspendLayout();
            groupBoxZVarAddress.SuspendLayout();
            groupBoxWVarAddress.SuspendLayout();
            groupBoxYDetectLocation.SuspendLayout();
            groupBoxZDetectLocation.SuspendLayout();
            groupBoxWDetectLocation.SuspendLayout();
            groupBoxXDetectLocation.SuspendLayout();
            groupBoxXOriginalLocation.SuspendLayout();
            groupBoxYOriginalLocation.SuspendLayout();
            groupBoxZOriginalLocation.SuspendLayout();
            groupBoxWOriginalLocation.SuspendLayout();
            tableLayoutPanel1.SuspendLayout();
            tableLayoutPanel7.SuspendLayout();
            ((System.ComponentModel.ISupportInitialize)uiSplitContainer1).BeginInit();
@@ -93,18 +140,29 @@
            // 
            // uiGroupBoxMotionControl
            // 
            uiGroupBoxMotionControl.Controls.Add(tableLayoutPanel3);
            uiGroupBoxMotionControl.Controls.Add(panel1);
            uiGroupBoxMotionControl.Dock = DockStyle.Fill;
            uiGroupBoxMotionControl.Font = new Font("宋体", 12F);
            uiGroupBoxMotionControl.ForeColor = SystemColors.Control;
            uiGroupBoxMotionControl.Location = new Point(0, 0);
            uiGroupBoxMotionControl.Margin = new Padding(4, 5, 4, 5);
            uiGroupBoxMotionControl.MinimumSize = new Size(1, 1);
            uiGroupBoxMotionControl.Name = "uiGroupBoxMotionControl";
            uiGroupBoxMotionControl.Padding = new Padding(0, 32, 0, 0);
            uiGroupBoxMotionControl.Size = new Size(374, 624);
            uiGroupBoxMotionControl.Padding = new Padding(0);
            uiGroupBoxMotionControl.Size = new Size(580, 684);
            uiGroupBoxMotionControl.TabIndex = 18;
            uiGroupBoxMotionControl.TabStop = false;
            uiGroupBoxMotionControl.Text = "运动控制参数";
            //
            // panel1
            //
            panel1.Controls.Add(tableLayoutPanel3);
            panel1.Dock = DockStyle.Fill;
            panel1.Location = new Point(0, 23);
            panel1.Name = "panel1";
            panel1.Padding = new Padding(0, 3, 0, 0);
            panel1.Size = new Size(580, 661);
            panel1.TabIndex = 1;
            // 
            // tableLayoutPanel3
            // 
@@ -116,16 +174,17 @@
            tableLayoutPanel3.Controls.Add(tableLayoutPanel2, 0, 4);
            tableLayoutPanel3.Controls.Add(tableLayoutPanel1, 0, 0);
            tableLayoutPanel3.Controls.Add(tableLayoutPanel7, 0, 1);
            tableLayoutPanel3.Location = new Point(0, 55);
            tableLayoutPanel3.Dock = DockStyle.Fill;
            tableLayoutPanel3.Location = new Point(0, 3);
            tableLayoutPanel3.Name = "tableLayoutPanel3";
            tableLayoutPanel3.RowCount = 6;
            tableLayoutPanel3.RowStyles.Add(new RowStyle(SizeType.Absolute, 45F));
            tableLayoutPanel3.RowStyles.Add(new RowStyle(SizeType.Absolute, 45F));
            tableLayoutPanel3.RowStyles.Add(new RowStyle(SizeType.Absolute, 45F));
            tableLayoutPanel3.RowStyles.Add(new RowStyle(SizeType.Absolute, 45F));
            tableLayoutPanel3.RowStyles.Add(new RowStyle(SizeType.Percent, 50F));
            tableLayoutPanel3.RowStyles.Add(new RowStyle(SizeType.Percent, 50F));
            tableLayoutPanel3.Size = new Size(374, 560);
            tableLayoutPanel3.RowStyles.Add(new RowStyle(SizeType.Absolute, 188F));
            tableLayoutPanel3.RowStyles.Add(new RowStyle(SizeType.Percent, 100F));
            tableLayoutPanel3.Size = new Size(580, 658);
            tableLayoutPanel3.TabIndex = 0;
            tableLayoutPanel3.Paint += tableLayoutPanel3_Paint;
            // 
@@ -141,14 +200,14 @@
            tableLayoutPanel6.Name = "tableLayoutPanel6";
            tableLayoutPanel6.RowCount = 1;
            tableLayoutPanel6.RowStyles.Add(new RowStyle(SizeType.Percent, 100F));
            tableLayoutPanel6.Size = new Size(368, 39);
            tableLayoutPanel6.Size = new Size(574, 39);
            tableLayoutPanel6.TabIndex = 6;
            // 
            // uiButtonCloseSoftGrab
            // 
            uiButtonCloseSoftGrab.Anchor = AnchorStyles.None;
            uiButtonCloseSoftGrab.BackColor = Color.Black;
            uiButtonCloseSoftGrab.Location = new Point(225, 5);
            uiButtonCloseSoftGrab.Location = new Point(379, 5);
            uiButtonCloseSoftGrab.Name = "uiButtonCloseSoftGrab";
            uiButtonCloseSoftGrab.Size = new Size(102, 29);
            uiButtonCloseSoftGrab.TabIndex = 2;
@@ -159,9 +218,9 @@
            // 
            uiButtonHardGrabWithPLC.Anchor = AnchorStyles.None;
            uiButtonHardGrabWithPLC.BackColor = Color.Black;
            uiButtonHardGrabWithPLC.Location = new Point(41, 5);
            uiButtonHardGrabWithPLC.Location = new Point(92, 3);
            uiButtonHardGrabWithPLC.Name = "uiButtonHardGrabWithPLC";
            uiButtonHardGrabWithPLC.Size = new Size(102, 29);
            uiButtonHardGrabWithPLC.Size = new Size(102, 33);
            uiButtonHardGrabWithPLC.TabIndex = 1;
            uiButtonHardGrabWithPLC.Text = "模拟采集";
            uiButtonHardGrabWithPLC.UseVisualStyleBackColor = false;
@@ -177,7 +236,7 @@
            tableLayoutPanel5.Name = "tableLayoutPanel5";
            tableLayoutPanel5.RowCount = 1;
            tableLayoutPanel5.RowStyles.Add(new RowStyle(SizeType.Percent, 50F));
            tableLayoutPanel5.Size = new Size(368, 39);
            tableLayoutPanel5.Size = new Size(574, 39);
            tableLayoutPanel5.TabIndex = 5;
            // 
            // uiButtonGrabOnce
@@ -186,7 +245,7 @@
            uiButtonGrabOnce.Dock = DockStyle.Fill;
            uiButtonGrabOnce.Location = new Point(3, 3);
            uiButtonGrabOnce.Name = "uiButtonGrabOnce";
            uiButtonGrabOnce.Size = new Size(362, 33);
            uiButtonGrabOnce.Size = new Size(568, 33);
            uiButtonGrabOnce.TabIndex = 0;
            uiButtonGrabOnce.Text = "单张采集";
            uiButtonGrabOnce.UseVisualStyleBackColor = false;
@@ -194,9 +253,11 @@
            // 
            // tableLayoutPanel4
            // 
            tableLayoutPanel4.ColumnCount = 2;
            tableLayoutPanel4.ColumnStyles.Add(new ColumnStyle(SizeType.Percent, 42.81768F));
            tableLayoutPanel4.ColumnStyles.Add(new ColumnStyle(SizeType.Percent, 57.18232F));
            tableLayoutPanel4.ColumnCount = 4;
            tableLayoutPanel4.ColumnStyles.Add(new ColumnStyle(SizeType.Absolute, 160F));
            tableLayoutPanel4.ColumnStyles.Add(new ColumnStyle(SizeType.Absolute, 160F));
            tableLayoutPanel4.ColumnStyles.Add(new ColumnStyle(SizeType.Absolute, 120F));
            tableLayoutPanel4.ColumnStyles.Add(new ColumnStyle(SizeType.Absolute, 120F));
            tableLayoutPanel4.Controls.Add(labelPointSpeed, 0, 0);
            tableLayoutPanel4.Controls.Add(textBoxAngleNow, 1, 3);
            tableLayoutPanel4.Controls.Add(labelAngleNow, 0, 3);
@@ -205,15 +266,20 @@
            tableLayoutPanel4.Controls.Add(textBoxAngSpeed, 1, 1);
            tableLayoutPanel4.Controls.Add(labelAngSpeed, 0, 1);
            tableLayoutPanel4.Controls.Add(textBoxPointSpeed, 1, 0);
            tableLayoutPanel4.Controls.Add(groupBoxPulseMotionSpeedAddress, 2, 0);
            tableLayoutPanel4.Controls.Add(groupBoxAngularVelocityAddress, 2, 1);
            tableLayoutPanel4.Controls.Add(groupBoxCom, 0, 4);
            tableLayoutPanel4.Dock = DockStyle.Fill;
            tableLayoutPanel4.Location = new Point(3, 373);
            tableLayoutPanel4.Location = new Point(3, 371);
            tableLayoutPanel4.Name = "tableLayoutPanel4";
            tableLayoutPanel4.RowCount = 4;
            tableLayoutPanel4.RowCount = 6;
            tableLayoutPanel4.RowStyles.Add(new RowStyle(SizeType.Absolute, 45F));
            tableLayoutPanel4.RowStyles.Add(new RowStyle(SizeType.Absolute, 45F));
            tableLayoutPanel4.RowStyles.Add(new RowStyle(SizeType.Absolute, 45F));
            tableLayoutPanel4.RowStyles.Add(new RowStyle(SizeType.Absolute, 45F));
            tableLayoutPanel4.Size = new Size(368, 184);
            tableLayoutPanel4.RowStyles.Add(new RowStyle(SizeType.Absolute, 60F));
            tableLayoutPanel4.RowStyles.Add(new RowStyle(SizeType.Percent, 100F));
            tableLayoutPanel4.Size = new Size(574, 284);
            tableLayoutPanel4.TabIndex = 2;
            // 
            // labelPointSpeed
@@ -223,7 +289,7 @@
            labelPointSpeed.Location = new Point(3, 5);
            labelPointSpeed.Margin = new Padding(3, 5, 3, 5);
            labelPointSpeed.Name = "labelPointSpeed";
            labelPointSpeed.Size = new Size(151, 35);
            labelPointSpeed.Size = new Size(154, 35);
            labelPointSpeed.TabIndex = 18;
            labelPointSpeed.Text = "点动速度(mm/s)";
            labelPointSpeed.TextAlign = ContentAlignment.MiddleLeft;
@@ -232,9 +298,9 @@
            // 
            textBoxAngleNow.Anchor = AnchorStyles.Left | AnchorStyles.Right;
            textBoxAngleNow.Enabled = false;
            textBoxAngleNow.Location = new Point(160, 144);
            textBoxAngleNow.Location = new Point(163, 142);
            textBoxAngleNow.Name = "textBoxAngleNow";
            textBoxAngleNow.Size = new Size(205, 30);
            textBoxAngleNow.Size = new Size(154, 30);
            textBoxAngleNow.TabIndex = 17;
            textBoxAngleNow.Text = "0";
            textBoxAngleNow.TextChanged += textBoxAngleNow_TextChanged;
@@ -246,7 +312,7 @@
            labelAngleNow.Location = new Point(3, 140);
            labelAngleNow.Margin = new Padding(3, 5, 3, 5);
            labelAngleNow.Name = "labelAngleNow";
            labelAngleNow.Size = new Size(151, 39);
            labelAngleNow.Size = new Size(154, 35);
            labelAngleNow.TabIndex = 16;
            labelAngleNow.Text = "当前角度(°)";
            labelAngleNow.TextAlign = ContentAlignment.MiddleLeft;
@@ -255,9 +321,9 @@
            // 
            textBoxPositionNow.Anchor = AnchorStyles.Left | AnchorStyles.Right;
            textBoxPositionNow.Enabled = false;
            textBoxPositionNow.Location = new Point(160, 97);
            textBoxPositionNow.Location = new Point(163, 97);
            textBoxPositionNow.Name = "textBoxPositionNow";
            textBoxPositionNow.Size = new Size(205, 30);
            textBoxPositionNow.Size = new Size(154, 30);
            textBoxPositionNow.TabIndex = 15;
            textBoxPositionNow.Text = "(0,0,0)";
            textBoxPositionNow.TextChanged += textBoxPositionNow_TextChanged;
@@ -269,7 +335,7 @@
            labelPositionNow.Location = new Point(3, 95);
            labelPositionNow.Margin = new Padding(3, 5, 3, 5);
            labelPositionNow.Name = "labelPositionNow";
            labelPositionNow.Size = new Size(151, 35);
            labelPositionNow.Size = new Size(154, 35);
            labelPositionNow.TabIndex = 14;
            labelPositionNow.Text = "当前点位(mm)";
            labelPositionNow.TextAlign = ContentAlignment.MiddleLeft;
@@ -277,9 +343,9 @@
            // textBoxAngSpeed
            // 
            textBoxAngSpeed.Anchor = AnchorStyles.Left | AnchorStyles.Right;
            textBoxAngSpeed.Location = new Point(160, 52);
            textBoxAngSpeed.Location = new Point(163, 52);
            textBoxAngSpeed.Name = "textBoxAngSpeed";
            textBoxAngSpeed.Size = new Size(205, 30);
            textBoxAngSpeed.Size = new Size(154, 30);
            textBoxAngSpeed.TabIndex = 13;
            textBoxAngSpeed.Text = "0";
            textBoxAngSpeed.TextChanged += textBoxAngSpeed_TextChanged;
@@ -293,7 +359,7 @@
            labelAngSpeed.Location = new Point(3, 50);
            labelAngSpeed.Margin = new Padding(3, 5, 3, 5);
            labelAngSpeed.Name = "labelAngSpeed";
            labelAngSpeed.Size = new Size(151, 35);
            labelAngSpeed.Size = new Size(154, 35);
            labelAngSpeed.TabIndex = 12;
            labelAngSpeed.Text = "角速度(rad/s)";
            labelAngSpeed.TextAlign = ContentAlignment.MiddleLeft;
@@ -301,21 +367,106 @@
            // textBoxPointSpeed
            // 
            textBoxPointSpeed.Anchor = AnchorStyles.Left | AnchorStyles.Right;
            textBoxPointSpeed.Location = new Point(160, 7);
            textBoxPointSpeed.Location = new Point(163, 7);
            textBoxPointSpeed.Name = "textBoxPointSpeed";
            textBoxPointSpeed.Size = new Size(205, 30);
            textBoxPointSpeed.Size = new Size(154, 30);
            textBoxPointSpeed.TabIndex = 11;
            textBoxPointSpeed.Text = "0";
            textBoxPointSpeed.TextChanged += textBoxPointSpeed_TextChanged;
            textBoxPointSpeed.KeyDown += textBoxXPosition_KeyDown;
            textBoxPointSpeed.KeyPress += textBoxXPosition_KeyPress;
            // 
            // groupBoxPulseMotionSpeedAddress
            //
            groupBoxPulseMotionSpeedAddress.Controls.Add(textBoxPulseMotionSpeedAddress);
            groupBoxPulseMotionSpeedAddress.Dock = DockStyle.Fill;
            groupBoxPulseMotionSpeedAddress.Font = new Font("宋体", 8F);
            groupBoxPulseMotionSpeedAddress.ForeColor = Color.White;
            groupBoxPulseMotionSpeedAddress.Location = new Point(323, 3);
            groupBoxPulseMotionSpeedAddress.Name = "groupBoxPulseMotionSpeedAddress";
            groupBoxPulseMotionSpeedAddress.Size = new Size(114, 39);
            groupBoxPulseMotionSpeedAddress.TabIndex = 30;
            groupBoxPulseMotionSpeedAddress.TabStop = false;
            groupBoxPulseMotionSpeedAddress.Text = "点速度地址";
            //
            // textBoxPulseMotionSpeedAddress
            //
            textBoxPulseMotionSpeedAddress.Dock = DockStyle.Bottom;
            textBoxPulseMotionSpeedAddress.Font = new Font("宋体", 10F);
            textBoxPulseMotionSpeedAddress.Location = new Point(3, 16);
            textBoxPulseMotionSpeedAddress.Multiline = true;
            textBoxPulseMotionSpeedAddress.Name = "textBoxPulseMotionSpeedAddress";
            textBoxPulseMotionSpeedAddress.Size = new Size(108, 20);
            textBoxPulseMotionSpeedAddress.TabIndex = 12;
            textBoxPulseMotionSpeedAddress.Text = "1";
            //
            // groupBoxAngularVelocityAddress
            //
            groupBoxAngularVelocityAddress.Controls.Add(textBoxAngularVelocityAddress);
            groupBoxAngularVelocityAddress.Dock = DockStyle.Fill;
            groupBoxAngularVelocityAddress.Font = new Font("宋体", 8F);
            groupBoxAngularVelocityAddress.ForeColor = Color.White;
            groupBoxAngularVelocityAddress.Location = new Point(323, 48);
            groupBoxAngularVelocityAddress.Name = "groupBoxAngularVelocityAddress";
            groupBoxAngularVelocityAddress.Size = new Size(114, 39);
            groupBoxAngularVelocityAddress.TabIndex = 30;
            groupBoxAngularVelocityAddress.TabStop = false;
            groupBoxAngularVelocityAddress.Text = "角速度地址";
            //
            // textBoxAngularVelocityAddress
            //
            textBoxAngularVelocityAddress.Dock = DockStyle.Bottom;
            textBoxAngularVelocityAddress.Font = new Font("宋体", 10F);
            textBoxAngularVelocityAddress.Location = new Point(3, 16);
            textBoxAngularVelocityAddress.Multiline = true;
            textBoxAngularVelocityAddress.Name = "textBoxAngularVelocityAddress";
            textBoxAngularVelocityAddress.Size = new Size(108, 20);
            textBoxAngularVelocityAddress.TabIndex = 12;
            textBoxAngularVelocityAddress.Text = "1";
            //
            // groupBoxCom
            //
            groupBoxCom.Controls.Add(cmbCom);
            groupBoxCom.Dock = DockStyle.Fill;
            groupBoxCom.Font = new Font("宋体", 9F, FontStyle.Regular, GraphicsUnit.Point, 134);
            groupBoxCom.ForeColor = Color.White;
            groupBoxCom.Location = new Point(3, 183);
            groupBoxCom.Name = "groupBoxCom";
            groupBoxCom.Size = new Size(154, 54);
            groupBoxCom.TabIndex = 31;
            groupBoxCom.TabStop = false;
            groupBoxCom.Text = "通讯";
            //
            // cmbCom
            //
            cmbCom.DataSource = null;
            cmbCom.Dock = DockStyle.Fill;
            cmbCom.DropDownStyle = Sunny.UI.UIDropDownStyle.DropDownList;
            cmbCom.FillColor = Color.White;
            cmbCom.Font = new Font("宋体", 12F, FontStyle.Regular, GraphicsUnit.Point, 134);
            cmbCom.ItemHoverColor = Color.FromArgb(155, 200, 255);
            cmbCom.ItemSelectForeColor = Color.FromArgb(235, 243, 255);
            cmbCom.Location = new Point(3, 21);
            cmbCom.Margin = new Padding(4, 5, 4, 5);
            cmbCom.MinimumSize = new Size(63, 0);
            cmbCom.Name = "cmbCom";
            cmbCom.Padding = new Padding(0, 0, 30, 2);
            cmbCom.Size = new Size(148, 30);
            cmbCom.SymbolSize = 24;
            cmbCom.TabIndex = 0;
            cmbCom.TextAlignment = ContentAlignment.MiddleLeft;
            cmbCom.Watermark = "";
            cmbCom.SelectedIndexChanged += cmbCom_SelectedIndexChanged;
            //
            // tableLayoutPanel2
            // 
            tableLayoutPanel2.ColumnCount = 3;
            tableLayoutPanel2.ColumnStyles.Add(new ColumnStyle(SizeType.Percent, 20F));
            tableLayoutPanel2.ColumnStyles.Add(new ColumnStyle(SizeType.Percent, 60F));
            tableLayoutPanel2.ColumnStyles.Add(new ColumnStyle(SizeType.Percent, 20F));
            tableLayoutPanel2.ColumnCount = 6;
            tableLayoutPanel2.ColumnStyles.Add(new ColumnStyle(SizeType.Absolute, 45F));
            tableLayoutPanel2.ColumnStyles.Add(new ColumnStyle(SizeType.Absolute, 100F));
            tableLayoutPanel2.ColumnStyles.Add(new ColumnStyle(SizeType.Absolute, 45F));
            tableLayoutPanel2.ColumnStyles.Add(new ColumnStyle(SizeType.Percent, 33.3333321F));
            tableLayoutPanel2.ColumnStyles.Add(new ColumnStyle(SizeType.Percent, 33.3333321F));
            tableLayoutPanel2.ColumnStyles.Add(new ColumnStyle(SizeType.Percent, 33.3333321F));
            tableLayoutPanel2.Controls.Add(uiButtonIncreasePitchAngle, 2, 3);
            tableLayoutPanel2.Controls.Add(groupBoxPitchAnglePosition, 1, 3);
            tableLayoutPanel2.Controls.Add(uiButtonDecreasePitchAngle, 0, 3);
@@ -328,6 +479,18 @@
            tableLayoutPanel2.Controls.Add(uiButtonIncreaseX, 2, 0);
            tableLayoutPanel2.Controls.Add(uiButtonDecreaseX, 0, 0);
            tableLayoutPanel2.Controls.Add(groupBoxXPosition, 1, 0);
            tableLayoutPanel2.Controls.Add(groupBoxYVarAddress, 3, 1);
            tableLayoutPanel2.Controls.Add(groupBoxXVarAddress, 3, 0);
            tableLayoutPanel2.Controls.Add(groupBoxZVarAddress, 3, 2);
            tableLayoutPanel2.Controls.Add(groupBoxWVarAddress, 3, 3);
            tableLayoutPanel2.Controls.Add(groupBoxYDetectLocation, 4, 1);
            tableLayoutPanel2.Controls.Add(groupBoxZDetectLocation, 4, 2);
            tableLayoutPanel2.Controls.Add(groupBoxWDetectLocation, 4, 3);
            tableLayoutPanel2.Controls.Add(groupBoxXDetectLocation, 4, 0);
            tableLayoutPanel2.Controls.Add(groupBoxXOriginalLocation, 5, 0);
            tableLayoutPanel2.Controls.Add(groupBoxYOriginalLocation, 5, 1);
            tableLayoutPanel2.Controls.Add(groupBoxZOriginalLocation, 5, 2);
            tableLayoutPanel2.Controls.Add(groupBoxWOriginalLocation, 5, 3);
            tableLayoutPanel2.Dock = DockStyle.Fill;
            tableLayoutPanel2.Location = new Point(3, 183);
            tableLayoutPanel2.Name = "tableLayoutPanel2";
@@ -336,17 +499,17 @@
            tableLayoutPanel2.RowStyles.Add(new RowStyle(SizeType.Absolute, 45F));
            tableLayoutPanel2.RowStyles.Add(new RowStyle(SizeType.Absolute, 45F));
            tableLayoutPanel2.RowStyles.Add(new RowStyle(SizeType.Absolute, 45F));
            tableLayoutPanel2.Size = new Size(368, 184);
            tableLayoutPanel2.Size = new Size(574, 182);
            tableLayoutPanel2.TabIndex = 3;
            // 
            // uiButtonIncreasePitchAngle
            // 
            uiButtonIncreasePitchAngle.BackColor = Color.Black;
            uiButtonIncreasePitchAngle.Dock = DockStyle.Left;
            uiButtonIncreasePitchAngle.Location = new Point(298, 140);
            uiButtonIncreasePitchAngle.Location = new Point(150, 140);
            uiButtonIncreasePitchAngle.Margin = new Padding(5);
            uiButtonIncreasePitchAngle.Name = "uiButtonIncreasePitchAngle";
            uiButtonIncreasePitchAngle.Size = new Size(32, 39);
            uiButtonIncreasePitchAngle.Size = new Size(32, 37);
            uiButtonIncreasePitchAngle.TabIndex = 27;
            uiButtonIncreasePitchAngle.Text = "+";
            uiButtonIncreasePitchAngle.UseVisualStyleBackColor = false;
@@ -355,12 +518,12 @@
            // groupBoxPitchAnglePosition
            // 
            groupBoxPitchAnglePosition.Controls.Add(textBoxPitchAnglePosition);
            groupBoxPitchAnglePosition.Dock = DockStyle.Fill;
            groupBoxPitchAnglePosition.Font = new Font("宋体", 8F);
            groupBoxPitchAnglePosition.ForeColor = Color.White;
            groupBoxPitchAnglePosition.Location = new Point(123, 138);
            groupBoxPitchAnglePosition.Margin = new Padding(50, 3, 3, 3);
            groupBoxPitchAnglePosition.Location = new Point(48, 138);
            groupBoxPitchAnglePosition.Name = "groupBoxPitchAnglePosition";
            groupBoxPitchAnglePosition.Size = new Size(115, 39);
            groupBoxPitchAnglePosition.Size = new Size(94, 41);
            groupBoxPitchAnglePosition.TabIndex = 26;
            groupBoxPitchAnglePosition.TabStop = false;
            groupBoxPitchAnglePosition.Text = "俯仰角(°)";
@@ -369,10 +532,10 @@
            // 
            textBoxPitchAnglePosition.Dock = DockStyle.Bottom;
            textBoxPitchAnglePosition.Font = new Font("宋体", 10F);
            textBoxPitchAnglePosition.Location = new Point(3, 16);
            textBoxPitchAnglePosition.Location = new Point(3, 18);
            textBoxPitchAnglePosition.Multiline = true;
            textBoxPitchAnglePosition.Name = "textBoxPitchAnglePosition";
            textBoxPitchAnglePosition.Size = new Size(109, 20);
            textBoxPitchAnglePosition.Size = new Size(88, 20);
            textBoxPitchAnglePosition.TabIndex = 13;
            textBoxPitchAnglePosition.Text = "1";
            textBoxPitchAnglePosition.KeyDown += textBoxXPosition_KeyDown;
@@ -382,10 +545,10 @@
            // 
            uiButtonDecreasePitchAngle.BackColor = Color.Black;
            uiButtonDecreasePitchAngle.Dock = DockStyle.Right;
            uiButtonDecreasePitchAngle.Location = new Point(37, 140);
            uiButtonDecreasePitchAngle.Location = new Point(9, 140);
            uiButtonDecreasePitchAngle.Margin = new Padding(5);
            uiButtonDecreasePitchAngle.Name = "uiButtonDecreasePitchAngle";
            uiButtonDecreasePitchAngle.Size = new Size(31, 39);
            uiButtonDecreasePitchAngle.Size = new Size(31, 37);
            uiButtonDecreasePitchAngle.TabIndex = 25;
            uiButtonDecreasePitchAngle.Text = "-";
            uiButtonDecreasePitchAngle.UseVisualStyleBackColor = false;
@@ -394,12 +557,12 @@
            // groupBoxZPosition
            // 
            groupBoxZPosition.Controls.Add(textBoxZPosition);
            groupBoxZPosition.Dock = DockStyle.Fill;
            groupBoxZPosition.Font = new Font("宋体", 8F);
            groupBoxZPosition.ForeColor = Color.White;
            groupBoxZPosition.Location = new Point(123, 93);
            groupBoxZPosition.Margin = new Padding(50, 3, 3, 3);
            groupBoxZPosition.Location = new Point(48, 93);
            groupBoxZPosition.Name = "groupBoxZPosition";
            groupBoxZPosition.Size = new Size(115, 39);
            groupBoxZPosition.Size = new Size(94, 39);
            groupBoxZPosition.TabIndex = 24;
            groupBoxZPosition.TabStop = false;
            groupBoxZPosition.Text = "Z(mm)";
@@ -411,7 +574,7 @@
            textBoxZPosition.Location = new Point(3, 16);
            textBoxZPosition.Multiline = true;
            textBoxZPosition.Name = "textBoxZPosition";
            textBoxZPosition.Size = new Size(109, 20);
            textBoxZPosition.Size = new Size(88, 20);
            textBoxZPosition.TabIndex = 13;
            textBoxZPosition.Text = "1";
            textBoxZPosition.KeyDown += textBoxXPosition_KeyDown;
@@ -420,12 +583,12 @@
            // groupBoxYPosition
            // 
            groupBoxYPosition.Controls.Add(textBoxYPosition);
            groupBoxYPosition.Dock = DockStyle.Fill;
            groupBoxYPosition.Font = new Font("宋体", 8F);
            groupBoxYPosition.ForeColor = Color.White;
            groupBoxYPosition.Location = new Point(123, 48);
            groupBoxYPosition.Margin = new Padding(50, 3, 3, 3);
            groupBoxYPosition.Location = new Point(48, 48);
            groupBoxYPosition.Name = "groupBoxYPosition";
            groupBoxYPosition.Size = new Size(115, 39);
            groupBoxYPosition.Size = new Size(94, 39);
            groupBoxYPosition.TabIndex = 23;
            groupBoxYPosition.TabStop = false;
            groupBoxYPosition.Text = "Y(mm)";
@@ -437,7 +600,7 @@
            textBoxYPosition.Location = new Point(3, 16);
            textBoxYPosition.Multiline = true;
            textBoxYPosition.Name = "textBoxYPosition";
            textBoxYPosition.Size = new Size(109, 20);
            textBoxYPosition.Size = new Size(88, 20);
            textBoxYPosition.TabIndex = 13;
            textBoxYPosition.Text = "1";
            textBoxYPosition.KeyDown += textBoxXPosition_KeyDown;
@@ -447,7 +610,7 @@
            // 
            uiButtonIncreaseZ.BackColor = Color.Black;
            uiButtonIncreaseZ.Dock = DockStyle.Left;
            uiButtonIncreaseZ.Location = new Point(298, 95);
            uiButtonIncreaseZ.Location = new Point(150, 95);
            uiButtonIncreaseZ.Margin = new Padding(5);
            uiButtonIncreaseZ.Name = "uiButtonIncreaseZ";
            uiButtonIncreaseZ.Size = new Size(32, 35);
@@ -460,7 +623,7 @@
            // 
            uiButtonDecreaseZ.BackColor = Color.Black;
            uiButtonDecreaseZ.Dock = DockStyle.Right;
            uiButtonDecreaseZ.Location = new Point(37, 95);
            uiButtonDecreaseZ.Location = new Point(9, 95);
            uiButtonDecreaseZ.Margin = new Padding(5);
            uiButtonDecreaseZ.Name = "uiButtonDecreaseZ";
            uiButtonDecreaseZ.Size = new Size(31, 35);
@@ -473,7 +636,7 @@
            // 
            uiButtonIncreaseY.BackColor = Color.Black;
            uiButtonIncreaseY.Dock = DockStyle.Left;
            uiButtonIncreaseY.Location = new Point(298, 50);
            uiButtonIncreaseY.Location = new Point(150, 50);
            uiButtonIncreaseY.Margin = new Padding(5);
            uiButtonIncreaseY.Name = "uiButtonIncreaseY";
            uiButtonIncreaseY.Size = new Size(32, 35);
@@ -486,7 +649,7 @@
            // 
            uiButtonDecreaseY.BackColor = Color.Black;
            uiButtonDecreaseY.Dock = DockStyle.Right;
            uiButtonDecreaseY.Location = new Point(37, 50);
            uiButtonDecreaseY.Location = new Point(9, 50);
            uiButtonDecreaseY.Margin = new Padding(5);
            uiButtonDecreaseY.Name = "uiButtonDecreaseY";
            uiButtonDecreaseY.Size = new Size(31, 35);
@@ -499,7 +662,7 @@
            // 
            uiButtonIncreaseX.BackColor = Color.Black;
            uiButtonIncreaseX.Dock = DockStyle.Left;
            uiButtonIncreaseX.Location = new Point(298, 5);
            uiButtonIncreaseX.Location = new Point(150, 5);
            uiButtonIncreaseX.Margin = new Padding(5);
            uiButtonIncreaseX.Name = "uiButtonIncreaseX";
            uiButtonIncreaseX.Size = new Size(32, 35);
@@ -512,7 +675,7 @@
            // 
            uiButtonDecreaseX.BackColor = Color.Black;
            uiButtonDecreaseX.Dock = DockStyle.Right;
            uiButtonDecreaseX.Location = new Point(37, 5);
            uiButtonDecreaseX.Location = new Point(9, 5);
            uiButtonDecreaseX.Margin = new Padding(5);
            uiButtonDecreaseX.Name = "uiButtonDecreaseX";
            uiButtonDecreaseX.Size = new Size(31, 35);
@@ -524,12 +687,12 @@
            // groupBoxXPosition
            // 
            groupBoxXPosition.Controls.Add(textBoxXPosition);
            groupBoxXPosition.Dock = DockStyle.Fill;
            groupBoxXPosition.Font = new Font("宋体", 8F);
            groupBoxXPosition.ForeColor = Color.White;
            groupBoxXPosition.Location = new Point(123, 3);
            groupBoxXPosition.Margin = new Padding(50, 3, 3, 3);
            groupBoxXPosition.Location = new Point(48, 3);
            groupBoxXPosition.Name = "groupBoxXPosition";
            groupBoxXPosition.Size = new Size(115, 39);
            groupBoxXPosition.Size = new Size(94, 39);
            groupBoxXPosition.TabIndex = 21;
            groupBoxXPosition.TabStop = false;
            groupBoxXPosition.Text = "X(mm)";
@@ -541,36 +704,324 @@
            textBoxXPosition.Location = new Point(3, 16);
            textBoxXPosition.Multiline = true;
            textBoxXPosition.Name = "textBoxXPosition";
            textBoxXPosition.Size = new Size(109, 20);
            textBoxXPosition.Size = new Size(88, 20);
            textBoxXPosition.TabIndex = 12;
            textBoxXPosition.Text = "1";
            textBoxXPosition.KeyDown += textBoxXPosition_KeyDown;
            textBoxXPosition.KeyPress += textBoxXPosition_KeyPress;
            //
            // groupBoxYVarAddress
            //
            groupBoxYVarAddress.Controls.Add(textBoxYVarAddress);
            groupBoxYVarAddress.Dock = DockStyle.Fill;
            groupBoxYVarAddress.Font = new Font("宋体", 8F);
            groupBoxYVarAddress.ForeColor = Color.White;
            groupBoxYVarAddress.Location = new Point(193, 48);
            groupBoxYVarAddress.Name = "groupBoxYVarAddress";
            groupBoxYVarAddress.Size = new Size(122, 39);
            groupBoxYVarAddress.TabIndex = 29;
            groupBoxYVarAddress.TabStop = false;
            groupBoxYVarAddress.Text = "Y轴变量地址";
            //
            // textBoxYVarAddress
            //
            textBoxYVarAddress.Dock = DockStyle.Bottom;
            textBoxYVarAddress.Font = new Font("宋体", 10F);
            textBoxYVarAddress.Location = new Point(3, 16);
            textBoxYVarAddress.Multiline = true;
            textBoxYVarAddress.Name = "textBoxYVarAddress";
            textBoxYVarAddress.Size = new Size(116, 20);
            textBoxYVarAddress.TabIndex = 12;
            textBoxYVarAddress.Text = "1";
            //
            // groupBoxXVarAddress
            //
            groupBoxXVarAddress.Controls.Add(textBoxXVarAddress);
            groupBoxXVarAddress.Dock = DockStyle.Fill;
            groupBoxXVarAddress.Font = new Font("宋体", 8F);
            groupBoxXVarAddress.ForeColor = Color.White;
            groupBoxXVarAddress.Location = new Point(193, 3);
            groupBoxXVarAddress.Name = "groupBoxXVarAddress";
            groupBoxXVarAddress.Size = new Size(122, 39);
            groupBoxXVarAddress.TabIndex = 28;
            groupBoxXVarAddress.TabStop = false;
            groupBoxXVarAddress.Text = "X轴变量地址";
            //
            // textBoxXVarAddress
            //
            textBoxXVarAddress.Dock = DockStyle.Bottom;
            textBoxXVarAddress.Font = new Font("宋体", 10F);
            textBoxXVarAddress.Location = new Point(3, 16);
            textBoxXVarAddress.Multiline = true;
            textBoxXVarAddress.Name = "textBoxXVarAddress";
            textBoxXVarAddress.Size = new Size(116, 20);
            textBoxXVarAddress.TabIndex = 12;
            textBoxXVarAddress.Text = "1";
            //
            // groupBoxZVarAddress
            //
            groupBoxZVarAddress.Controls.Add(textBoxZVarAddress);
            groupBoxZVarAddress.Dock = DockStyle.Fill;
            groupBoxZVarAddress.Font = new Font("宋体", 8F);
            groupBoxZVarAddress.ForeColor = Color.White;
            groupBoxZVarAddress.Location = new Point(193, 93);
            groupBoxZVarAddress.Name = "groupBoxZVarAddress";
            groupBoxZVarAddress.Size = new Size(122, 39);
            groupBoxZVarAddress.TabIndex = 29;
            groupBoxZVarAddress.TabStop = false;
            groupBoxZVarAddress.Text = "Z轴变量地址";
            //
            // textBoxZVarAddress
            //
            textBoxZVarAddress.Dock = DockStyle.Bottom;
            textBoxZVarAddress.Font = new Font("宋体", 10F);
            textBoxZVarAddress.Location = new Point(3, 16);
            textBoxZVarAddress.Multiline = true;
            textBoxZVarAddress.Name = "textBoxZVarAddress";
            textBoxZVarAddress.Size = new Size(116, 20);
            textBoxZVarAddress.TabIndex = 12;
            textBoxZVarAddress.Text = "1";
            //
            // groupBoxWVarAddress
            //
            groupBoxWVarAddress.Controls.Add(textBoxWVarAddress);
            groupBoxWVarAddress.Dock = DockStyle.Fill;
            groupBoxWVarAddress.Font = new Font("宋体", 8F);
            groupBoxWVarAddress.ForeColor = Color.White;
            groupBoxWVarAddress.Location = new Point(193, 138);
            groupBoxWVarAddress.Name = "groupBoxWVarAddress";
            groupBoxWVarAddress.Size = new Size(122, 41);
            groupBoxWVarAddress.TabIndex = 29;
            groupBoxWVarAddress.TabStop = false;
            groupBoxWVarAddress.Text = "W轴变量地址";
            //
            // textBoxWVarAddress
            //
            textBoxWVarAddress.Dock = DockStyle.Bottom;
            textBoxWVarAddress.Font = new Font("宋体", 10F);
            textBoxWVarAddress.Location = new Point(3, 18);
            textBoxWVarAddress.Multiline = true;
            textBoxWVarAddress.Name = "textBoxWVarAddress";
            textBoxWVarAddress.Size = new Size(116, 20);
            textBoxWVarAddress.TabIndex = 12;
            textBoxWVarAddress.Text = "1";
            //
            // groupBoxYDetectLocation
            //
            groupBoxYDetectLocation.Controls.Add(textBoxYDetectLocation);
            groupBoxYDetectLocation.Dock = DockStyle.Fill;
            groupBoxYDetectLocation.Font = new Font("宋体", 8F);
            groupBoxYDetectLocation.ForeColor = Color.White;
            groupBoxYDetectLocation.Location = new Point(321, 48);
            groupBoxYDetectLocation.Name = "groupBoxYDetectLocation";
            groupBoxYDetectLocation.Size = new Size(122, 39);
            groupBoxYDetectLocation.TabIndex = 30;
            groupBoxYDetectLocation.TabStop = false;
            groupBoxYDetectLocation.Text = "Y轴检测位置";
            //
            // textBoxYDetectLocation
            //
            textBoxYDetectLocation.Dock = DockStyle.Bottom;
            textBoxYDetectLocation.Font = new Font("宋体", 10F);
            textBoxYDetectLocation.Location = new Point(3, 16);
            textBoxYDetectLocation.Multiline = true;
            textBoxYDetectLocation.Name = "textBoxYDetectLocation";
            textBoxYDetectLocation.Size = new Size(116, 20);
            textBoxYDetectLocation.TabIndex = 12;
            textBoxYDetectLocation.Text = "1";
            //
            // groupBoxZDetectLocation
            //
            groupBoxZDetectLocation.Controls.Add(textBoxZDetectLocation);
            groupBoxZDetectLocation.Dock = DockStyle.Fill;
            groupBoxZDetectLocation.Font = new Font("宋体", 8F);
            groupBoxZDetectLocation.ForeColor = Color.White;
            groupBoxZDetectLocation.Location = new Point(321, 93);
            groupBoxZDetectLocation.Name = "groupBoxZDetectLocation";
            groupBoxZDetectLocation.Size = new Size(122, 39);
            groupBoxZDetectLocation.TabIndex = 30;
            groupBoxZDetectLocation.TabStop = false;
            groupBoxZDetectLocation.Text = "Z轴检测位置";
            //
            // textBoxZDetectLocation
            //
            textBoxZDetectLocation.Dock = DockStyle.Bottom;
            textBoxZDetectLocation.Font = new Font("宋体", 10F);
            textBoxZDetectLocation.Location = new Point(3, 16);
            textBoxZDetectLocation.Multiline = true;
            textBoxZDetectLocation.Name = "textBoxZDetectLocation";
            textBoxZDetectLocation.Size = new Size(116, 20);
            textBoxZDetectLocation.TabIndex = 12;
            textBoxZDetectLocation.Text = "1";
            //
            // groupBoxWDetectLocation
            //
            groupBoxWDetectLocation.Controls.Add(textBoxWDetectLocation);
            groupBoxWDetectLocation.Dock = DockStyle.Fill;
            groupBoxWDetectLocation.Font = new Font("宋体", 8F);
            groupBoxWDetectLocation.ForeColor = Color.White;
            groupBoxWDetectLocation.Location = new Point(321, 138);
            groupBoxWDetectLocation.Name = "groupBoxWDetectLocation";
            groupBoxWDetectLocation.Size = new Size(122, 41);
            groupBoxWDetectLocation.TabIndex = 30;
            groupBoxWDetectLocation.TabStop = false;
            groupBoxWDetectLocation.Text = "W轴检测位置";
            //
            // textBoxWDetectLocation
            //
            textBoxWDetectLocation.Dock = DockStyle.Bottom;
            textBoxWDetectLocation.Font = new Font("宋体", 10F);
            textBoxWDetectLocation.Location = new Point(3, 18);
            textBoxWDetectLocation.Multiline = true;
            textBoxWDetectLocation.Name = "textBoxWDetectLocation";
            textBoxWDetectLocation.Size = new Size(116, 20);
            textBoxWDetectLocation.TabIndex = 12;
            textBoxWDetectLocation.Text = "1";
            //
            // groupBoxXDetectLocation
            //
            groupBoxXDetectLocation.Controls.Add(textBoxXDetectLocation);
            groupBoxXDetectLocation.Dock = DockStyle.Fill;
            groupBoxXDetectLocation.Font = new Font("宋体", 8F);
            groupBoxXDetectLocation.ForeColor = Color.White;
            groupBoxXDetectLocation.Location = new Point(321, 3);
            groupBoxXDetectLocation.Name = "groupBoxXDetectLocation";
            groupBoxXDetectLocation.Size = new Size(122, 39);
            groupBoxXDetectLocation.TabIndex = 30;
            groupBoxXDetectLocation.TabStop = false;
            groupBoxXDetectLocation.Text = "X轴检测位置";
            //
            // textBoxXDetectLocation
            //
            textBoxXDetectLocation.Dock = DockStyle.Bottom;
            textBoxXDetectLocation.Font = new Font("宋体", 10F);
            textBoxXDetectLocation.Location = new Point(3, 16);
            textBoxXDetectLocation.Multiline = true;
            textBoxXDetectLocation.Name = "textBoxXDetectLocation";
            textBoxXDetectLocation.Size = new Size(116, 20);
            textBoxXDetectLocation.TabIndex = 12;
            textBoxXDetectLocation.Text = "1";
            //
            // groupBoxXOriginalLocation
            //
            groupBoxXOriginalLocation.Controls.Add(textBoxXOriginalLocation);
            groupBoxXOriginalLocation.Dock = DockStyle.Fill;
            groupBoxXOriginalLocation.Font = new Font("宋体", 8F);
            groupBoxXOriginalLocation.ForeColor = Color.White;
            groupBoxXOriginalLocation.Location = new Point(449, 3);
            groupBoxXOriginalLocation.Name = "groupBoxXOriginalLocation";
            groupBoxXOriginalLocation.Size = new Size(122, 39);
            groupBoxXOriginalLocation.TabIndex = 30;
            groupBoxXOriginalLocation.TabStop = false;
            groupBoxXOriginalLocation.Text = "X轴原点位置";
            //
            // textBoxXOriginalLocation
            //
            textBoxXOriginalLocation.Dock = DockStyle.Bottom;
            textBoxXOriginalLocation.Font = new Font("宋体", 10F);
            textBoxXOriginalLocation.Location = new Point(3, 16);
            textBoxXOriginalLocation.Multiline = true;
            textBoxXOriginalLocation.Name = "textBoxXOriginalLocation";
            textBoxXOriginalLocation.Size = new Size(116, 20);
            textBoxXOriginalLocation.TabIndex = 12;
            textBoxXOriginalLocation.Text = "1";
            //
            // groupBoxYOriginalLocation
            //
            groupBoxYOriginalLocation.Controls.Add(textBoxYOriginalLocation);
            groupBoxYOriginalLocation.Dock = DockStyle.Fill;
            groupBoxYOriginalLocation.Font = new Font("宋体", 8F);
            groupBoxYOriginalLocation.ForeColor = Color.White;
            groupBoxYOriginalLocation.Location = new Point(449, 48);
            groupBoxYOriginalLocation.Name = "groupBoxYOriginalLocation";
            groupBoxYOriginalLocation.Size = new Size(122, 39);
            groupBoxYOriginalLocation.TabIndex = 30;
            groupBoxYOriginalLocation.TabStop = false;
            groupBoxYOriginalLocation.Text = "Y轴原点位置";
            //
            // textBoxYOriginalLocation
            //
            textBoxYOriginalLocation.Dock = DockStyle.Bottom;
            textBoxYOriginalLocation.Font = new Font("宋体", 10F);
            textBoxYOriginalLocation.Location = new Point(3, 16);
            textBoxYOriginalLocation.Multiline = true;
            textBoxYOriginalLocation.Name = "textBoxYOriginalLocation";
            textBoxYOriginalLocation.Size = new Size(116, 20);
            textBoxYOriginalLocation.TabIndex = 12;
            textBoxYOriginalLocation.Text = "1";
            //
            // groupBoxZOriginalLocation
            //
            groupBoxZOriginalLocation.Controls.Add(textBoxZOriginalLocation);
            groupBoxZOriginalLocation.Dock = DockStyle.Fill;
            groupBoxZOriginalLocation.Font = new Font("宋体", 8F);
            groupBoxZOriginalLocation.ForeColor = Color.White;
            groupBoxZOriginalLocation.Location = new Point(449, 93);
            groupBoxZOriginalLocation.Name = "groupBoxZOriginalLocation";
            groupBoxZOriginalLocation.Size = new Size(122, 39);
            groupBoxZOriginalLocation.TabIndex = 30;
            groupBoxZOriginalLocation.TabStop = false;
            groupBoxZOriginalLocation.Text = "Z轴原点位置";
            //
            // textBoxZOriginalLocation
            //
            textBoxZOriginalLocation.Dock = DockStyle.Bottom;
            textBoxZOriginalLocation.Font = new Font("宋体", 10F);
            textBoxZOriginalLocation.Location = new Point(3, 16);
            textBoxZOriginalLocation.Multiline = true;
            textBoxZOriginalLocation.Name = "textBoxZOriginalLocation";
            textBoxZOriginalLocation.Size = new Size(116, 20);
            textBoxZOriginalLocation.TabIndex = 12;
            textBoxZOriginalLocation.Text = "1";
            //
            // groupBoxWOriginalLocation
            //
            groupBoxWOriginalLocation.Controls.Add(textBoxWOriginalLocation);
            groupBoxWOriginalLocation.Dock = DockStyle.Fill;
            groupBoxWOriginalLocation.Font = new Font("宋体", 8F);
            groupBoxWOriginalLocation.ForeColor = Color.White;
            groupBoxWOriginalLocation.Location = new Point(449, 138);
            groupBoxWOriginalLocation.Name = "groupBoxWOriginalLocation";
            groupBoxWOriginalLocation.Size = new Size(122, 41);
            groupBoxWOriginalLocation.TabIndex = 30;
            groupBoxWOriginalLocation.TabStop = false;
            groupBoxWOriginalLocation.Text = "W轴原点位置";
            //
            // textBoxWOriginalLocation
            //
            textBoxWOriginalLocation.Dock = DockStyle.Bottom;
            textBoxWOriginalLocation.Font = new Font("宋体", 10F);
            textBoxWOriginalLocation.Location = new Point(3, 18);
            textBoxWOriginalLocation.Multiline = true;
            textBoxWOriginalLocation.Name = "textBoxWOriginalLocation";
            textBoxWOriginalLocation.Size = new Size(116, 20);
            textBoxWOriginalLocation.TabIndex = 12;
            textBoxWOriginalLocation.Text = "1";
            // 
            // tableLayoutPanel1
            // 
            tableLayoutPanel1.ColumnCount = 2;
            tableLayoutPanel1.ColumnStyles.Add(new ColumnStyle(SizeType.Absolute, 75F));
            tableLayoutPanel1.ColumnStyles.Add(new ColumnStyle(SizeType.Percent, 100F));
            tableLayoutPanel1.Controls.Add(textBox1, 1, 0);
            tableLayoutPanel1.Controls.Add(textBoxSN, 1, 0);
            tableLayoutPanel1.Controls.Add(uiMarkLabelSN, 0, 0);
            tableLayoutPanel1.Dock = DockStyle.Fill;
            tableLayoutPanel1.Location = new Point(3, 3);
            tableLayoutPanel1.Name = "tableLayoutPanel1";
            tableLayoutPanel1.RowCount = 1;
            tableLayoutPanel1.RowStyles.Add(new RowStyle(SizeType.Percent, 100F));
            tableLayoutPanel1.Size = new Size(368, 39);
            tableLayoutPanel1.Size = new Size(574, 39);
            tableLayoutPanel1.TabIndex = 4;
            tableLayoutPanel1.Paint += tableLayoutPanel1_Paint;
            // 
            // textBox1
            // textBoxSN
            // 
            textBox1.Anchor = AnchorStyles.Left | AnchorStyles.Right;
            textBox1.Enabled = false;
            textBox1.Location = new Point(78, 4);
            textBox1.Name = "textBox1";
            textBox1.Size = new Size(287, 30);
            textBox1.TabIndex = 20;
            textBoxSN.Anchor = AnchorStyles.Left | AnchorStyles.Right;
            textBoxSN.Enabled = false;
            textBoxSN.Location = new Point(78, 4);
            textBoxSN.Name = "textBoxSN";
            textBoxSN.Size = new Size(493, 30);
            textBoxSN.TabIndex = 20;
            // 
            // uiMarkLabelSN
            // 
@@ -589,24 +1040,24 @@
            tableLayoutPanel7.ColumnCount = 2;
            tableLayoutPanel7.ColumnStyles.Add(new ColumnStyle(SizeType.Absolute, 75F));
            tableLayoutPanel7.ColumnStyles.Add(new ColumnStyle(SizeType.Percent, 100F));
            tableLayoutPanel7.Controls.Add(textBox2, 1, 0);
            tableLayoutPanel7.Controls.Add(textBoxName, 1, 0);
            tableLayoutPanel7.Controls.Add(uiMarkLabelName, 0, 0);
            tableLayoutPanel7.Dock = DockStyle.Fill;
            tableLayoutPanel7.Location = new Point(3, 48);
            tableLayoutPanel7.Name = "tableLayoutPanel7";
            tableLayoutPanel7.RowCount = 1;
            tableLayoutPanel7.RowStyles.Add(new RowStyle(SizeType.Percent, 100F));
            tableLayoutPanel7.Size = new Size(368, 39);
            tableLayoutPanel7.Size = new Size(574, 39);
            tableLayoutPanel7.TabIndex = 7;
            // 
            // textBox2
            // textBoxName
            // 
            textBox2.Anchor = AnchorStyles.Left | AnchorStyles.Right;
            textBox2.Enabled = false;
            textBox2.Location = new Point(78, 4);
            textBox2.Name = "textBox2";
            textBox2.Size = new Size(287, 30);
            textBox2.TabIndex = 21;
            textBoxName.Anchor = AnchorStyles.Left | AnchorStyles.Right;
            textBoxName.Enabled = false;
            textBoxName.Location = new Point(78, 4);
            textBoxName.Name = "textBoxName";
            textBoxName.Size = new Size(493, 30);
            textBoxName.TabIndex = 21;
            // 
            // uiMarkLabelName
            // 
@@ -630,7 +1081,7 @@
            uiGroupBoxImage.MinimumSize = new Size(1, 1);
            uiGroupBoxImage.Name = "uiGroupBoxImage";
            uiGroupBoxImage.Padding = new Padding(0, 32, 0, 0);
            uiGroupBoxImage.Size = new Size(495, 684);
            uiGroupBoxImage.Size = new Size(589, 684);
            uiGroupBoxImage.TabIndex = 17;
            uiGroupBoxImage.TabStop = false;
            uiGroupBoxImage.Text = "实时采集";
@@ -651,8 +1102,8 @@
            // uiSplitContainer1.Panel2
            // 
            uiSplitContainer1.Panel2.Controls.Add(uiGroupBoxImage);
            uiSplitContainer1.Size = new Size(880, 684);
            uiSplitContainer1.SplitterDistance = 374;
            uiSplitContainer1.Size = new Size(1180, 684);
            uiSplitContainer1.SplitterDistance = 580;
            uiSplitContainer1.SplitterWidth = 11;
            uiSplitContainer1.TabIndex = 20;
            // 
@@ -669,7 +1120,7 @@
            themeForm1.Padding = new Padding(10, 70, 10, 9);
            themeForm1.RoundCorners = true;
            themeForm1.Sizable = true;
            themeForm1.Size = new Size(900, 763);
            themeForm1.Size = new Size(1200, 763);
            themeForm1.SmartBounds = true;
            themeForm1.StartPosition = FormStartPosition.WindowsDefaultLocation;
            themeForm1.TabIndex = 21;
@@ -685,7 +1136,7 @@
            controlBox1.EnableMaximizeButton = true;
            controlBox1.EnableMinimizeButton = true;
            controlBox1.ForeColor = Color.FromArgb(155, 155, 155);
            controlBox1.Location = new Point(800, 18);
            controlBox1.Location = new Point(1100, 18);
            controlBox1.MaximizeHoverColor = Color.FromArgb(74, 74, 74);
            controlBox1.MinimizeHoverColor = Color.FromArgb(63, 63, 65);
            controlBox1.Name = "controlBox1";
@@ -698,7 +1149,7 @@
            AutoScaleDimensions = new SizeF(120F, 120F);
            AutoScaleMode = AutoScaleMode.Dpi;
            AutoSize = true;
            ClientSize = new Size(900, 763);
            ClientSize = new Size(1200, 763);
            Controls.Add(themeForm1);
            FormBorderStyle = FormBorderStyle.None;
            MinimumSize = new Size(261, 61);
@@ -706,11 +1157,17 @@
            Text = "运动控制设置";
            TransparencyKey = Color.Fuchsia;
            uiGroupBoxMotionControl.ResumeLayout(false);
            panel1.ResumeLayout(false);
            tableLayoutPanel3.ResumeLayout(false);
            tableLayoutPanel6.ResumeLayout(false);
            tableLayoutPanel5.ResumeLayout(false);
            tableLayoutPanel4.ResumeLayout(false);
            tableLayoutPanel4.PerformLayout();
            groupBoxPulseMotionSpeedAddress.ResumeLayout(false);
            groupBoxPulseMotionSpeedAddress.PerformLayout();
            groupBoxAngularVelocityAddress.ResumeLayout(false);
            groupBoxAngularVelocityAddress.PerformLayout();
            groupBoxCom.ResumeLayout(false);
            tableLayoutPanel2.ResumeLayout(false);
            groupBoxPitchAnglePosition.ResumeLayout(false);
            groupBoxPitchAnglePosition.PerformLayout();
@@ -720,6 +1177,30 @@
            groupBoxYPosition.PerformLayout();
            groupBoxXPosition.ResumeLayout(false);
            groupBoxXPosition.PerformLayout();
            groupBoxYVarAddress.ResumeLayout(false);
            groupBoxYVarAddress.PerformLayout();
            groupBoxXVarAddress.ResumeLayout(false);
            groupBoxXVarAddress.PerformLayout();
            groupBoxZVarAddress.ResumeLayout(false);
            groupBoxZVarAddress.PerformLayout();
            groupBoxWVarAddress.ResumeLayout(false);
            groupBoxWVarAddress.PerformLayout();
            groupBoxYDetectLocation.ResumeLayout(false);
            groupBoxYDetectLocation.PerformLayout();
            groupBoxZDetectLocation.ResumeLayout(false);
            groupBoxZDetectLocation.PerformLayout();
            groupBoxWDetectLocation.ResumeLayout(false);
            groupBoxWDetectLocation.PerformLayout();
            groupBoxXDetectLocation.ResumeLayout(false);
            groupBoxXDetectLocation.PerformLayout();
            groupBoxXOriginalLocation.ResumeLayout(false);
            groupBoxXOriginalLocation.PerformLayout();
            groupBoxYOriginalLocation.ResumeLayout(false);
            groupBoxYOriginalLocation.PerformLayout();
            groupBoxZOriginalLocation.ResumeLayout(false);
            groupBoxZOriginalLocation.PerformLayout();
            groupBoxWOriginalLocation.ResumeLayout(false);
            groupBoxWOriginalLocation.PerformLayout();
            tableLayoutPanel1.ResumeLayout(false);
            tableLayoutPanel1.PerformLayout();
            tableLayoutPanel7.ResumeLayout(false);
@@ -774,10 +1255,41 @@
        private TableLayoutPanel tableLayoutPanel5;
        private Button uiButtonGrabOnce;
        private TableLayoutPanel tableLayoutPanel1;
        private TextBox textBox1;
        private TextBox textBoxSN;
        private Label uiMarkLabelSN;
        private Button uiButtonCloseSoftGrab;
        private Label uiMarkLabelName;
        private TextBox textBox2;
        private TextBox textBoxName;
        private Panel panel1;
        private GroupBox groupBoxYVarAddress;
        private TextBox textBoxYVarAddress;
        private GroupBox groupBoxXVarAddress;
        private TextBox textBoxXVarAddress;
        private GroupBox groupBoxZVarAddress;
        private TextBox textBoxZVarAddress;
        private GroupBox groupBoxWVarAddress;
        private TextBox textBoxWVarAddress;
        private GroupBox groupBoxYDetectLocation;
        private TextBox textBoxYDetectLocation;
        private GroupBox groupBoxZDetectLocation;
        private TextBox textBoxZDetectLocation;
        private GroupBox groupBoxWDetectLocation;
        private TextBox textBoxWDetectLocation;
        private GroupBox groupBoxXDetectLocation;
        private TextBox textBoxXDetectLocation;
        private GroupBox groupBoxXOriginalLocation;
        private TextBox textBoxXOriginalLocation;
        private GroupBox groupBoxYOriginalLocation;
        private TextBox textBoxYOriginalLocation;
        private GroupBox groupBoxZOriginalLocation;
        private TextBox textBoxZOriginalLocation;
        private GroupBox groupBoxWOriginalLocation;
        private TextBox textBoxWOriginalLocation;
        private GroupBox groupBoxPulseMotionSpeedAddress;
        private TextBox textBoxPulseMotionSpeedAddress;
        private GroupBox groupBoxAngularVelocityAddress;
        private TextBox textBoxAngularVelocityAddress;
        private GroupBox groupBoxCom;
        private Sunny.UI.UIComboBox cmbCom;
    }
}
LB_SmartVision/Forms/Pages/MotionControlPage/MotionControlForm.cs
@@ -1,6 +1,8 @@
using LB_VisionControl;
using LB_SmartVisionCommon;
using LB_VisionControl;
using LB_VisionProcesses.Cameras;
using System;
using System.Collections.Concurrent;
using System.Collections.Generic;
using System.ComponentModel;
using System.Data;
@@ -12,6 +14,7 @@
using System.Threading.Tasks;
using System.Windows;
using System.Windows.Forms;
using System.Windows.Media.Media3D;
using static ZXing.QrCode.Internal.Mode;
namespace LB_SmartVision.Forms.Pages.MotionControlPage
@@ -20,10 +23,12 @@
    {
        BaseCamera camera { get; set; }
        UserPictureBox onlinePictureBox { get; set; }
        string communicatorsName { get; set; }
        public MotionControlForm()
        {
            InitializeComponent();
        }
        string cameraSN = string.Empty;
        public MotionControlForm(BaseCamera camera)
        {
@@ -34,8 +39,8 @@
            this.camera = camera;
            this.Text = camera.SN;
            textBox1.Text = camera.SN;
            textBoxSN.Text = camera.SN;
            cameraSN = camera.SN;
            onlinePictureBox = new UserPictureBox(uiGroupBoxImage);
            this.uiGroupBoxImage.Controls.Clear();
            this.uiGroupBoxImage.Controls.Add(onlinePictureBox);
@@ -43,8 +48,12 @@
            //加载回调函数
            Subscribe();
            foreach (var name in GlobalVar.dicCommunicators.Items.Keys)
            {
                cmbCom.Items.Add(name);
            }
        }
        ConcurrentDictionary<string, RecordMotionControlData> concurrentDictionary = new ConcurrentDictionary<string, RecordMotionControlData>();
        private void CameraForm_FormClosing(object sender, FormClosingEventArgs e)
        {
            if (camera == null)
@@ -53,7 +62,141 @@
            camera.StopGrabbing();
            camera.StartGrabbing();
            if (GlobalVar.dicMotionControlData.Keys.Contains(GlobalVar.strProductName))
            {
                concurrentDictionary = GlobalVar.dicMotionControlData[GlobalVar.strProductName];
                double xAxisDetectLocationValue, xAxisOriginalLocationValue, yAxisDetectLocationValue, yAxisOriginalLocationValue, zAxisDetectLocationValue, zAxisOriginalLocationValue, wAxisDetectLocationValue, wAxisOriginalLocationValue, pulseMotionSpeedValue, angularVelocityValue;
                xAxisDetectLocationValue = double.Parse(this.textBoxXDetectLocation.Text);
                xAxisOriginalLocationValue = double.Parse(this.textBoxXOriginalLocation.Text);
                yAxisDetectLocationValue = double.Parse(this.textBoxYDetectLocation.Text);
                yAxisOriginalLocationValue = double.Parse(this.textBoxYOriginalLocation.Text);
                zAxisDetectLocationValue = double.Parse(this.textBoxZDetectLocation.Text);
                zAxisOriginalLocationValue = double.Parse(this.textBoxZOriginalLocation.Text);
                wAxisDetectLocationValue = double.Parse(this.textBoxWDetectLocation.Text);
                wAxisOriginalLocationValue = double.Parse(this.textBoxWOriginalLocation.Text);
                pulseMotionSpeedValue = double.Parse(this.textBoxPointSpeed.Text);
                angularVelocityValue = double.Parse(this.textBoxPointSpeed.Text);
                if (concurrentDictionary.Keys.Contains(cameraSN))
                {
                    RecordMotionControlData recordMotionControlData = new RecordMotionControlData
                    {
                        ProductName = GlobalVar.strProductName,
                        CommunicatorsName = communicatorsName,
                        CameraSN = cameraSN,
                        XAxisAddress = this.textBoxXVarAddress.Text,
                        XAxisDetectLocationValue = xAxisDetectLocationValue,
                        XAxisOriginalLocationValue = xAxisOriginalLocationValue,
                        YAxisAddress = this.textBoxYVarAddress.Text,
                        YAxisDetectLocationValue = yAxisDetectLocationValue,
                        YAxisOriginalLocationValue = yAxisOriginalLocationValue,
                        ZAxisAddress = this.textBoxZVarAddress.Text,
                        ZAxisDetectLocationValue = zAxisDetectLocationValue,
                        ZAxisOriginalLocationValue = zAxisOriginalLocationValue,
                        WAxisAddress = this.textBoxWVarAddress.Text,
                        WAxisDetectLocationValue = wAxisDetectLocationValue,
                        WAxisOriginalLocationValue = wAxisOriginalLocationValue,
                        PulseMotionSpeedAddress = this.textBoxPulseMotionSpeedAddress.Text,
                        PulseMotionSpeedValue = pulseMotionSpeedValue,
                        AngularVelocityAddress = this.textBoxAngularVelocityAddress.Text,
                        AngularVelocityValue = angularVelocityValue
                    };
                    concurrentDictionary.TryAdd(cameraSN, recordMotionControlData);
                }
                else
                {
                    RecordMotionControlData recordMotionControlData = new RecordMotionControlData
                    {
                        ProductName = GlobalVar.strProductName,
                        CommunicatorsName = communicatorsName,
                        CameraSN = cameraSN,
                        XAxisAddress = this.textBoxXVarAddress.Text,
                        XAxisDetectLocationValue = xAxisDetectLocationValue,
                        XAxisOriginalLocationValue = xAxisOriginalLocationValue,
                        YAxisAddress = this.textBoxYVarAddress.Text,
                        YAxisDetectLocationValue = yAxisDetectLocationValue,
                        YAxisOriginalLocationValue = yAxisOriginalLocationValue,
                        ZAxisAddress = this.textBoxZVarAddress.Text,
                        ZAxisDetectLocationValue = zAxisDetectLocationValue,
                        ZAxisOriginalLocationValue = zAxisOriginalLocationValue,
                        WAxisAddress = this.textBoxWVarAddress.Text,
                        WAxisDetectLocationValue = wAxisDetectLocationValue,
                        WAxisOriginalLocationValue = wAxisOriginalLocationValue,
                        PulseMotionSpeedAddress = this.textBoxPulseMotionSpeedAddress.Text,
                        PulseMotionSpeedValue = pulseMotionSpeedValue,
                        AngularVelocityAddress = this.textBoxAngularVelocityAddress.Text,
                        AngularVelocityValue = angularVelocityValue
                    };
                    concurrentDictionary.TryAdd(cameraSN, recordMotionControlData);
                }
            }
            else
            {
                double xAxisDetectLocationValue, xAxisOriginalLocationValue, yAxisDetectLocationValue, yAxisOriginalLocationValue, zAxisDetectLocationValue, zAxisOriginalLocationValue, wAxisDetectLocationValue, wAxisOriginalLocationValue, pulseMotionSpeedValue, angularVelocityValue;
                xAxisDetectLocationValue = double.Parse(this.textBoxXDetectLocation.Text);
                xAxisOriginalLocationValue = double.Parse(this.textBoxXOriginalLocation.Text);
                yAxisDetectLocationValue = double.Parse(this.textBoxYDetectLocation.Text);
                yAxisOriginalLocationValue = double.Parse(this.textBoxYOriginalLocation.Text);
                zAxisDetectLocationValue = double.Parse(this.textBoxZDetectLocation.Text);
                zAxisOriginalLocationValue = double.Parse(this.textBoxZOriginalLocation.Text);
                wAxisDetectLocationValue = double.Parse(this.textBoxWDetectLocation.Text);
                wAxisOriginalLocationValue = double.Parse(this.textBoxWOriginalLocation.Text);
                pulseMotionSpeedValue = double.Parse(this.textBoxPointSpeed.Text);
                angularVelocityValue = double.Parse(this.textBoxPointSpeed.Text);
                if (concurrentDictionary.Keys.Contains(cameraSN))
                {
                    RecordMotionControlData recordMotionControlData = new RecordMotionControlData
                    {
                        ProductName = GlobalVar.strProductName,
                        CommunicatorsName = communicatorsName,
                        CameraSN = cameraSN,
                        XAxisAddress = this.textBoxXVarAddress.Text,
                        XAxisDetectLocationValue = xAxisDetectLocationValue,
                        XAxisOriginalLocationValue = xAxisOriginalLocationValue,
                        YAxisAddress = this.textBoxYVarAddress.Text,
                        YAxisDetectLocationValue = yAxisDetectLocationValue,
                        YAxisOriginalLocationValue = yAxisOriginalLocationValue,
                        ZAxisAddress = this.textBoxZVarAddress.Text,
                        ZAxisDetectLocationValue = zAxisDetectLocationValue,
                        ZAxisOriginalLocationValue = zAxisOriginalLocationValue,
                        WAxisAddress = this.textBoxWVarAddress.Text,
                        WAxisDetectLocationValue = wAxisDetectLocationValue,
                        WAxisOriginalLocationValue = wAxisOriginalLocationValue,
                        PulseMotionSpeedAddress = this.textBoxPulseMotionSpeedAddress.Text,
                        PulseMotionSpeedValue = pulseMotionSpeedValue,
                        AngularVelocityAddress = this.textBoxAngularVelocityAddress.Text,
                        AngularVelocityValue = angularVelocityValue
                    };
                    concurrentDictionary.TryAdd(cameraSN, recordMotionControlData);
                }
                else
                {
                    RecordMotionControlData recordMotionControlData = new RecordMotionControlData
                    {
                        ProductName = GlobalVar.strProductName,
                        CommunicatorsName = communicatorsName,
                        CameraSN = cameraSN,
                        XAxisAddress = this.textBoxXVarAddress.Text,
                        XAxisDetectLocationValue = xAxisDetectLocationValue,
                        XAxisOriginalLocationValue = xAxisOriginalLocationValue,
                        YAxisAddress = this.textBoxYVarAddress.Text,
                        YAxisDetectLocationValue = yAxisDetectLocationValue,
                        YAxisOriginalLocationValue = yAxisOriginalLocationValue,
                        ZAxisAddress = this.textBoxZVarAddress.Text,
                        ZAxisDetectLocationValue = zAxisDetectLocationValue,
                        ZAxisOriginalLocationValue = zAxisOriginalLocationValue,
                        WAxisAddress = this.textBoxWVarAddress.Text,
                        WAxisDetectLocationValue = wAxisDetectLocationValue,
                        WAxisOriginalLocationValue = wAxisOriginalLocationValue,
                        PulseMotionSpeedAddress = this.textBoxPulseMotionSpeedAddress.Text,
                        PulseMotionSpeedValue = pulseMotionSpeedValue,
                        AngularVelocityAddress = this.textBoxAngularVelocityAddress.Text,
                        AngularVelocityValue = angularVelocityValue
                    };
                    concurrentDictionary.TryAdd(cameraSN, recordMotionControlData);
                }
            }
            GlobalVar.dicMotionControlData.TryAdd(GlobalVar.strProductName, concurrentDictionary);
            ConfigManager<ConcurrentDictionary<string, ConcurrentDictionary<string, RecordMotionControlData>>>.SaveConfig<ConcurrentDictionary<string, ConcurrentDictionary<string, RecordMotionControlData>>>(GlobalVar.dicMotionControlData, GlobalVar.allMotionControlDataPath);
            Unsubscribe();
        }
@@ -370,5 +513,10 @@
        {
        }
        private void cmbCom_SelectedIndexChanged(object sender, EventArgs e)
        {
            communicatorsName = cmbCom.Text;
        }
    }
}
LB_SmartVision/Forms/Pages/MotionControlPage/MotionControlForm.resx
@@ -121,7 +121,7 @@
  <data name="themeForm1.Image" type="System.Drawing.Bitmap, System.Drawing" mimetype="application/x-microsoft.net.object.bytearray.base64">
    <value>
        iVBORw0KGgoAAAANSUhEUgAAACAAAAAgCAYAAABzenr0AAAABGdBTUEAALGPC/xhBQAAAAlwSFlzAAAO
        wgAADsIBFShKgAAAA+JJREFUWEftVkuIHGUQbt34iMEoq2S2q3p3yTJsuqpnJ+L6WBRdwaigohfFgEou
        vwAADr8BOAVTJAAAA+JJREFUWEftVkuIHGUQbt34iMEoq2S2q3p3yTJsuqpnJ+L6WBRdwaigohfFgEou
        BkVBUPCBCEG8BXNQ48GLeImCehIJxMsqhsSZruod46K4HtSIGjU+4iOr0c1I9fSsM3/PLNtCPO0H36m/
        evz/X11VnreKVRTAHPOZumkY6lFwqURws3BwZ8ywTQnuiCP/+iTCzY1qaUPzdm/Atf3PaHre6XPsjyQM
        2xLGV4XwIyX4QRj+UMK/lPFvJTyhBMeV8IgQvmRJuH4Ko+l5p9UjGBbCJ5RxTgj+VMZmXxKcSAjekHE/
LB_SmartVision/Forms/Pages/MotionControlPage/RecordMotionControlData.cs
¶Ô±ÈÐÂÎļþ
@@ -0,0 +1,93 @@
using Newtonsoft.Json;
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
namespace LB_SmartVision.Forms.Pages.MotionControlPage
{
    /// <summary>
    /// è®°å½•运动控制相关参数
    /// </summary>
    [JsonObject(MemberSerialization.OptOut)]
    public class RecordMotionControlData
    {
        /// <summary>
        /// äº§å“åç§°
        /// </summary>
        public required string ProductName { get; set; }
        /// <summary>
        /// é€šè®¯åç§°
        /// </summary>
        public required string CommunicatorsName { get; set; }
        /// <summary>
        /// ç›¸æœºåºåˆ—号
        /// </summary>
        public required string CameraSN { get; set; }
        /// <summary>
        /// Xè½´PLC地址
        /// </summary>
        public required string XAxisAddress { get; set; }
        /// <summary>
        /// Xè½´PLC检测位置值
        /// </summary>
        public required double XAxisDetectLocationValue { get; set; }
        /// <summary>
        /// Xè½´PLC原点位置值
        /// </summary>
        public required double XAxisOriginalLocationValue { get; set; }
        /// <summary>
        /// Yè½´PLC地址
        /// </summary>
        public required string YAxisAddress { get; set; }
        /// <summary>
        /// Yè½´PLC检测位置值
        /// </summary>
        public required double YAxisDetectLocationValue { get; set; }
        /// <summary>
        /// Yè½´PLC原点位置值
        /// </summary>
        public required double YAxisOriginalLocationValue { get; set; }
        /// <summary>
        /// Zè½´PLC地址
        /// </summary>
        public required string ZAxisAddress { get; set; }
        /// <summary>
        /// Zè½´PLC检测位置值
        /// </summary>
        public required double ZAxisDetectLocationValue { get; set; }
        /// <summary>
        /// Zè½´PLC原点位置值
        /// </summary>
        public required double ZAxisOriginalLocationValue { get; set; }
        /// <summary>
        /// Wè½´PLC地址
        /// </summary>
        public required string WAxisAddress { get; set; }
        /// <summary>
        /// Wè½´PLC检测位置值
        /// </summary>
        public required double WAxisDetectLocationValue { get; set; }
        /// <summary>
        /// Wè½´PLC原点位置值
        /// </summary>
        public required double WAxisOriginalLocationValue { get; set; }
        /// <summary>
        /// ç‚¹åŠ¨é€Ÿåº¦åœ°å€
        /// </summary>
        public required string PulseMotionSpeedAddress { get; set; }
        /// <summary>
        /// ç‚¹åŠ¨é€Ÿåº¦å€¼
        /// </summary>
        public required double PulseMotionSpeedValue { get; set; }
        /// <summary>
        /// è§’速度地址
        /// </summary>
        public required string AngularVelocityAddress { get; set; }
        /// <summary>
        /// è§’速度值
        /// </summary>
        public required double AngularVelocityValue { get; set; }
    }
}
LB_SmartVision/Forms/Pages/ProcessPage/AllProcessesPage.cs
@@ -9,7 +9,12 @@
    public partial class AllProcessesPage : TabPage
    {
        public ObservableConcurrentDictionary<string, ProcessControl> dicProcessControls = new ObservableConcurrentDictionary<string, ProcessControl>();
        // ä¿å­˜æŽ§ä»¶åŽŸå§‹å¸ƒå±€ï¼ˆå°ºå¯¸+位置),用于恢复矩阵布局
        private Dictionary<string, (Size Size, Point Location)> _originalControlLayouts = new Dictionary<string, (Size, Point)>();
        // æ ‡è®°æ˜¯å¦å¤„于全屏状态
        private bool _isFullScreen = false;
        // è®°å½•当前全屏的控件标题
        private string _fullScreenControlTitle = string.Empty;
        /// <summary>
        /// å®žä¾‹åŒ–流程界面
        /// </summary>
@@ -49,8 +54,16 @@
                {
                    if (dicProcessControls.ContainsKey(title))
                    {
                        // ç§»é™¤å‰å…ˆè§£ç»‘事件,避免内存泄漏
                        var control = dicProcessControls[title];
                        control.event_MouseDoubleClick -= ProcessControl_DoubleClick;
                        this.controlsPanel.Controls.Remove(dicProcessControls[title]);
                        dicProcessControls.TryRemove(title, out _);
                        // ç§»é™¤åŽŸå§‹å¸ƒå±€è®°å½•
                        if (_originalControlLayouts.ContainsKey(title))
                            _originalControlLayouts.Remove(title);
                    }
                }
            }
@@ -61,45 +74,142 @@
                if (GlobalVar.dicProcesses.ContainsKey(layout.ProcessName))
                    enableLayout++;
            }
            //总行数,向下取整
            int matrixRows = (int)Math.Floor(Math.Sqrt(enableLayout));
            if (enableLayout == 0 || matrixRows == 0)
            {
                _originalControlLayouts.Clear();
                _isFullScreen = false;
                _fullScreenControlTitle = string.Empty;
                // æ— å¯ç”¨å¸ƒå±€æ—¶ç›´æŽ¥è¿”回,避免除零错误
                return;
            }
            //总列数,向上取整
            int matrixColumns = (int)Math.Ceiling((double)enableLayout / matrixRows);
            int index = 0;
            // è®¡ç®—每个ProcessControl的尺寸(按行列均分面板大小)
            int controlWidth = this.controlsPanel.Width / matrixColumns;
            int controlHeight = this.controlsPanel.Height / matrixRows;
            // æ¯æ¬¡é‡æž„布局时清空原始记录
            _originalControlLayouts.Clear();
            for (int i = 0; i < GlobalVar.dicLayout.Count; i++)
            {
                string name = GlobalVar.dicLayout[i].ProcessName;
                string title = GlobalVar.dicLayout[i].Title;
                if (GlobalVar.dicProcesses.ContainsKey(name))
                {
                    // è®¡ç®—当前控件的行列索引
                    int colIndex = index % matrixColumns; // åˆ—索引(0,1,0,1...)
                    int rowIndex = index / matrixColumns; // è¡Œç´¢å¼•(0,0,1,1...)
                                                          // è®¡ç®—原始位置和尺寸(矩阵布局)
                    Size originalSize = new Size(controlWidth, controlHeight);
                    Point originalLocation = new Point(colIndex * controlWidth, rowIndex * controlHeight);
                    ProcessControl processControl;
                    if (dicProcessControls.ContainsKey(title))
                    {
                        ProcessControl processControl = dicProcessControls[title];
                        processControl.Size
                            = new Size(this.controlsPanel.Size.Width / enableLayout
                            , this.controlsPanel.Size.Height);
                        processControl.Location
                            = new Point(processControl.Size.Width * index, 0);
                        if (GlobalVar.dicProcesses[name].GetImage(GlobalVar.dicLayout[i], out _, out HObject RecordImage))
                            dicProcessControls[title].ShowHoImage(RecordImage);
                        // å¤ç”¨å·²æœ‰æŽ§ä»¶ï¼Œæ›´æ–°å°ºå¯¸å’Œä½ç½®
                        processControl = dicProcessControls[title];
                        processControl.Size = originalSize;
                        processControl.Location = originalLocation;
                        processControl.Visible = true;
                        // è§£ç»‘旧事件,避免重复绑定
                        processControl.event_MouseDoubleClick -= ProcessControl_DoubleClick;
                    }
                    else
                    {
                        ProcessControl processControl = new ProcessControl(GlobalVar.dicLayout[i]);
                        processControl.Size
                            = new Size(this.controlsPanel.Size.Width / enableLayout
                            , this.controlsPanel.Size.Height);
                        processControl.Location
                            = new Point(processControl.Size.Width * index, 0);
                        // æ–°å»ºæŽ§ä»¶ï¼ŒæŒ‰çŸ©é˜µå¸ƒå±€èµ‹å€¼å°ºå¯¸å’Œä½ç½®
                        processControl = new ProcessControl(GlobalVar.dicLayout[i]);
                        processControl.Size = originalSize;
                        processControl.Location = originalLocation;
                        processControl.SetTitle(title);
                        // æ·»åŠ åˆ°å­—å…¸å’Œé¢æ¿
                        dicProcessControls.TryAdd(title, processControl);
                        this.controlsPanel.Controls.Add(processControl);
                        if (GlobalVar.dicProcesses[name].GetImage(GlobalVar.dicLayout[i], out _, out HObject RecordImage))
                            dicProcessControls[title].ShowHoImage(RecordImage);
                    }
                    index++;
                    // ç»‘定双击事件(左键)和鼠标按下事件(右键双击)
                    processControl.event_MouseDoubleClick += ProcessControl_DoubleClick;
                    // ä¿å­˜åŽŸå§‹å¸ƒå±€ï¼ˆçŸ©é˜µçŠ¶æ€ï¼‰
                    _originalControlLayouts[title] = (originalSize, originalLocation);
                    // æ›´æ–°å›¾ç‰‡
                    if (GlobalVar.dicProcesses[name].GetImage(GlobalVar.dicLayout[i], out _, out HObject recordImage))
                        dicProcessControls[title].ShowHoImage(recordImage);
                    index++; // ä»…启用的布局索引递增
                }
            }
            // å¦‚果当前是全屏状态,恢复矩阵布局后重置状态
            if (_isFullScreen)
            {
                _isFullScreen = false;
                _fullScreenControlTitle = string.Empty;
            }
        }
        #region åŒå‡»äº‹ä»¶å¤„理(全屏/恢复布局)
        /// <summary>
        /// å·¦é”®åŒå‡»äº‹ä»¶ï¼šå…¨å±æ˜¾ç¤ºå½“前ProcessControl
        /// </summary>
        private void ProcessControl_DoubleClick(object sender, EventArgs e)
        {
            if (_isFullScreen)
            {
                RestoreMatrixLayout();
                return;
            }
            var targetControl = sender as ProcessControl;
            if (targetControl == null || string.IsNullOrEmpty(targetControl.Title)) return;
            // è®°å½•全屏的控件标题
            _fullScreenControlTitle = targetControl.Title;
            _isFullScreen = true;
            // éšè—æ‰€æœ‰å…¶ä»–ProcessControl,仅显示目标控件
            foreach (var kvp in dicProcessControls)
            {
                if (kvp.Key != _fullScreenControlTitle)
                {
                    kvp.Value.Visible = false;
                }
                else
                {
                    // ç›®æ ‡æŽ§ä»¶è®¾ä¸ºé¢æ¿å¤§å°ï¼Œä½ç½®(0,0)(全屏)
                    kvp.Value.Size = this.controlsPanel.Size;
                    kvp.Value.Location = new Point(0, 0);
                    kvp.Value.BringToFront(); // ç¡®ä¿åœ¨æœ€ä¸Šå±‚
                }
            }
        }
        /// <summary>
        /// æ¢å¤çŸ©é˜µå¸ƒå±€ï¼ˆå¤ç”¨InitVisionUI的核心逻辑,避免代码重复)
        /// </summary>
        private void RestoreMatrixLayout()
        {
            // 1. é‡ç½®å…¨å±çŠ¶æ€
            _isFullScreen = false;
            _fullScreenControlTitle = string.Empty;
            // 2. æ¢å¤æ‰€æœ‰æŽ§ä»¶çš„原始尺寸、位置和可见性
            foreach (var kvp in dicProcessControls)
            {
                string title = kvp.Key;
                var control = kvp.Value;
                // 3. ä»ŽåŽŸå§‹å¸ƒå±€å­—å…¸ä¸­æ¢å¤å°ºå¯¸å’Œä½ç½®
                if (_originalControlLayouts.TryGetValue(title, out var originalLayout))
                {
                    control.Size = originalLayout.Size;
                    control.Location = originalLayout.Location;
                }
                control.Visible = true; // æ˜¾ç¤ºæŽ§ä»¶
            }
        }
        #endregion
    }
}
LB_SmartVision/Forms/Pages/ProcessPage/ProcessControl.Designer.cs
@@ -71,6 +71,7 @@
            btnRun.Size = new Size(93, 24);
            btnRun.Text = "单次运行";
            btnRun.ToolTipText = "单次运行";
            btnRun.Visible = false;
            btnRun.Click += btnRun_Click;
            // 
            // btnCircleRun
@@ -82,6 +83,7 @@
            btnCircleRun.Size = new Size(93, 24);
            btnCircleRun.Text = "连续运行";
            btnCircleRun.ToolTipText = "连续";
            btnCircleRun.Visible = false;
            btnCircleRun.Click += btnCircleRun_Click;
            // 
            // panel1
@@ -156,7 +158,7 @@
            BackColor = Color.FromArgb(32, 41, 50);
            Controls.Add(uiPanel1);
            Controls.Add(toolStrip1);
            Margin = new Padding(4, 4, 4, 4);
            Margin = new Padding(4);
            Name = "ProcessControl";
            Size = new Size(450, 287);
            Load += ProcessControl_Load;
LB_SmartVision/Forms/Pages/ProcessPage/ProcessControl.cs
@@ -10,6 +10,35 @@
    {
        UserHSmartWindowControl UserHSmartWindowControl = new UserHSmartWindowControl();
        public event ProcessRunBllRun OnProcessRunBllRun;
        private void onProcessRunBllRun()
        {
            if (OnProcessRunBllRun != null)
            {
                OnProcessRunBllRun();
            }
        }
        public string Title = string.Empty;
        public event Control_MouseDown event_MouseDown;
        public event Control_MouseDoubleClick event_MouseDoubleClick;
        private void event_mouseDown(object sender, MouseEventArgs e)
        {
            if (event_MouseDown != null)
            {
                event_MouseDown(sender, e);
            }
        }
        private void event_mouseDoubleClick(object sender, MouseEventArgs e)
        {
            if (event_MouseDoubleClick != null)
            {
                event_MouseDoubleClick(this, e);
            }
        }
        ProcessRunBll ProcessRunBll
        {
            get
@@ -38,12 +67,13 @@
        {
            this.panel1.Controls.Add(this.UserHSmartWindowControl);
            this.UserHSmartWindowControl.Dock = DockStyle.Fill;
            this.UserHSmartWindowControl.event_MouseDoubleClick += event_mouseDoubleClick;
            this.UserHSmartWindowControl.event_MouseDown += event_mouseDown;
            SetTitle(_Layout.ProcessName);
            Title = _Layout.Title;
            if (ProcessRunBll != null)
                this.label1.Text = $"总数:{ProcessRunBll.total}";
            this.isClosed = false ;
            this.isClosed = false;
            var TaskPhotoContinue = Task.Factory.StartNew(() =>
            {
                ThreadCircleRun();
@@ -110,8 +140,8 @@
            if (isCircleRuning || ProcessRunBll.bRuning)
                ProcessRunBll.LogInfo($"{ProcessRunBll.Name}正在运行", LogInfoType.ERROR);
            ProcessRunBll.Run();
            //ProcessRunBll.Run();
            onProcessRunBllRun();
            msg = ProcessRunBll.Msg;
            return ProcessRunBll.Result;
        }
LB_SmartVision/Forms/Pages/ProcessPage/ProcessPage.cs
@@ -333,6 +333,16 @@
                        LogInfo?.Invoke(string.Format("流程[{0}]步骤\"{1}\"加载失败了", this.Text, ProcessName), LogInfoType.ERROR);
                    process.strProcessName = ProcessName;
                }
                else if (process is LB_VisionProcesses.Processes.BarcodeReaderProcess)
                {
                    LB_VisionProcesses.BarcodeReaders.BarcodeReaderForm barcodeForm
                        = new LB_VisionProcesses.BarcodeReaders.BarcodeReaderForm((LB_VisionProcesses.Processes.BarcodeReaderProcess)process, ProcessPath);
                    barcodeForm.ShowDialog();
                    if (!(process.Load(ProcessPath)))
                        LogInfo?.Invoke(string.Format("流程[{0}]步骤\"{1}\"加载失败了", this.Text, ProcessName), LogInfoType.ERROR);
                    process.strProcessName = ProcessName;
                }
                else if (ClassName.Contains("CommunicatorConfig") && process is CommunicatorConfig)
                {
                    LB_VisionProcesses.Communicators.CommunicatorForm communicatorForm
@@ -370,7 +380,11 @@
                ProcessRunBll.UpdataInputsAndOutputs(ProcessName, process);
            }
            catch (Exception ex) { Debug.WriteLine(ex.Message); }
            catch (Exception ex)
            {
                Debug.WriteLine(ex.Message);
                MessageBox.Show($"打开配置界面失败: {ex.Message}\n{ex.StackTrace}", "错误", MessageBoxButtons.OK, MessageBoxIcon.Error);
            }
        }
        private void AddBranch(string ProcessName)
LB_SmartVision/Forms/Pages/UserManagementPage/UserManagementEditPage.Designer.cs
@@ -50,10 +50,10 @@
            comboBoxPermission = new ComboBox();
            dataGridViewUM = new DataGridView();
            tableLayoutPanel4 = new TableLayoutPanel();
            btnEdit = new HopeButton();
            btnFind = new HopeButton();
            btnDel = new HopeButton();
            btnEdit = new HopeButton();
            btnAdd = new ForeverButton();
            btnDel = new HopeButton();
            grpSetting.SuspendLayout();
            tableLayoutPanel1.SuspendLayout();
            tableLayoutPanel2.SuspendLayout();
@@ -250,20 +250,40 @@
            // 
            tableLayoutPanel4.Anchor = AnchorStyles.Top | AnchorStyles.Right;
            tableLayoutPanel4.ColumnCount = 4;
            tableLayoutPanel4.ColumnStyles.Add(new ColumnStyle(SizeType.Percent, 25F));
            tableLayoutPanel4.ColumnStyles.Add(new ColumnStyle(SizeType.Percent, 25F));
            tableLayoutPanel4.ColumnStyles.Add(new ColumnStyle(SizeType.Percent, 25F));
            tableLayoutPanel4.ColumnStyles.Add(new ColumnStyle(SizeType.Percent, 25F));
            tableLayoutPanel4.Controls.Add(btnEdit, 1, 0);
            tableLayoutPanel4.ColumnStyles.Add(new ColumnStyle(SizeType.Percent, 20F));
            tableLayoutPanel4.ColumnStyles.Add(new ColumnStyle(SizeType.Percent, 20F));
            tableLayoutPanel4.ColumnStyles.Add(new ColumnStyle(SizeType.Percent, 20F));
            tableLayoutPanel4.ColumnStyles.Add(new ColumnStyle(SizeType.Percent, 20F));
            tableLayoutPanel4.Controls.Add(btnFind, 0, 0);
            tableLayoutPanel4.Controls.Add(btnDel, 3, 0);
            tableLayoutPanel4.Controls.Add(btnEdit, 1, 0);
            tableLayoutPanel4.Controls.Add(btnAdd, 2, 0);
            tableLayoutPanel4.Controls.Add(btnDel, 3, 0);
            tableLayoutPanel4.Location = new Point(457, 509);
            tableLayoutPanel4.Name = "tableLayoutPanel4";
            tableLayoutPanel4.RowCount = 1;
            tableLayoutPanel4.RowStyles.Add(new RowStyle(SizeType.Percent, 100F));
            tableLayoutPanel4.Size = new Size(400, 39);
            tableLayoutPanel4.TabIndex = 1;
            //
            // btnFind
            //
            btnFind.BorderColor = Color.FromArgb(220, 223, 230);
            btnFind.ButtonType = ReaLTaiizor.Util.HopeButtonType.Primary;
            btnFind.DangerColor = Color.FromArgb(245, 108, 108);
            btnFind.DefaultColor = Color.FromArgb(255, 255, 255);
            btnFind.Font = new Font("Segoe UI", 12F);
            btnFind.HoverTextColor = Color.FromArgb(48, 49, 51);
            btnFind.InfoColor = Color.FromArgb(144, 147, 153);
            btnFind.Location = new Point(3, 3);
            btnFind.Name = "btnFind";
            btnFind.PrimaryColor = Color.FromArgb(64, 158, 255);
            btnFind.Size = new Size(94, 33);
            btnFind.SuccessColor = Color.FromArgb(103, 194, 58);
            btnFind.TabIndex = 1;
            btnFind.Text = "查询";
            btnFind.TextColor = Color.White;
            btnFind.WarningColor = Color.FromArgb(230, 162, 60);
            btnFind.Click += btnFind_Click;
            // 
            // btnEdit
            // 
@@ -285,24 +305,19 @@
            btnEdit.WarningColor = Color.FromArgb(230, 162, 60);
            btnEdit.Click += btnEdit_Click;
            // 
            // btnFind
            // btnAdd
            // 
            btnFind.BorderColor = Color.FromArgb(220, 223, 230);
            btnFind.ButtonType = ReaLTaiizor.Util.HopeButtonType.Primary;
            btnFind.DangerColor = Color.FromArgb(245, 108, 108);
            btnFind.DefaultColor = Color.FromArgb(255, 255, 255);
            btnFind.Font = new Font("Segoe UI", 12F);
            btnFind.HoverTextColor = Color.FromArgb(48, 49, 51);
            btnFind.InfoColor = Color.FromArgb(144, 147, 153);
            btnFind.Location = new Point(3, 3);
            btnFind.Name = "btnFind";
            btnFind.PrimaryColor = Color.FromArgb(64, 158, 255);
            btnFind.Size = new Size(94, 33);
            btnFind.SuccessColor = Color.FromArgb(103, 194, 58);
            btnFind.TabIndex = 1;
            btnFind.Text = "查询";
            btnFind.TextColor = Color.White;
            btnFind.WarningColor = Color.FromArgb(230, 162, 60);
            btnAdd.BackColor = Color.Transparent;
            btnAdd.BaseColor = Color.FromArgb(35, 168, 109);
            btnAdd.Font = new Font("Segoe UI", 12F);
            btnAdd.Location = new Point(203, 3);
            btnAdd.Name = "btnAdd";
            btnAdd.Rounded = false;
            btnAdd.Size = new Size(94, 33);
            btnAdd.TabIndex = 4;
            btnAdd.Text = "添加";
            btnAdd.TextColor = Color.FromArgb(243, 243, 243);
            btnAdd.Click += btnAdd_Click;
            // 
            // btnDel
            // 
@@ -323,20 +338,6 @@
            btnDel.TextColor = Color.White;
            btnDel.WarningColor = Color.FromArgb(230, 162, 60);
            btnDel.Click += btnDel_Click;
            //
            // btnAdd
            //
            btnAdd.BackColor = Color.Transparent;
            btnAdd.BaseColor = Color.FromArgb(35, 168, 109);
            btnAdd.Font = new Font("Segoe UI", 12F);
            btnAdd.Location = new Point(203, 3);
            btnAdd.Name = "btnAdd";
            btnAdd.Rounded = false;
            btnAdd.Size = new Size(94, 33);
            btnAdd.TabIndex = 4;
            btnAdd.Text = "添加";
            btnAdd.TextColor = Color.FromArgb(243, 243, 243);
            btnAdd.Click += btnAdd_Click;
            // 
            // UserManagementEditPage
            // 
LB_SmartVision/Forms/Pages/UserManagementPage/UserManagementEditPage.cs
@@ -1,25 +1,27 @@
using LB_SmartVision.Forms.Pages.ProcessPage;
using LB_SmartVision.Forms.Pages.CameraPage;
using LB_SmartVision.Forms.Pages.ProcessPage;
using LB_SmartVision.Forms.Pages.SettingPage;
using LB_SmartVision.ProcessRun;
using LB_SmartVision.SQL;
using LB_SmartVisionCommon;
using LB_VisionControl;
using LB_VisionProcesses;
using Newtonsoft.Json;
using Newtonsoft.Json.Serialization;
using System.Collections.Concurrent;
using System.Data;
using System.Text;
using VisionControl.Forms;
using LB_SmartVision.Forms.Pages.SettingPage;
using LB_SmartVisionCommon;
using static System.Windows.Forms.VisualStyles.VisualStyleElement.StartPanel;
using LB_SmartVision.Forms.Pages.CameraPage;
using System.Security.Principal;
using System.Text;
using System.Windows.Forms;
using VisionControl.Forms;
using static System.Windows.Forms.VisualStyles.VisualStyleElement.StartPanel;
namespace LB_SmartVision.Forms.Pages.UserManagementPage
{
    public partial class UserManagementEditPage : UserControl
    {
        public Action<string, LogInfoType> LogInfo;
        List<RecordUserData> recordUserDatas = new List<RecordUserData>();
        public UserManagementEditPage()
        {
@@ -27,8 +29,9 @@
            Text = "用户管理设置";
            InitializeComponent();
            InitializeDataGridView();
            InitializeComboBox();
            InitializeDataGridView();
        }
        /// <summary>
@@ -36,42 +39,9 @@
        /// </summary>
        private void InitializeDataGridView()
        {
            this.dataGridViewUM.DataSource = recordUserDatas;
            // è®¾ç½®DataGridView列宽
            dataGridViewUM.ColumnCount = 4;
            int totalWidth = dataGridViewUM.ClientSize.Width;
            int columnCount = dataGridViewUM.ColumnCount;
            int columnWidth = totalWidth / columnCount;
            // è®¾ç½®æœ€å°å®½åº¦
            int minWidth = 100; // æœ€å°å®½åº¦
            if (columnWidth < minWidth)
            {
                columnWidth = minWidth;
            }
            for (int i = 0; i < columnCount; i++)
            {
                dataGridViewUM.Columns[i].Width = columnWidth;
            }
            // è®¾ç½®åˆ—标题
            dataGridViewUM.Columns[0].Name = "用户名";
            //dataGridViewUM.Columns[1].Name = "密码";
            dataGridViewUM.Columns[1].Name = "姓名";
            dataGridViewUM.Columns[2].Name = "工号";
            dataGridViewUM.Columns[3].Name = "权限";
            dataGridViewUM.AutoSizeColumnsMode = DataGridViewAutoSizeColumnsMode.Fill;
            // ç¦æ­¢ç¼–辑单元格(可选)
            dataGridViewUM.ReadOnly = true;
            // å…è®¸å¤šè¡Œé€‰æ‹©ï¼ˆå¯é€‰ï¼‰
            dataGridViewUM.MultiSelect = false;
            // æ˜¾ç¤ºè¡Œæ ‡é¢˜ï¼ˆå¯é€‰ï¼‰
            dataGridViewUM.RowHeadersVisible = true;
        }
        /// <summary>
@@ -99,6 +69,8 @@
            comboBoxPermission.SelectedIndex = 0;
            textBoxUsername.Focus(); // å°†ç„¦ç‚¹è®¾ç½®å›žç”¨æˆ·åè¾“入框
        }
        #region æ·»åŠ ç”¨æˆ·æŒ‰é’®
        private void btnAdd_Click(object sender, EventArgs e)
        {
            // éªŒè¯è¾“å…¥
@@ -112,41 +84,81 @@
                return;
            }
            // åˆ›å»ºæ–°è¡Œæ•°æ®
            string[] row = new string[]
            RecordUserData user = new RecordUserData();
            user.EmployeeNumber = this.textBoxEmployeeID.Text;
            user.EmployeeAccount = this.textBoxUsername.Text;
            user.EmployeePassword = this.textBoxPassword.Text;
            user.EmployeeName = this.textBoxName.Text;
            user.EmployeePermission = (UserPermission)this.comboBoxPermission.SelectedIndex;
            // æ·»åŠ åˆ° UserManager
            bool success = UserManager.Instance.AddUser(user);
            if (success)
            {
                textBoxUsername.Text,
                //textBoxPassword.Text, // å®žé™…应用中密码应该加密
                textBoxName.Text,
                textBoxEmployeeID.Text,
                comboBoxPermission.SelectedItem.ToString()
            };
                recordUserDatas.Add(user);
            // è®¾ç½®æ•´ä¸ªDataGridView的默认字体和颜色
            dataGridViewUM.DefaultCellStyle.Font = new Font("宋体", 12);
            dataGridViewUM.DefaultCellStyle.ForeColor = Color.Black;  // å­—体颜色
            dataGridViewUM.DefaultCellStyle.BackColor = Color.White;   // èƒŒæ™¯é¢œè‰²
                //MessageBox.Show("用户添加成功!", "提示",
                //    MessageBoxButtons.OK, MessageBoxIcon.Information);
            // æ·»åŠ æ–°è¡Œåˆ°DataGridView
            dataGridViewUM.Rows.Add(row);
                // æ¸…空输入框
                ClearInputFields();
            }
            else
            {
                MessageBox.Show("添加用户失败!", "错误",
                    MessageBoxButtons.OK, MessageBoxIcon.Error);
            }
            // æ¸…空输入框
            ClearInputFields();
        }
        #endregion
        #region åˆ é™¤ç”¨æˆ·æŒ‰é’®
        private void btnDel_Click(object sender, EventArgs e)
        {
            if (dataGridViewUM.SelectedRows.Count > 0)
            {
                // èŽ·å–é€‰ä¸­çš„è¡Œ
                DataGridViewRow selectedRow = dataGridViewUM.SelectedRows[0];
                // ç¡®è®¤åˆ é™¤
                DialogResult result = MessageBox.Show("确定要删除选中的行吗?",
                    "确认删除", MessageBoxButtons.YesNo, MessageBoxIcon.Question);
                if (result == DialogResult.Yes)
                {
                    foreach (DataGridViewRow row in dataGridViewUM.SelectedRows)
                    try
                    {
                        dataGridViewUM.Rows.Remove(row);
                        // å…ˆèŽ·å–è¦åˆ é™¤çš„æ•°æ®
                        string employeeNumber = selectedRow.Cells[0].Value?.ToString();
                        if (!string.IsNullOrEmpty(employeeNumber))
                        {
                            // 1. ä»Žæ•°æ®æºåˆ é™¤
                            var dataSource = dataGridViewUM.DataSource as List<RecordUserData>;
                            if (dataSource != null)
                            {
                                var itemToRemove = dataSource.FirstOrDefault(u => u.EmployeeNumber == employeeNumber);
                                if (itemToRemove != null)
                                {
                                    dataSource.Remove(itemToRemove);
                                }
                            }
                            // 2. ä»Žç”¨æˆ·ç®¡ç†å™¨åˆ é™¤
                            UserManager.Instance.DeleteUser(employeeNumber);
                            // 3. åˆ·æ–°æ•°æ®ç»‘定
                            dataGridViewUM.DataSource = null;
                            dataGridViewUM.DataSource = dataSource;
                            //MessageBox.Show("删除成功!", "提示",
                            //    MessageBoxButtons.OK, MessageBoxIcon.Information);
                        }
                    }
                    catch (Exception ex)
                    {
                        MessageBox.Show($"删除失败: {ex.Message}", "错误",
                            MessageBoxButtons.OK, MessageBoxIcon.Error);
                    }
                }
            }
@@ -156,9 +168,11 @@
                    MessageBoxButtons.OK, MessageBoxIcon.Information);
            }
        }
        #endregion
        private int editingRowIndex = -1;
        private bool isEditingMode = false;
        private string originalButtonText = "修改";
        #region ä¿®æ”¹ç”¨æˆ·ä¿¡æ¯
        private void btnEdit_Click(object sender, EventArgs e)
        {
            // å•元格可编辑
@@ -227,8 +241,16 @@
                // æ¸…空输入框
                ClearInputFields();
                MessageBox.Show("修改完成!", "提示",
                    MessageBoxButtons.OK, MessageBoxIcon.Information);
                RecordUserData user = new RecordUserData();
                user.EmployeeNumber = this.textBoxEmployeeID.Text;
                user.EmployeeAccount = this.textBoxUsername.Text;
                user.EmployeePassword = this.textBoxPassword.Text;
                user.EmployeeName = this.textBoxName.Text;
                user.EmployeePermission = (UserPermission)this.comboBoxPermission.SelectedIndex;
                UserManager.Instance.UpdateUser(user);
                //MessageBox.Show("修改完成!", "提示",
                //    MessageBoxButtons.OK, MessageBoxIcon.Information);
            }
        }
@@ -277,7 +299,6 @@
                //textBoxPassword.PlaceholderText = "如需修改密码请填写";
            }
        }
        private void UpdateRowData(int rowIndex)
        {
            if (rowIndex >= 0 && rowIndex < dataGridViewUM.Rows.Count)
@@ -304,5 +325,17 @@
                row.Cells[3].Value = comboBoxPermission.SelectedItem.ToString();
            }
        }
        #endregion
        #region æŸ¥è¯¢ç”¨æˆ·ä¿¡æ¯
        private void btnFind_Click(object sender, EventArgs e)
        {
            List<RecordUserData> recordUserDatas = UserManager.Instance.GetAllUsers();
            this.dataGridViewUM.DataSource = recordUserDatas;
            this.dataGridViewUM.AutoGenerateColumns = true;
        }
        #endregion
    }
}
LB_SmartVision/GlobalVar.cs
@@ -1,8 +1,10 @@
using LB_SmartVision.Forms.Pages.SettingPage;
using LB_SmartVision.Forms.Pages.MotionControlPage;
using LB_SmartVision.Forms.Pages.SettingPage;
using LB_SmartVision.ProcessRun;
using LB_SmartVision.Tool;
using LB_VisionProcesses.Cameras;
using LB_VisionProcesses.Communicators;
using LB_VisionProcesses.BarcodeReaders;
using System;
using System.Collections.Concurrent;
using System.Collections.Generic;
@@ -38,6 +40,11 @@
        public static ObservableConcurrentDictionary<string, BaseCamera> dicCameras { get; set; } = new ObservableConcurrentDictionary<string, BaseCamera>();
        /// <summary>
        /// è¯»ç å™¨é›†åˆ(Key:设备SN,Value:读码器句柄)
        /// </summary>
        public static ObservableConcurrentDictionary<string, BarcodeReaderBase> dicBarcodeReaders { get; set; } = new ObservableConcurrentDictionary<string, BarcodeReaderBase>();
        /// <summary>
        /// é€šè®¯é›†åˆ(Key:通讯名,Value:通讯句柄)
        /// </summary>
        public static ObservableConcurrentDictionary<string, BaseCommunicator> dicCommunicators { get; set; } = new ObservableConcurrentDictionary<string, BaseCommunicator>();
@@ -48,6 +55,14 @@
        public static ConcurrentDictionary<int, ConcurrentDictionary<string, string>> dicProcessSetting { get; set; } = new ConcurrentDictionary<int, ConcurrentDictionary<string, string>>();
        /// <summary>
        /// è¿åŠ¨æŽ§æ•°æ®åˆ¶é›†åˆ Key:产品名称,Value: SN,RecordMotionControlData
        /// </summary>
        public static ConcurrentDictionary<string, ConcurrentDictionary<string, RecordMotionControlData>> dicMotionControlData { get; set; } = new ConcurrentDictionary<string, ConcurrentDictionary<string, RecordMotionControlData>>();
        public static string allMotionControlDataPath
            => GlobalVar.strApplicationPath + "\\所有产品\\" + GlobalVar.strProductName + "\\A_MotionControlDatas.json";
        /// <summary>
        /// å¸ƒå±€é›†åˆ
        /// </summary>
        public static ConcurrentDictionary<int, Layout> dicLayout { get; set; } = new ConcurrentDictionary<int, Layout>();
LB_SmartVision/LB_SmartVision.csproj
@@ -47,16 +47,29 @@
  </ItemGroup>
  <ItemGroup>
    <PackageReference Include="CsvHelper" Version="33.1.0" />
    <PackageReference Include="MaterialSkin.NET5" Version="1.0.2" />
  </ItemGroup>
  <ItemGroup>
    <Reference Include="CLIDelegate">
      <HintPath>..\LB_VisionProcesses\ref\CLIDelegate.dll</HintPath>
    </Reference>
    <Reference Include="EasyIDSDK_Net">
      <HintPath>..\LB_VisionProcesses\ref\EasyIDSDK_Net.dll</HintPath>
    </Reference>
    <Reference Include="halcondotnet">
      <HintPath>ref\halcondotnet.dll</HintPath>
    </Reference>
    <Reference Include="MVSDK_Net">
      <HintPath>..\LB_VisionProcesses\ref\MVSDK_Net.dll</HintPath>
    </Reference>
    <Reference Include="MySql.Data">
      <HintPath>ref\MySql.Data.dll</HintPath>
    </Reference>
    <Reference Include="ThridLibray">
      <HintPath>..\LB_VisionProcesses\ref\ThridLibray.dll</HintPath>
    </Reference>
  </ItemGroup>
  <ItemGroup>
LB_SmartVision/ProcessRun/ProcessContext.cs
@@ -570,12 +570,23 @@
        [Node("相机取图", "取像工具", "Basic", "相机取图")]
        public void ç›¸æœºå–图(FlowNode node) { RunNodeAsync(node); }
        [Node("Halcon2D斑点工具", "Haclon2D工具", "Basic", "Halcon2D斑点工具")]
        [Node("读码工具", "取像工具", "Basic", "读码工具")]
        public void è¯»ç å·¥å…·(FlowNode node) { RunNodeAsync(node); }
        [Node("Halcon2D斑点工具", "Halcon2D工具", "Basic", "Halcon2D斑点工具")]
        public void Halcon2D斑点工具(FlowNode node) { RunNodeAsync(node); }
        [Node("通讯模块", "通讯工具", "Basic", "通讯模块")]
        public void é€šè®¯æ¨¡å—(FlowNode node) { RunNodeAsync(node); }
        [Node("Halcon2D图像增强", "Halcon2D工具", "Basic", "Halcon2D图像增强")]
        public void Halcon2D图像增强(FlowNode node) { RunNodeAsync(node); }
        [Node("Halcon2D图像滤波", "Halcon2D工具", "Basic", "Halcon2D图像滤波")]
        public void Halcon2D图像滤波(FlowNode node) { RunNodeAsync(node); }
        #endregion
LB_SmartVision/ProcessRun/ProcessRunBll.cs
@@ -17,6 +17,8 @@
namespace LB_SmartVision.ProcessRun
{
    public delegate void ProcessRunBllRun();
    public class ProcessRunBll
    {
@@ -648,7 +650,7 @@
                    {
                        dicOutputsMapping.TryAdd(name, new List<string>());
                        dicOutputsMapping[name].Add(name + ".Outputs.Image");
                        //dicOutputsMapping[name].Add(name + ".Outputs.Record");
                        dicOutputsMapping[name].Add(name + ".Outputs.Record");
                        dicOutputsMapping[name].Add(name + ".Outputs.Result");
                        foreach (var item in process.Params.Outputs)
LB_SmartVision/SQL/DatabaseRecordProductDataHelper.cs
@@ -47,7 +47,7 @@
                                                 InspectionOperator VARCHAR(255),
                                                 NGType VARCHAR(255),
                                                 NGSize VARCHAR(255),
                                                 DetectionTime VARCHAR(255)),
                                                 DetectionTime VARCHAR(255),
                                                 CameraInspection VARCHAR(255),
                                                 CreatedDate DATETIME DEFAULT CURRENT_TIMESTAMP,
                                                 INDEX idx_created_date (CreatedDate),
LB_SmartVision/VisionForm.Designer.cs
@@ -35,9 +35,11 @@
            materialTabControl = new MaterialSkin.Controls.MaterialTabControl();
            tlp_VisionMainOperator = new Sunny.UI.UITableLayoutPanel();
            ckb_AllowRun = new Sunny.UI.UICheckBox();
            btn_Login = new ReaLTaiizor.Controls.Button();
            btn_GlobalVar = new ReaLTaiizor.Controls.Button();
            com_ProductName = new ReaLTaiizor.Controls.AloneComboBox();
            btn_SingleRun = new Sunny.UI.UIButton();
            btn_Login = new Sunny.UI.UIButton();
            btn_RunContinuously = new Sunny.UI.UIButton();
            btn_GlobalVar = new Sunny.UI.UIButton();
            materialTabSelector = new MaterialSkin.Controls.MaterialTabSelector();
            grb_Info = new Sunny.UI.UIGroupBox();
            rich_Info = new Sunny.UI.UIRichTextBox();
@@ -61,11 +63,12 @@
            theme_VisionForm.Font = new Font("Microsoft YaHei UI", 12F, FontStyle.Regular, GraphicsUnit.Point, 0);
            theme_VisionForm.Image = (Image)resources.GetObject("theme_VisionForm.Image");
            theme_VisionForm.Location = new Point(0, 0);
            theme_VisionForm.Margin = new Padding(4);
            theme_VisionForm.Name = "theme_VisionForm";
            theme_VisionForm.Padding = new Padding(10, 70, 10, 9);
            theme_VisionForm.Padding = new Padding(12, 88, 12, 11);
            theme_VisionForm.RoundCorners = true;
            theme_VisionForm.Sizable = true;
            theme_VisionForm.Size = new Size(1152, 704);
            theme_VisionForm.Size = new Size(1440, 880);
            theme_VisionForm.SmartBounds = true;
            theme_VisionForm.StartPosition = FormStartPosition.WindowsDefaultLocation;
            theme_VisionForm.TabIndex = 0;
@@ -75,7 +78,8 @@
            // 
            sc_VisionForm.Dock = DockStyle.Fill;
            sc_VisionForm.FixedPanel = FixedPanel.Panel2;
            sc_VisionForm.Location = new Point(10, 70);
            sc_VisionForm.Location = new Point(12, 88);
            sc_VisionForm.Margin = new Padding(4);
            sc_VisionForm.Name = "sc_VisionForm";
            sc_VisionForm.Orientation = Orientation.Horizontal;
            // 
@@ -86,8 +90,9 @@
            // sc_VisionForm.Panel2
            // 
            sc_VisionForm.Panel2.Controls.Add(grb_Info);
            sc_VisionForm.Size = new Size(1132, 625);
            sc_VisionForm.SplitterDistance = 476;
            sc_VisionForm.Size = new Size(1416, 781);
            sc_VisionForm.SplitterDistance = 593;
            sc_VisionForm.SplitterWidth = 5;
            sc_VisionForm.TabIndex = 1;
            // 
            // tlp_MainView
@@ -102,10 +107,10 @@
            tlp_MainView.Margin = new Padding(2);
            tlp_MainView.Name = "tlp_MainView";
            tlp_MainView.RowCount = 3;
            tlp_MainView.RowStyles.Add(new RowStyle(SizeType.Absolute, 48F));
            tlp_MainView.RowStyles.Add(new RowStyle(SizeType.Absolute, 31F));
            tlp_MainView.RowStyles.Add(new RowStyle(SizeType.Absolute, 60F));
            tlp_MainView.RowStyles.Add(new RowStyle(SizeType.Absolute, 39F));
            tlp_MainView.RowStyles.Add(new RowStyle(SizeType.Percent, 100F));
            tlp_MainView.Size = new Size(1132, 476);
            tlp_MainView.Size = new Size(1416, 593);
            tlp_MainView.TabIndex = 1;
            tlp_MainView.TagString = null;
            // 
@@ -114,12 +119,12 @@
            materialTabControl.AccessibleRole = AccessibleRole.Sound;
            materialTabControl.Depth = 0;
            materialTabControl.Dock = DockStyle.Fill;
            materialTabControl.Location = new Point(2, 81);
            materialTabControl.Location = new Point(2, 101);
            materialTabControl.Margin = new Padding(2);
            materialTabControl.MouseState = MaterialSkin.MouseState.HOVER;
            materialTabControl.Name = "materialTabControl";
            materialTabControl.SelectedIndex = 0;
            materialTabControl.Size = new Size(1128, 393);
            materialTabControl.Size = new Size(1412, 490);
            materialTabControl.TabIndex = 0;
            // 
            // tlp_VisionMainOperator
@@ -136,15 +141,18 @@
            tlp_VisionMainOperator.ColumnStyles.Add(new ColumnStyle(SizeType.Percent, 11.1111107F));
            tlp_VisionMainOperator.ColumnStyles.Add(new ColumnStyle(SizeType.Percent, 11.1111107F));
            tlp_VisionMainOperator.Controls.Add(ckb_AllowRun, 0, 0);
            tlp_VisionMainOperator.Controls.Add(btn_Login, 1, 0);
            tlp_VisionMainOperator.Controls.Add(btn_GlobalVar, 7, 0);
            tlp_VisionMainOperator.Controls.Add(com_ProductName, 8, 0);
            tlp_VisionMainOperator.Controls.Add(btn_SingleRun, 2, 0);
            tlp_VisionMainOperator.Controls.Add(btn_Login, 1, 0);
            tlp_VisionMainOperator.Controls.Add(btn_RunContinuously, 3, 0);
            tlp_VisionMainOperator.Controls.Add(btn_GlobalVar, 7, 0);
            tlp_VisionMainOperator.Dock = DockStyle.Fill;
            tlp_VisionMainOperator.Location = new Point(3, 51);
            tlp_VisionMainOperator.Location = new Point(4, 64);
            tlp_VisionMainOperator.Margin = new Padding(4);
            tlp_VisionMainOperator.Name = "tlp_VisionMainOperator";
            tlp_VisionMainOperator.RowCount = 1;
            tlp_VisionMainOperator.RowStyles.Add(new RowStyle(SizeType.Percent, 100F));
            tlp_VisionMainOperator.Size = new Size(1126, 25);
            tlp_VisionMainOperator.Size = new Size(1408, 31);
            tlp_VisionMainOperator.TabIndex = 0;
            tlp_VisionMainOperator.TagString = null;
            // 
@@ -153,54 +161,13 @@
            ckb_AllowRun.Dock = DockStyle.Fill;
            ckb_AllowRun.Font = new Font("宋体", 10.5F, FontStyle.Regular, GraphicsUnit.Point, 134);
            ckb_AllowRun.ForeColor = SystemColors.Control;
            ckb_AllowRun.Location = new Point(3, 3);
            ckb_AllowRun.Location = new Point(4, 4);
            ckb_AllowRun.Margin = new Padding(4);
            ckb_AllowRun.MinimumSize = new Size(1, 1);
            ckb_AllowRun.Name = "ckb_AllowRun";
            ckb_AllowRun.Size = new Size(119, 19);
            ckb_AllowRun.Size = new Size(148, 23);
            ckb_AllowRun.TabIndex = 2;
            ckb_AllowRun.Text = "运行模式";
            //
            // btn_Login
            //
            btn_Login.BackColor = Color.Transparent;
            btn_Login.BorderColor = Color.FromArgb(32, 34, 37);
            btn_Login.Dock = DockStyle.Fill;
            btn_Login.EnteredBorderColor = Color.FromArgb(165, 37, 37);
            btn_Login.EnteredColor = Color.FromArgb(32, 34, 37);
            btn_Login.Font = new Font("宋体", 10.5F, FontStyle.Regular, GraphicsUnit.Point, 134);
            btn_Login.Image = null;
            btn_Login.ImageAlign = ContentAlignment.MiddleLeft;
            btn_Login.InactiveColor = Color.FromArgb(32, 34, 37);
            btn_Login.Location = new Point(128, 3);
            btn_Login.Name = "btn_Login";
            btn_Login.PressedBorderColor = Color.FromArgb(165, 37, 37);
            btn_Login.PressedColor = Color.FromArgb(165, 37, 37);
            btn_Login.Size = new Size(119, 19);
            btn_Login.TabIndex = 3;
            btn_Login.Text = "用户登录";
            btn_Login.TextAlignment = StringAlignment.Center;
            btn_Login.Click += btn_Login_Click;
            //
            // btn_GlobalVar
            //
            btn_GlobalVar.BackColor = Color.Gray;
            btn_GlobalVar.BorderColor = Color.FromArgb(32, 34, 37);
            btn_GlobalVar.Dock = DockStyle.Fill;
            btn_GlobalVar.EnteredBorderColor = Color.FromArgb(165, 37, 37);
            btn_GlobalVar.EnteredColor = Color.FromArgb(32, 34, 37);
            btn_GlobalVar.Font = new Font("宋体", 10.5F, FontStyle.Regular, GraphicsUnit.Point, 0);
            btn_GlobalVar.Image = null;
            btn_GlobalVar.ImageAlign = ContentAlignment.MiddleLeft;
            btn_GlobalVar.InactiveColor = Color.FromArgb(32, 34, 37);
            btn_GlobalVar.Location = new Point(878, 3);
            btn_GlobalVar.Name = "btn_GlobalVar";
            btn_GlobalVar.PressedBorderColor = Color.FromArgb(165, 37, 37);
            btn_GlobalVar.PressedColor = Color.FromArgb(165, 37, 37);
            btn_GlobalVar.Size = new Size(119, 19);
            btn_GlobalVar.TabIndex = 4;
            btn_GlobalVar.Text = "全局变量";
            btn_GlobalVar.TextAlignment = StringAlignment.Center;
            btn_GlobalVar.Click += btn_GlobalVar_Click;
            // 
            // com_ProductName
            // 
@@ -211,21 +178,91 @@
            com_ProductName.Font = new Font("宋体", 10.5F, FontStyle.Regular, GraphicsUnit.Point, 134);
            com_ProductName.FormattingEnabled = true;
            com_ProductName.ItemHeight = 20;
            com_ProductName.Location = new Point(1003, 3);
            com_ProductName.Location = new Point(1252, 4);
            com_ProductName.Margin = new Padding(4);
            com_ProductName.Name = "com_ProductName";
            com_ProductName.Size = new Size(120, 26);
            com_ProductName.Size = new Size(152, 26);
            com_ProductName.TabIndex = 5;
            com_ProductName.SelectedValueChanged += com_ProductName_SelectedValueChanged;
            //
            // btn_SingleRun
            //
            btn_SingleRun.BackColor = Color.FromArgb(39, 51, 63);
            btn_SingleRun.Dock = DockStyle.Fill;
            btn_SingleRun.FillColor = Color.FromArgb(39, 51, 63);
            btn_SingleRun.FillColor2 = Color.FromArgb(39, 51, 63);
            btn_SingleRun.FillSelectedColor = Color.FromArgb(128, 255, 128);
            btn_SingleRun.Font = new Font("宋体", 12F, FontStyle.Regular, GraphicsUnit.Point, 134);
            btn_SingleRun.Location = new Point(315, 3);
            btn_SingleRun.MinimumSize = new Size(1, 1);
            btn_SingleRun.Name = "btn_SingleRun";
            btn_SingleRun.Size = new Size(150, 25);
            btn_SingleRun.TabIndex = 6;
            btn_SingleRun.Text = "单次运行";
            btn_SingleRun.TipsFont = new Font("宋体", 9F, FontStyle.Regular, GraphicsUnit.Point, 134);
            btn_SingleRun.Click += btn_Run_Click;
            //
            // btn_Login
            //
            btn_Login.BackColor = Color.FromArgb(39, 51, 63);
            btn_Login.Dock = DockStyle.Fill;
            btn_Login.FillColor = Color.FromArgb(39, 51, 63);
            btn_Login.FillColor2 = Color.FromArgb(39, 51, 63);
            btn_Login.FillSelectedColor = Color.FromArgb(128, 255, 128);
            btn_Login.Font = new Font("宋体", 12F, FontStyle.Regular, GraphicsUnit.Point, 134);
            btn_Login.Location = new Point(159, 3);
            btn_Login.MinimumSize = new Size(1, 1);
            btn_Login.Name = "btn_Login";
            btn_Login.Size = new Size(150, 25);
            btn_Login.TabIndex = 6;
            btn_Login.Text = "用户登录";
            btn_Login.TipsFont = new Font("宋体", 9F, FontStyle.Regular, GraphicsUnit.Point, 134);
            btn_Login.Click += btn_Login_Click;
            //
            // btn_RunContinuously
            //
            btn_RunContinuously.BackColor = Color.FromArgb(39, 51, 63);
            btn_RunContinuously.Dock = DockStyle.Fill;
            btn_RunContinuously.FillColor = Color.FromArgb(39, 51, 63);
            btn_RunContinuously.FillColor2 = Color.FromArgb(39, 51, 63);
            btn_RunContinuously.FillSelectedColor = Color.FromArgb(128, 255, 128);
            btn_RunContinuously.Font = new Font("宋体", 12F, FontStyle.Regular, GraphicsUnit.Point, 134);
            btn_RunContinuously.Location = new Point(471, 3);
            btn_RunContinuously.MinimumSize = new Size(1, 1);
            btn_RunContinuously.Name = "btn_RunContinuously";
            btn_RunContinuously.Size = new Size(150, 25);
            btn_RunContinuously.TabIndex = 6;
            btn_RunContinuously.Text = "连续运行";
            btn_RunContinuously.TipsFont = new Font("宋体", 9F, FontStyle.Regular, GraphicsUnit.Point, 134);
            btn_RunContinuously.Click += btn_RunContinuously_Click;
            //
            // btn_GlobalVar
            //
            btn_GlobalVar.BackColor = Color.FromArgb(39, 51, 63);
            btn_GlobalVar.Dock = DockStyle.Fill;
            btn_GlobalVar.FillColor = Color.FromArgb(39, 51, 63);
            btn_GlobalVar.FillColor2 = Color.FromArgb(39, 51, 63);
            btn_GlobalVar.FillSelectedColor = Color.FromArgb(128, 255, 128);
            btn_GlobalVar.Font = new Font("宋体", 12F, FontStyle.Regular, GraphicsUnit.Point, 134);
            btn_GlobalVar.Location = new Point(1095, 3);
            btn_GlobalVar.MinimumSize = new Size(1, 1);
            btn_GlobalVar.Name = "btn_GlobalVar";
            btn_GlobalVar.Size = new Size(150, 25);
            btn_GlobalVar.TabIndex = 6;
            btn_GlobalVar.Text = "全局变量";
            btn_GlobalVar.TipsFont = new Font("宋体", 9F, FontStyle.Regular, GraphicsUnit.Point, 134);
            btn_GlobalVar.Click += btn_GlobalVar_Click;
            // 
            // materialTabSelector
            // 
            materialTabSelector.BaseTabControl = null;
            materialTabSelector.Depth = 0;
            materialTabSelector.Dock = DockStyle.Fill;
            materialTabSelector.Location = new Point(3, 3);
            materialTabSelector.Location = new Point(4, 4);
            materialTabSelector.Margin = new Padding(4);
            materialTabSelector.MouseState = MaterialSkin.MouseState.HOVER;
            materialTabSelector.Name = "materialTabSelector";
            materialTabSelector.Size = new Size(1126, 42);
            materialTabSelector.Size = new Size(1408, 52);
            materialTabSelector.TabIndex = 1;
            // 
            // grb_Info
@@ -236,11 +273,11 @@
            grb_Info.Font = new Font("宋体", 12F, FontStyle.Regular, GraphicsUnit.Point, 134);
            grb_Info.ForeColor = SystemColors.Control;
            grb_Info.Location = new Point(0, 0);
            grb_Info.Margin = new Padding(4, 5, 4, 5);
            grb_Info.Margin = new Padding(5, 6, 5, 6);
            grb_Info.MinimumSize = new Size(1, 1);
            grb_Info.Name = "grb_Info";
            grb_Info.Padding = new Padding(0, 32, 0, 0);
            grb_Info.Size = new Size(1132, 145);
            grb_Info.Padding = new Padding(0, 40, 0, 0);
            grb_Info.Size = new Size(1416, 183);
            grb_Info.TabIndex = 1;
            grb_Info.Text = "日志显示区:";
            grb_Info.TextAlignment = ContentAlignment.MiddleLeft;
@@ -250,13 +287,13 @@
            rich_Info.Dock = DockStyle.Fill;
            rich_Info.FillColor = Color.FromArgb(32, 41, 50);
            rich_Info.Font = new Font("宋体", 12F, FontStyle.Regular, GraphicsUnit.Point, 134);
            rich_Info.Location = new Point(0, 32);
            rich_Info.Location = new Point(0, 40);
            rich_Info.Margin = new Padding(4, 5, 4, 5);
            rich_Info.MinimumSize = new Size(1, 1);
            rich_Info.Name = "rich_Info";
            rich_Info.Padding = new Padding(2);
            rich_Info.ShowText = false;
            rich_Info.Size = new Size(1132, 113);
            rich_Info.Size = new Size(1416, 143);
            rich_Info.TabIndex = 0;
            rich_Info.TextAlignment = ContentAlignment.MiddleLeft;
            // 
@@ -270,7 +307,8 @@
            cb_VisionForm.EnableMaximizeButton = true;
            cb_VisionForm.EnableMinimizeButton = true;
            cb_VisionForm.ForeColor = Color.FromArgb(155, 155, 155);
            cb_VisionForm.Location = new Point(1072, 14);
            cb_VisionForm.Location = new Point(1330, 18);
            cb_VisionForm.Margin = new Padding(4);
            cb_VisionForm.MaximizeHoverColor = Color.FromArgb(74, 74, 74);
            cb_VisionForm.MinimizeHoverColor = Color.FromArgb(63, 63, 65);
            cb_VisionForm.Name = "cb_VisionForm";
@@ -280,13 +318,14 @@
            // 
            // VisionForm
            // 
            AutoScaleDimensions = new SizeF(96F, 96F);
            AutoScaleDimensions = new SizeF(120F, 120F);
            AutoScaleMode = AutoScaleMode.Dpi;
            ClientSize = new Size(1152, 704);
            ClientSize = new Size(1440, 880);
            Controls.Add(theme_VisionForm);
            FormBorderStyle = FormBorderStyle.None;
            Icon = (Icon)resources.GetObject("$this.Icon");
            MinimumSize = new Size(261, 61);
            Margin = new Padding(4);
            MinimumSize = new Size(326, 76);
            Name = "VisionForm";
            Text = "轮胎外观视觉检测系统";
            TransparencyKey = Color.Fuchsia;
@@ -310,13 +349,15 @@
        private SplitContainer sc_VisionForm;
        private Sunny.UI.UITableLayoutPanel tlp_VisionMainOperator;
        private Sunny.UI.UICheckBox ckb_AllowRun;
        private ReaLTaiizor.Controls.Button btn_Login;
        private ReaLTaiizor.Controls.Button btn_GlobalVar;
        private Sunny.UI.UIGroupBox grb_Info;
        private Sunny.UI.UIRichTextBox rich_Info;
        private MaterialSkin.Controls.MaterialTabControl materialTabControl;
        private ReaLTaiizor.Controls.AloneComboBox com_ProductName;
        private MaterialSkin.Controls.MaterialTabSelector materialTabSelector;
        private Sunny.UI.UITableLayoutPanel tlp_MainView;
        private Sunny.UI.UIButton btn_SingleRun;
        private Sunny.UI.UIButton btn_Login;
        private Sunny.UI.UIButton btn_RunContinuously;
        private Sunny.UI.UIButton btn_GlobalVar;
    }
}
LB_SmartVision/VisionForm.cs
@@ -10,6 +10,7 @@
using LB_SmartVision.Forms.Pages.SettingPage;
using LB_SmartVision.Forms.Pages.UserManagementPage;
using LB_SmartVision.ProcessRun;
using LB_SmartVision.SQL;
using LB_SmartVision.Tool;
using LB_SmartVisionCommon;
using LB_SmartVisionLoginUI;
@@ -633,7 +634,15 @@
            {
                LogInfo("全局变量加载失败", LogInfoType.ERROR);
            }
            GlobalVar.dicMotionControlData.Clear();
            if (LoadMotionControlDatas(GlobalVar.allMotionControlDataPath))
            {
                LogInfo("运动控制参数加载成功", LogInfoType.PASS);
            }
            else
            {
                LogInfo("运动控制参数加载失败", LogInfoType.ERROR);
            }
            //加载流程
            GlobalVar.dicProcesses.Clear();
            if (LoadAllProcess(GlobalVar.allProcessConnectionStringPath))
@@ -687,6 +696,7 @@
            com_ProductName.Items.Add("新增");
            com_ProductName.Text = GlobalVar.strProductName;
            this.WindowState = FormWindowState.Maximized;
            DatabaseRecordProductDataHelper.InitializeDatabase();
        }
        public void SaveAllSetting()
@@ -698,6 +708,54 @@
            SaveAllProcessSetting();
            SaveAllLayout();
            SaveAllCsv();
            SaveMotionControlDatas();
        }
        public bool LoadMotionControlDatas(string alMotionControlDataPath)
        {
            try
            {
                GlobalVar.dicMotionControlData = ConfigManager<ConcurrentDictionary<string, ConcurrentDictionary<string, RecordMotionControlData>>>.LoadConfig<ConcurrentDictionary<string, ConcurrentDictionary<string, RecordMotionControlData>>>(alMotionControlDataPath);
            }
            catch
            {
                return false;
            }
            return true;
        }
        public bool SaveMotionControlDatas()
        {
            try
            {
                ConcurrentDictionary<string, List<string>> removeCameraSN = new ConcurrentDictionary<string, List<string>>();
                foreach (var item in GlobalVar.dicMotionControlData.Keys)
                {
                    List<string> list = new List<string>();
                    foreach (var itemSN in GlobalVar.dicMotionControlData[item].Keys)
                    {
                        if (!GlobalVar.dicCameras.Keys.Contains(itemSN))
                        {
                            list.Add(itemSN);
                        }
                    }
                    if (list.Count > 0)
                    {
                        removeCameraSN.TryAdd(item, list);
                    }
                }
                foreach (var item in removeCameraSN.Keys)
                {
                    foreach (var itemSN in removeCameraSN[item])
                    {
                        GlobalVar.dicMotionControlData[item].Keys.Remove(itemSN);
                    }
                }
                ConfigManager<ConcurrentDictionary<string, ConcurrentDictionary<string, RecordMotionControlData>>>.SaveConfig<ConcurrentDictionary<string, ConcurrentDictionary<string, RecordMotionControlData>>>(GlobalVar.dicMotionControlData, GlobalVar.allMotionControlDataPath);
            }
            catch
            {
                return false;
            }
            return true;
        }
        public bool LoadAllCameras(string allCamerasConnectionStringPath)
@@ -850,7 +908,7 @@
                            string ClassName = match.Groups["ClassName"].Value;   // "TCP"
                            string IP = match.Groups["IP"].Value;          // "127.0.0.1"
                            string Slot = match.Groups["Slot"].Value;        // "1111"
                            string CpuType= match.Groups["CpuType"].Value;
                            string CpuType = match.Groups["CpuType"].Value;
                            string PlcAddress = match.Groups["PlcAddress"].Value;
                            string DataType = match.Groups["DataType"].Success ? match.Groups["DataType"].Value : "String";
@@ -1027,7 +1085,6 @@
            {
                string strJson = string.Empty;
                GlobalVar.allCommunicatorsConnectionString = new ConcurrentDictionary<string, string>();
                foreach (var item in GlobalVar.dicCommunicators)
                {
                    string ClassName = item.Value.GetType().FullName;// "TCP"
@@ -1056,6 +1113,7 @@
                        string CommunicatorConnectionString = $"({ClassName})[{IP}][{PORT}]";
                        GlobalVar.allCommunicatorsConnectionString.TryAdd(item.Key, CommunicatorConnectionString);
                    }
                    GlobalVar.dicCommunicators[item.Key].ClassName = ClassName;
                }
                var settings = new JsonSerializerSettings
                {
@@ -1080,6 +1138,11 @@
                    { }
                }
                File.WriteAllText(GlobalVar.allCommunicatorsConnectionStringPath, strJson, Encoding.UTF8);
                foreach (var item in GlobalVar.dicCommunicators)
                {
                    string ClassName = item.Value.GetType().FullName;// "TCP"
                }
                ConfigManager<ObservableConcurrentDictionary<string, BaseCommunicator>>.SaveConfig<ObservableConcurrentDictionary<string, BaseCommunicator>>(GlobalVar.dicCommunicators, GlobalVar.strApplicationPath + "\\所有产品\\" + GlobalVar.strProductName + "\\dicCommunicators.json");
                return true;
            }
            catch { return false; }
@@ -1339,6 +1402,7 @@
                GlobalVar.strProductName = com_ProductName.SelectedItem?.ToString();
                foreach (BaseCamera camera in GlobalVar.dicCameras.Values)
                {
                    camera.TriggerRunMessageReceived -= TriggerRunMessageReceived;
                    camera.Dispose();
                }
                GlobalVar.dicCameras.Clear();
@@ -1652,6 +1716,128 @@
                communicator.Disconnect();
            }
            FormClosing -= VisionForm_FormClosing;
            //try
            //{
            //    Process[] processes = System.Diagnostics.Process.GetProcesses(); //获得所有进程
            //    foreach (Process p in processes)
            //    {
            //        if (p.ProcessName == "LB_SmartVision" && p.StartTime < DateTime.Now.AddMilliseconds(-300))
            //        {
            //            p.Kill();
            //        }
            //    }
            //}
            //catch { }
            KillAllTargetProcesses();
        }
        /// <summary>
        /// æ€è¿›ç¨‹é€»è¾‘
        /// </summary>
        private void KillAllTargetProcesses()
        {
            try
            {
                // 1. èŽ·å–å½“å‰è¿›ç¨‹ID,避免杀死自己
                int currentProcessId = Process.GetCurrentProcess().Id;
                // 2. æ¨¡ç³ŠåŒ¹é…è¿›ç¨‹åï¼ˆå¿½ç•¥å¤§å°å†™ï¼‰ï¼Œè¦†ç›–vshost/后缀等情况
                var targetProcesses = Process.GetProcesses()
                    .Where(p =>
                        p.ProcessName.IndexOf("LB_SmartVision", StringComparison.OrdinalIgnoreCase) >= 0
                        && p.Id == currentProcessId);
                foreach (var p in targetProcesses)
                {
                    try
                    {
                        if (!p.HasExited)
                        {
                            // å…ˆå°è¯•优雅关闭WinForm程序(比直接Kill更友好)
                            p.CloseMainWindow();
                            // ç­‰å¾…500ms,看是否正常退出
                            if (!p.WaitForExit(500))
                            {
                                p.Kill(); // å¼ºåˆ¶æ€æ­»
                                p.WaitForExit(1000); // ç­‰å¾…进程完全终止
                            }
                        }
                        p.Dispose(); // é‡Šæ”¾è¿›ç¨‹èµ„源,避免句柄泄漏
                    }
                    catch (Exception ex)
                    {
                        // è®°å½•异常但不中断,比如权限不足的情况
                        System.IO.File.AppendAllText("kill_process_log.txt", $"[{DateTime.Now}] æ€æ­»è¿›ç¨‹å¤±è´¥: {ex.Message}\r\n");
                    }
                }
                // é¢å¤–延迟,确保文件句柄完全释放
                Thread.Sleep(1000);
            }
            catch (Exception)
            {
                // é™é»˜å¤±è´¥ï¼Œä¸å½±å“ç¨‹åºé€€å‡º
            }
        }
        private void btn_Run_Click(object sender, EventArgs e)
        {
            var matchedItems = GlobalVar.dicProcessSetting
                                        .Where(item =>
                                        {
                                            var value = item.Value;
                                            var triggerComm = value["触发通讯"];
                                            var triggerChar = value["触发字符"];
                                            return triggerComm != null;
                                            //return triggerComm != null && triggerComm.Equals(name) &&
                                            //       (string.IsNullOrEmpty(triggerChar?.ToString()) ||
                                            //        msg.StartsWith(triggerChar.ToString()));
                                        })
                                        .ToList(); // é¿å…é‡å¤å­—典访问和装箱操作
            if (matchedItems.Count <= 0)
            {
                return;
            }
            TriggerRunMessageReceived(matchedItems[0].Value["触发通讯"], matchedItems[0].Value["触发字符"]);
        }
        private void btn_RunContinuously_Click(object sender, EventArgs e)
        {
            if (btn_RunContinuously.Text.Equals("连续运行"))
            {
                btn_RunContinuously.Text = "暂停运行";
                Task.Factory.StartNew(() =>
                {
                    var matchedItems = GlobalVar.dicProcessSetting
                                                .Where(item =>
                                                {
                                                    var value = item.Value;
                                                    var triggerComm = value["触发通讯"];
                                                    var triggerChar = value["触发字符"];
                                                    return triggerComm != null;
                                                    //return triggerComm != null && triggerComm.Equals(name) &&
                                                    //       (string.IsNullOrEmpty(triggerChar?.ToString()) ||
                                                    //        msg.StartsWith(triggerChar.ToString()));
                                                })
                                                .ToList(); // é¿å…é‡å¤å­—典访问和装箱操作
                    while (btn_RunContinuously.Text.Equals("暂停运行"))
                    {
                        TriggerRunMessageReceived(matchedItems[0].Value["触发通讯"], matchedItems[0].Value["触发字符"]);
                        Thread.Sleep(500);
                    }
                    //this.Invoke(() =>
                    //{
                    //});
                });
            }
            else if (btn_RunContinuously.Text.Equals("暂停运行"))
            {
                btn_RunContinuously.Text = "连续运行";
                Thread.Sleep(100);
            }
        }
    }
}
LB_SmartVision/VisionForm.resx
@@ -121,24 +121,24 @@
  <data name="theme_VisionForm.Image" type="System.Drawing.Bitmap, System.Drawing" mimetype="application/x-microsoft.net.object.bytearray.base64">
    <value>
        iVBORw0KGgoAAAANSUhEUgAAACAAAAAgCAYAAABzenr0AAAABGdBTUEAALGPC/xhBQAAAAlwSFlzAAAO
        vAAADrwBlbxySQAAA+JJREFUWEftVkuIHGUQbt34iMEoq2S2q3p3yTJsuqpnJ+L6WBRdwaigohfFgEou
        BkVBUPCBCEG8BXNQ48GLeImCehIJxMsqhsSZruod46K4HtSIGjU+4iOr0c1I9fSsM3/PLNtCPO0H36m/
        evz/X11VnreKVRTAHPOZumkY6lFwqURws3BwZ8ywTQnuiCP/+iTCzY1qaUPzdm/Atf3PaHre6XPsjyQM
        2xLGV4XwIyX4QRj+UMK/lPFvJTyhBMeV8IgQvmRJuH4Ko+l5p9UjGBbCJ5RxTgj+VMZmXxKcSAjekHE/
        NNs5DgaTKLinEQYVO4Trf1mkV81wixLUslPmA3bzF2XcKeP+hWY/u3n0fCXcrQwLyjAvjNsb1dI6N05P
        mFAIHlHG73sEypPgGwnhfpn0zzH7jzddcK4Q7kqfKNMI4a9K+MwBDgbdeF04MBWsFYYdQvhbLlBvfhKT
        f+vMtLfG7C0JJXxKGY67WnvCmPAFGRs7z42boul5AzHBfdK6TjdQtzPGk8oos5F/5Y7sfVvPhg+lp+1h
        0yIsxARPmtaN78WEl8eEX+SNclxUhne0glUrNrN9zfMGlPAuZTzaQ99FYfwuDv3ruoLvq5bWaQSvZCfL
        GXUYLwrj240Qxtu2lkSN4FpdWfKZH9jb9RQ1Cq62f9sVOlxUxn3KQXnJ0PO8QxU/jBm1h74v7ZniEG9K
        Hdg/quzvXO709k0Y3u08ucGqWgheX862H4XgxbR47SqU8D1X0EXC2VmGizqDz0xPr0kYH9eO360gNe0b
        jWppozB+1kOQEb5MCLa0C64NoeGrhOGrvH6lhK81GiIvnggmrDLzgvTkvwvDA+5wsU4nhG/m9AUoBD/F
        HFzWN4H0XQn2vF8eXN8Z3FAPYasl59oUYjuB+sTImDB+nhfgYQ39STf4fmu1DHtz+oIUgiM1KkWtwcFw
        sOujVT3hrnaL7UQc+hcL5W+sKIXhw0OVjaW0iwnBc47gqIQ45QY32PKRzv8eTguRYM9SS5YouEEZjv37
        EffbzbjBDdZyxZYQ12EB2qS0bWrJqRVazPDWkojwZbuZrsgZtDJ0iY1g12khEtTicMTvclwn2CKE32YJ
        7G5PORfZ1HtMCH7MOV4BrQ3XCe92+4onk5Nn2PolDAvWXnuOzAwzo6Nnx4Q3SrojwqfKeMxWMpsXWVs+
        2WrfKRdbW1W6Hf0shM/33Y7my4PrleFZIfhAaWjU/e5ivlw+y3S2FySMtynjvcrwsFiLJv/RhPBB2ws1
        hK2WcBLBFf1qawlplwvxaQlxe786OOU4PBWsjSO85mBlQ8n99r/BisSdAas4FfgHpdEUZpwUX7sAAAAA
        SUVORK5CYII=
        vAAADrwBlbxySQAAA+xJREFUWEftV0loFUkYbvcNFzJi0lWdBEPQruqXKEYdcRgz4AYqeplBwYiXEUVB
        UHAhCEG8iR509OBlmIsOjJ5EBvQSRVHzuvslxjAy8eCG+75GozF+f716L6873fqe2ykffDR59e9/1V8V
        ow99KARtUg72J5aypGNN8xy2yJPWcleylb5gS13HnJdy+KSW6uJx3b8ZA7TKl6PbMPq3SbMsBUcpyf/2
        BP8PDh96kr32BX/rS/4O30789grfO1j/k4LQ6p8POO6XdFgpDNbDSZsn2Bt8u2MpWGdKsCPeBNMm3TZp
        FaUc6/cW20pQEtpsflCllmwxjDbpLKOd9vAZuBPOx5J+86TyMdDbBxsdYLsn+SpUZYQy/imQILLdBIP3
        cxzEU7Dbns3WejXmcNK/NPGHkajabtUiLYO/nyOgXWdRFeUkDmdnWMOg2ACFFwEn8fzfFeaSxlpjIOlT
        EHC0HVm/CstSC13B93sVFaOVszDQpwGuYGtQLipnQDlMyLzH12t2zJ8adH/TbeMbVLYROmmyDvjYRrLK
        aS4Q3Y/gtWjFALtg6KSf4NW02Uj3HwSPzOuw9iAk24sI/p5rm3OV0wyOo+++ww7pzCIViVjvAk+02GyC
        VlWnpUmw2Qggn+AV0eZ/A61oEtYsOttRwjlE5vy4L61KrabQmjBtV3I/JPtRUptcmy9UBuiM+tLc+bHs
        aQ1Rn8rNnEC7Gpvr8KcqF0XoHVCbl0qB8p2OEspS8OZmySZrvwqNtbUDMRm3Yj9kj1uB9NXcwLkfjwyu
        RAhoshuYcHMyGy4DT5T+jKrcjNbJh+yW75QIw62yqhDAvUghwV/Cybrw5UKTDn08GqmTJ9GCx660pscG
        oPoq2MHzlUWjtN8skjZbRsGFdQpiJoBkVVkFnF3tLcCv+7ZZo31mcYZGLY5RL/kCiQrcaRLFTvrikOxc
        YJF2PeZ5ZsTmAkNkCtaiW1YAkcTF1sT4YjXFEM3ekMADz+YztM8AULqlqE5nSL5wor3Zkew51nxU4WnP
        Ij9DlVGLIWCtDhV6FzBWIJH9a3pNaZOGQRsNT6tjWSHB/6LK6OUA/ETJVER/O9dgwcQ7w7XLTG0yjSTO
        Onp7Ny3A92VuuTD0rbcFbXsUMJonaQwnBV8Rniu4y2sGYbEe5emA8cORV6ZGY3n5UNycC9AKvBHZZRh+
        iqxoX9BlRWMZozvLLiSEV5V6HT2Bjz9iX0ftaAWE9sDoBV+UlOufY9FeWTmE5OhdgLH8Kxyvhv5GON3q
        C3NzSvD19C70MTco4JTDZsbtrSzUlLP5DnBV3D745riOp5nr8F/OJcYV65++P2iTfNV/MPoQCcP4AKXR
        FGYxo/VGAAAAAElFTkSuQmCC
</value>
  </data>
  <data name="$this.Icon" type="System.Drawing.Icon, System.Drawing" mimetype="application/x-microsoft.net.object.bytearray.base64">
LB_SmartVisionCommon/ConfigManager.cs
@@ -21,6 +21,16 @@
        /// <param name="filePath">文件存储路径以及名称</param>
        public static void SaveConfig<T>(T config, string filePath)
        {
            if (config == null)
            {
                AsyncLogHelper.Error(nameof(config));
                throw new ArgumentNullException(nameof(config));
            }
            if (filePath == null)
            {
                AsyncLogHelper.Error(nameof(filePath));
                AsyncLogHelper.Error(nameof(filePath));
            }
            var json = JsonConvert.SerializeObject(config, Newtonsoft.Json.Formatting.Indented);
            File.WriteAllText(filePath, json);
        }
LB_SmartVisionCommon/FilterData.cs
¶Ô±ÈÐÂÎļþ
@@ -0,0 +1,80 @@
using Newtonsoft.Json;
using System;
using System.Collections.Generic;
using System.ComponentModel;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
namespace LB_SmartVisionCommon
{
    /// <summary>
    /// è®°å½•图像增强算子参数
    /// </summary>
    [JsonObject(MemberSerialization.OptOut)]
    [TypeConverter(typeof(PropertySorter))]
    public class RecordFilterData
    {
        /// <summary>
        /// ç®—子类型
        /// </summary>
        [Category("RecordFilterData"), PropertyOrder(1)]
        [DisplayName("滤波类型")]
        [Browsable(true)]
        public FilterType FilterName { get; set; } = FilterType.均值滤波_MeanImage;
        /// <summary>
        /// æŽ©è†œå®½åº¦
        /// </summary>
        [Category("RecordFilterData"), PropertyOrder(2)]
        [DisplayName("掩膜宽度")]
        [Browsable(true)]
        public string MaskWidth { get; set; }
        /// <summary>
        /// æŽ©è†œé«˜åº¦
        /// </summary>
        [Category("RecordFilterData"), PropertyOrder(3)]
        [DisplayName("掩膜高度")]
        [Browsable(true)]
        public string MaskHight { get; set; }
        /// <summary>
        /// å¢žå¼ºå› å­
        /// </summary>
        [Category("RecordFilterData"), PropertyOrder(4)]
        [DisplayName("高斯核尺寸")]
        [Browsable(true)]
        public string GaussSize { get; set; }
        /// <summary>
        /// å¤åˆ¶ç”¨æˆ·æ•°æ®
        /// </summary>
        public RecordFilterData Clone()
        {
            return new RecordFilterData
            {
                MaskWidth = this.MaskWidth,
                MaskHight = this.MaskHight,
                GaussSize = this.GaussSize,
                FilterName = this.FilterName
            };
        }
    }
    /// <summary>
    /// OperatorType
    /// </summary>
    public enum FilterType
    {
        /// <summary>
        /// FilterType:MeanImage
        /// </summary>
        å‡å€¼æ»¤æ³¢_MeanImage,
        /// <summary>
        /// FilterType:GaussFilter
        /// </summary>
        é«˜æ–¯æ»¤æ³¢_GaussFilter,
        /// <summary>
        /// FilterType:MedianRect
        /// </summary>
        ä¸­å€¼æ»¤æ³¢_MedianRect
    }
}
LB_SmartVisionCommon/FilterManager.cs
¶Ô±ÈÐÂÎļþ
@@ -0,0 +1,152 @@
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
namespace LB_SmartVisionCommon
{
    public class FilterManager
    {
        private Dictionary<FilterType, RecordFilterData> _filters;
        private readonly string _dataFilePath;
        private RecordFilterData _currentFilter;
        private static FilterManager _instance;
        /// <summary>
        /// çº¿ç¨‹é”
        /// </summary>
        private static readonly object _lock = new object();
        private FilterManager(string dataFilePath = "filters.json")
        {
            _dataFilePath = dataFilePath;
            _filters = new Dictionary<FilterType, RecordFilterData>();
            _currentFilter = null;
            LoadUsers();
        }
        public static FilterManager Instance
        {
            get
            {
                // åŒé‡æ£€æŸ¥é”å®šç¡®ä¿çº¿ç¨‹å®‰å…¨
                if (_instance == null)
                {
                    lock (_lock)
                    {
                        if (_instance == null)
                        {
                            _instance = new FilterManager();
                        }
                    }
                }
                return _instance;
            }
        }
        /// <summary>
        /// æ·»åŠ æ»¤æ³¢ç®—å­
        /// </summary>
        /// <param name="user"></param>
        /// <returns></returns>
        public bool AddFilter(RecordFilterData filter)
        {
            if (_currentFilter == null)
            {
                _currentFilter = filter;
            }
            try
            {
                RecordFilterData recordFilterData = new RecordFilterData();
                recordFilterData.MaskWidth = filter.MaskWidth;
                recordFilterData.MaskHight = filter.MaskHight;
                recordFilterData.GaussSize = filter.GaussSize;
                recordFilterData.FilterName = filter.FilterName;
                _filters.Add(recordFilterData.FilterName, recordFilterData);
            }
            catch (Exception ex)
            {
                MessageBox.Show("该算子已存在");
            }
            SaveUsers();
            return true;
        }
        /// <summary>
        /// åˆ é™¤å›¾åƒå¢žå¼ºç®—子
        /// </summary>
        /// <param name="filterName"></param>
        /// <returns></returns>
        public bool DeleteUser(RecordFilterData filter)
        {
            try
            {
                // 1. ä»Žå­—典中删除
                if (_filters.ContainsKey(filter.FilterName))
                {
                    _filters.Remove(filter.FilterName);
                }
                // 2. å¦‚果删除的是当前滤波,清空_currentFilter
                if (_currentFilter != null && _currentFilter.FilterName == filter.FilterName)
                {
                    _currentFilter = null;
                }
                // 3. ä¿å­˜æ›´æ”¹
                SaveUsers();
                return true;
            }
            catch (Exception ex)
            {
                // è®°å½•日志
                Console.WriteLine($"删除滤波失败: {ex.Message}");
                return false;
            }
        }
        /// <summary>
        /// èŽ·å–æ‰€æœ‰ç”¨æˆ·åˆ—è¡¨
        /// </summary>
        /// <returns>List<RecordUserData></returns>
        public List<RecordFilterData> GetAllUsers()
        {
            return _filters.Select(u => u.Value.Clone()).ToList();
        }
        #region json文件保存加载
        /// <summary>
        /// ä¿å­˜ç”¨æˆ·æ•°æ®åˆ°JSON文件
        /// </summary>
        private void SaveUsers()
        {
            try
            {
                ConfigManager<Dictionary<FilterType, RecordFilterData>>.SaveConfig<Dictionary<FilterType, RecordFilterData>>(_filters, _dataFilePath);
            }
            catch (Exception ex)
            {
                MessageBox.Show($"保存图像增强算子失败:{ex.Message}", "错误", MessageBoxButtons.OK, MessageBoxIcon.Error);
            }
        }
        /// <summary>
        /// ä»ŽJSON文件加载用户数据
        /// </summary>
        private void LoadUsers()
        {
            try
            {
                if (File.Exists(_dataFilePath))
                {
                    _filters = ConfigManager<Dictionary<FilterType, RecordFilterData>>.LoadConfig<Dictionary<FilterType, RecordFilterData>>(_dataFilePath) ?? new Dictionary<FilterType, RecordFilterData>();
                }
            }
            catch (Exception ex)
            {
                MessageBox.Show($"加载图像增强算子失败:{ex.Message}", "错误", MessageBoxButtons.OK, MessageBoxIcon.Error);
                _filters = new Dictionary<FilterType, RecordFilterData>();
            }
        }
        #endregion
    }
}
LB_SmartVisionCommon/ImageEnhancementData.cs
¶Ô±ÈÐÂÎļþ
@@ -0,0 +1,75 @@
using Newtonsoft.Json;
using System;
using System.Collections.Generic;
using System.ComponentModel;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
namespace LB_SmartVisionCommon
{
    /// <summary>
    /// è®°å½•图像增强算子参数
    /// </summary>
    [JsonObject(MemberSerialization.OptOut)]
    [TypeConverter(typeof(PropertySorter))]
    public class RecordImageEnhancementData
    {
        /// <summary>
        /// ç®—子类型
        /// </summary>
        [Category("RecordImageEnhancementData"), PropertyOrder(1)]
        [DisplayName("算子类型")]
        [Browsable(true)]
        public ImageEnhancementDataType FilterName { get; set; } = ImageEnhancementDataType.比例增强_ScaleImageMax;
        /// <summary>
        /// æŽ©è†œå®½åº¦
        /// </summary>
        [Category("RecordImageEnhancementData"), PropertyOrder(2)]
        [DisplayName("掩膜宽度")]
        [Browsable(true)]
        public string MaskWidth { get; set; }
        /// <summary>
        /// æŽ©è†œé«˜åº¦
        /// </summary>
        [Category("RecordImageEnhancementData"), PropertyOrder(3)]
        [DisplayName("掩膜高度")]
        [Browsable(true)]
        public string MaskHight { get; set; }
        /// <summary>
        /// å¢žå¼ºå› å­
        /// </summary>
        [Category("RecordImageEnhancementData"), PropertyOrder(4)]
        [DisplayName("增强因子")]
        [Browsable(true)]
        public string Factor { get; set; }
        /// <summary>
        /// å¤åˆ¶ç”¨æˆ·æ•°æ®
        /// </summary>
        public RecordImageEnhancementData Clone()
        {
            return new RecordImageEnhancementData
            {
                MaskWidth = this.MaskWidth,
                MaskHight = this.MaskHight,
                Factor = this.Factor,
                FilterName = this.FilterName
            };
        }
    }
    /// <summary>
    /// OperatorType
    /// </summary>
    public enum ImageEnhancementDataType
    {
        /// </summary>
        è¾¹ç¼˜å¢žå¼º_ImageEmphasize,
        /// </summary>
        ç›´æ–¹å›¾å‡è¡¡åŒ–_EquHistoImage,
        /// </summary>
        æ¯”例增强_ScaleImageMax
    }
}
LB_SmartVisionCommon/ImageEnhancementManager.cs
¶Ô±ÈÐÂÎļþ
@@ -0,0 +1,155 @@
using Microsoft.VisualBasic.ApplicationServices;
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
namespace LB_SmartVisionCommon
{
    public class ImageEnhancementManager
    {
        private Dictionary<ImageEnhancementDataType, RecordImageEnhancementData> _filters;
        private readonly string _dataFilePath;
        private RecordImageEnhancementData _currentFilter;
        private static ImageEnhancementManager _instance;
        /// <summary>
        /// çº¿ç¨‹é”
        /// </summary>
        private static readonly object _lock = new object();
        private ImageEnhancementManager(string dataFilePath = "imageEnhancements.json")
        {
            _dataFilePath = dataFilePath;
            _filters = new Dictionary<ImageEnhancementDataType, RecordImageEnhancementData>();
            _currentFilter = null;
            LoadUsers();
        }
        public static ImageEnhancementManager Instance
        {
            get
            {
                // åŒé‡æ£€æŸ¥é”å®šç¡®ä¿çº¿ç¨‹å®‰å…¨
                if (_instance == null)
                {
                    lock (_lock)
                    {
                        if (_instance == null)
                        {
                            _instance = new ImageEnhancementManager();
                        }
                    }
                }
                return _instance;
            }
        }
        /// <summary>
        /// æ·»åŠ å›¾åƒå¢žå¼ºç®—å­
        /// </summary>
        /// <param name="user"></param>
        /// <returns></returns>
        public bool AddUser(RecordImageEnhancementData filter)
        {
            if (_currentFilter == null)
            {
                _currentFilter = filter;
            }
            try
            {
                RecordImageEnhancementData recordImageEnhancementData = new RecordImageEnhancementData();
                recordImageEnhancementData.MaskWidth = filter.MaskWidth;
                recordImageEnhancementData.MaskHight = filter.MaskHight;
                recordImageEnhancementData.Factor = filter.Factor;
                recordImageEnhancementData.FilterName = filter.FilterName;
                _filters.Add(recordImageEnhancementData.FilterName, recordImageEnhancementData);
            }
            catch (Exception ex)
            {
                MessageBox.Show("该算子已存在");
            }
            SaveUsers();
            return true;
        }
        /// <summary>
        /// åˆ é™¤å›¾åƒå¢žå¼ºç®—子
        /// </summary>
        /// <param name="filter"></param>
        /// <returns></returns>
        public bool DeleteUser(RecordImageEnhancementData filter)
        {
            try
            {
                // 1. ä»Žå­—典中删除
                if (_filters.ContainsKey(filter.FilterName))
                {
                    _filters.Remove(filter.FilterName);
                }
                // 2. å¦‚果删除的是当前滤波,清空_currentFilter
                if (_currentFilter != null && _currentFilter.FilterName == filter.FilterName)
                {
                    _currentFilter = null;
                }
                // 3. ä¿å­˜æ›´æ”¹
                SaveUsers();
                return true;
            }
            catch (Exception ex)
            {
                // è®°å½•日志
                Console.WriteLine($"删除滤波失败: {ex.Message}");
                return false;
            }
        }
        /// <summary>
        /// èŽ·å–æ‰€æœ‰ç”¨æˆ·åˆ—è¡¨
        /// </summary>
        /// <returns>List<RecordUserData></returns>
        public List<RecordImageEnhancementData> GetAllUsers()
        {
            return _filters.Select(u => u.Value.Clone()).ToList();
        }
        #region json文件保存加载
        /// <summary>
        /// ä¿å­˜ç”¨æˆ·æ•°æ®åˆ°JSON文件
        /// </summary>
        private void SaveUsers()
        {
            try
            {
                ConfigManager<Dictionary<ImageEnhancementDataType, RecordImageEnhancementData>>.SaveConfig<Dictionary<ImageEnhancementDataType, RecordImageEnhancementData>>(_filters, _dataFilePath);
            }
            catch (Exception ex)
            {
                MessageBox.Show($"保存图像增强算子失败:{ex.Message}", "错误", MessageBoxButtons.OK, MessageBoxIcon.Error);
            }
        }
        /// <summary>
        /// ä»ŽJSON文件加载用户数据
        /// </summary>
        private void LoadUsers()
        {
            try
            {
                if (File.Exists(_dataFilePath))
                {
                    _filters = ConfigManager<Dictionary<ImageEnhancementDataType, RecordImageEnhancementData>>.LoadConfig<Dictionary<ImageEnhancementDataType, RecordImageEnhancementData>>(_dataFilePath) ?? new Dictionary<ImageEnhancementDataType, RecordImageEnhancementData>();
                }
            }
            catch (Exception ex)
            {
                MessageBox.Show($"加载图像增强算子失败:{ex.Message}", "错误", MessageBoxButtons.OK, MessageBoxIcon.Error);
                _filters = new Dictionary<ImageEnhancementDataType, RecordImageEnhancementData>();
            }
        }
        #endregion
    }
}
LB_SmartVisionCommon/UserManager.cs
@@ -113,11 +113,11 @@
            {
                _currentUser = user;
            }
            if (!CheckPermission(true))
            {
                MessageBox.Show("需要管理员权限才能添加用户!", "权限不足", MessageBoxButtons.OK, MessageBoxIcon.Warning);
                return false;
            }
            //if (!CheckPermission(true))
            //{
            //    MessageBox.Show("需要管理员权限才能添加用户!", "权限不足", MessageBoxButtons.OK, MessageBoxIcon.Warning);
            //    return false;
            //}
            if (_users.Any(u => u.Value.EmployeeNumber == user.EmployeeNumber ||
                               u.Value.EmployeeAccount == user.EmployeeAccount))
@@ -125,6 +125,7 @@
                MessageBox.Show("员工号或账号已存在!", "添加失败", MessageBoxButtons.OK, MessageBoxIcon.Warning);
                return false;
            }
            RecordUserData recordUserData = new RecordUserData();
            recordUserData.EmployeeNumber = user.EmployeeNumber;
            recordUserData.EmployeeAccount = user.EmployeeAccount;
@@ -143,18 +144,18 @@
        /// <returns>是否删除成功</returns>
        public bool DeleteUser(string employeeNumber)
        {
            if (!CheckPermission(true))
            {
                MessageBox.Show("需要管理员权限才能删除用户!", "权限不足", MessageBoxButtons.OK, MessageBoxIcon.Warning);
                return false;
            }
            //if (!CheckPermission(true))
            //{
            //    MessageBox.Show("需要管理员权限才能删除用户!", "权限不足", MessageBoxButtons.OK, MessageBoxIcon.Warning);
            //    return false;
            //}
            // ç®¡ç†å‘˜ä¸èƒ½åˆ é™¤è‡ªå·±
            if (_currentUser.EmployeeNumber == employeeNumber)
            {
                MessageBox.Show("不能删除当前登录的用户!", "删除失败", MessageBoxButtons.OK, MessageBoxIcon.Warning);
                return false;
            }
            //// ç®¡ç†å‘˜ä¸èƒ½åˆ é™¤è‡ªå·±
            //if (_currentUser.EmployeeNumber == employeeNumber)
            //{
            //    MessageBox.Show("不能删除当前登录的用户!", "删除失败", MessageBoxButtons.OK, MessageBoxIcon.Warning);
            //    return false;
            //}
            var user = _users.FirstOrDefault(u => u.Value.EmployeeNumber == employeeNumber);
            if (user.Value != null)
LB_VisionControl/UserHSmartWindowControl.Designer.cs
@@ -44,14 +44,15 @@
            // 
            // RightContextMenuStrip
            // 
            RightContextMenuStrip.ImageScalingSize = new Size(20, 20);
            RightContextMenuStrip.Items.AddRange(new ToolStripItem[] { resizeImageStripMenuItem, autoSizeStripMenuItem, mouseIndexStripMenuItem });
            RightContextMenuStrip.Name = "RightContextMenuStrip";
            RightContextMenuStrip.Size = new Size(149, 70);
            RightContextMenuStrip.Size = new Size(169, 82);
            // 
            // resizeImageStripMenuItem
            // 
            resizeImageStripMenuItem.Name = "resizeImageStripMenuItem";
            resizeImageStripMenuItem.Size = new Size(148, 22);
            resizeImageStripMenuItem.Size = new Size(168, 26);
            resizeImageStripMenuItem.Text = "重新缩放图像";
            resizeImageStripMenuItem.Click += resizeImageStripMenuItem_Click;
            // 
@@ -60,39 +61,41 @@
            autoSizeStripMenuItem.Checked = true;
            autoSizeStripMenuItem.CheckState = CheckState.Checked;
            autoSizeStripMenuItem.Name = "autoSizeStripMenuItem";
            autoSizeStripMenuItem.Size = new Size(148, 22);
            autoSizeStripMenuItem.Size = new Size(168, 26);
            autoSizeStripMenuItem.Text = "图像自动适应";
            autoSizeStripMenuItem.Click += autoSizeStripMenuItem_Click;
            // 
            // mouseIndexStripMenuItem
            // 
            mouseIndexStripMenuItem.Name = "mouseIndexStripMenuItem";
            mouseIndexStripMenuItem.Size = new Size(148, 22);
            mouseIndexStripMenuItem.Size = new Size(168, 26);
            mouseIndexStripMenuItem.Text = "鼠标索引像素";
            mouseIndexStripMenuItem.Click += mouseIndexStripMenuItem_Click;
            // 
            // BtmStatusStrip
            // 
            BtmStatusStrip.ImageScalingSize = new Size(20, 20);
            BtmStatusStrip.Items.AddRange(new ToolStripItem[] { StatusLabel });
            BtmStatusStrip.Location = new Point(0, 220);
            BtmStatusStrip.Location = new Point(0, 280);
            BtmStatusStrip.Name = "BtmStatusStrip";
            BtmStatusStrip.Padding = new Padding(1, 0, 16, 0);
            BtmStatusStrip.Size = new Size(274, 22);
            BtmStatusStrip.Padding = new Padding(1, 0, 20, 0);
            BtmStatusStrip.Size = new Size(342, 22);
            BtmStatusStrip.TabIndex = 44;
            BtmStatusStrip.Text = "statusStrip1";
            // 
            // StatusLabel
            // 
            StatusLabel.Name = "StatusLabel";
            StatusLabel.Size = new Size(0, 17);
            StatusLabel.Size = new Size(0, 16);
            // 
            // pnl
            // 
            pnl.Controls.Add(hWindowControl);
            pnl.Dock = DockStyle.Fill;
            pnl.Location = new Point(0, 0);
            pnl.Margin = new Padding(4);
            pnl.Name = "pnl";
            pnl.Size = new Size(274, 220);
            pnl.Size = new Size(342, 280);
            pnl.TabIndex = 45;
            // 
            // hWindowControl
@@ -104,29 +107,30 @@
            hWindowControl.Dock = DockStyle.Fill;
            hWindowControl.HDoubleClickToFitContent = true;
            hWindowControl.HDrawingObjectsModifier = HalconDotNet.HSmartWindowControl.DrawingObjectsModifier.None;
            hWindowControl.HImagePart = new Rectangle(0, 88, 2591, 1767);
            hWindowControl.HImagePart = new Rectangle(-321, -152, 3233, 2247);
            hWindowControl.HKeepAspectRatio = true;
            hWindowControl.HMoveContent = true;
            hWindowControl.HZoomContent = HalconDotNet.HSmartWindowControl.ZoomContent.WheelForwardZoomsIn;
            hWindowControl.Location = new Point(0, 0);
            hWindowControl.Margin = new Padding(4);
            hWindowControl.Margin = new Padding(5);
            hWindowControl.Name = "hWindowControl";
            hWindowControl.Size = new Size(274, 220);
            hWindowControl.Size = new Size(342, 280);
            hWindowControl.TabIndex = 43;
            hWindowControl.WindowSize = new Size(274, 220);
            hWindowControl.WindowSize = new Size(342, 280);
            hWindowControl.HMouseMove += hWindowControl_HMouseMove;
            hWindowControl.HMouseDown += hWindowControl_HMouseDown;
            hWindowControl.HMouseUp += hWindowControl_HMouseUp;
            hWindowControl.HMouseDoubleClick += hWindowControl_HMouseDoubleClick;
            // 
            // UserHSmartWindowControl
            // 
            AutoScaleDimensions = new SizeF(96F, 96F);
            AutoScaleDimensions = new SizeF(120F, 120F);
            AutoScaleMode = AutoScaleMode.Dpi;
            Controls.Add(pnl);
            Controls.Add(BtmStatusStrip);
            Margin = new Padding(4);
            Margin = new Padding(5);
            Name = "UserHSmartWindowControl";
            Size = new Size(274, 242);
            Size = new Size(342, 302);
            Load += UserHSmartWindowControl_Load;
            SizeChanged += UserHSmartWindowControl_SizeChanged;
            MouseWheel += UserHSmartWindowControl_HMouseWheel;
LB_VisionControl/UserHSmartWindowControl.cs
@@ -1,9 +1,12 @@
using HalconDotNet;
using Sunny.UI.Win32;
using System.Diagnostics;
using System.Windows.Forms;
namespace LB_VisionControl
{
    public delegate void Control_MouseDown(object sender, MouseEventArgs e);
    public delegate void Control_MouseDoubleClick(object sender, MouseEventArgs e);
    public partial class UserHSmartWindowControl : UserControl
    {
        public UserHSmartWindowControl()
@@ -19,7 +22,22 @@
            // è®¾ç½®é»˜è®¤å­—体为 20号 mono字体加粗
            set_display_font(this.hWindowControl.HalconWindow, 20, "mono", "true", "false");
        }
        public event Control_MouseDown event_MouseDown;
        public event Control_MouseDoubleClick event_MouseDoubleClick;
        private void event_mouseDown(object sender, MouseEventArgs e)
        {
            if (event_MouseDown != null)
            {
                event_MouseDown(sender, e);
            }
        }
        private void event_mouseDoubleClick(object sender, MouseEventArgs e)
        {
            if (event_MouseDoubleClick != null)
            {
                event_MouseDoubleClick(sender, e);
            }
        }
        private void UserHSmartWindowControl_Load(object sender, EventArgs e)
        {
            // å¯ç”¨åŒç¼“冲减少闪烁
@@ -969,6 +987,8 @@
                    default:
                        break;
                }
                MouseEventArgs mouseEventArgs = new MouseEventArgs(e.Button, e.Clicks, (int)e.X, (int)e.Y, e.Delta);
                event_mouseDown(sender, mouseEventArgs);
            }
            catch { }
        }
@@ -1171,5 +1191,11 @@
        {
            ShowHoImage(hImage);
        }
        private void hWindowControl_HMouseDoubleClick(object sender, HMouseEventArgs e)
        {
            MouseEventArgs mouseEventArgs = new MouseEventArgs(e.Button, e.Clicks, (int)e.X, (int)e.Y, e.Delta);
            event_mouseDoubleClick(sender, mouseEventArgs);
        }
    }
}
LB_VisionFlowNode/FlowPanel.cs
@@ -1,4 +1,5 @@
using System.Collections.Concurrent;
using LB_SmartVisionCommon;
using System.Collections.Concurrent;
using System.Diagnostics;
using System.Xml.Linq;
@@ -305,6 +306,7 @@
            bool result = Context.ExecuteNode(currentNode);
#if DEBUG
            Debug.WriteLine(DateTime.Now.ToString("[yyyy:MM:dd:HH:mm:ss:fff] ") + $"执行节点[{currentNode.Text}],结果为{result}");
            AsyncLogHelper.Debug(DateTime.Now.ToString("[yyyy:MM:dd:HH:mm:ss:fff] ") + $"执行节点[{currentNode.Text}],结果为{result}");
#endif
            context.BranchResults.TryAdd(context.CurrentBranchName, currentNode.Result);
            currentNode.Result = result;
LB_VisionFlowNode/IFlowContext.cs
@@ -280,12 +280,21 @@
        [Node("相机取图", "取像工具", "Basic", "相机取图")]
        public void ç›¸æœºå–图(FlowNode node) { RunNodeAsync(node); }
        [Node("Halcon2D斑点工具", "Haclon2D工具", "Basic", "Halcon2D斑点工具")]
        [Node("读码工具", "取像工具", "Basic", "读码工具")]
        public void è¯»ç å·¥å…·(FlowNode node) { RunNodeAsync(node); }
        [Node("Halcon2D斑点工具", "Halcon2D工具", "Basic", "Halcon2D斑点工具")]
        public void Halcon2D斑点工具(FlowNode node) { RunNodeAsync(node); }
        [Node("通讯模块", "通讯模块工具", "Basic", "通讯模块")]
        public void é€šè®¯æ¨¡å—(FlowNode node) { RunNodeAsync(node); }
        //  [Process("Halcon图像增强", Category = "Halcon2D工具", Description = "创建图像增强工具")]
        [Node("Halcon2D图像增强", "Halcon2D工具", "Basic", "Halcon2D图像增强")]
        public void Halcon2D图像增强(FlowNode node) { RunNodeAsync(node); }
        [Node("Halcon2D图像滤波", "Halcon2D工具", "Basic", "Halcon2D图像滤波")]
        public void Halcon2D图像滤波(FlowNode node) { RunNodeAsync(node); }
        #endregion
LB_VisionProcesses/Alogrithms/BaseAlgorithm/TAlgorithm.cs
@@ -3833,6 +3833,93 @@
        }
        /// <summary>
        /// å›¾åƒå¢žå¼ºç®—法-边缘增强
        /// </summary>
        /// <param name="ho_Image">待测图片</param>
        /// <param name="hv_ImageEnhancementType">滤波器类型(mean/gauss/median)</param>
        /// <param name="hv_Wid">掩膜宽</param>
        /// <param name="hv_High">掩膜高</param>
        /// <param name="hv_Fac">增强因子</param>
        public static void ImageEnhancement(HObject ho_Image, out HObject ho_OutImage, string hv_ImageEnhancementType, int hv_Wid, int hv_High, double hv_Fac)
        {
            HOperatorSet.GenEmptyObj(out ho_OutImage);
            try
            {
                // æ ¹æ®æ»¤æ³¢å™¨ç±»åž‹æ‰§è¡Œç›¸åº”操作
                switch (hv_ImageEnhancementType.ToLower())
                {
                    case "emphasize":
                        HOperatorSet.Emphasize(ho_Image, out ho_OutImage, hv_Wid, hv_High, hv_Fac);
                        break;
                    case "scaleimagemax":
                        HOperatorSet.ScaleImageMax(ho_Image, out ho_OutImage);
                        break;
                    case "equhisto":
                        HOperatorSet.EquHistoImage(ho_Image, out ho_OutImage);
                        break;
                    default:
                        throw new ArgumentException($"不支持的滤波器类型: {hv_ImageEnhancementType}");
                }
            }
            catch (Exception ex)
            {
                // ç¡®ä¿å¼‚常时释放资源
                ho_OutImage?.Dispose();
                throw new Exception($"图像滤波失败: {ex.Message}", ex);
            }
        }
        /// <summary>
        /// å›¾åƒæ»¤æ³¢
        /// </summary>
        /// <param name="ho_Image">待测图片</param>
        /// <param name="ho_OutImage">输出图片</param>
        /// <param name="hv_FilterType">滤波器类型(mean/gauss/median)</param>
        /// <param name="hv_Wid">掩膜宽</param>
        /// <param name="hv_High">掩膜高</param>
        /// <param name="hv_Size">高斯核尺寸</param>
        public static void Filter(HObject ho_Image, out HObject ho_OutImage, string hv_FilterType, int hv_Wid, int hv_High, int hv_Size)
        {
            // åˆå§‹åŒ–输出对象
            HOperatorSet.GenEmptyObj(out ho_OutImage);
            try
            {
                // æ ¹æ®æ»¤æ³¢å™¨ç±»åž‹æ‰§è¡Œç›¸åº”操作
                switch (hv_FilterType.ToLower())
                {
                    case "mean":
                        HOperatorSet.MeanImage(ho_Image, out ho_OutImage, hv_Wid, hv_High);
                        break;
                    case "gauss":
                    case "guass":  // å…¼å®¹æ‹¼å†™é”™è¯¯
                        HOperatorSet.GaussFilter(ho_Image, out ho_OutImage, hv_Size);
                        break;
                    case "median":
                        HOperatorSet.MedianRect(ho_Image, out ho_OutImage, hv_Wid, hv_High);
                        break;
                    default:
                        throw new ArgumentException($"不支持的滤波器类型: {hv_FilterType}");
                }
            }
            catch (Exception ex)
            {
                // ç¡®ä¿å¼‚常时释放资源
                ho_OutImage?.Dispose();
                throw new Exception($"图像滤波失败: {ex.Message}", ex);
            }
        }
        /// <summary>
        /// å¡å°ºç®—法
        /// </summary>
        /// <param name="ho_Image">待测图片</param>
LB_VisionProcesses/Alogrithms/Halcon/2D/HBlobTool/HBlobTool.cs
@@ -85,10 +85,13 @@
                    {
                        using (HImage hImage = new HImage())
                        {
                            Rectangle rect = new Rectangle(0, 0, ((Bitmap)InputImage).Width, ((Bitmap)InputImage).Height);
                            BitmapData srcBmpData = ((Bitmap)InputImage).LockBits(rect, ImageLockMode.ReadOnly, PixelFormat.Format32bppRgb);
                            hImage.GenImageInterleaved(srcBmpData.Scan0, "rgbx", ((Bitmap)InputImage).Width, ((Bitmap)InputImage).Height, 0, "byte", ((Bitmap)InputImage).Width, ((Bitmap)InputImage).Height, 0, 0, -1, 0);
                            ((Bitmap)InputImage).UnlockBits(srcBmpData);
                            Bitmap bitmap = (Bitmap)InputImage;
                            Rectangle rect = new Rectangle(0, 0, ((Bitmap)bitmap).Width, ((Bitmap)bitmap).Height);
                            BitmapData srcBmpData = ((Bitmap)bitmap).LockBits(rect, ImageLockMode.ReadOnly, PixelFormat.Format32bppRgb);
                            hImage.GenImageInterleaved(srcBmpData.Scan0, "rgbx", ((Bitmap)bitmap).Width, ((Bitmap)bitmap).Height, 0, "byte", ((Bitmap)bitmap).Width, ((Bitmap)bitmap).Height, 0, 0, -1, 0);
                            ((Bitmap)bitmap).UnlockBits(srcBmpData);
                            bitmap.Dispose();
                            bitmap = null;
                            InputImage = null;
                            InputImage = hImage.Clone();
                        }
LB_VisionProcesses/Alogrithms/Halcon/2D/HBlobTool/HBlobToolEdit.Designer.cs
@@ -155,9 +155,9 @@
            // tablePanelParas
            // 
            tablePanelParas.ColumnCount = 4;
            tablePanelParas.ColumnStyles.Add(new ColumnStyle(SizeType.Absolute, 90F));
            tablePanelParas.ColumnStyles.Add(new ColumnStyle(SizeType.Absolute, 116F));
            tablePanelParas.ColumnStyles.Add(new ColumnStyle(SizeType.Percent, 50F));
            tablePanelParas.ColumnStyles.Add(new ColumnStyle(SizeType.Absolute, 90F));
            tablePanelParas.ColumnStyles.Add(new ColumnStyle(SizeType.Absolute, 116F));
            tablePanelParas.ColumnStyles.Add(new ColumnStyle(SizeType.Percent, 50F));
            tablePanelParas.Controls.Add(dtxtMaxDistDeviation, 3, 7);
            tablePanelParas.Controls.Add(dtxtMinDistDeviation, 1, 7);
@@ -204,8 +204,8 @@
            tablePanelParas.Controls.Add(label32, 2, 7);
            tablePanelParas.Controls.Add(dtxtMinContlength, 1, 4);
            tablePanelParas.Dock = DockStyle.Fill;
            tablePanelParas.Location = new Point(3, 3);
            tablePanelParas.Margin = new Padding(2, 3, 2, 3);
            tablePanelParas.Location = new Point(4, 4);
            tablePanelParas.Margin = new Padding(3, 4, 3, 4);
            tablePanelParas.Name = "tablePanelParas";
            tablePanelParas.RowCount = 12;
            tablePanelParas.RowStyles.Add(new RowStyle(SizeType.Percent, 8.333333F));
@@ -220,284 +220,286 @@
            tablePanelParas.RowStyles.Add(new RowStyle(SizeType.Percent, 8.333333F));
            tablePanelParas.RowStyles.Add(new RowStyle(SizeType.Percent, 8.333333F));
            tablePanelParas.RowStyles.Add(new RowStyle(SizeType.Percent, 8.333333F));
            tablePanelParas.Size = new Size(386, 516);
            tablePanelParas.Size = new Size(498, 611);
            tablePanelParas.TabIndex = 0;
            // 
            // dtxtMaxDistDeviation
            // 
            dtxtMaxDistDeviation.Location = new Point(286, 297);
            dtxtMaxDistDeviation.Location = new Point(369, 354);
            dtxtMaxDistDeviation.Margin = new Padding(4);
            dtxtMaxDistDeviation.Name = "dtxtMaxDistDeviation";
            dtxtMaxDistDeviation.Size = new Size(97, 23);
            dtxtMaxDistDeviation.Size = new Size(124, 27);
            dtxtMaxDistDeviation.TabIndex = 36;
            dtxtMaxDistDeviation.Text = "0";
            // 
            // dtxtMinDistDeviation
            // 
            dtxtMinDistDeviation.Location = new Point(93, 297);
            dtxtMinDistDeviation.Location = new Point(120, 354);
            dtxtMinDistDeviation.Margin = new Padding(4);
            dtxtMinDistDeviation.Name = "dtxtMinDistDeviation";
            dtxtMinDistDeviation.Size = new Size(97, 23);
            dtxtMinDistDeviation.Size = new Size(124, 27);
            dtxtMinDistDeviation.TabIndex = 35;
            dtxtMinDistDeviation.Text = "0";
            // 
            // dtxtMaxDistMean
            // 
            dtxtMaxDistMean.Location = new Point(286, 255);
            dtxtMaxDistMean.Location = new Point(369, 304);
            dtxtMaxDistMean.Margin = new Padding(4);
            dtxtMaxDistMean.Name = "dtxtMaxDistMean";
            dtxtMaxDistMean.Size = new Size(97, 23);
            dtxtMaxDistMean.Size = new Size(124, 27);
            dtxtMaxDistMean.TabIndex = 34;
            dtxtMaxDistMean.Text = "0";
            // 
            // dtxtMinDistMean
            // 
            dtxtMinDistMean.Location = new Point(93, 255);
            dtxtMinDistMean.Location = new Point(120, 304);
            dtxtMinDistMean.Margin = new Padding(4);
            dtxtMinDistMean.Name = "dtxtMinDistMean";
            dtxtMinDistMean.Size = new Size(97, 23);
            dtxtMinDistMean.Size = new Size(124, 27);
            dtxtMinDistMean.TabIndex = 33;
            dtxtMinDistMean.Text = "0";
            // 
            // dtxtMaxAnisometry
            // 
            dtxtMaxAnisometry.Location = new Point(286, 213);
            dtxtMaxAnisometry.Location = new Point(369, 254);
            dtxtMaxAnisometry.Margin = new Padding(4);
            dtxtMaxAnisometry.Name = "dtxtMaxAnisometry";
            dtxtMaxAnisometry.Size = new Size(97, 23);
            dtxtMaxAnisometry.Size = new Size(124, 27);
            dtxtMaxAnisometry.TabIndex = 32;
            dtxtMaxAnisometry.Text = "0";
            // 
            // dtxtMinAnisometry
            // 
            dtxtMinAnisometry.Location = new Point(93, 213);
            dtxtMinAnisometry.Location = new Point(120, 254);
            dtxtMinAnisometry.Margin = new Padding(4);
            dtxtMinAnisometry.Name = "dtxtMinAnisometry";
            dtxtMinAnisometry.Size = new Size(97, 23);
            dtxtMinAnisometry.Size = new Size(124, 27);
            dtxtMinAnisometry.TabIndex = 31;
            dtxtMinAnisometry.Text = "0";
            // 
            // dtxtMaxContlength
            // 
            dtxtMaxContlength.Location = new Point(286, 171);
            dtxtMaxContlength.Location = new Point(369, 204);
            dtxtMaxContlength.Margin = new Padding(4);
            dtxtMaxContlength.Name = "dtxtMaxContlength";
            dtxtMaxContlength.Size = new Size(97, 23);
            dtxtMaxContlength.Size = new Size(124, 27);
            dtxtMaxContlength.TabIndex = 30;
            dtxtMaxContlength.Text = "0";
            // 
            // label1
            // 
            label1.AutoSize = true;
            label1.Location = new Point(2, 0);
            label1.Margin = new Padding(2, 0, 2, 0);
            label1.MaximumSize = new Size(0, 28);
            label1.MinimumSize = new Size(0, 28);
            label1.Location = new Point(3, 0);
            label1.MaximumSize = new Size(0, 33);
            label1.MinimumSize = new Size(0, 33);
            label1.Name = "label1";
            label1.Size = new Size(68, 28);
            label1.Size = new Size(84, 33);
            label1.TabIndex = 0;
            label1.Text = "最小灰度值";
            label1.TextAlign = ContentAlignment.MiddleCenter;
            // 
            // dtxtMinThreshold
            // 
            dtxtMinThreshold.Location = new Point(92, 3);
            dtxtMinThreshold.Margin = new Padding(2, 3, 2, 3);
            dtxtMinThreshold.Location = new Point(119, 4);
            dtxtMinThreshold.Margin = new Padding(3, 4, 3, 4);
            dtxtMinThreshold.Name = "dtxtMinThreshold";
            dtxtMinThreshold.Size = new Size(99, 23);
            dtxtMinThreshold.Size = new Size(126, 27);
            dtxtMinThreshold.TabIndex = 5;
            dtxtMinThreshold.Text = "0";
            // 
            // label2
            // 
            label2.AutoSize = true;
            label2.Location = new Point(195, 0);
            label2.Margin = new Padding(2, 0, 2, 0);
            label2.MaximumSize = new Size(0, 28);
            label2.MinimumSize = new Size(0, 28);
            label2.Location = new Point(252, 0);
            label2.MaximumSize = new Size(0, 33);
            label2.MinimumSize = new Size(0, 33);
            label2.Name = "label2";
            label2.Size = new Size(68, 28);
            label2.Size = new Size(84, 33);
            label2.TabIndex = 1;
            label2.Text = "最大灰度值";
            label2.TextAlign = ContentAlignment.MiddleCenter;
            // 
            // dtxtMaxThreshold
            // 
            dtxtMaxThreshold.Location = new Point(285, 3);
            dtxtMaxThreshold.Margin = new Padding(2, 3, 2, 3);
            dtxtMaxThreshold.Location = new Point(368, 4);
            dtxtMaxThreshold.Margin = new Padding(3, 4, 3, 4);
            dtxtMaxThreshold.Name = "dtxtMaxThreshold";
            dtxtMaxThreshold.Size = new Size(98, 23);
            dtxtMaxThreshold.Size = new Size(125, 27);
            dtxtMaxThreshold.TabIndex = 6;
            dtxtMaxThreshold.Text = "255";
            // 
            // label3
            // 
            label3.AutoSize = true;
            label3.Location = new Point(2, 42);
            label3.Margin = new Padding(2, 0, 2, 0);
            label3.MaximumSize = new Size(0, 28);
            label3.MinimumSize = new Size(0, 28);
            label3.Location = new Point(3, 50);
            label3.MaximumSize = new Size(0, 33);
            label3.MinimumSize = new Size(0, 33);
            label3.Name = "label3";
            label3.Size = new Size(56, 28);
            label3.Size = new Size(69, 33);
            label3.TabIndex = 2;
            label3.Text = "最小面积";
            label3.TextAlign = ContentAlignment.MiddleCenter;
            // 
            // dtxtMinArea
            // 
            dtxtMinArea.Location = new Point(92, 45);
            dtxtMinArea.Margin = new Padding(2, 3, 2, 3);
            dtxtMinArea.Location = new Point(119, 54);
            dtxtMinArea.Margin = new Padding(3, 4, 3, 4);
            dtxtMinArea.Name = "dtxtMinArea";
            dtxtMinArea.Size = new Size(99, 23);
            dtxtMinArea.Size = new Size(126, 27);
            dtxtMinArea.TabIndex = 7;
            dtxtMinArea.Text = "0";
            // 
            // label4
            // 
            label4.AutoSize = true;
            label4.Location = new Point(195, 42);
            label4.Margin = new Padding(2, 0, 2, 0);
            label4.MaximumSize = new Size(0, 28);
            label4.MinimumSize = new Size(0, 28);
            label4.Location = new Point(252, 50);
            label4.MaximumSize = new Size(0, 33);
            label4.MinimumSize = new Size(0, 33);
            label4.Name = "label4";
            label4.Size = new Size(56, 28);
            label4.Size = new Size(69, 33);
            label4.TabIndex = 3;
            label4.Text = "最大面积";
            label4.TextAlign = ContentAlignment.MiddleCenter;
            // 
            // dtxtMaxArea
            // 
            dtxtMaxArea.Location = new Point(285, 45);
            dtxtMaxArea.Margin = new Padding(2, 3, 2, 3);
            dtxtMaxArea.Location = new Point(368, 54);
            dtxtMaxArea.Margin = new Padding(3, 4, 3, 4);
            dtxtMaxArea.Name = "dtxtMaxArea";
            dtxtMaxArea.Size = new Size(98, 23);
            dtxtMaxArea.Size = new Size(125, 27);
            dtxtMaxArea.TabIndex = 8;
            dtxtMaxArea.Text = "0";
            // 
            // label10
            // 
            label10.AutoSize = true;
            label10.Location = new Point(2, 84);
            label10.Margin = new Padding(2, 0, 2, 0);
            label10.MaximumSize = new Size(0, 28);
            label10.MinimumSize = new Size(0, 28);
            label10.Location = new Point(3, 100);
            label10.MaximumSize = new Size(0, 33);
            label10.MinimumSize = new Size(0, 33);
            label10.Name = "label10";
            label10.Size = new Size(75, 28);
            label10.Size = new Size(93, 33);
            label10.TabIndex = 9;
            label10.Text = "最小纵坐标Y";
            label10.TextAlign = ContentAlignment.MiddleCenter;
            // 
            // dtxtMinRow
            // 
            dtxtMinRow.Location = new Point(92, 87);
            dtxtMinRow.Margin = new Padding(2, 3, 2, 3);
            dtxtMinRow.Location = new Point(119, 104);
            dtxtMinRow.Margin = new Padding(3, 4, 3, 4);
            dtxtMinRow.Name = "dtxtMinRow";
            dtxtMinRow.Size = new Size(99, 23);
            dtxtMinRow.Size = new Size(126, 27);
            dtxtMinRow.TabIndex = 9;
            dtxtMinRow.Text = "0";
            // 
            // label11
            // 
            label11.AutoSize = true;
            label11.Location = new Point(195, 84);
            label11.Margin = new Padding(2, 0, 2, 0);
            label11.MaximumSize = new Size(0, 28);
            label11.MinimumSize = new Size(0, 28);
            label11.Location = new Point(252, 100);
            label11.MaximumSize = new Size(0, 33);
            label11.MinimumSize = new Size(0, 33);
            label11.Name = "label11";
            label11.Size = new Size(75, 28);
            label11.Size = new Size(93, 33);
            label11.TabIndex = 10;
            label11.Text = "最大纵坐标Y";
            label11.TextAlign = ContentAlignment.MiddleCenter;
            // 
            // dtxtMaxRow
            // 
            dtxtMaxRow.Location = new Point(285, 87);
            dtxtMaxRow.Margin = new Padding(2, 3, 2, 3);
            dtxtMaxRow.Location = new Point(368, 104);
            dtxtMaxRow.Margin = new Padding(3, 4, 3, 4);
            dtxtMaxRow.Name = "dtxtMaxRow";
            dtxtMaxRow.Size = new Size(98, 23);
            dtxtMaxRow.Size = new Size(125, 27);
            dtxtMaxRow.TabIndex = 9;
            dtxtMaxRow.Text = "0";
            // 
            // label12
            // 
            label12.AutoSize = true;
            label12.Location = new Point(2, 126);
            label12.Margin = new Padding(2, 0, 2, 0);
            label12.MaximumSize = new Size(0, 28);
            label12.MinimumSize = new Size(0, 28);
            label12.Location = new Point(3, 150);
            label12.MaximumSize = new Size(0, 33);
            label12.MinimumSize = new Size(0, 33);
            label12.Name = "label12";
            label12.Size = new Size(76, 28);
            label12.Size = new Size(94, 33);
            label12.TabIndex = 11;
            label12.Text = "最小横坐标X";
            label12.TextAlign = ContentAlignment.MiddleCenter;
            // 
            // dtxtMinColumn
            // 
            dtxtMinColumn.Location = new Point(92, 129);
            dtxtMinColumn.Margin = new Padding(2, 3, 2, 3);
            dtxtMinColumn.Location = new Point(119, 154);
            dtxtMinColumn.Margin = new Padding(3, 4, 3, 4);
            dtxtMinColumn.Name = "dtxtMinColumn";
            dtxtMinColumn.Size = new Size(99, 23);
            dtxtMinColumn.Size = new Size(126, 27);
            dtxtMinColumn.TabIndex = 9;
            dtxtMinColumn.Text = "0";
            // 
            // label13
            // 
            label13.AutoSize = true;
            label13.Location = new Point(195, 126);
            label13.Margin = new Padding(2, 0, 2, 0);
            label13.MaximumSize = new Size(0, 28);
            label13.MinimumSize = new Size(0, 28);
            label13.Location = new Point(252, 150);
            label13.MaximumSize = new Size(0, 33);
            label13.MinimumSize = new Size(0, 33);
            label13.Name = "label13";
            label13.Size = new Size(76, 28);
            label13.Size = new Size(94, 33);
            label13.TabIndex = 12;
            label13.Text = "最大横坐标X";
            label13.TextAlign = ContentAlignment.MiddleCenter;
            // 
            // dtxtMaxColumn
            // 
            dtxtMaxColumn.Location = new Point(285, 129);
            dtxtMaxColumn.Margin = new Padding(2, 3, 2, 3);
            dtxtMaxColumn.Location = new Point(368, 154);
            dtxtMaxColumn.Margin = new Padding(3, 4, 3, 4);
            dtxtMaxColumn.Name = "dtxtMaxColumn";
            dtxtMaxColumn.Size = new Size(98, 23);
            dtxtMaxColumn.Size = new Size(125, 27);
            dtxtMaxColumn.TabIndex = 9;
            dtxtMaxColumn.Text = "0";
            // 
            // label19
            // 
            label19.AutoSize = true;
            label19.Location = new Point(3, 462);
            label19.Location = new Point(4, 550);
            label19.Margin = new Padding(4, 0, 4, 0);
            label19.Name = "label19";
            label19.Size = new Size(56, 17);
            label19.Size = new Size(69, 20);
            label19.TabIndex = 19;
            label19.Text = "最小数量";
            // 
            // dtxtMinCount
            // 
            dtxtMinCount.Location = new Point(93, 465);
            dtxtMinCount.Location = new Point(120, 554);
            dtxtMinCount.Margin = new Padding(4);
            dtxtMinCount.Name = "dtxtMinCount";
            dtxtMinCount.Size = new Size(97, 23);
            dtxtMinCount.Size = new Size(124, 27);
            dtxtMinCount.TabIndex = 17;
            dtxtMinCount.Text = "0";
            // 
            // label20
            // 
            label20.AutoSize = true;
            label20.Location = new Point(196, 462);
            label20.Location = new Point(253, 550);
            label20.Margin = new Padding(4, 0, 4, 0);
            label20.Name = "label20";
            label20.Size = new Size(56, 17);
            label20.Size = new Size(69, 20);
            label20.TabIndex = 20;
            label20.Text = "最大数量";
            // 
            // dtxtMaxCount
            // 
            dtxtMaxCount.Location = new Point(286, 465);
            dtxtMaxCount.Location = new Point(369, 554);
            dtxtMaxCount.Margin = new Padding(4);
            dtxtMaxCount.Name = "dtxtMaxCount";
            dtxtMaxCount.Size = new Size(97, 23);
            dtxtMaxCount.Size = new Size(124, 27);
            dtxtMaxCount.TabIndex = 18;
            dtxtMaxCount.Text = "9999";
            // 
            // label16
            // 
            label16.AutoSize = true;
            label16.Location = new Point(2, 378);
            label16.Margin = new Padding(2, 0, 2, 0);
            label16.MaximumSize = new Size(0, 28);
            label16.MinimumSize = new Size(0, 28);
            label16.Location = new Point(3, 450);
            label16.MaximumSize = new Size(0, 33);
            label16.MinimumSize = new Size(0, 33);
            label16.Name = "label16";
            label16.Size = new Size(68, 28);
            label16.Size = new Size(84, 33);
            label16.TabIndex = 15;
            label16.Text = "最小矩形度";
            label16.TextAlign = ContentAlignment.MiddleCenter;
@@ -505,173 +507,180 @@
            // label14
            // 
            label14.AutoSize = true;
            label14.Location = new Point(2, 336);
            label14.Margin = new Padding(2, 0, 2, 0);
            label14.MaximumSize = new Size(0, 28);
            label14.MinimumSize = new Size(0, 28);
            label14.Location = new Point(3, 400);
            label14.MaximumSize = new Size(0, 33);
            label14.MinimumSize = new Size(0, 33);
            label14.Name = "label14";
            label14.Size = new Size(56, 28);
            label14.Size = new Size(69, 33);
            label14.TabIndex = 13;
            label14.Text = "最小圆度";
            label14.TextAlign = ContentAlignment.MiddleCenter;
            // 
            // dtxtMinRectangularity
            // 
            dtxtMinRectangularity.Location = new Point(92, 381);
            dtxtMinRectangularity.Margin = new Padding(2, 3, 2, 3);
            dtxtMinRectangularity.Location = new Point(119, 454);
            dtxtMinRectangularity.Margin = new Padding(3, 4, 3, 4);
            dtxtMinRectangularity.Name = "dtxtMinRectangularity";
            dtxtMinRectangularity.Size = new Size(98, 23);
            dtxtMinRectangularity.Size = new Size(125, 27);
            dtxtMinRectangularity.TabIndex = 9;
            dtxtMinRectangularity.Text = "0";
            // 
            // dtxtMinCircularity
            // 
            dtxtMinCircularity.Location = new Point(92, 339);
            dtxtMinCircularity.Margin = new Padding(2, 3, 2, 3);
            dtxtMinCircularity.Location = new Point(119, 404);
            dtxtMinCircularity.Margin = new Padding(3, 4, 3, 4);
            dtxtMinCircularity.Name = "dtxtMinCircularity";
            dtxtMinCircularity.Size = new Size(98, 23);
            dtxtMinCircularity.Size = new Size(125, 27);
            dtxtMinCircularity.TabIndex = 9;
            dtxtMinCircularity.Text = "0";
            // 
            // label17
            // 
            label17.AutoSize = true;
            label17.Location = new Point(195, 378);
            label17.Margin = new Padding(2, 0, 2, 0);
            label17.MaximumSize = new Size(0, 28);
            label17.MinimumSize = new Size(0, 28);
            label17.Location = new Point(252, 450);
            label17.MaximumSize = new Size(0, 33);
            label17.MinimumSize = new Size(0, 33);
            label17.Name = "label17";
            label17.Size = new Size(68, 28);
            label17.Size = new Size(84, 33);
            label17.TabIndex = 16;
            label17.Text = "最大矩形度";
            label17.TextAlign = ContentAlignment.MiddleCenter;
            // 
            // dtxtMaxRectangularity
            // 
            dtxtMaxRectangularity.Location = new Point(285, 381);
            dtxtMaxRectangularity.Margin = new Padding(2, 3, 2, 3);
            dtxtMaxRectangularity.Location = new Point(368, 454);
            dtxtMaxRectangularity.Margin = new Padding(3, 4, 3, 4);
            dtxtMaxRectangularity.Name = "dtxtMaxRectangularity";
            dtxtMaxRectangularity.Size = new Size(98, 23);
            dtxtMaxRectangularity.Size = new Size(125, 27);
            dtxtMaxRectangularity.TabIndex = 10;
            dtxtMaxRectangularity.Text = "1";
            // 
            // label15
            // 
            label15.AutoSize = true;
            label15.Location = new Point(195, 336);
            label15.Margin = new Padding(2, 0, 2, 0);
            label15.MaximumSize = new Size(0, 28);
            label15.MinimumSize = new Size(0, 28);
            label15.Location = new Point(252, 400);
            label15.MaximumSize = new Size(0, 33);
            label15.MinimumSize = new Size(0, 33);
            label15.Name = "label15";
            label15.Size = new Size(56, 28);
            label15.Size = new Size(69, 33);
            label15.TabIndex = 14;
            label15.Text = "最大圆度";
            label15.TextAlign = ContentAlignment.MiddleCenter;
            // 
            // dtxtMaxCircularity
            // 
            dtxtMaxCircularity.Location = new Point(285, 339);
            dtxtMaxCircularity.Margin = new Padding(2, 3, 2, 3);
            dtxtMaxCircularity.Location = new Point(368, 404);
            dtxtMaxCircularity.Margin = new Padding(3, 4, 3, 4);
            dtxtMaxCircularity.Name = "dtxtMaxCircularity";
            dtxtMaxCircularity.Size = new Size(98, 23);
            dtxtMaxCircularity.Size = new Size(125, 27);
            dtxtMaxCircularity.TabIndex = 9;
            dtxtMaxCircularity.Text = "1";
            // 
            // label25
            // 
            label25.AutoSize = true;
            label25.Location = new Point(3, 168);
            label25.Location = new Point(4, 200);
            label25.Margin = new Padding(4, 0, 4, 0);
            label25.Name = "label25";
            label25.Size = new Size(56, 17);
            label25.Size = new Size(69, 20);
            label25.TabIndex = 21;
            label25.Text = "最小周长";
            // 
            // label26
            // 
            label26.AutoSize = true;
            label26.Location = new Point(3, 210);
            label26.Location = new Point(4, 250);
            label26.Margin = new Padding(4, 0, 4, 0);
            label26.Name = "label26";
            label26.Size = new Size(68, 17);
            label26.Size = new Size(84, 20);
            label26.TabIndex = 22;
            label26.Text = "最小宽高比";
            // 
            // label27
            // 
            label27.AutoSize = true;
            label27.Location = new Point(3, 252);
            label27.Location = new Point(4, 300);
            label27.Margin = new Padding(4, 0, 4, 0);
            label27.Name = "label27";
            label27.Size = new Size(80, 17);
            label27.Size = new Size(99, 20);
            label27.TabIndex = 23;
            label27.Text = "边距最小平均";
            // 
            // label28
            // 
            label28.AutoSize = true;
            label28.Location = new Point(3, 294);
            label28.Location = new Point(4, 350);
            label28.Margin = new Padding(4, 0, 4, 0);
            label28.Name = "label28";
            label28.Size = new Size(80, 17);
            label28.Size = new Size(99, 20);
            label28.TabIndex = 24;
            label28.Text = "边距最小方差";
            // 
            // label29
            // 
            label29.AutoSize = true;
            label29.Location = new Point(196, 168);
            label29.Location = new Point(253, 200);
            label29.Margin = new Padding(4, 0, 4, 0);
            label29.Name = "label29";
            label29.Size = new Size(56, 17);
            label29.Size = new Size(69, 20);
            label29.TabIndex = 25;
            label29.Text = "最大周长";
            // 
            // label30
            // 
            label30.AutoSize = true;
            label30.Location = new Point(196, 210);
            label30.Location = new Point(253, 250);
            label30.Margin = new Padding(4, 0, 4, 0);
            label30.Name = "label30";
            label30.Size = new Size(68, 17);
            label30.Size = new Size(84, 20);
            label30.TabIndex = 26;
            label30.Text = "最大宽高比";
            // 
            // label31
            // 
            label31.AutoSize = true;
            label31.Location = new Point(196, 252);
            label31.Location = new Point(253, 300);
            label31.Margin = new Padding(4, 0, 4, 0);
            label31.Name = "label31";
            label31.Size = new Size(80, 17);
            label31.Size = new Size(99, 20);
            label31.TabIndex = 27;
            label31.Text = "边距最大平均";
            // 
            // label32
            // 
            label32.AutoSize = true;
            label32.Location = new Point(196, 294);
            label32.Location = new Point(253, 350);
            label32.Margin = new Padding(4, 0, 4, 0);
            label32.Name = "label32";
            label32.Size = new Size(80, 17);
            label32.Size = new Size(99, 20);
            label32.TabIndex = 28;
            label32.Text = "边距最大方差";
            // 
            // dtxtMinContlength
            // 
            dtxtMinContlength.Location = new Point(93, 171);
            dtxtMinContlength.Location = new Point(120, 204);
            dtxtMinContlength.Margin = new Padding(4);
            dtxtMinContlength.Name = "dtxtMinContlength";
            dtxtMinContlength.Size = new Size(97, 23);
            dtxtMinContlength.Size = new Size(124, 27);
            dtxtMinContlength.TabIndex = 29;
            dtxtMinContlength.Text = "0";
            // 
            // pnlInputImage
            // 
            pnlInputImage.Dock = DockStyle.Fill;
            pnlInputImage.Location = new Point(3, 3);
            pnlInputImage.Margin = new Padding(4);
            pnlInputImage.Location = new Point(4, 4);
            pnlInputImage.Margin = new Padding(5);
            pnlInputImage.Name = "pnlInputImage";
            pnlInputImage.Size = new Size(626, 516);
            pnlInputImage.Size = new Size(807, 611);
            pnlInputImage.TabIndex = 44;
            // 
            // TopToolStrip
            // 
            TopToolStrip.ImageScalingSize = new Size(20, 20);
            TopToolStrip.Items.AddRange(new ToolStripItem[] { btnRun, btnLoadImage, btnSaveParas, btnLoadParas });
            TopToolStrip.Location = new Point(0, 0);
            TopToolStrip.Name = "TopToolStrip";
            TopToolStrip.Size = new Size(1044, 25);
            TopToolStrip.Size = new Size(1342, 27);
            TopToolStrip.TabIndex = 45;
            TopToolStrip.Text = "toolStrip1";
            // 
@@ -680,7 +689,7 @@
            btnRun.BackgroundImageLayout = ImageLayout.Zoom;
            btnRun.ImageTransparentColor = Color.Magenta;
            btnRun.Name = "btnRun";
            btnRun.Size = new Size(36, 22);
            btnRun.Size = new Size(43, 24);
            btnRun.Text = "运行";
            btnRun.Click += btnRun_Click;
            // 
@@ -688,7 +697,7 @@
            // 
            btnLoadImage.ImageTransparentColor = Color.Magenta;
            btnLoadImage.Name = "btnLoadImage";
            btnLoadImage.Size = new Size(36, 22);
            btnLoadImage.Size = new Size(43, 24);
            btnLoadImage.Text = "导图";
            btnLoadImage.Click += btnLoadImage_Click;
            // 
@@ -696,7 +705,7 @@
            // 
            btnSaveParas.ImageTransparentColor = Color.Magenta;
            btnSaveParas.Name = "btnSaveParas";
            btnSaveParas.Size = new Size(36, 22);
            btnSaveParas.Size = new Size(43, 24);
            btnSaveParas.Text = "保存";
            btnSaveParas.Click += btnSaveParas_Click;
            // 
@@ -704,35 +713,37 @@
            // 
            btnLoadParas.ImageTransparentColor = Color.Magenta;
            btnLoadParas.Name = "btnLoadParas";
            btnLoadParas.Size = new Size(36, 22);
            btnLoadParas.Size = new Size(43, 24);
            btnLoadParas.Text = "加载";
            btnLoadParas.Click += btnLoadParas_Click;
            // 
            // BtmStatusStrip
            // 
            BtmStatusStrip.ImageScalingSize = new Size(20, 20);
            BtmStatusStrip.Items.AddRange(new ToolStripItem[] { lblResult, lblMsg, lblRunTime });
            BtmStatusStrip.Location = new Point(0, 577);
            BtmStatusStrip.Location = new Point(0, 679);
            BtmStatusStrip.Name = "BtmStatusStrip";
            BtmStatusStrip.Size = new Size(1044, 22);
            BtmStatusStrip.Padding = new Padding(1, 0, 18, 0);
            BtmStatusStrip.Size = new Size(1342, 26);
            BtmStatusStrip.TabIndex = 46;
            BtmStatusStrip.Text = "statusStrip1";
            // 
            // lblResult
            // 
            lblResult.Name = "lblResult";
            lblResult.Size = new Size(34, 17);
            lblResult.Size = new Size(42, 20);
            lblResult.Text = "True";
            // 
            // lblMsg
            // 
            lblMsg.Name = "lblMsg";
            lblMsg.Size = new Size(56, 17);
            lblMsg.Size = new Size(69, 20);
            lblMsg.Text = "运行成功";
            // 
            // lblRunTime
            // 
            lblRunTime.Name = "lblRunTime";
            lblRunTime.Size = new Size(32, 17);
            lblRunTime.Size = new Size(39, 20);
            lblRunTime.Text = "0ms";
            // 
            // parasTabControl
@@ -742,18 +753,20 @@
            parasTabControl.Controls.Add(tabPage2);
            parasTabControl.Dock = DockStyle.Fill;
            parasTabControl.Location = new Point(0, 0);
            parasTabControl.Margin = new Padding(4);
            parasTabControl.Name = "parasTabControl";
            parasTabControl.SelectedIndex = 0;
            parasTabControl.Size = new Size(400, 552);
            parasTabControl.Size = new Size(514, 652);
            parasTabControl.TabIndex = 48;
            // 
            // tabPage1
            // 
            tabPage1.Controls.Add(tablePanelParas);
            tabPage1.Location = new Point(4, 26);
            tabPage1.Location = new Point(4, 29);
            tabPage1.Margin = new Padding(4);
            tabPage1.Name = "tabPage1";
            tabPage1.Padding = new Padding(3);
            tabPage1.Size = new Size(392, 522);
            tabPage1.Padding = new Padding(4);
            tabPage1.Size = new Size(506, 619);
            tabPage1.TabIndex = 0;
            tabPage1.Text = "输入参数";
            tabPage1.UseVisualStyleBackColor = true;
@@ -761,9 +774,10 @@
            // tabPage5
            // 
            tabPage5.Controls.Add(tableLayoutPanel2);
            tabPage5.Location = new Point(4, 26);
            tabPage5.Location = new Point(4, 29);
            tabPage5.Margin = new Padding(4);
            tabPage5.Name = "tabPage5";
            tabPage5.Size = new Size(392, 522);
            tabPage5.Size = new Size(506, 619);
            tabPage5.TabIndex = 2;
            tabPage5.Text = "运行参数";
            tabPage5.UseVisualStyleBackColor = true;
@@ -771,9 +785,9 @@
            // tableLayoutPanel2
            // 
            tableLayoutPanel2.ColumnCount = 4;
            tableLayoutPanel2.ColumnStyles.Add(new ColumnStyle(SizeType.Absolute, 60F));
            tableLayoutPanel2.ColumnStyles.Add(new ColumnStyle(SizeType.Absolute, 150F));
            tableLayoutPanel2.ColumnStyles.Add(new ColumnStyle(SizeType.Absolute, 40F));
            tableLayoutPanel2.ColumnStyles.Add(new ColumnStyle(SizeType.Absolute, 77F));
            tableLayoutPanel2.ColumnStyles.Add(new ColumnStyle(SizeType.Absolute, 193F));
            tableLayoutPanel2.ColumnStyles.Add(new ColumnStyle(SizeType.Absolute, 51F));
            tableLayoutPanel2.ColumnStyles.Add(new ColumnStyle(SizeType.Percent, 100F));
            tableLayoutPanel2.Controls.Add(cmbTypeRoi, 1, 0);
            tableLayoutPanel2.Controls.Add(label21, 0, 0);
@@ -786,21 +800,23 @@
            tableLayoutPanel2.Controls.Add(tableLayoutPanel3, 3, 2);
            tableLayoutPanel2.Dock = DockStyle.Fill;
            tableLayoutPanel2.Location = new Point(0, 0);
            tableLayoutPanel2.Margin = new Padding(4);
            tableLayoutPanel2.Name = "tableLayoutPanel2";
            tableLayoutPanel2.RowCount = 3;
            tableLayoutPanel2.RowStyles.Add(new RowStyle(SizeType.Absolute, 30F));
            tableLayoutPanel2.RowStyles.Add(new RowStyle(SizeType.Absolute, 30F));
            tableLayoutPanel2.RowStyles.Add(new RowStyle(SizeType.Absolute, 35F));
            tableLayoutPanel2.RowStyles.Add(new RowStyle(SizeType.Absolute, 35F));
            tableLayoutPanel2.RowStyles.Add(new RowStyle(SizeType.Percent, 100F));
            tableLayoutPanel2.Size = new Size(392, 522);
            tableLayoutPanel2.Size = new Size(506, 619);
            tableLayoutPanel2.TabIndex = 4;
            // 
            // cmbTypeRoi
            // 
            cmbTypeRoi.Dock = DockStyle.Fill;
            cmbTypeRoi.FormattingEnabled = true;
            cmbTypeRoi.Location = new Point(63, 3);
            cmbTypeRoi.Location = new Point(81, 4);
            cmbTypeRoi.Margin = new Padding(4);
            cmbTypeRoi.Name = "cmbTypeRoi";
            cmbTypeRoi.Size = new Size(144, 25);
            cmbTypeRoi.Size = new Size(185, 28);
            cmbTypeRoi.TabIndex = 1;
            cmbTypeRoi.SelectedIndexChanged += cmbTypeRoi_SelectedIndexChanged;
            // 
@@ -808,9 +824,10 @@
            // 
            label21.AutoSize = true;
            label21.Dock = DockStyle.Fill;
            label21.Location = new Point(3, 0);
            label21.Location = new Point(4, 0);
            label21.Margin = new Padding(4, 0, 4, 0);
            label21.Name = "label21";
            label21.Size = new Size(54, 30);
            label21.Size = new Size(69, 35);
            label21.TabIndex = 3;
            label21.Text = "ROI";
            label21.TextAlign = ContentAlignment.MiddleCenter;
@@ -819,9 +836,10 @@
            // 
            label22.AutoSize = true;
            label22.Dock = DockStyle.Fill;
            label22.Location = new Point(3, 30);
            label22.Location = new Point(4, 35);
            label22.Margin = new Padding(4, 0, 4, 0);
            label22.Name = "label22";
            label22.Size = new Size(54, 30);
            label22.Size = new Size(69, 35);
            label22.TabIndex = 4;
            label22.Text = "Fixture";
            label22.TextAlign = ContentAlignment.MiddleCenter;
@@ -830,9 +848,10 @@
            // 
            cmbFixture.Dock = DockStyle.Fill;
            cmbFixture.FormattingEnabled = true;
            cmbFixture.Location = new Point(63, 33);
            cmbFixture.Location = new Point(81, 39);
            cmbFixture.Margin = new Padding(4);
            cmbFixture.Name = "cmbFixture";
            cmbFixture.Size = new Size(144, 25);
            cmbFixture.Size = new Size(185, 28);
            cmbFixture.TabIndex = 5;
            cmbFixture.SelectedIndexChanged += cmbFixture_SelectedIndexChanged;
            // 
@@ -840,9 +859,10 @@
            // 
            ckbDrawRoi.AutoSize = true;
            ckbDrawRoi.CheckAlign = ContentAlignment.MiddleCenter;
            ckbDrawRoi.Location = new Point(213, 3);
            ckbDrawRoi.Location = new Point(274, 4);
            ckbDrawRoi.Margin = new Padding(4);
            ckbDrawRoi.Name = "ckbDrawRoi";
            ckbDrawRoi.Size = new Size(15, 14);
            ckbDrawRoi.Size = new Size(18, 17);
            ckbDrawRoi.TabIndex = 2;
            ckbDrawRoi.UseVisualStyleBackColor = true;
            ckbDrawRoi.CheckedChanged += ckbDrawRoi_CheckedChanged;
@@ -851,9 +871,10 @@
            // 
            ckbListAfter.Dock = DockStyle.Fill;
            ckbListAfter.FormattingEnabled = true;
            ckbListAfter.Location = new Point(63, 63);
            ckbListAfter.Location = new Point(81, 74);
            ckbListAfter.Margin = new Padding(4);
            ckbListAfter.Name = "ckbListAfter";
            ckbListAfter.Size = new Size(144, 456);
            ckbListAfter.Size = new Size(185, 541);
            ckbListAfter.TabIndex = 6;
            // 
            // tableLayoutPanel1
@@ -865,23 +886,25 @@
            tableLayoutPanel1.Controls.Add(btnUp, 0, 2);
            tableLayoutPanel1.Controls.Add(btnDown, 0, 3);
            tableLayoutPanel1.Dock = DockStyle.Fill;
            tableLayoutPanel1.Location = new Point(213, 63);
            tableLayoutPanel1.Location = new Point(274, 74);
            tableLayoutPanel1.Margin = new Padding(4);
            tableLayoutPanel1.Name = "tableLayoutPanel1";
            tableLayoutPanel1.RowCount = 5;
            tableLayoutPanel1.RowStyles.Add(new RowStyle(SizeType.Absolute, 30F));
            tableLayoutPanel1.RowStyles.Add(new RowStyle(SizeType.Absolute, 30F));
            tableLayoutPanel1.RowStyles.Add(new RowStyle(SizeType.Absolute, 30F));
            tableLayoutPanel1.RowStyles.Add(new RowStyle(SizeType.Absolute, 30F));
            tableLayoutPanel1.RowStyles.Add(new RowStyle(SizeType.Absolute, 35F));
            tableLayoutPanel1.RowStyles.Add(new RowStyle(SizeType.Absolute, 35F));
            tableLayoutPanel1.RowStyles.Add(new RowStyle(SizeType.Absolute, 35F));
            tableLayoutPanel1.RowStyles.Add(new RowStyle(SizeType.Absolute, 35F));
            tableLayoutPanel1.RowStyles.Add(new RowStyle(SizeType.Percent, 100F));
            tableLayoutPanel1.Size = new Size(34, 456);
            tableLayoutPanel1.Size = new Size(43, 541);
            tableLayoutPanel1.TabIndex = 7;
            // 
            // btnAdd
            // 
            btnAdd.Dock = DockStyle.Fill;
            btnAdd.Location = new Point(3, 3);
            btnAdd.Location = new Point(4, 4);
            btnAdd.Margin = new Padding(4);
            btnAdd.Name = "btnAdd";
            btnAdd.Size = new Size(28, 24);
            btnAdd.Size = new Size(35, 27);
            btnAdd.TabIndex = 0;
            btnAdd.Text = "+";
            btnAdd.UseVisualStyleBackColor = true;
@@ -889,9 +912,10 @@
            // btnDel
            // 
            btnDel.Dock = DockStyle.Fill;
            btnDel.Location = new Point(3, 33);
            btnDel.Location = new Point(4, 39);
            btnDel.Margin = new Padding(4);
            btnDel.Name = "btnDel";
            btnDel.Size = new Size(28, 24);
            btnDel.Size = new Size(35, 27);
            btnDel.TabIndex = 1;
            btnDel.Text = "-";
            btnDel.UseVisualStyleBackColor = true;
@@ -899,9 +923,10 @@
            // btnUp
            // 
            btnUp.Dock = DockStyle.Fill;
            btnUp.Location = new Point(3, 63);
            btnUp.Location = new Point(4, 74);
            btnUp.Margin = new Padding(4);
            btnUp.Name = "btnUp";
            btnUp.Size = new Size(28, 24);
            btnUp.Size = new Size(35, 27);
            btnUp.TabIndex = 2;
            btnUp.Text = "↑";
            btnUp.UseVisualStyleBackColor = true;
@@ -909,9 +934,10 @@
            // btnDown
            // 
            btnDown.Dock = DockStyle.Fill;
            btnDown.Location = new Point(3, 93);
            btnDown.Location = new Point(4, 109);
            btnDown.Margin = new Padding(4);
            btnDown.Name = "btnDown";
            btnDown.Size = new Size(28, 24);
            btnDown.Size = new Size(35, 27);
            btnDown.TabIndex = 3;
            btnDown.Text = "↓";
            btnDown.UseVisualStyleBackColor = true;
@@ -920,9 +946,10 @@
            // 
            label24.AutoSize = true;
            label24.Dock = DockStyle.Fill;
            label24.Location = new Point(3, 60);
            label24.Location = new Point(4, 70);
            label24.Margin = new Padding(4, 0, 4, 0);
            label24.Name = "label24";
            label24.Size = new Size(54, 462);
            label24.Size = new Size(69, 549);
            label24.TabIndex = 8;
            label24.Text = "形态学";
            label24.TextAlign = ContentAlignment.TopCenter;
@@ -930,46 +957,50 @@
            // tableLayoutPanel3
            // 
            tableLayoutPanel3.ColumnCount = 1;
            tableLayoutPanel3.ColumnStyles.Add(new ColumnStyle(SizeType.Absolute, 60F));
            tableLayoutPanel3.ColumnStyles.Add(new ColumnStyle(SizeType.Absolute, 175F));
            tableLayoutPanel3.Controls.Add(cmbProcessType, 0, 1);
            tableLayoutPanel3.Controls.Add(cmbShapeType, 0, 2);
            tableLayoutPanel3.Controls.Add(lblTips, 0, 3);
            tableLayoutPanel3.Controls.Add(tableLayoutPanel4, 0, 0);
            tableLayoutPanel3.Dock = DockStyle.Fill;
            tableLayoutPanel3.Location = new Point(253, 63);
            tableLayoutPanel3.Location = new Point(325, 74);
            tableLayoutPanel3.Margin = new Padding(4);
            tableLayoutPanel3.Name = "tableLayoutPanel3";
            tableLayoutPanel3.RowCount = 4;
            tableLayoutPanel3.RowStyles.Add(new RowStyle(SizeType.Absolute, 41F));
            tableLayoutPanel3.RowStyles.Add(new RowStyle(SizeType.Absolute, 35F));
            tableLayoutPanel3.RowStyles.Add(new RowStyle(SizeType.Absolute, 30F));
            tableLayoutPanel3.RowStyles.Add(new RowStyle(SizeType.Absolute, 30F));
            tableLayoutPanel3.RowStyles.Add(new RowStyle(SizeType.Absolute, 35F));
            tableLayoutPanel3.RowStyles.Add(new RowStyle(SizeType.Percent, 100F));
            tableLayoutPanel3.Size = new Size(136, 456);
            tableLayoutPanel3.Size = new Size(177, 541);
            tableLayoutPanel3.TabIndex = 9;
            // 
            // cmbProcessType
            // 
            cmbProcessType.Dock = DockStyle.Fill;
            cmbProcessType.FormattingEnabled = true;
            cmbProcessType.Location = new Point(3, 38);
            cmbProcessType.Location = new Point(4, 45);
            cmbProcessType.Margin = new Padding(4);
            cmbProcessType.Name = "cmbProcessType";
            cmbProcessType.Size = new Size(130, 25);
            cmbProcessType.Size = new Size(169, 28);
            cmbProcessType.TabIndex = 3;
            // 
            // cmbShapeType
            // 
            cmbShapeType.Dock = DockStyle.Fill;
            cmbShapeType.FormattingEnabled = true;
            cmbShapeType.Location = new Point(3, 68);
            cmbShapeType.Location = new Point(4, 80);
            cmbShapeType.Margin = new Padding(4);
            cmbShapeType.Name = "cmbShapeType";
            cmbShapeType.Size = new Size(130, 25);
            cmbShapeType.Size = new Size(169, 28);
            cmbShapeType.TabIndex = 5;
            // 
            // lblTips
            // 
            lblTips.AutoSize = true;
            lblTips.Location = new Point(3, 95);
            lblTips.Location = new Point(4, 111);
            lblTips.Margin = new Padding(4, 0, 4, 0);
            lblTips.Name = "lblTips";
            lblTips.Size = new Size(32, 17);
            lblTips.Size = new Size(39, 20);
            lblTips.TabIndex = 6;
            lblTips.Text = "提示";
            // 
@@ -980,38 +1011,42 @@
            tableLayoutPanel4.ColumnStyles.Add(new ColumnStyle(SizeType.Percent, 50F));
            tableLayoutPanel4.Controls.Add(txtAfterProcessWidth, 0, 0);
            tableLayoutPanel4.Controls.Add(txtAfterProcessHeight, 1, 0);
            tableLayoutPanel4.Location = new Point(3, 3);
            tableLayoutPanel4.Location = new Point(4, 4);
            tableLayoutPanel4.Margin = new Padding(4);
            tableLayoutPanel4.Name = "tableLayoutPanel4";
            tableLayoutPanel4.RowCount = 1;
            tableLayoutPanel4.RowStyles.Add(new RowStyle(SizeType.Percent, 50F));
            tableLayoutPanel4.Size = new Size(130, 29);
            tableLayoutPanel4.Size = new Size(167, 33);
            tableLayoutPanel4.TabIndex = 7;
            // 
            // txtAfterProcessWidth
            // 
            txtAfterProcessWidth.Dock = DockStyle.Fill;
            txtAfterProcessWidth.Location = new Point(3, 3);
            txtAfterProcessWidth.Location = new Point(4, 4);
            txtAfterProcessWidth.Margin = new Padding(4);
            txtAfterProcessWidth.Name = "txtAfterProcessWidth";
            txtAfterProcessWidth.Size = new Size(59, 23);
            txtAfterProcessWidth.Size = new Size(75, 27);
            txtAfterProcessWidth.TabIndex = 4;
            txtAfterProcessWidth.Value = new decimal(new int[] { 3, 0, 0, 0 });
            // 
            // txtAfterProcessHeight
            // 
            txtAfterProcessHeight.Dock = DockStyle.Fill;
            txtAfterProcessHeight.Location = new Point(68, 3);
            txtAfterProcessHeight.Location = new Point(87, 4);
            txtAfterProcessHeight.Margin = new Padding(4);
            txtAfterProcessHeight.Name = "txtAfterProcessHeight";
            txtAfterProcessHeight.Size = new Size(59, 23);
            txtAfterProcessHeight.Size = new Size(76, 27);
            txtAfterProcessHeight.TabIndex = 5;
            txtAfterProcessHeight.Value = new decimal(new int[] { 3, 0, 0, 0 });
            // 
            // tabPage2
            // 
            tabPage2.Controls.Add(tableLayoutResults);
            tabPage2.Location = new Point(4, 26);
            tabPage2.Location = new Point(4, 29);
            tabPage2.Margin = new Padding(4);
            tabPage2.Name = "tabPage2";
            tabPage2.Padding = new Padding(3);
            tabPage2.Size = new Size(392, 522);
            tabPage2.Padding = new Padding(4);
            tabPage2.Size = new Size(506, 619);
            tabPage2.TabIndex = 1;
            tabPage2.Text = "输出结果";
            tabPage2.UseVisualStyleBackColor = true;
@@ -1019,7 +1054,7 @@
            // tableLayoutResults
            // 
            tableLayoutResults.ColumnCount = 2;
            tableLayoutResults.ColumnStyles.Add(new ColumnStyle(SizeType.Absolute, 100F));
            tableLayoutResults.ColumnStyles.Add(new ColumnStyle(SizeType.Absolute, 129F));
            tableLayoutResults.ColumnStyles.Add(new ColumnStyle(SizeType.Percent, 100F));
            tableLayoutResults.Controls.Add(dtxtHeight, 1, 4);
            tableLayoutResults.Controls.Add(label9, 0, 4);
@@ -1036,8 +1071,8 @@
            tableLayoutResults.Controls.Add(label23, 0, 5);
            tableLayoutResults.Controls.Add(dtxtArea, 1, 5);
            tableLayoutResults.Dock = DockStyle.Fill;
            tableLayoutResults.Location = new Point(3, 3);
            tableLayoutResults.Margin = new Padding(2, 3, 2, 3);
            tableLayoutResults.Location = new Point(4, 4);
            tableLayoutResults.Margin = new Padding(3, 4, 3, 4);
            tableLayoutResults.Name = "tableLayoutResults";
            tableLayoutResults.RowCount = 10;
            tableLayoutResults.RowStyles.Add(new RowStyle(SizeType.Percent, 10F));
@@ -1050,29 +1085,28 @@
            tableLayoutResults.RowStyles.Add(new RowStyle(SizeType.Percent, 10F));
            tableLayoutResults.RowStyles.Add(new RowStyle(SizeType.Percent, 10F));
            tableLayoutResults.RowStyles.Add(new RowStyle(SizeType.Percent, 10F));
            tableLayoutResults.Size = new Size(386, 516);
            tableLayoutResults.Size = new Size(498, 611);
            tableLayoutResults.TabIndex = 1;
            // 
            // dtxtHeight
            // 
            dtxtHeight.Dock = DockStyle.Fill;
            dtxtHeight.Location = new Point(102, 207);
            dtxtHeight.Margin = new Padding(2, 3, 2, 3);
            dtxtHeight.Location = new Point(132, 248);
            dtxtHeight.Margin = new Padding(3, 4, 3, 4);
            dtxtHeight.Name = "dtxtHeight";
            dtxtHeight.ReadOnly = true;
            dtxtHeight.Size = new Size(282, 23);
            dtxtHeight.Size = new Size(363, 27);
            dtxtHeight.TabIndex = 9;
            // 
            // label9
            // 
            label9.AutoSize = true;
            label9.Dock = DockStyle.Fill;
            label9.Location = new Point(2, 204);
            label9.Margin = new Padding(2, 0, 2, 0);
            label9.MaximumSize = new Size(0, 28);
            label9.MinimumSize = new Size(0, 28);
            label9.Location = new Point(3, 244);
            label9.MaximumSize = new Size(0, 33);
            label9.MinimumSize = new Size(0, 33);
            label9.Name = "label9";
            label9.Size = new Size(96, 28);
            label9.Size = new Size(123, 33);
            label9.TabIndex = 3;
            label9.Text = "高度";
            label9.TextAlign = ContentAlignment.TopCenter;
@@ -1081,12 +1115,11 @@
            // 
            label5.AutoSize = true;
            label5.Dock = DockStyle.Fill;
            label5.Location = new Point(2, 0);
            label5.Margin = new Padding(2, 0, 2, 0);
            label5.MaximumSize = new Size(0, 28);
            label5.MinimumSize = new Size(0, 28);
            label5.Location = new Point(3, 0);
            label5.MaximumSize = new Size(0, 33);
            label5.MinimumSize = new Size(0, 33);
            label5.Name = "label5";
            label5.Size = new Size(96, 28);
            label5.Size = new Size(123, 33);
            label5.TabIndex = 0;
            label5.Text = "X";
            label5.TextAlign = ContentAlignment.TopCenter;
@@ -1095,12 +1128,11 @@
            // 
            label6.AutoSize = true;
            label6.Dock = DockStyle.Fill;
            label6.Location = new Point(2, 51);
            label6.Margin = new Padding(2, 0, 2, 0);
            label6.MaximumSize = new Size(0, 28);
            label6.MinimumSize = new Size(0, 28);
            label6.Location = new Point(3, 61);
            label6.MaximumSize = new Size(0, 33);
            label6.MinimumSize = new Size(0, 33);
            label6.Name = "label6";
            label6.Size = new Size(96, 28);
            label6.Size = new Size(123, 33);
            label6.TabIndex = 1;
            label6.Text = "Y";
            label6.TextAlign = ContentAlignment.TopCenter;
@@ -1109,12 +1141,11 @@
            // 
            label7.AutoSize = true;
            label7.Dock = DockStyle.Fill;
            label7.Location = new Point(2, 102);
            label7.Margin = new Padding(2, 0, 2, 0);
            label7.MaximumSize = new Size(0, 28);
            label7.MinimumSize = new Size(0, 28);
            label7.Location = new Point(3, 122);
            label7.MaximumSize = new Size(0, 33);
            label7.MinimumSize = new Size(0, 33);
            label7.Name = "label7";
            label7.Size = new Size(96, 28);
            label7.Size = new Size(123, 33);
            label7.TabIndex = 2;
            label7.Text = "弧度(rad)";
            label7.TextAlign = ContentAlignment.TopCenter;
@@ -1123,12 +1154,11 @@
            // 
            label8.AutoSize = true;
            label8.Dock = DockStyle.Fill;
            label8.Location = new Point(2, 153);
            label8.Margin = new Padding(2, 0, 2, 0);
            label8.MaximumSize = new Size(0, 28);
            label8.MinimumSize = new Size(0, 28);
            label8.Location = new Point(3, 183);
            label8.MaximumSize = new Size(0, 33);
            label8.MinimumSize = new Size(0, 33);
            label8.Name = "label8";
            label8.Size = new Size(96, 28);
            label8.Size = new Size(123, 33);
            label8.TabIndex = 3;
            label8.Text = "宽度";
            label8.TextAlign = ContentAlignment.TopCenter;
@@ -1136,50 +1166,51 @@
            // dtxtCenterX
            // 
            dtxtCenterX.Dock = DockStyle.Fill;
            dtxtCenterX.Location = new Point(102, 3);
            dtxtCenterX.Margin = new Padding(2, 3, 2, 3);
            dtxtCenterX.Location = new Point(132, 4);
            dtxtCenterX.Margin = new Padding(3, 4, 3, 4);
            dtxtCenterX.Name = "dtxtCenterX";
            dtxtCenterX.ReadOnly = true;
            dtxtCenterX.Size = new Size(282, 23);
            dtxtCenterX.Size = new Size(363, 27);
            dtxtCenterX.TabIndex = 5;
            // 
            // dtxtCenterY
            // 
            dtxtCenterY.Dock = DockStyle.Fill;
            dtxtCenterY.Location = new Point(102, 54);
            dtxtCenterY.Margin = new Padding(2, 3, 2, 3);
            dtxtCenterY.Location = new Point(132, 65);
            dtxtCenterY.Margin = new Padding(3, 4, 3, 4);
            dtxtCenterY.Name = "dtxtCenterY";
            dtxtCenterY.ReadOnly = true;
            dtxtCenterY.Size = new Size(282, 23);
            dtxtCenterY.Size = new Size(363, 27);
            dtxtCenterY.TabIndex = 6;
            // 
            // dtxtPhi
            // 
            dtxtPhi.Dock = DockStyle.Fill;
            dtxtPhi.Location = new Point(102, 105);
            dtxtPhi.Margin = new Padding(2, 3, 2, 3);
            dtxtPhi.Location = new Point(132, 126);
            dtxtPhi.Margin = new Padding(3, 4, 3, 4);
            dtxtPhi.Name = "dtxtPhi";
            dtxtPhi.ReadOnly = true;
            dtxtPhi.Size = new Size(282, 23);
            dtxtPhi.Size = new Size(363, 27);
            dtxtPhi.TabIndex = 7;
            // 
            // dtxtWidth
            // 
            dtxtWidth.Dock = DockStyle.Fill;
            dtxtWidth.Location = new Point(102, 156);
            dtxtWidth.Margin = new Padding(2, 3, 2, 3);
            dtxtWidth.Location = new Point(132, 187);
            dtxtWidth.Margin = new Padding(3, 4, 3, 4);
            dtxtWidth.Name = "dtxtWidth";
            dtxtWidth.ReadOnly = true;
            dtxtWidth.Size = new Size(282, 23);
            dtxtWidth.Size = new Size(363, 27);
            dtxtWidth.TabIndex = 8;
            // 
            // label18
            // 
            label18.AutoSize = true;
            label18.Dock = DockStyle.Fill;
            label18.Location = new Point(3, 306);
            label18.Location = new Point(4, 366);
            label18.Margin = new Padding(4, 0, 4, 0);
            label18.Name = "label18";
            label18.Size = new Size(94, 51);
            label18.Size = new Size(121, 61);
            label18.TabIndex = 10;
            label18.Text = "数量";
            label18.TextAlign = ContentAlignment.TopCenter;
@@ -1187,19 +1218,21 @@
            // dtxtCount
            // 
            dtxtCount.Dock = DockStyle.Fill;
            dtxtCount.Location = new Point(103, 309);
            dtxtCount.Location = new Point(133, 370);
            dtxtCount.Margin = new Padding(4);
            dtxtCount.Name = "dtxtCount";
            dtxtCount.ReadOnly = true;
            dtxtCount.Size = new Size(280, 23);
            dtxtCount.Size = new Size(361, 27);
            dtxtCount.TabIndex = 11;
            // 
            // label23
            // 
            label23.AutoSize = true;
            label23.Dock = DockStyle.Fill;
            label23.Location = new Point(3, 255);
            label23.Location = new Point(4, 305);
            label23.Margin = new Padding(4, 0, 4, 0);
            label23.Name = "label23";
            label23.Size = new Size(94, 51);
            label23.Size = new Size(121, 61);
            label23.TabIndex = 12;
            label23.Text = "面积";
            label23.TextAlign = ContentAlignment.TopCenter;
@@ -1207,10 +1240,11 @@
            // dtxtArea
            // 
            dtxtArea.Dock = DockStyle.Fill;
            dtxtArea.Location = new Point(103, 258);
            dtxtArea.Location = new Point(133, 309);
            dtxtArea.Margin = new Padding(4);
            dtxtArea.Name = "dtxtArea";
            dtxtArea.ReadOnly = true;
            dtxtArea.Size = new Size(280, 23);
            dtxtArea.Size = new Size(361, 27);
            dtxtArea.TabIndex = 13;
            // 
            // imgTabControl
@@ -1219,18 +1253,20 @@
            imgTabControl.Controls.Add(tabPageRecordImage);
            imgTabControl.Dock = DockStyle.Fill;
            imgTabControl.Location = new Point(0, 0);
            imgTabControl.Margin = new Padding(4);
            imgTabControl.Name = "imgTabControl";
            imgTabControl.SelectedIndex = 0;
            imgTabControl.Size = new Size(640, 552);
            imgTabControl.Size = new Size(823, 652);
            imgTabControl.TabIndex = 49;
            // 
            // tabPageInputImage
            // 
            tabPageInputImage.Controls.Add(pnlInputImage);
            tabPageInputImage.Location = new Point(4, 26);
            tabPageInputImage.Location = new Point(4, 29);
            tabPageInputImage.Margin = new Padding(4);
            tabPageInputImage.Name = "tabPageInputImage";
            tabPageInputImage.Padding = new Padding(3);
            tabPageInputImage.Size = new Size(632, 522);
            tabPageInputImage.Padding = new Padding(4);
            tabPageInputImage.Size = new Size(815, 619);
            tabPageInputImage.TabIndex = 0;
            tabPageInputImage.Text = "输入图像";
            tabPageInputImage.UseVisualStyleBackColor = true;
@@ -1238,10 +1274,11 @@
            // tabPageRecordImage
            // 
            tabPageRecordImage.Controls.Add(pnlRecordImage);
            tabPageRecordImage.Location = new Point(4, 26);
            tabPageRecordImage.Location = new Point(4, 29);
            tabPageRecordImage.Margin = new Padding(4);
            tabPageRecordImage.Name = "tabPageRecordImage";
            tabPageRecordImage.Padding = new Padding(3);
            tabPageRecordImage.Size = new Size(632, 522);
            tabPageRecordImage.Padding = new Padding(4);
            tabPageRecordImage.Size = new Size(815, 619);
            tabPageRecordImage.TabIndex = 1;
            tabPageRecordImage.Text = "结果图像";
            tabPageRecordImage.UseVisualStyleBackColor = true;
@@ -1249,16 +1286,17 @@
            // pnlRecordImage
            // 
            pnlRecordImage.Dock = DockStyle.Fill;
            pnlRecordImage.Location = new Point(3, 3);
            pnlRecordImage.Margin = new Padding(4);
            pnlRecordImage.Location = new Point(4, 4);
            pnlRecordImage.Margin = new Padding(5);
            pnlRecordImage.Name = "pnlRecordImage";
            pnlRecordImage.Size = new Size(626, 516);
            pnlRecordImage.Size = new Size(807, 611);
            pnlRecordImage.TabIndex = 45;
            // 
            // splitContainer1
            // 
            splitContainer1.Dock = DockStyle.Fill;
            splitContainer1.Location = new Point(0, 25);
            splitContainer1.Location = new Point(0, 27);
            splitContainer1.Margin = new Padding(4);
            splitContainer1.Name = "splitContainer1";
            // 
            // splitContainer1.Panel1
@@ -1268,20 +1306,21 @@
            // splitContainer1.Panel2
            // 
            splitContainer1.Panel2.Controls.Add(imgTabControl);
            splitContainer1.Size = new Size(1044, 552);
            splitContainer1.SplitterDistance = 400;
            splitContainer1.Size = new Size(1342, 652);
            splitContainer1.SplitterDistance = 514;
            splitContainer1.SplitterWidth = 5;
            splitContainer1.TabIndex = 48;
            // 
            // HBlobToolEdit
            // 
            AutoScaleDimensions = new SizeF(7F, 17F);
            AutoScaleDimensions = new SizeF(9F, 20F);
            AutoScaleMode = AutoScaleMode.Font;
            Controls.Add(splitContainer1);
            Controls.Add(BtmStatusStrip);
            Controls.Add(TopToolStrip);
            Margin = new Padding(2, 3, 2, 3);
            Margin = new Padding(3, 4, 3, 4);
            Name = "HBlobToolEdit";
            Size = new Size(1044, 599);
            Size = new Size(1342, 705);
            Load += HBlobToolEdit_Load;
            tablePanelParas.ResumeLayout(false);
            tablePanelParas.PerformLayout();
LB_VisionProcesses/Alogrithms/Halcon/2D/HBlobTool/HBlobToolEdit.cs
@@ -84,6 +84,7 @@
            foreach (string value in IProcess.dicFixtures.Keys)
                cmbFixture.Items.Add(value.ToString());
            ckbDrawRoi.Checked = true;
            cmbTypeRoi.Text = RoiType.None.ToString();
            LoadParas();
@@ -376,6 +377,7 @@
        public override void btnSaveParas_Click(object sender, EventArgs e) { base.btnSaveParas_Click(sender, e); }
        public override void ckbDrawRoi_CheckedChanged(object sender, EventArgs e)
        {
            if (ckbDrawRoi.Checked)
LB_VisionProcesses/Alogrithms/Halcon/2D/HBlobTool/HBlobToolEdit.resx
@@ -121,9 +121,9 @@
    <value>17, 17</value>
  </metadata>
  <metadata name="TopToolStrip.TrayLocation" type="System.Drawing.Point, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a">
    <value>156, 17</value>
    <value>183, 17</value>
  </metadata>
  <metadata name="BtmStatusStrip.TrayLocation" type="System.Drawing.Point, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a">
    <value>287, 17</value>
    <value>340, 17</value>
  </metadata>
</root>
LB_VisionProcesses/Alogrithms/Halcon/2D/HFilterTool/HFilterTool.cs
¶Ô±ÈÐÂÎļþ
@@ -0,0 +1,229 @@
using HalconDotNet;
using LB_SmartVisionCommon;
using LB_VisionControl;
using System;
using System.Collections.Generic;
using System.Drawing.Imaging;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
namespace LB_VisionProcesses.Alogrithms.Halcon
{
    public enum ImageFilterType { Mean, Guass, Median }
    [Process("Halcon2D图像滤波", Category = "Halcon2D工具", Description = "创建滤波工具")]
    public class HFilterTool : TAlgorithm
    {
        public HFilterTool()
        {
            strProcessClass = "LB_VisionProcesses.Alogrithms.Halcon.HFilterTool";
            strProcessName = "Halcon2D图像滤波工具";
            Params.Inputs.Add("滤波器类型", "均值滤波");
            Params.Inputs.Add("掩膜宽", 1);
            Params.Inputs.Add("掩膜高", 1);
            //mean_image(Image : ImageMean : MaskWidth, MaskHeight : )
            Params.Inputs.Add("滤波器类型", "高斯滤波");
            Params.Inputs.Add("高斯核尺寸", 1.0);
            //gauss_filter(Image : ImageGauss : Size : )
            Params.Inputs.Add("滤波器类型", "中值滤波");
            Params.Inputs.Add("掩膜宽", 1);
            Params.Inputs.Add("掩膜高", 1);
            //median_rect(Image : ImageMedian :MaskWidth,MaskHeight:)
            Params.ROI = new HSegment(0, 0, 250, 250);
        }
        List<RecordFilterData> recordFilterDatas = new List<RecordFilterData>();
        /// <summary>
        /// ç®—子逻辑
        /// </summary>
        public override void TAlgorithmMain()
        {
            #region åˆå§‹åŒ–变量
            HObject ho_Regions, ho_LineXld;
            HOperatorSet.GenEmptyObj(out ho_Regions);
            HOperatorSet.GenEmptyObj(out ho_LineXld);
            #endregion
            try
            {
                if (InputImage == null)
                {
                    Msg = "输入图片为空";
                    Result = false;
                    return;
                }
                if (InputImage is Bitmap)
                {
                    try
                    {
                        using (HImage hImage = new HImage())
                        {
                            Bitmap bitmap = (Bitmap)InputImage;
                            Rectangle rect = new Rectangle(0, 0, ((Bitmap)bitmap).Width, ((Bitmap)bitmap).Height);
                            BitmapData srcBmpData = ((Bitmap)bitmap).LockBits(rect, ImageLockMode.ReadOnly, PixelFormat.Format32bppRgb);
                            hImage.GenImageInterleaved(srcBmpData.Scan0, "rgbx", ((Bitmap)bitmap).Width, ((Bitmap)bitmap).Height, 0, "byte", ((Bitmap)bitmap).Width, ((Bitmap)bitmap).Height, 0, 0, -1, 0);
                            ((Bitmap)bitmap).UnlockBits(srcBmpData);
                            bitmap.Dispose();
                            bitmap = null;
                            InputImage = null;
                            InputImage = hImage.Clone();
                        }
                    }
                    catch (Exception ex)
                    {
                    }
                }
                if (!(InputImage is HObject))
                {
                    Msg = "输入图片格式不为HObject";
                    Result = false;
                    return;
                }
                #region è£å‰ªåŒºåŸŸ
                //if (!(Params.ROI is HSegment))
                //{
                //    Msg = "ROI类型错误,必须为HSegment类型";
                //    Result = false;
                //    return;
                //}
                //if (!(InputImage is HObject))
                //{
                //    Msg = "输入图片类型错误,必须为HObject类型";
                //    Result = false;
                //    return;
                //}
                //HObject DomainImage = ((HObject)InputImage)?.CopyObj(1, -1);
                object DomainImage = null;
                if (!ReduceDomainImage(InputImage, ref DomainImage))
                {
                    Msg = "裁剪区域失败";
                    Result = false;
                    return;
                }
                #endregion
                #region ç®—子逻辑
                Record = new ObjectRecord();
                HObject hoDomainImage = DomainImage as HObject;
                HTuple hv_Channels = new HTuple();
                //判断是否为灰度图
                using (HDevDisposeHelper dh = new HDevDisposeHelper())
                {
                    try
                    {
                        HOperatorSet.CountChannels(hoDomainImage, out hv_Channels);
                        if (hv_Channels.TupleInt() != 1)
                            HOperatorSet.Rgb1ToGray(hoDomainImage, out hoDomainImage);
                        //转换后再次检查是否为灰度图
                        HOperatorSet.CountChannels(hoDomainImage, out hv_Channels);
                        if (hv_Channels.TupleInt() != 1)
                        {
                            HOperatorSet.Rgb1ToGray(hoDomainImage, out hoDomainImage);
                            Msg = "输入图片不为灰度图";
                            Result = false;
                            return;
                        }
                    }
                    catch
                    {
                        Msg = "输入图片不为灰度图且转换失败";
                        Result = false;
                        return;
                    }
                }
                int hv_MaskWidth = Convert.ToInt16(Params.Inputs["掩膜宽"]);
                int hv_MaskHight = Convert.ToInt16(Params.Inputs["掩膜高"]);
                int hv_Size = Convert.ToInt16(Params.Inputs["高斯核尺寸"]);
                recordFilterDatas = FilterManager.Instance.GetAllUsers();
                string hv_FilterType = "";
                foreach (var recordFilterData in recordFilterDatas)
                {
                    switch (recordFilterData.FilterName)
                    {
                        case FilterType.均值滤波_MeanImage:
                            hv_FilterType = "mean";
                            hv_MaskWidth = Convert.ToInt16(recordFilterData.MaskWidth);
                            hv_MaskHight = Convert.ToInt16(recordFilterData.MaskHight);
                            Filter(hoDomainImage, out ho_Regions, hv_FilterType, hv_MaskWidth, hv_MaskHight, hv_Size);
                            break;
                        case FilterType.高斯滤波_GaussFilter:
                            hv_FilterType = "gauss";
                            hv_Size = Convert.ToInt16(recordFilterData.GaussSize);
                            Filter(hoDomainImage, out ho_Regions, hv_FilterType, hv_MaskWidth, hv_MaskHight, hv_Size);
                            break;
                        case FilterType.中值滤波_MedianRect:
                            hv_FilterType = "median";
                            hv_MaskWidth = Convert.ToInt16(recordFilterData.MaskWidth);
                            hv_MaskHight = Convert.ToInt16(recordFilterData.MaskHight);
                            Filter(hoDomainImage, out ho_Regions, hv_FilterType, hv_MaskWidth, hv_MaskHight, hv_Size);
                            break;
                        default:
                            hv_FilterType = "median";
                            hv_MaskWidth = Convert.ToInt16(recordFilterData.MaskWidth);
                            hv_MaskHight = Convert.ToInt16(recordFilterData.MaskHight);
                            Filter(hoDomainImage, out ho_Regions, hv_FilterType, hv_MaskWidth, hv_MaskHight, hv_Size);
                            break;
                    }
                }
                #endregion
                #region ç”ŸæˆOutputImage给后续处理
                try
                {
                    OutputImage = hoDomainImage;
                }
                catch (Exception ex)
                {
                    Msg = "生成OutputImage失败,原因是:" + ex.ToString();
                    Result = false;
                    return;
                }
                #endregion
                if (Msg == "运行超时")
                {
                    Result = false;
                    return;
                }
                Msg = "运行成功";
                Result = true;
                return;
            }
            catch (Exception ex)
            {
                Msg = "运行失败,原因是:" + ex.ToString().TrimEnd();
                OutputImage = null;
                Result = false;
                return;
            }
            finally
            {
                if (!Result)
                {
                    Params.Outputs.Add("Segment", new HSegment());
                }
                bCompleted = true;
                #region å†…存释放
                ho_Regions.Dispose();
                #endregion
            }
        }
    }
}
LB_VisionProcesses/Alogrithms/Halcon/2D/HFilterTool/HFilterToolEdit.Designer.cs
¶Ô±ÈÐÂÎļþ
@@ -0,0 +1,613 @@
namespace LB_VisionProcesses.Alogrithms.Halcon
{
    partial class HFilterToolEdit
    {
        /// <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()
        {
            pnlInputImage = new Panel();
            TopToolStrip = new ToolStrip();
            btnRun = new ToolStripButton();
            btnLoadImage = new ToolStripButton();
            btnSaveParas = new ToolStripButton();
            btnLoadParas = new ToolStripButton();
            BtmStatusStrip = new StatusStrip();
            lblResult = new ToolStripStatusLabel();
            lblMsg = new ToolStripStatusLabel();
            lblRunTime = new ToolStripStatusLabel();
            MainTableLayoutPanel = new TableLayoutPanel();
            parasTabControl = new TabControl();
            tabPage1 = new TabPage();
            tableLayoutPanel1 = new TableLayoutPanel();
            dataGridViewFi = new DataGridView();
            tableLayoutPanel4 = new TableLayoutPanel();
            tableLayoutPanel6 = new TableLayoutPanel();
            txtGuassSize = new TextBox();
            labelGuassSize = new Label();
            tableLayoutPanel3 = new TableLayoutPanel();
            cmbFilterType = new ComboBox();
            btnAdd = new Button();
            labelFilterType = new Label();
            btnDel = new Button();
            tableLayoutPanel5 = new TableLayoutPanel();
            labelMaskWidth = new Label();
            labelMaskHeight = new Label();
            txtMaskWidth = new TextBox();
            txtMaskHeight = new TextBox();
            tabPage5 = new TabPage();
            tableLayoutPanel2 = new TableLayoutPanel();
            cmbTypeRoi = new ComboBox();
            label21 = new Label();
            label22 = new Label();
            cmbFixture = new ComboBox();
            ckbDrawRoi = new CheckBox();
            imgTabControl = new TabControl();
            tabPageInputImage = new TabPage();
            tabPageRecordImage = new TabPage();
            pnlRecordImage = new Panel();
            TopToolStrip.SuspendLayout();
            BtmStatusStrip.SuspendLayout();
            MainTableLayoutPanel.SuspendLayout();
            parasTabControl.SuspendLayout();
            tabPage1.SuspendLayout();
            tableLayoutPanel1.SuspendLayout();
            ((System.ComponentModel.ISupportInitialize)dataGridViewFi).BeginInit();
            tableLayoutPanel4.SuspendLayout();
            tableLayoutPanel6.SuspendLayout();
            tableLayoutPanel3.SuspendLayout();
            tableLayoutPanel5.SuspendLayout();
            tabPage5.SuspendLayout();
            tableLayoutPanel2.SuspendLayout();
            imgTabControl.SuspendLayout();
            tabPageInputImage.SuspendLayout();
            tabPageRecordImage.SuspendLayout();
            SuspendLayout();
            //
            // pnlInputImage
            //
            pnlInputImage.Dock = DockStyle.Fill;
            pnlInputImage.Location = new Point(4, 4);
            pnlInputImage.Margin = new Padding(5);
            pnlInputImage.Name = "pnlInputImage";
            pnlInputImage.Size = new Size(782, 603);
            pnlInputImage.TabIndex = 44;
            //
            // TopToolStrip
            //
            TopToolStrip.ImageScalingSize = new Size(20, 20);
            TopToolStrip.Items.AddRange(new ToolStripItem[] { btnRun, btnLoadImage, btnSaveParas, btnLoadParas });
            TopToolStrip.Location = new Point(0, 0);
            TopToolStrip.Name = "TopToolStrip";
            TopToolStrip.Size = new Size(1342, 27);
            TopToolStrip.TabIndex = 45;
            TopToolStrip.Text = "toolStrip1";
            //
            // btnRun
            //
            btnRun.BackgroundImageLayout = ImageLayout.Zoom;
            btnRun.ImageTransparentColor = Color.Magenta;
            btnRun.Name = "btnRun";
            btnRun.Size = new Size(43, 24);
            btnRun.Text = "运行";
            btnRun.Click += btnRun_Click;
            //
            // btnLoadImage
            //
            btnLoadImage.ImageTransparentColor = Color.Magenta;
            btnLoadImage.Name = "btnLoadImage";
            btnLoadImage.Size = new Size(43, 24);
            btnLoadImage.Text = "导图";
            btnLoadImage.Click += btnLoadImage_Click;
            //
            // btnSaveParas
            //
            btnSaveParas.ImageTransparentColor = Color.Magenta;
            btnSaveParas.Name = "btnSaveParas";
            btnSaveParas.Size = new Size(43, 24);
            btnSaveParas.Text = "保存";
            btnSaveParas.Click += btnSaveParas_Click;
            //
            // btnLoadParas
            //
            btnLoadParas.ImageTransparentColor = Color.Magenta;
            btnLoadParas.Name = "btnLoadParas";
            btnLoadParas.Size = new Size(43, 24);
            btnLoadParas.Text = "加载";
            //
            // BtmStatusStrip
            //
            BtmStatusStrip.ImageScalingSize = new Size(20, 20);
            BtmStatusStrip.Items.AddRange(new ToolStripItem[] { lblResult, lblMsg, lblRunTime });
            BtmStatusStrip.Location = new Point(0, 679);
            BtmStatusStrip.Name = "BtmStatusStrip";
            BtmStatusStrip.Padding = new Padding(1, 0, 18, 0);
            BtmStatusStrip.Size = new Size(1342, 26);
            BtmStatusStrip.TabIndex = 46;
            BtmStatusStrip.Text = "statusStrip1";
            //
            // lblResult
            //
            lblResult.Name = "lblResult";
            lblResult.Size = new Size(42, 20);
            lblResult.Text = "True";
            //
            // lblMsg
            //
            lblMsg.Name = "lblMsg";
            lblMsg.Size = new Size(69, 20);
            lblMsg.Text = "运行成功";
            //
            // lblRunTime
            //
            lblRunTime.Name = "lblRunTime";
            lblRunTime.Size = new Size(39, 20);
            lblRunTime.Text = "0ms";
            //
            // MainTableLayoutPanel
            //
            MainTableLayoutPanel.ColumnCount = 2;
            MainTableLayoutPanel.ColumnStyles.Add(new ColumnStyle(SizeType.Percent, 40F));
            MainTableLayoutPanel.ColumnStyles.Add(new ColumnStyle(SizeType.Percent, 60F));
            MainTableLayoutPanel.Controls.Add(parasTabControl, 0, 0);
            MainTableLayoutPanel.Controls.Add(imgTabControl, 1, 0);
            MainTableLayoutPanel.Dock = DockStyle.Fill;
            MainTableLayoutPanel.Location = new Point(0, 27);
            MainTableLayoutPanel.Margin = new Padding(4);
            MainTableLayoutPanel.Name = "MainTableLayoutPanel";
            MainTableLayoutPanel.RowCount = 1;
            MainTableLayoutPanel.RowStyles.Add(new RowStyle(SizeType.Percent, 100F));
            MainTableLayoutPanel.Size = new Size(1342, 652);
            MainTableLayoutPanel.TabIndex = 47;
            //
            // parasTabControl
            //
            parasTabControl.Controls.Add(tabPage1);
            parasTabControl.Controls.Add(tabPage5);
            parasTabControl.Dock = DockStyle.Fill;
            parasTabControl.Location = new Point(4, 4);
            parasTabControl.Margin = new Padding(4);
            parasTabControl.Name = "parasTabControl";
            parasTabControl.SelectedIndex = 0;
            parasTabControl.Size = new Size(528, 644);
            parasTabControl.TabIndex = 48;
            //
            // tabPage1
            //
            tabPage1.Controls.Add(tableLayoutPanel1);
            tabPage1.Location = new Point(4, 29);
            tabPage1.Margin = new Padding(4);
            tabPage1.Name = "tabPage1";
            tabPage1.Padding = new Padding(4);
            tabPage1.Size = new Size(520, 611);
            tabPage1.TabIndex = 0;
            tabPage1.Text = "输入参数";
            tabPage1.UseVisualStyleBackColor = true;
            //
            // tableLayoutPanel1
            //
            tableLayoutPanel1.ColumnCount = 1;
            tableLayoutPanel1.ColumnStyles.Add(new ColumnStyle(SizeType.Percent, 100F));
            tableLayoutPanel1.Controls.Add(dataGridViewFi, 0, 1);
            tableLayoutPanel1.Controls.Add(tableLayoutPanel4, 0, 0);
            tableLayoutPanel1.Dock = DockStyle.Fill;
            tableLayoutPanel1.Location = new Point(4, 4);
            tableLayoutPanel1.Name = "tableLayoutPanel1";
            tableLayoutPanel1.RowCount = 2;
            tableLayoutPanel1.RowStyles.Add(new RowStyle(SizeType.Absolute, 135F));
            tableLayoutPanel1.RowStyles.Add(new RowStyle(SizeType.Percent, 100F));
            tableLayoutPanel1.Size = new Size(512, 603);
            tableLayoutPanel1.TabIndex = 1;
            //
            // dataGridViewFi
            //
            dataGridViewFi.ColumnHeadersHeightSizeMode = DataGridViewColumnHeadersHeightSizeMode.AutoSize;
            dataGridViewFi.Location = new Point(3, 138);
            dataGridViewFi.Name = "dataGridViewFi";
            dataGridViewFi.RowHeadersWidth = 51;
            dataGridViewFi.Size = new Size(506, 462);
            dataGridViewFi.TabIndex = 2;
            //
            // tableLayoutPanel4
            //
            tableLayoutPanel4.ColumnCount = 1;
            tableLayoutPanel4.ColumnStyles.Add(new ColumnStyle(SizeType.Absolute, 506F));
            tableLayoutPanel4.Controls.Add(tableLayoutPanel6, 0, 2);
            tableLayoutPanel4.Controls.Add(tableLayoutPanel3, 0, 0);
            tableLayoutPanel4.Controls.Add(tableLayoutPanel5, 0, 1);
            tableLayoutPanel4.Location = new Point(3, 3);
            tableLayoutPanel4.Name = "tableLayoutPanel4";
            tableLayoutPanel4.RowCount = 3;
            tableLayoutPanel4.RowStyles.Add(new RowStyle(SizeType.Absolute, 45F));
            tableLayoutPanel4.RowStyles.Add(new RowStyle(SizeType.Absolute, 45F));
            tableLayoutPanel4.RowStyles.Add(new RowStyle(SizeType.Absolute, 45F));
            tableLayoutPanel4.Size = new Size(506, 125);
            tableLayoutPanel4.TabIndex = 3;
            //
            // tableLayoutPanel6
            //
            tableLayoutPanel6.ColumnCount = 4;
            tableLayoutPanel6.ColumnStyles.Add(new ColumnStyle(SizeType.Absolute, 85F));
            tableLayoutPanel6.ColumnStyles.Add(new ColumnStyle(SizeType.Absolute, 165F));
            tableLayoutPanel6.ColumnStyles.Add(new ColumnStyle(SizeType.Absolute, 85F));
            tableLayoutPanel6.ColumnStyles.Add(new ColumnStyle(SizeType.Absolute, 165F));
            tableLayoutPanel6.Controls.Add(txtGuassSize, 1, 0);
            tableLayoutPanel6.Controls.Add(labelGuassSize, 0, 0);
            tableLayoutPanel6.Dock = DockStyle.Fill;
            tableLayoutPanel6.Location = new Point(3, 93);
            tableLayoutPanel6.Name = "tableLayoutPanel6";
            tableLayoutPanel6.RowCount = 1;
            tableLayoutPanel6.RowStyles.Add(new RowStyle(SizeType.Percent, 100F));
            tableLayoutPanel6.Size = new Size(500, 39);
            tableLayoutPanel6.TabIndex = 2;
            //
            // txtGuassSize
            //
            txtGuassSize.Location = new Point(88, 3);
            txtGuassSize.Name = "txtGuassSize";
            txtGuassSize.Size = new Size(159, 27);
            txtGuassSize.TabIndex = 4;
            //
            // labelGuassSize
            //
            labelGuassSize.AutoSize = true;
            labelGuassSize.Location = new Point(3, 0);
            labelGuassSize.Name = "labelGuassSize";
            labelGuassSize.Size = new Size(69, 39);
            labelGuassSize.TabIndex = 1;
            labelGuassSize.Text = "高斯核尺寸";
            //
            // tableLayoutPanel3
            //
            tableLayoutPanel3.ColumnCount = 4;
            tableLayoutPanel3.ColumnStyles.Add(new ColumnStyle(SizeType.Absolute, 85F));
            tableLayoutPanel3.ColumnStyles.Add(new ColumnStyle(SizeType.Absolute, 165F));
            tableLayoutPanel3.ColumnStyles.Add(new ColumnStyle(SizeType.Percent, 50F));
            tableLayoutPanel3.ColumnStyles.Add(new ColumnStyle(SizeType.Percent, 50F));
            tableLayoutPanel3.Controls.Add(cmbFilterType, 1, 0);
            tableLayoutPanel3.Controls.Add(btnAdd, 2, 0);
            tableLayoutPanel3.Controls.Add(labelFilterType, 0, 0);
            tableLayoutPanel3.Controls.Add(btnDel, 3, 0);
            tableLayoutPanel3.Dock = DockStyle.Fill;
            tableLayoutPanel3.Location = new Point(3, 3);
            tableLayoutPanel3.Name = "tableLayoutPanel3";
            tableLayoutPanel3.RowCount = 1;
            tableLayoutPanel3.RowStyles.Add(new RowStyle(SizeType.Percent, 100F));
            tableLayoutPanel3.Size = new Size(500, 39);
            tableLayoutPanel3.TabIndex = 0;
            //
            // cmbFilterType
            //
            cmbFilterType.FormattingEnabled = true;
            cmbFilterType.Location = new Point(89, 4);
            cmbFilterType.Margin = new Padding(4);
            cmbFilterType.Name = "cmbFilterType";
            cmbFilterType.Size = new Size(157, 28);
            cmbFilterType.TabIndex = 14;
            cmbFilterType.SelectedIndexChanged += cmbFilterType_SelectedIndexChanged;
            //
            // btnAdd
            //
            btnAdd.Location = new Point(253, 3);
            btnAdd.Name = "btnAdd";
            btnAdd.Size = new Size(119, 33);
            btnAdd.TabIndex = 15;
            btnAdd.Text = "添加";
            btnAdd.UseVisualStyleBackColor = true;
            btnAdd.Click += btnAdd_Click;
            //
            // labelFilterType
            //
            labelFilterType.AutoSize = true;
            labelFilterType.Location = new Point(3, 0);
            labelFilterType.MaximumSize = new Size(0, 33);
            labelFilterType.MinimumSize = new Size(0, 33);
            labelFilterType.Name = "labelFilterType";
            labelFilterType.Size = new Size(69, 33);
            labelFilterType.TabIndex = 1;
            labelFilterType.Text = "滤波类型";
            labelFilterType.TextAlign = ContentAlignment.MiddleCenter;
            //
            // btnDel
            //
            btnDel.Location = new Point(378, 3);
            btnDel.Name = "btnDel";
            btnDel.Size = new Size(119, 33);
            btnDel.TabIndex = 16;
            btnDel.Text = "删除";
            btnDel.UseVisualStyleBackColor = true;
            btnDel.Click += btnDel_Click;
            //
            // tableLayoutPanel5
            //
            tableLayoutPanel5.ColumnCount = 4;
            tableLayoutPanel5.ColumnStyles.Add(new ColumnStyle(SizeType.Absolute, 85F));
            tableLayoutPanel5.ColumnStyles.Add(new ColumnStyle(SizeType.Absolute, 165F));
            tableLayoutPanel5.ColumnStyles.Add(new ColumnStyle(SizeType.Absolute, 85F));
            tableLayoutPanel5.ColumnStyles.Add(new ColumnStyle(SizeType.Absolute, 165F));
            tableLayoutPanel5.Controls.Add(labelMaskWidth, 0, 0);
            tableLayoutPanel5.Controls.Add(labelMaskHeight, 2, 0);
            tableLayoutPanel5.Controls.Add(txtMaskWidth, 1, 0);
            tableLayoutPanel5.Controls.Add(txtMaskHeight, 3, 0);
            tableLayoutPanel5.Dock = DockStyle.Fill;
            tableLayoutPanel5.Location = new Point(3, 48);
            tableLayoutPanel5.Name = "tableLayoutPanel5";
            tableLayoutPanel5.RowCount = 1;
            tableLayoutPanel5.RowStyles.Add(new RowStyle(SizeType.Percent, 100F));
            tableLayoutPanel5.Size = new Size(500, 39);
            tableLayoutPanel5.TabIndex = 1;
            //
            // labelMaskWidth
            //
            labelMaskWidth.AutoSize = true;
            labelMaskWidth.Location = new Point(3, 0);
            labelMaskWidth.MaximumSize = new Size(0, 33);
            labelMaskWidth.MinimumSize = new Size(0, 33);
            labelMaskWidth.Name = "labelMaskWidth";
            labelMaskWidth.Size = new Size(54, 33);
            labelMaskWidth.TabIndex = 0;
            labelMaskWidth.Text = "掩膜宽";
            //
            // labelMaskHeight
            //
            labelMaskHeight.AutoSize = true;
            labelMaskHeight.Location = new Point(253, 0);
            labelMaskHeight.Name = "labelMaskHeight";
            labelMaskHeight.Size = new Size(54, 20);
            labelMaskHeight.TabIndex = 1;
            labelMaskHeight.Text = "掩膜高";
            //
            // txtMaskWidth
            //
            txtMaskWidth.Location = new Point(88, 3);
            txtMaskWidth.Name = "txtMaskWidth";
            txtMaskWidth.Size = new Size(159, 27);
            txtMaskWidth.TabIndex = 3;
            //
            // txtMaskHeight
            //
            txtMaskHeight.Location = new Point(338, 3);
            txtMaskHeight.Name = "txtMaskHeight";
            txtMaskHeight.Size = new Size(159, 27);
            txtMaskHeight.TabIndex = 4;
            //
            // tabPage5
            //
            tabPage5.Controls.Add(tableLayoutPanel2);
            tabPage5.Location = new Point(4, 29);
            tabPage5.Margin = new Padding(4);
            tabPage5.Name = "tabPage5";
            tabPage5.Size = new Size(520, 611);
            tabPage5.TabIndex = 2;
            tabPage5.Text = "运行参数";
            tabPage5.UseVisualStyleBackColor = true;
            //
            // tableLayoutPanel2
            //
            tableLayoutPanel2.ColumnCount = 4;
            tableLayoutPanel2.ColumnStyles.Add(new ColumnStyle(SizeType.Absolute, 77F));
            tableLayoutPanel2.ColumnStyles.Add(new ColumnStyle(SizeType.Absolute, 193F));
            tableLayoutPanel2.ColumnStyles.Add(new ColumnStyle(SizeType.Absolute, 26F));
            tableLayoutPanel2.ColumnStyles.Add(new ColumnStyle(SizeType.Percent, 100F));
            tableLayoutPanel2.Controls.Add(cmbTypeRoi, 1, 0);
            tableLayoutPanel2.Controls.Add(label21, 0, 0);
            tableLayoutPanel2.Controls.Add(label22, 0, 1);
            tableLayoutPanel2.Controls.Add(cmbFixture, 1, 1);
            tableLayoutPanel2.Controls.Add(ckbDrawRoi, 2, 0);
            tableLayoutPanel2.Location = new Point(4, 4);
            tableLayoutPanel2.Margin = new Padding(4);
            tableLayoutPanel2.Name = "tableLayoutPanel2";
            tableLayoutPanel2.RowCount = 8;
            tableLayoutPanel2.RowStyles.Add(new RowStyle(SizeType.Absolute, 35F));
            tableLayoutPanel2.RowStyles.Add(new RowStyle(SizeType.Absolute, 35F));
            tableLayoutPanel2.RowStyles.Add(new RowStyle(SizeType.Absolute, 35F));
            tableLayoutPanel2.RowStyles.Add(new RowStyle(SizeType.Absolute, 35F));
            tableLayoutPanel2.RowStyles.Add(new RowStyle(SizeType.Absolute, 35F));
            tableLayoutPanel2.RowStyles.Add(new RowStyle(SizeType.Absolute, 35F));
            tableLayoutPanel2.RowStyles.Add(new RowStyle(SizeType.Absolute, 35F));
            tableLayoutPanel2.RowStyles.Add(new RowStyle(SizeType.Percent, 100F));
            tableLayoutPanel2.Size = new Size(415, 364);
            tableLayoutPanel2.TabIndex = 4;
            //
            // cmbTypeRoi
            //
            cmbTypeRoi.FormattingEnabled = true;
            cmbTypeRoi.Location = new Point(81, 4);
            cmbTypeRoi.Margin = new Padding(4);
            cmbTypeRoi.Name = "cmbTypeRoi";
            cmbTypeRoi.Size = new Size(154, 28);
            cmbTypeRoi.TabIndex = 1;
            cmbTypeRoi.SelectedIndexChanged += cmbTypeRoi_SelectedIndexChanged;
            //
            // label21
            //
            label21.AutoSize = true;
            label21.Dock = DockStyle.Fill;
            label21.Location = new Point(4, 0);
            label21.Margin = new Padding(4, 0, 4, 0);
            label21.Name = "label21";
            label21.Size = new Size(69, 35);
            label21.TabIndex = 3;
            label21.Text = "ROI";
            label21.TextAlign = ContentAlignment.MiddleCenter;
            //
            // label22
            //
            label22.AutoSize = true;
            label22.Dock = DockStyle.Fill;
            label22.Location = new Point(4, 35);
            label22.Margin = new Padding(4, 0, 4, 0);
            label22.Name = "label22";
            label22.Size = new Size(69, 35);
            label22.TabIndex = 4;
            label22.Text = "Fixture";
            label22.TextAlign = ContentAlignment.MiddleCenter;
            //
            // cmbFixture
            //
            cmbFixture.FormattingEnabled = true;
            cmbFixture.Location = new Point(81, 39);
            cmbFixture.Margin = new Padding(4);
            cmbFixture.Name = "cmbFixture";
            cmbFixture.Size = new Size(154, 28);
            cmbFixture.TabIndex = 5;
            //
            // ckbDrawRoi
            //
            ckbDrawRoi.AutoSize = true;
            ckbDrawRoi.CheckAlign = ContentAlignment.MiddleCenter;
            ckbDrawRoi.Location = new Point(274, 4);
            ckbDrawRoi.Margin = new Padding(4);
            ckbDrawRoi.Name = "ckbDrawRoi";
            ckbDrawRoi.Size = new Size(18, 17);
            ckbDrawRoi.TabIndex = 2;
            ckbDrawRoi.UseVisualStyleBackColor = true;
            ckbDrawRoi.CheckedChanged += ckbDrawRoi_CheckedChanged;
            //
            // imgTabControl
            //
            imgTabControl.Controls.Add(tabPageInputImage);
            imgTabControl.Controls.Add(tabPageRecordImage);
            imgTabControl.Dock = DockStyle.Fill;
            imgTabControl.Location = new Point(540, 4);
            imgTabControl.Margin = new Padding(4);
            imgTabControl.Name = "imgTabControl";
            imgTabControl.SelectedIndex = 0;
            imgTabControl.Size = new Size(798, 644);
            imgTabControl.TabIndex = 49;
            //
            // tabPageInputImage
            //
            tabPageInputImage.Controls.Add(pnlInputImage);
            tabPageInputImage.Location = new Point(4, 29);
            tabPageInputImage.Margin = new Padding(4);
            tabPageInputImage.Name = "tabPageInputImage";
            tabPageInputImage.Padding = new Padding(4);
            tabPageInputImage.Size = new Size(790, 611);
            tabPageInputImage.TabIndex = 0;
            tabPageInputImage.Text = "输入图像";
            tabPageInputImage.UseVisualStyleBackColor = true;
            //
            // tabPageRecordImage
            //
            tabPageRecordImage.Controls.Add(pnlRecordImage);
            tabPageRecordImage.Location = new Point(4, 29);
            tabPageRecordImage.Margin = new Padding(4);
            tabPageRecordImage.Name = "tabPageRecordImage";
            tabPageRecordImage.Padding = new Padding(4);
            tabPageRecordImage.Size = new Size(790, 611);
            tabPageRecordImage.TabIndex = 1;
            tabPageRecordImage.Text = "结果图像";
            tabPageRecordImage.UseVisualStyleBackColor = true;
            //
            // pnlRecordImage
            //
            pnlRecordImage.Dock = DockStyle.Fill;
            pnlRecordImage.Location = new Point(4, 4);
            pnlRecordImage.Margin = new Padding(5);
            pnlRecordImage.Name = "pnlRecordImage";
            pnlRecordImage.Size = new Size(782, 603);
            pnlRecordImage.TabIndex = 45;
            //
            // HFilterToolEdit
            //
            AutoScaleDimensions = new SizeF(9F, 20F);
            AutoScaleMode = AutoScaleMode.Font;
            Controls.Add(MainTableLayoutPanel);
            Controls.Add(BtmStatusStrip);
            Controls.Add(TopToolStrip);
            Margin = new Padding(3, 4, 3, 4);
            Name = "HFilterToolEdit";
            Size = new Size(1342, 705);
            Load += HFilterToolEdit_Load;
            TopToolStrip.ResumeLayout(false);
            TopToolStrip.PerformLayout();
            BtmStatusStrip.ResumeLayout(false);
            BtmStatusStrip.PerformLayout();
            MainTableLayoutPanel.ResumeLayout(false);
            parasTabControl.ResumeLayout(false);
            tabPage1.ResumeLayout(false);
            tableLayoutPanel1.ResumeLayout(false);
            ((System.ComponentModel.ISupportInitialize)dataGridViewFi).EndInit();
            tableLayoutPanel4.ResumeLayout(false);
            tableLayoutPanel6.ResumeLayout(false);
            tableLayoutPanel6.PerformLayout();
            tableLayoutPanel3.ResumeLayout(false);
            tableLayoutPanel3.PerformLayout();
            tableLayoutPanel5.ResumeLayout(false);
            tableLayoutPanel5.PerformLayout();
            tabPage5.ResumeLayout(false);
            tableLayoutPanel2.ResumeLayout(false);
            tableLayoutPanel2.PerformLayout();
            imgTabControl.ResumeLayout(false);
            tabPageInputImage.ResumeLayout(false);
            tabPageRecordImage.ResumeLayout(false);
            ResumeLayout(false);
            PerformLayout();
        }
        #endregion
        private System.Windows.Forms.Panel pnlInputImage;
        private ToolStrip TopToolStrip;
        private ToolStripButton btnRun;
        private StatusStrip BtmStatusStrip;
        private ToolStripStatusLabel lblResult;
        private ToolStripStatusLabel lblMsg;
        private TableLayoutPanel MainTableLayoutPanel;
        private ToolStripButton btnLoadImage;
        private TabControl parasTabControl;
        private TabPage tabPage1;
        private TabPage tabPage5;
        private TabControl imgTabControl;
        private TabPage tabPageInputImage;
        private TabPage tabPageRecordImage;
        private ToolStripButton btnSaveParas;
        private ToolStripButton btnLoadParas;
        private Panel pnlRecordImage;
        private ToolStripStatusLabel lblRunTime;
        private TableLayoutPanel tableLayoutPanel2;
        public ComboBox cmbTypeRoi;
        private Label label21;
        private Label label22;
        private ComboBox cmbFixture;
        private CheckBox ckbDrawRoi;
        private TableLayoutPanel tableLayoutPanel1;
        private TableLayoutPanel tableLayoutPanel3;
        private Label labelFilterType;
        private ComboBox cmbFilterType;
        private DataGridView dataGridViewFi;
        private TableLayoutPanel tableLayoutPanel4;
        private Button btnAdd;
        private TableLayoutPanel tableLayoutPanel5;
        private Label labelMaskWidth;
        private Label labelMaskHeight;
        private TextBox txtMaskWidth;
        private TextBox txtMaskHeight;
        private TableLayoutPanel tableLayoutPanel6;
        private TextBox txtGuassSize;
        private Label labelGuassSize;
        private Button btnDel;
    }
}
LB_VisionProcesses/Alogrithms/Halcon/2D/HFilterTool/HFilterToolEdit.cs
¶Ô±ÈÐÂÎļþ
@@ -0,0 +1,611 @@
using HalconDotNet;
using LB_SmartVisionCommon;
using LB_VisionControl;
using Newtonsoft.Json;
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;
namespace LB_VisionProcesses.Alogrithms.Halcon
{
    public partial class HFilterToolEdit : TAlgorithmEdit
    {
        List<RecordFilterData> recordFilterDatas = new List<RecordFilterData>();
        private int rowriginalHeight;
        public HFilterToolEdit(HFilterTool subject = null)
        {
            if (subject != null && subject is HFilterTool)
                Subject = subject;
            else
                Subject = new HFilterTool();
            //if (!(Subject.Params.ROI is HSegment))
            //    Subject.Params.ROI = new HSegment(0, 0, 250, 250);
            this.Dock = DockStyle.Fill;
            InitializeComponent();
            // ä¿å­˜åŽŸå§‹è¡Œé«˜åº¦
            rowriginalHeight = (int)tableLayoutPanel4.RowStyles[1].Height; //45;
            recordFilterDatas = FilterManager.Instance.GetAllUsers();
            InitializeComboBox();
            InitializeDataGridView();
            this.dataGridViewFi.DataSource = recordFilterDatas;
            this.dataGridViewFi.AutoGenerateColumns = true;
        }
        private void InitializeComboBox()
        {
            // æ·»åŠ æƒé™é€‰é¡¹
            foreach (var item in Enum.GetValues(typeof(FilterType)))
            {
                cmbFilterType.Items.Add(item.ToString());
            }
            // è®¾ç½®é»˜è®¤é€‰æ‹©é¡¹
            cmbFilterType.SelectedIndex = 0;
        }
        private void InitializeDataGridView()
        {
            this.dataGridViewFi.DataSource = recordFilterDatas;
            // è®¾ç½®DataGridView列宽
            dataGridViewFi.AutoSizeColumnsMode = DataGridViewAutoSizeColumnsMode.Fill;
        }
        /// <summary>
        /// æŽ§ä»¶åŠ è½½äº‹ä»¶
        /// </summary>
        /// <param name="sender"></param>
        /// <param name="e"></param>
        private void HFilterToolEdit_Load(object sender, EventArgs e)
        {
            pnlInputImage.Controls.Add(inputImageHSmartWindowControl);
            inputImageHSmartWindowControl.Dock = DockStyle.Fill;
            pnlRecordImage.Controls.Add(recordImageHSmartWindowControl);
            recordImageHSmartWindowControl.Dock = DockStyle.Fill;
            //遍历可以选择的Roi类型枚举
            foreach (var value in Enum.GetValues(typeof(RoiType)))
                cmbTypeRoi.Items.Add(value.ToString());
            //遍历可以选择的图像滤波类型枚举
            //foreach (var value in Enum.GetValues(typeof(FilterType)))
            //    cmbFilterType.Items.Add(value.ToString());
            //遍历可以选择的Fixture枚举
            cmbFixture.Items.Add("");
            foreach (string value in IProcess.dicFixtures.Keys)
                cmbFixture.Items.Add(value.ToString());
            ckbDrawRoi.Checked = true;
            cmbTypeRoi.Text = RoiType.Segment.ToString();
            cmbFilterType.Text = FilterType.均值滤波_MeanImage.ToString();
            LoadParas();
            if (Subject.Result)
            {
                lblResult.BackColor = Color.Green;
                lblResult.Text = "True";
            }
            else
            {
                lblResult.BackColor = Color.Red;
                lblResult.Text = "False";
            }
            lblMsg.Text = Msg.Length > 50 ? Msg.Substring(0, 50) : Msg;
            lblMsgToolTip.SetToolTip(BtmStatusStrip, Msg);
            lblRunTime.Text = $"{Subject.RunTime}ms";
        }
        private void ClearInputFields()
        {
            txtMaskWidth.Clear();
            txtMaskHeight.Clear();
            txtGuassSize.Clear();
            cmbFilterType.SelectedIndex = 0;
        }
        /// <summary>
        /// æ·»åŠ ç®—å­
        /// </summary>
        /// <param name="sender"></param>
        /// <param name="e"></param>
        private void btnAdd_Click(object sender, EventArgs e)
        {
            // éªŒè¯è¾“å…¥
            switch (cmbFilterType.SelectedIndex)
            {
                case 0:
                    if (string.IsNullOrWhiteSpace(txtMaskWidth.Text) || string.IsNullOrWhiteSpace(txtMaskHeight.Text))
                    {
                        MessageBox.Show("请填写所有必填字段!", "提示",
                            MessageBoxButtons.OK, MessageBoxIcon.Warning);
                        return;
                    }
                    break;
                case 1:
                    if (string.IsNullOrWhiteSpace(txtGuassSize.Text))
                    {
                        MessageBox.Show("请填写所有必填字段!", "提示",
                            MessageBoxButtons.OK, MessageBoxIcon.Warning);
                        return;
                    }
                    break;
                case 2:
                    if (string.IsNullOrWhiteSpace(txtMaskWidth.Text) || string.IsNullOrWhiteSpace(txtMaskHeight.Text))
                    {
                        MessageBox.Show("请填写所有必填字段!", "提示",
                            MessageBoxButtons.OK, MessageBoxIcon.Warning);
                        return;
                    }
                    break;
            }
            RecordFilterData filter = new RecordFilterData();
            filter.MaskWidth = this.txtMaskWidth.Text;
            filter.MaskHight = this.txtMaskHeight.Text;
            filter.GaussSize = this.txtGuassSize.Text;
            filter.FilterName = (FilterType)this.cmbFilterType.SelectedIndex;
            // æ·»åŠ åˆ° UserManager
            bool success = FilterManager.Instance.AddFilter(filter);
            if (success)
            {
                recordFilterDatas.Add(filter);
                //MessageBox.Show("用户添加成功!", "提示",
                //    MessageBoxButtons.OK, MessageBoxIcon.Information);
                // æ¸…空输入框
                ClearInputFields();
            }
            else
            {
                MessageBox.Show("添加用户失败!", "错误",
                    MessageBoxButtons.OK, MessageBoxIcon.Error);
            }
            recordFilterDatas = FilterManager.Instance.GetAllUsers();
            this.dataGridViewFi.DataSource = recordFilterDatas;
            this.dataGridViewFi.AutoGenerateColumns = true;
        }
        private void btnDel_Click(object sender, EventArgs e)
        {
            // æ£€æŸ¥æ˜¯å¦æœ‰é€‰ä¸­çš„æ»¤æ³¢ç±»åž‹
            if (cmbFilterType.SelectedIndex < 0)
            {
                MessageBox.Show("请选择要删除的滤波类型!", "提示",
                    MessageBoxButtons.OK, MessageBoxIcon.Warning);
                return;
            }
            try
            {
                DataGridViewRow selectedRow = dataGridViewFi.SelectedRows[0];
                string filterToDel = selectedRow.Cells[0].Value?.ToString();
                FilterType filterToDelete = (FilterType)cmbFilterType.SelectedIndex;
                // æŸ¥æ‰¾å¯¹åº”的记录
                RecordFilterData filterToRemove = null;
                // ä»Žæœ¬åœ°åˆ—表中查找
                foreach (var filter in recordFilterDatas)
                {
                    if (filter.FilterName.ToString() == filterToDel)
                    {
                        filterToRemove = filter;
                        break;
                    }
                }
                if (filterToRemove == null)
                {
                    MessageBox.Show("未找到对应的记录!", "提示",
                        MessageBoxButtons.OK, MessageBoxIcon.Warning);
                    return;
                }
                // ç¡®è®¤åˆ é™¤
                DialogResult result = MessageBox.Show(
                    $"确定要删除 '{filterToDel}' è®°å½•吗?",
                    "确认删除",
                    MessageBoxButtons.YesNo,
                    MessageBoxIcon.Question,
                    MessageBoxDefaultButton.Button2); // é»˜è®¤é€‰æ‹©"否"
                if (result == DialogResult.No)
                    return;
                // ä»Žç®¡ç†å™¨ä¸­åˆ é™¤
                bool success = FilterManager.Instance.DeleteUser(filterToRemove);
                if (success)
                {
                    // ä»Žæœ¬åœ°åˆ—表中删除
                    recordFilterDatas.Remove(filterToRemove);
                    MessageBox.Show("删除成功!", "提示",
                        MessageBoxButtons.OK, MessageBoxIcon.Information);
                }
                else
                {
                    MessageBox.Show("删除失败!", "错误",
                        MessageBoxButtons.OK, MessageBoxIcon.Error);
                }
                recordFilterDatas = FilterManager.Instance.GetAllUsers();
                this.dataGridViewFi.DataSource = recordFilterDatas;
                this.dataGridViewFi.AutoGenerateColumns = true;
            }
            catch (Exception ex)
            {
                MessageBox.Show("请选择要删除的算子");
            }
        }
        #region ç®—法选择下拉框
        private void cmbFilterType_SelectedIndexChanged(object sender, EventArgs e)
        {
            ComboBox cb = sender as ComboBox;
            if (cb.SelectedIndex == 0)
            {
                ShowRow1();
            }
            else if (cb.SelectedIndex == 1)
            {
                ShowRow2();
            }
            else
            {
                ShowRow1();
            }
        }
        private void ShowRow1()
        {
            // æ˜¾ç¤ºRow2(恢复高度)
            tableLayoutPanel4.RowStyles[1].SizeType = SizeType.Absolute;
            tableLayoutPanel4.RowStyles[1].Height = rowriginalHeight;
            tableLayoutPanel4.RowStyles[2].SizeType = SizeType.Absolute;
            tableLayoutPanel4.RowStyles[2].Height = 0;
            // æ˜¾ç¤ºRow2中的控件
            foreach (Control ctrl in tableLayoutPanel4.Controls)
            {
                int row = tableLayoutPanel4.GetRow(ctrl);
                if (row == 1)
                    ctrl.Visible = true;
                if (row == 2)
                    ctrl.Visible = false;
            }
        }
        private void ShowRow2()
        {
            // æ˜¾ç¤ºRow2(恢复高度)
            tableLayoutPanel4.RowStyles[1].SizeType = SizeType.Absolute;
            tableLayoutPanel4.RowStyles[1].Height = 0;
            tableLayoutPanel4.RowStyles[2].SizeType = SizeType.Absolute;
            tableLayoutPanel4.RowStyles[2].Height = rowriginalHeight;
            // æ˜¾ç¤ºRow2中的控件
            foreach (Control ctrl in tableLayoutPanel4.Controls)
            {
                int row = tableLayoutPanel4.GetRow(ctrl);
                if (row == 1)
                    ctrl.Visible = false;
                if (row == 2)
                    ctrl.Visible = true;
            }
        }
        #endregion
        #region ROI
        /// <summary>
        /// æ›´æ–°è¿è¡Œå‚æ•°
        /// </summary>
        public override void UpdataInputs()
        {
            //设置运行参数
            double dResult = 0;
            int iResult = 0;
            if (cmbFixture.Text == "")
                Subject.Params.Fixture = new Fixture();
            else if (IProcess.dicFixtures.ContainsKey(cmbFixture.Text))
                Subject.Params.Fixture = IProcess.dicFixtures[cmbFixture.Text];
            Type type = inputImageHSmartWindowControl.oRoi?.GetType();
            switch (type)
            {
                case Type t when t == typeof(HRectangle2):
                    HRectangle2 hRectangle2 = (HRectangle2)inputImageHSmartWindowControl.oRoi;
                    Subject.Params.ROI
                        = new HRectangle2(hRectangle2.X - Subject.Params.Fixture.X, hRectangle2.Y - Subject.Params.Fixture.Y
                        , hRectangle2.Phi - Subject.Params.Fixture.Phi, hRectangle2.Width, hRectangle2.Height);
                    break;
                case Type t when t == typeof(HCircle):
                    HCircle hCircle = (HCircle)inputImageHSmartWindowControl.oRoi;
                    Subject.Params.ROI
                        = new HCircle(hCircle.X - Subject.Params.Fixture.X, hCircle.Y - Subject.Params.Fixture.Y, hCircle.Radius);
                    break;
                case Type t when t == typeof(HSegment):
                    HSegment hSegment = (HSegment)inputImageHSmartWindowControl.oRoi;
                    Subject.Params.ROI
                        = new HSegment(hSegment.StartX - Subject.Params.Fixture.X, hSegment.StartY - Subject.Params.Fixture.Y
                        , hSegment.EndX - Subject.Params.Fixture.X, hSegment.EndY - Subject.Params.Fixture.Y);
                    break;
                default:
                    Subject.Params.ROI = new ROI();
                    break;
            }
        }
        /// <summary>
        /// åŠ è½½è¿è¡Œå‚æ•°
        /// </summary>
        public override void LoadParas()
        {
            this.BeginInvoke(new Action(() =>
            {
                if (Subject.InputImage != null && Subject.InputImage is HObject)
                    inputImageHSmartWindowControl.ShowHoImage((HObject)Subject.InputImage);
                Type type = Subject.Params.ROI?.GetType();
                if (Subject.Params.ROI != null)
                {
                    switch (type)
                    {
                        case Type t when t == typeof(HRectangle2):
                            cmbTypeRoi.Text = RoiType.Rectangle2.ToString();
                            break;
                        case Type t when t == typeof(HCircle):
                            cmbTypeRoi.Text = RoiType.Circle.ToString();
                            break;
                        case Type t when t == typeof(HSegment):
                            cmbTypeRoi.Text = RoiType.Segment.ToString();
                            break;
                        default:
                            cmbTypeRoi.Text = RoiType.None.ToString();
                            break;
                    }
                    if (cmbTypeRoi.Text.ToString() != "None")
                        ckbDrawRoi.Checked = true;
                    else
                        ckbDrawRoi.Checked = false;
                    inputImageHSmartWindowControl.oRoi = Subject.Params.ROI;
                }
                if (Subject.Params.Fixture != null)
                    cmbFixture.Text = Subject.Params.Fixture.strName;
                else
                    cmbFixture.Text = "";
                switch (type)
                {
                    case Type t when t == typeof(HRectangle2):
                        inputImageHSmartWindowControl.oRoi
                             = new HRectangle2(Subject.Params.ROI.X + Subject.Params.Fixture.X, Subject.Params.ROI.Y + Subject.Params.Fixture.Y
                             , Subject.Params.ROI.Phi + Subject.Params.Fixture.Phi, ((HRectangle2)Subject.Params.ROI).Width, ((HRectangle2)Subject.Params.ROI).Height);
                        break;
                    case Type t when t == typeof(HCircle):
                        inputImageHSmartWindowControl.oRoi
                        = new HCircle(Subject.Params.ROI.X + Subject.Params.Fixture.X, Subject.Params.ROI.Y + Subject.Params.Fixture.Y
                        , ((HCircle)Subject.Params.ROI).Radius);
                        break;
                    case Type t when t == typeof(HSegment):
                        inputImageHSmartWindowControl.oRoi
                        = new HSegment(((HSegment)Subject.Params.ROI).StartX + Subject.Params.Fixture.X, ((HSegment)Subject.Params.ROI).StartY + Subject.Params.Fixture.Y
                        , ((HSegment)Subject.Params.ROI).EndX + Subject.Params.Fixture.X, ((HSegment)Subject.Params.ROI).EndY + Subject.Params.Fixture.Y);
                        break;
                    default:
                        inputImageHSmartWindowControl.oRoi = null;
                        break;
                }
                base.LoadParas();
            }));
        }
        #endregion
        #region å·¥å…·æ æŒ‰é’®äº‹ä»¶
        /// <summary>
        /// ç‚¹å‡»è¿è¡Œ
        /// </summary>
        /// <param name="sender"></param>
        /// <param name="e"></param>
        public override void btnRun_Click(object sender, EventArgs e)
        {
            if (Subject.InputImage != null)
                InputImage = Subject.InputImage;
            DateTime StartTime = DateTime.Now;
            Run();
            //更新日志与结果
            this.BeginInvoke(new Action(() =>
            {
                if (Subject.Result)
                {
                    lblResult.BackColor = Color.Green;
                    lblResult.Text = "True";
                    recordImageHSmartWindowControl.SetColor("green");
                }
                else
                {
                    lblResult.BackColor = Color.Red;
                    lblResult.Text = "False";
                    recordImageHSmartWindowControl.SetColor("red");
                }
                lblMsg.Text = Msg.Length > 50 ? Msg.Substring(0, 50) : Msg;
                lblMsgToolTip.SetToolTip(BtmStatusStrip, Msg);
                lblRunTime.Text = $"{(DateTime.Now - StartTime).TotalMilliseconds}ms";
                UpdataOutputs();
                imgTabControl.SelectedTab = tabPageRecordImage;
                if (Subject.InputImage != null && Subject.InputImage is HObject)
                {
                    HOperatorSet.GetImageSize((HObject)Subject.InputImage, out HTuple ho_ImageWidth, out HTuple ho_ImageHeight);
                    recordImageHSmartWindowControl.ShowHoImage((HObject)Subject.InputImage);
                }
                //先判断子类再判断父类
                if (Subject.Record != null && Subject.Record is MsgRecord msgRecord)
                {
                    recordImageHSmartWindowControl.DispObj(msgRecord.RecordObject_OK, true);
                    recordImageHSmartWindowControl.DispObj(msgRecord.RecordObject_NG, false);
                    for (int i = 0; i < msgRecord.Msg.Length; i++)
                        recordImageHSmartWindowControl.ShowMsg(msgRecord.Msg[i]
                            , 1 == msgRecord.Result[i] ? true : false, msgRecord.Column[i], msgRecord.Row[i]);
                }
                else if (Subject.Record != null && Subject.Record is ObjectRecord objRecord)
                {
                    recordImageHSmartWindowControl.DispObj(objRecord.RecordObject_OK, true);
                    recordImageHSmartWindowControl.DispObj(objRecord.RecordObject_NG, false);
                }
                GC.Collect();
            }));
        }
        /// <summary>
        /// å·¥å…·æ â€œå¯¼å›¾â€
        /// </summary>
        /// <param name="sender"></param>
        /// <param name="e"></param>
        public override void btnLoadImage_Click(object sender, EventArgs e)
        {
            OpenFileDialog openFileDialog = new OpenFileDialog();
            // è®¾ç½®æ–‡ä»¶å¯¹è¯æ¡†çš„属性
            openFileDialog.Multiselect = false; // ä¸å…è®¸å¤šé€‰
            // è®¾ç½®æ–‡ä»¶è¿‡æ»¤å™¨ï¼Œæ”¯æŒå¤šç§æ–‡ä»¶ç±»åž‹
            openFileDialog.Filter = "Image Files (*.png;*.jpg;*.jpeg;*.bmp)|*.png;*.jpg;*.jpeg;*.bmp|All Files (*.*)|*.*";
            // æ˜¾ç¤ºæ–‡ä»¶å¯¹è¯æ¡†
            DialogResult result = openFileDialog.ShowDialog();
            // å¤„理对话框返回结果
            if (result == DialogResult.OK)
            {
                // èŽ·å–ç”¨æˆ·é€‰æ‹©çš„æ–‡ä»¶å
                string[] selectedFiles = openFileDialog.FileNames;
                if (selectedFiles.Length > 0)
                {
                    HOperatorSet.ReadImage(out HObject ho_Image, selectedFiles[0]);
                    //判断是否为灰度图
                    using (HDevDisposeHelper dh = new HDevDisposeHelper())
                    {
                        HOperatorSet.CountChannels(ho_Image, out HTuple hv_Channels);
                        if (hv_Channels.TupleInt() != 1)
                        {
                            HOperatorSet.Rgb1ToGray(ho_Image, out ho_Image);
                            //更新日志与结果
                            this.BeginInvoke(new Action(() =>
                            {
                                lblMsg.Text = "导入图片非灰度图,自动转换为灰度图";
                            }));
                        }
                        InputImage = ho_Image;
                        imgTabControl.SelectedTab = tabPageInputImage;
                        inputImageHSmartWindowControl.oRoi = inputImageHSmartWindowControl.oRoi;
                    }
                }
            }
        }
        /// <summary>
        /// å·¥å…·æ â€œä¿å­˜â€
        /// </summary>
        /// <param name="sender"></param>
        /// <param name="e"></param>
        public override void btnSaveParas_Click(object sender, EventArgs e) { base.btnSaveParas_Click(sender, e); }
        #endregion
        #region ROI功能
        /// <summary>
        /// æ˜¯å¦å¯ç”¨ROI
        /// </summary>
        /// <param name="sender"></param>
        /// <param name="e"></param>
        public override void ckbDrawRoi_CheckedChanged(object sender, EventArgs e)
        {
            if (ckbDrawRoi.Checked)
            {
                inputImageHSmartWindowControl.bAollowDraw = true;
                imgTabControl.SelectedTab = tabPageInputImage;
            }
            else
            {
                inputImageHSmartWindowControl.bAollowDraw = false;
                Subject.Params.ROI = new ROI();
            }
        }
        /// <summary>
        /// ROI下拉框改变事件
        /// </summary>
        /// <param name="sender"></param>
        /// <param name="e"></param>
        public override void cmbTypeRoi_SelectedIndexChanged(object sender, EventArgs e)
        {
            try
            {
                if (Enum.TryParse(cmbTypeRoi.Text.ToString(), out RoiType type))
                {
                    HTuple hv_imageWidth = 0;
                    HTuple hv_imageHeight = 0;
                    if (InputImage != null && InputImage is HObject)
                        HOperatorSet.GetImageSize((HObject)InputImage, out hv_imageWidth, out hv_imageHeight);
                    switch (type)
                    {
                        case RoiType.Rectangle2:
                            inputImageHSmartWindowControl.oRoi
                                = new HRectangle2(hv_imageWidth.TupleReal() / 2, hv_imageHeight.TupleReal() / 2, 0
                                , hv_imageWidth.TupleReal() / 4, hv_imageHeight.TupleReal() / 4);
                            break;
                        case RoiType.Circle:
                            inputImageHSmartWindowControl.oRoi
                                = new HCircle(hv_imageWidth.TupleReal() / 2, hv_imageHeight.TupleReal() / 2, hv_imageWidth.TupleReal() / 4);
                            break;
                        case RoiType.Segment:
                            inputImageHSmartWindowControl.oRoi
                                = new HSegment(0, 0, hv_imageWidth.TupleReal() / 4, hv_imageHeight.TupleReal() / 4);
                            break;
                        case RoiType.None:
                        default:
                            inputImageHSmartWindowControl.oRoi = null;
                            break;
                    }
                }
            }
            catch { }
        }
        public override void cmbFixture_SelectedIndexChanged(object sender, EventArgs e)
        {
            try
            {
                if (IProcess.dicFixtures.ContainsKey(cmbFixture.Text))
                    Subject.Params.Fixture = IProcess.dicFixtures[cmbFixture.Text];
                else
                    Subject.Params.Fixture = new Fixture();
            }
            catch { }
        }
        #endregion
    }
}
LB_VisionProcesses/Alogrithms/Halcon/2D/HFilterTool/HFilterToolEdit.resx
¶Ô±ÈÐÂÎļþ
@@ -0,0 +1,129 @@
<?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="lblMsgToolTip.TrayLocation" type="System.Drawing.Point, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a">
    <value>17, 17</value>
  </metadata>
  <metadata name="TopToolStrip.TrayLocation" type="System.Drawing.Point, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a">
    <value>183, 17</value>
  </metadata>
  <metadata name="BtmStatusStrip.TrayLocation" type="System.Drawing.Point, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a">
    <value>340, 17</value>
  </metadata>
</root>
LB_VisionProcesses/Alogrithms/Halcon/2D/HFindCode2dTool/HFindCode2dTool.cs
@@ -2,6 +2,7 @@
using System;
using System.Collections.Generic;
using System.Drawing;
using System.Drawing.Imaging;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
@@ -64,9 +65,30 @@
                        Result = false;
                        return;
                    }
                    if (InputImage is Bitmap)
                    {
                        try
                        {
                            using (HImage hImage = new HImage())
                            {
                                Bitmap bitmap = (Bitmap)InputImage;
                                Rectangle rect = new Rectangle(0, 0, ((Bitmap)bitmap).Width, ((Bitmap)bitmap).Height);
                                BitmapData srcBmpData = ((Bitmap)bitmap).LockBits(rect, ImageLockMode.ReadOnly, PixelFormat.Format32bppRgb);
                                hImage.GenImageInterleaved(srcBmpData.Scan0, "rgbx", ((Bitmap)bitmap).Width, ((Bitmap)bitmap).Height, 0, "byte", ((Bitmap)bitmap).Width, ((Bitmap)bitmap).Height, 0, 0, -1, 0);
                                ((Bitmap)bitmap).UnlockBits(srcBmpData);
                                bitmap.Dispose();
                                bitmap = null;
                                InputImage = null;
                                InputImage = hImage.Clone();
                            }
                        }
                        catch (Exception ex)
                        {
                        }
                    }
                    if (!(InputImage is HObject))
                    {
                        Msg = "输入图片格式不为Mat";
                        Msg = "输入图片格式不为HObject";
                        Result = false;
                        return;
                    }
LB_VisionProcesses/Alogrithms/Halcon/2D/HFindCode2dTool/HFindCode2dToolEdit.Designer.cs
@@ -91,9 +91,9 @@
            // tablePanelParas
            // 
            tablePanelParas.ColumnCount = 4;
            tablePanelParas.ColumnStyles.Add(new ColumnStyle(SizeType.Absolute, 90F));
            tablePanelParas.ColumnStyles.Add(new ColumnStyle(SizeType.Absolute, 116F));
            tablePanelParas.ColumnStyles.Add(new ColumnStyle(SizeType.Percent, 50F));
            tablePanelParas.ColumnStyles.Add(new ColumnStyle(SizeType.Absolute, 90F));
            tablePanelParas.ColumnStyles.Add(new ColumnStyle(SizeType.Absolute, 116F));
            tablePanelParas.ColumnStyles.Add(new ColumnStyle(SizeType.Percent, 50F));
            tablePanelParas.Controls.Add(label1, 0, 0);
            tablePanelParas.Controls.Add(dtxtMinThreshold, 1, 0);
@@ -110,8 +110,8 @@
            tablePanelParas.Controls.Add(label10, 2, 3);
            tablePanelParas.Controls.Add(dtxtCodeLength, 3, 3);
            tablePanelParas.Dock = DockStyle.Fill;
            tablePanelParas.Location = new Point(3, 3);
            tablePanelParas.Margin = new Padding(2, 3, 2, 3);
            tablePanelParas.Location = new Point(4, 4);
            tablePanelParas.Margin = new Padding(3, 4, 3, 4);
            tablePanelParas.Name = "tablePanelParas";
            tablePanelParas.RowCount = 10;
            tablePanelParas.RowStyles.Add(new RowStyle(SizeType.Percent, 10F));
@@ -124,71 +124,71 @@
            tablePanelParas.RowStyles.Add(new RowStyle(SizeType.Percent, 10.000001F));
            tablePanelParas.RowStyles.Add(new RowStyle(SizeType.Percent, 10.000001F));
            tablePanelParas.RowStyles.Add(new RowStyle(SizeType.Percent, 10F));
            tablePanelParas.RowStyles.Add(new RowStyle(SizeType.Absolute, 20F));
            tablePanelParas.RowStyles.Add(new RowStyle(SizeType.Absolute, 20F));
            tablePanelParas.RowStyles.Add(new RowStyle(SizeType.Absolute, 20F));
            tablePanelParas.RowStyles.Add(new RowStyle(SizeType.Absolute, 20F));
            tablePanelParas.RowStyles.Add(new RowStyle(SizeType.Absolute, 20F));
            tablePanelParas.Size = new Size(397, 510);
            tablePanelParas.RowStyles.Add(new RowStyle(SizeType.Absolute, 24F));
            tablePanelParas.RowStyles.Add(new RowStyle(SizeType.Absolute, 24F));
            tablePanelParas.RowStyles.Add(new RowStyle(SizeType.Absolute, 24F));
            tablePanelParas.RowStyles.Add(new RowStyle(SizeType.Absolute, 24F));
            tablePanelParas.RowStyles.Add(new RowStyle(SizeType.Absolute, 24F));
            tablePanelParas.Size = new Size(512, 603);
            tablePanelParas.TabIndex = 0;
            // 
            // label1
            // 
            label1.AutoSize = true;
            label1.Location = new Point(2, 0);
            label1.Margin = new Padding(2, 0, 2, 0);
            label1.MaximumSize = new Size(0, 28);
            label1.MinimumSize = new Size(0, 28);
            label1.Location = new Point(3, 0);
            label1.MaximumSize = new Size(0, 33);
            label1.MinimumSize = new Size(0, 33);
            label1.Name = "label1";
            label1.Size = new Size(68, 28);
            label1.Size = new Size(84, 33);
            label1.TabIndex = 0;
            label1.Text = "最小灰度值";
            label1.TextAlign = ContentAlignment.MiddleCenter;
            // 
            // dtxtMinThreshold
            // 
            dtxtMinThreshold.Location = new Point(92, 3);
            dtxtMinThreshold.Margin = new Padding(2, 3, 2, 3);
            dtxtMinThreshold.Location = new Point(119, 4);
            dtxtMinThreshold.Margin = new Padding(3, 4, 3, 4);
            dtxtMinThreshold.Name = "dtxtMinThreshold";
            dtxtMinThreshold.Size = new Size(98, 23);
            dtxtMinThreshold.Size = new Size(125, 27);
            dtxtMinThreshold.TabIndex = 5;
            dtxtMinThreshold.Text = "80";
            // 
            // dtxtMaxThreshold
            // 
            dtxtMaxThreshold.Location = new Point(290, 3);
            dtxtMaxThreshold.Margin = new Padding(2, 3, 2, 3);
            dtxtMaxThreshold.Location = new Point(375, 4);
            dtxtMaxThreshold.Margin = new Padding(3, 4, 3, 4);
            dtxtMaxThreshold.Name = "dtxtMaxThreshold";
            dtxtMaxThreshold.Size = new Size(98, 23);
            dtxtMaxThreshold.Size = new Size(125, 27);
            dtxtMaxThreshold.TabIndex = 6;
            dtxtMaxThreshold.Text = "180";
            // 
            // label19
            // 
            label19.AutoSize = true;
            label19.Location = new Point(3, 51);
            label19.Location = new Point(4, 60);
            label19.Margin = new Padding(4, 0, 4, 0);
            label19.Name = "label19";
            label19.Size = new Size(56, 17);
            label19.Size = new Size(69, 20);
            label19.TabIndex = 19;
            label19.Text = "最小数量";
            // 
            // dtxtMinCount
            // 
            dtxtMinCount.Location = new Point(93, 54);
            dtxtMinCount.Location = new Point(120, 64);
            dtxtMinCount.Margin = new Padding(4, 4, 4, 4);
            dtxtMinCount.Name = "dtxtMinCount";
            dtxtMinCount.Size = new Size(97, 23);
            dtxtMinCount.Size = new Size(124, 27);
            dtxtMinCount.TabIndex = 17;
            dtxtMinCount.Text = "0";
            // 
            // label2
            // 
            label2.AutoSize = true;
            label2.Location = new Point(200, 0);
            label2.Margin = new Padding(2, 0, 2, 0);
            label2.MaximumSize = new Size(0, 28);
            label2.MinimumSize = new Size(0, 28);
            label2.Location = new Point(259, 0);
            label2.MaximumSize = new Size(0, 33);
            label2.MinimumSize = new Size(0, 33);
            label2.Name = "label2";
            label2.Size = new Size(68, 28);
            label2.Size = new Size(84, 33);
            label2.TabIndex = 1;
            label2.Text = "最大灰度值";
            label2.TextAlign = ContentAlignment.MiddleCenter;
@@ -196,84 +196,93 @@
            // label20
            // 
            label20.AutoSize = true;
            label20.Location = new Point(201, 51);
            label20.Location = new Point(260, 60);
            label20.Margin = new Padding(4, 0, 4, 0);
            label20.Name = "label20";
            label20.Size = new Size(56, 17);
            label20.Size = new Size(69, 20);
            label20.TabIndex = 20;
            label20.Text = "最大数量";
            // 
            // dtxtMaxCount
            // 
            dtxtMaxCount.Location = new Point(291, 54);
            dtxtMaxCount.Location = new Point(376, 64);
            dtxtMaxCount.Margin = new Padding(4, 4, 4, 4);
            dtxtMaxCount.Name = "dtxtMaxCount";
            dtxtMaxCount.Size = new Size(97, 23);
            dtxtMaxCount.Size = new Size(124, 27);
            dtxtMaxCount.TabIndex = 18;
            dtxtMaxCount.Text = "9999";
            // 
            // label3
            // 
            label3.AutoSize = true;
            label3.Location = new Point(3, 153);
            label3.Location = new Point(4, 180);
            label3.Margin = new Padding(4, 0, 4, 0);
            label3.Name = "label3";
            label3.Size = new Size(44, 17);
            label3.Size = new Size(54, 20);
            label3.TabIndex = 21;
            label3.Text = "条码头";
            // 
            // stxtCodeHead
            // 
            stxtCodeHead.Location = new Point(93, 156);
            stxtCodeHead.Location = new Point(120, 184);
            stxtCodeHead.Margin = new Padding(4, 4, 4, 4);
            stxtCodeHead.Name = "stxtCodeHead";
            stxtCodeHead.Size = new Size(97, 23);
            stxtCodeHead.Size = new Size(124, 27);
            stxtCodeHead.TabIndex = 22;
            // 
            // label4
            // 
            label4.AutoSize = true;
            label4.Location = new Point(3, 102);
            label4.Location = new Point(4, 120);
            label4.Margin = new Padding(4, 0, 4, 0);
            label4.Name = "label4";
            label4.Size = new Size(56, 17);
            label4.Size = new Size(69, 20);
            label4.TabIndex = 23;
            label4.Text = "条码类型";
            // 
            // cmbCode2dType
            // 
            cmbCode2dType.FormattingEnabled = true;
            cmbCode2dType.Location = new Point(93, 105);
            cmbCode2dType.Location = new Point(120, 124);
            cmbCode2dType.Margin = new Padding(4, 4, 4, 4);
            cmbCode2dType.Name = "cmbCode2dType";
            cmbCode2dType.Size = new Size(97, 25);
            cmbCode2dType.Size = new Size(124, 28);
            cmbCode2dType.TabIndex = 24;
            // 
            // label10
            // 
            label10.AutoSize = true;
            label10.Location = new Point(201, 153);
            label10.Location = new Point(260, 180);
            label10.Margin = new Padding(4, 0, 4, 0);
            label10.Name = "label10";
            label10.Size = new Size(56, 17);
            label10.Size = new Size(69, 20);
            label10.TabIndex = 25;
            label10.Text = "条码长度";
            // 
            // dtxtCodeLength
            // 
            dtxtCodeLength.Location = new Point(291, 156);
            dtxtCodeLength.Location = new Point(376, 184);
            dtxtCodeLength.Margin = new Padding(4, 4, 4, 4);
            dtxtCodeLength.Name = "dtxtCodeLength";
            dtxtCodeLength.Size = new Size(97, 23);
            dtxtCodeLength.Size = new Size(124, 27);
            dtxtCodeLength.TabIndex = 26;
            // 
            // pnlInputImage
            // 
            pnlInputImage.Dock = DockStyle.Fill;
            pnlInputImage.Location = new Point(3, 3);
            pnlInputImage.Margin = new Padding(4);
            pnlInputImage.Location = new Point(4, 4);
            pnlInputImage.Margin = new Padding(5, 5, 5, 5);
            pnlInputImage.Name = "pnlInputImage";
            pnlInputImage.Size = new Size(607, 510);
            pnlInputImage.Size = new Size(782, 603);
            pnlInputImage.TabIndex = 44;
            // 
            // TopToolStrip
            // 
            TopToolStrip.ImageScalingSize = new Size(20, 20);
            TopToolStrip.Items.AddRange(new ToolStripItem[] { btnRun, btnLoadImage, btnSaveParas, btnLoadParas });
            TopToolStrip.Location = new Point(0, 0);
            TopToolStrip.Name = "TopToolStrip";
            TopToolStrip.Size = new Size(1044, 25);
            TopToolStrip.Size = new Size(1342, 27);
            TopToolStrip.TabIndex = 45;
            TopToolStrip.Text = "toolStrip1";
            // 
@@ -282,7 +291,7 @@
            btnRun.BackgroundImageLayout = ImageLayout.Zoom;
            btnRun.ImageTransparentColor = Color.Magenta;
            btnRun.Name = "btnRun";
            btnRun.Size = new Size(36, 22);
            btnRun.Size = new Size(43, 24);
            btnRun.Text = "运行";
            btnRun.Click += btnRun_Click;
            // 
@@ -290,7 +299,7 @@
            // 
            btnLoadImage.ImageTransparentColor = Color.Magenta;
            btnLoadImage.Name = "btnLoadImage";
            btnLoadImage.Size = new Size(36, 22);
            btnLoadImage.Size = new Size(43, 24);
            btnLoadImage.Text = "导图";
            btnLoadImage.Click += btnLoadImage_Click;
            // 
@@ -298,7 +307,7 @@
            // 
            btnSaveParas.ImageTransparentColor = Color.Magenta;
            btnSaveParas.Name = "btnSaveParas";
            btnSaveParas.Size = new Size(36, 22);
            btnSaveParas.Size = new Size(43, 24);
            btnSaveParas.Text = "保存";
            btnSaveParas.Click += btnSaveParas_Click;
            // 
@@ -306,35 +315,37 @@
            // 
            btnLoadParas.ImageTransparentColor = Color.Magenta;
            btnLoadParas.Name = "btnLoadParas";
            btnLoadParas.Size = new Size(36, 22);
            btnLoadParas.Size = new Size(43, 24);
            btnLoadParas.Text = "加载";
            btnLoadParas.Click += btnLoadParas_Click;
            // 
            // BtmStatusStrip
            // 
            BtmStatusStrip.ImageScalingSize = new Size(20, 20);
            BtmStatusStrip.Items.AddRange(new ToolStripItem[] { lblResult, lblMsg, lblRunTime });
            BtmStatusStrip.Location = new Point(0, 577);
            BtmStatusStrip.Location = new Point(0, 679);
            BtmStatusStrip.Name = "BtmStatusStrip";
            BtmStatusStrip.Size = new Size(1044, 22);
            BtmStatusStrip.Padding = new Padding(1, 0, 18, 0);
            BtmStatusStrip.Size = new Size(1342, 26);
            BtmStatusStrip.TabIndex = 46;
            BtmStatusStrip.Text = "statusStrip1";
            // 
            // lblResult
            // 
            lblResult.Name = "lblResult";
            lblResult.Size = new Size(34, 17);
            lblResult.Size = new Size(42, 20);
            lblResult.Text = "True";
            // 
            // lblMsg
            // 
            lblMsg.Name = "lblMsg";
            lblMsg.Size = new Size(56, 17);
            lblMsg.Size = new Size(69, 20);
            lblMsg.Text = "运行成功";
            // 
            // lblRunTime
            // 
            lblRunTime.Name = "lblRunTime";
            lblRunTime.Size = new Size(32, 17);
            lblRunTime.Size = new Size(39, 20);
            lblRunTime.Text = "0ms";
            // 
            // MainTableLayoutPanel
@@ -345,11 +356,12 @@
            MainTableLayoutPanel.Controls.Add(parasTabControl, 0, 0);
            MainTableLayoutPanel.Controls.Add(imgTabControl, 1, 0);
            MainTableLayoutPanel.Dock = DockStyle.Fill;
            MainTableLayoutPanel.Location = new Point(0, 25);
            MainTableLayoutPanel.Location = new Point(0, 27);
            MainTableLayoutPanel.Margin = new Padding(4, 4, 4, 4);
            MainTableLayoutPanel.Name = "MainTableLayoutPanel";
            MainTableLayoutPanel.RowCount = 1;
            MainTableLayoutPanel.RowStyles.Add(new RowStyle(SizeType.Percent, 100F));
            MainTableLayoutPanel.Size = new Size(1044, 552);
            MainTableLayoutPanel.Size = new Size(1342, 652);
            MainTableLayoutPanel.TabIndex = 47;
            // 
            // parasTabControl
@@ -358,19 +370,21 @@
            parasTabControl.Controls.Add(tabPage5);
            parasTabControl.Controls.Add(tabPage2);
            parasTabControl.Dock = DockStyle.Fill;
            parasTabControl.Location = new Point(3, 3);
            parasTabControl.Location = new Point(4, 4);
            parasTabControl.Margin = new Padding(4, 4, 4, 4);
            parasTabControl.Name = "parasTabControl";
            parasTabControl.SelectedIndex = 0;
            parasTabControl.Size = new Size(411, 546);
            parasTabControl.Size = new Size(528, 644);
            parasTabControl.TabIndex = 48;
            // 
            // tabPage1
            // 
            tabPage1.Controls.Add(tablePanelParas);
            tabPage1.Location = new Point(4, 26);
            tabPage1.Location = new Point(4, 29);
            tabPage1.Margin = new Padding(4, 4, 4, 4);
            tabPage1.Name = "tabPage1";
            tabPage1.Padding = new Padding(3);
            tabPage1.Size = new Size(403, 516);
            tabPage1.Padding = new Padding(4, 4, 4, 4);
            tabPage1.Size = new Size(520, 611);
            tabPage1.TabIndex = 0;
            tabPage1.Text = "输入参数";
            tabPage1.UseVisualStyleBackColor = true;
@@ -378,9 +392,10 @@
            // tabPage5
            // 
            tabPage5.Controls.Add(tableLayoutPanel2);
            tabPage5.Location = new Point(4, 26);
            tabPage5.Location = new Point(4, 29);
            tabPage5.Margin = new Padding(4, 4, 4, 4);
            tabPage5.Name = "tabPage5";
            tabPage5.Size = new Size(403, 516);
            tabPage5.Size = new Size(520, 611);
            tabPage5.TabIndex = 2;
            tabPage5.Text = "运行参数";
            tabPage5.UseVisualStyleBackColor = true;
@@ -388,30 +403,32 @@
            // tableLayoutPanel2
            // 
            tableLayoutPanel2.ColumnCount = 4;
            tableLayoutPanel2.ColumnStyles.Add(new ColumnStyle(SizeType.Absolute, 60F));
            tableLayoutPanel2.ColumnStyles.Add(new ColumnStyle(SizeType.Absolute, 150F));
            tableLayoutPanel2.ColumnStyles.Add(new ColumnStyle(SizeType.Absolute, 20F));
            tableLayoutPanel2.ColumnStyles.Add(new ColumnStyle(SizeType.Absolute, 77F));
            tableLayoutPanel2.ColumnStyles.Add(new ColumnStyle(SizeType.Absolute, 193F));
            tableLayoutPanel2.ColumnStyles.Add(new ColumnStyle(SizeType.Absolute, 26F));
            tableLayoutPanel2.ColumnStyles.Add(new ColumnStyle(SizeType.Percent, 100F));
            tableLayoutPanel2.Controls.Add(cmbTypeRoi, 1, 0);
            tableLayoutPanel2.Controls.Add(label21, 0, 0);
            tableLayoutPanel2.Controls.Add(label22, 0, 1);
            tableLayoutPanel2.Controls.Add(cmbFixture, 1, 1);
            tableLayoutPanel2.Controls.Add(ckbDrawRoi, 2, 0);
            tableLayoutPanel2.Location = new Point(3, 3);
            tableLayoutPanel2.Location = new Point(4, 4);
            tableLayoutPanel2.Margin = new Padding(4, 4, 4, 4);
            tableLayoutPanel2.Name = "tableLayoutPanel2";
            tableLayoutPanel2.RowCount = 3;
            tableLayoutPanel2.RowStyles.Add(new RowStyle(SizeType.Absolute, 30F));
            tableLayoutPanel2.RowStyles.Add(new RowStyle(SizeType.Absolute, 30F));
            tableLayoutPanel2.RowStyles.Add(new RowStyle(SizeType.Absolute, 35F));
            tableLayoutPanel2.RowStyles.Add(new RowStyle(SizeType.Absolute, 35F));
            tableLayoutPanel2.RowStyles.Add(new RowStyle(SizeType.Percent, 100F));
            tableLayoutPanel2.Size = new Size(323, 196);
            tableLayoutPanel2.Size = new Size(415, 231);
            tableLayoutPanel2.TabIndex = 5;
            // 
            // cmbTypeRoi
            // 
            cmbTypeRoi.FormattingEnabled = true;
            cmbTypeRoi.Location = new Point(63, 3);
            cmbTypeRoi.Location = new Point(81, 4);
            cmbTypeRoi.Margin = new Padding(4, 4, 4, 4);
            cmbTypeRoi.Name = "cmbTypeRoi";
            cmbTypeRoi.Size = new Size(121, 25);
            cmbTypeRoi.Size = new Size(154, 28);
            cmbTypeRoi.TabIndex = 1;
            cmbTypeRoi.SelectedIndexChanged += cmbTypeRoi_SelectedIndexChanged;
            // 
@@ -419,9 +436,10 @@
            // 
            label21.AutoSize = true;
            label21.Dock = DockStyle.Fill;
            label21.Location = new Point(3, 0);
            label21.Location = new Point(4, 0);
            label21.Margin = new Padding(4, 0, 4, 0);
            label21.Name = "label21";
            label21.Size = new Size(54, 30);
            label21.Size = new Size(69, 35);
            label21.TabIndex = 3;
            label21.Text = "ROI";
            label21.TextAlign = ContentAlignment.MiddleCenter;
@@ -430,9 +448,10 @@
            // 
            label22.AutoSize = true;
            label22.Dock = DockStyle.Fill;
            label22.Location = new Point(3, 30);
            label22.Location = new Point(4, 35);
            label22.Margin = new Padding(4, 0, 4, 0);
            label22.Name = "label22";
            label22.Size = new Size(54, 30);
            label22.Size = new Size(69, 35);
            label22.TabIndex = 4;
            label22.Text = "Fixture";
            label22.TextAlign = ContentAlignment.MiddleCenter;
@@ -440,9 +459,10 @@
            // cmbFixture
            // 
            cmbFixture.FormattingEnabled = true;
            cmbFixture.Location = new Point(63, 33);
            cmbFixture.Location = new Point(81, 39);
            cmbFixture.Margin = new Padding(4, 4, 4, 4);
            cmbFixture.Name = "cmbFixture";
            cmbFixture.Size = new Size(121, 25);
            cmbFixture.Size = new Size(154, 28);
            cmbFixture.TabIndex = 5;
            cmbFixture.SelectedIndexChanged += cmbFixture_SelectedIndexChanged;
            // 
@@ -450,9 +470,10 @@
            // 
            ckbDrawRoi.AutoSize = true;
            ckbDrawRoi.CheckAlign = ContentAlignment.MiddleCenter;
            ckbDrawRoi.Location = new Point(213, 3);
            ckbDrawRoi.Location = new Point(274, 4);
            ckbDrawRoi.Margin = new Padding(4, 4, 4, 4);
            ckbDrawRoi.Name = "ckbDrawRoi";
            ckbDrawRoi.Size = new Size(14, 14);
            ckbDrawRoi.Size = new Size(18, 17);
            ckbDrawRoi.TabIndex = 2;
            ckbDrawRoi.UseVisualStyleBackColor = true;
            ckbDrawRoi.CheckedChanged += ckbDrawRoi_CheckedChanged;
@@ -460,10 +481,11 @@
            // tabPage2
            // 
            tabPage2.Controls.Add(tableLayoutResults);
            tabPage2.Location = new Point(4, 26);
            tabPage2.Location = new Point(4, 29);
            tabPage2.Margin = new Padding(4, 4, 4, 4);
            tabPage2.Name = "tabPage2";
            tabPage2.Padding = new Padding(3);
            tabPage2.Size = new Size(403, 516);
            tabPage2.Padding = new Padding(4, 4, 4, 4);
            tabPage2.Size = new Size(520, 611);
            tabPage2.TabIndex = 1;
            tabPage2.Text = "输出结果";
            tabPage2.UseVisualStyleBackColor = true;
@@ -471,15 +493,15 @@
            // tableLayoutResults
            // 
            tableLayoutResults.ColumnCount = 2;
            tableLayoutResults.ColumnStyles.Add(new ColumnStyle(SizeType.Absolute, 100F));
            tableLayoutResults.ColumnStyles.Add(new ColumnStyle(SizeType.Absolute, 129F));
            tableLayoutResults.ColumnStyles.Add(new ColumnStyle(SizeType.Percent, 100F));
            tableLayoutResults.Controls.Add(label5, 0, 0);
            tableLayoutResults.Controls.Add(stxtCodeStrings, 1, 0);
            tableLayoutResults.Controls.Add(label18, 0, 1);
            tableLayoutResults.Controls.Add(dtxtCount, 1, 1);
            tableLayoutResults.Dock = DockStyle.Fill;
            tableLayoutResults.Location = new Point(3, 3);
            tableLayoutResults.Margin = new Padding(2, 3, 2, 3);
            tableLayoutResults.Location = new Point(4, 4);
            tableLayoutResults.Margin = new Padding(3, 4, 3, 4);
            tableLayoutResults.Name = "tableLayoutResults";
            tableLayoutResults.RowCount = 10;
            tableLayoutResults.RowStyles.Add(new RowStyle(SizeType.Percent, 10F));
@@ -492,19 +514,18 @@
            tableLayoutResults.RowStyles.Add(new RowStyle(SizeType.Percent, 10F));
            tableLayoutResults.RowStyles.Add(new RowStyle(SizeType.Percent, 10F));
            tableLayoutResults.RowStyles.Add(new RowStyle(SizeType.Percent, 10F));
            tableLayoutResults.Size = new Size(397, 510);
            tableLayoutResults.Size = new Size(512, 603);
            tableLayoutResults.TabIndex = 1;
            // 
            // label5
            // 
            label5.AutoSize = true;
            label5.Dock = DockStyle.Fill;
            label5.Location = new Point(2, 0);
            label5.Margin = new Padding(2, 0, 2, 0);
            label5.MaximumSize = new Size(0, 28);
            label5.MinimumSize = new Size(0, 28);
            label5.Location = new Point(3, 0);
            label5.MaximumSize = new Size(0, 33);
            label5.MinimumSize = new Size(0, 33);
            label5.Name = "label5";
            label5.Size = new Size(96, 28);
            label5.Size = new Size(123, 33);
            label5.TabIndex = 0;
            label5.Text = "结果";
            label5.TextAlign = ContentAlignment.TopCenter;
@@ -512,21 +533,22 @@
            // stxtCodeStrings
            // 
            stxtCodeStrings.Dock = DockStyle.Fill;
            stxtCodeStrings.Location = new Point(102, 3);
            stxtCodeStrings.Margin = new Padding(2, 3, 2, 3);
            stxtCodeStrings.Location = new Point(132, 4);
            stxtCodeStrings.Margin = new Padding(3, 4, 3, 4);
            stxtCodeStrings.Multiline = true;
            stxtCodeStrings.Name = "stxtCodeStrings";
            stxtCodeStrings.ReadOnly = true;
            stxtCodeStrings.Size = new Size(293, 45);
            stxtCodeStrings.Size = new Size(377, 52);
            stxtCodeStrings.TabIndex = 5;
            // 
            // label18
            // 
            label18.AutoSize = true;
            label18.Dock = DockStyle.Fill;
            label18.Location = new Point(3, 51);
            label18.Location = new Point(4, 60);
            label18.Margin = new Padding(4, 0, 4, 0);
            label18.Name = "label18";
            label18.Size = new Size(94, 51);
            label18.Size = new Size(121, 60);
            label18.TabIndex = 10;
            label18.Text = "数量";
            label18.TextAlign = ContentAlignment.TopCenter;
@@ -534,10 +556,11 @@
            // dtxtCount
            // 
            dtxtCount.Dock = DockStyle.Fill;
            dtxtCount.Location = new Point(103, 54);
            dtxtCount.Location = new Point(133, 64);
            dtxtCount.Margin = new Padding(4, 4, 4, 4);
            dtxtCount.Name = "dtxtCount";
            dtxtCount.ReadOnly = true;
            dtxtCount.Size = new Size(291, 23);
            dtxtCount.Size = new Size(375, 27);
            dtxtCount.TabIndex = 11;
            // 
            // imgTabControl
@@ -545,19 +568,21 @@
            imgTabControl.Controls.Add(tabPageInputImage);
            imgTabControl.Controls.Add(tabPageRecordImage);
            imgTabControl.Dock = DockStyle.Fill;
            imgTabControl.Location = new Point(420, 3);
            imgTabControl.Location = new Point(540, 4);
            imgTabControl.Margin = new Padding(4, 4, 4, 4);
            imgTabControl.Name = "imgTabControl";
            imgTabControl.SelectedIndex = 0;
            imgTabControl.Size = new Size(621, 546);
            imgTabControl.Size = new Size(798, 644);
            imgTabControl.TabIndex = 49;
            // 
            // tabPageInputImage
            // 
            tabPageInputImage.Controls.Add(pnlInputImage);
            tabPageInputImage.Location = new Point(4, 26);
            tabPageInputImage.Location = new Point(4, 29);
            tabPageInputImage.Margin = new Padding(4, 4, 4, 4);
            tabPageInputImage.Name = "tabPageInputImage";
            tabPageInputImage.Padding = new Padding(3);
            tabPageInputImage.Size = new Size(613, 516);
            tabPageInputImage.Padding = new Padding(4, 4, 4, 4);
            tabPageInputImage.Size = new Size(790, 611);
            tabPageInputImage.TabIndex = 0;
            tabPageInputImage.Text = "输入图像";
            tabPageInputImage.UseVisualStyleBackColor = true;
@@ -565,10 +590,11 @@
            // tabPageRecordImage
            // 
            tabPageRecordImage.Controls.Add(pnlRecordImage);
            tabPageRecordImage.Location = new Point(4, 26);
            tabPageRecordImage.Location = new Point(4, 29);
            tabPageRecordImage.Margin = new Padding(4, 4, 4, 4);
            tabPageRecordImage.Name = "tabPageRecordImage";
            tabPageRecordImage.Padding = new Padding(3);
            tabPageRecordImage.Size = new Size(613, 516);
            tabPageRecordImage.Padding = new Padding(4, 4, 4, 4);
            tabPageRecordImage.Size = new Size(790, 611);
            tabPageRecordImage.TabIndex = 1;
            tabPageRecordImage.Text = "结果图像";
            tabPageRecordImage.UseVisualStyleBackColor = true;
@@ -576,22 +602,22 @@
            // pnlRecordImage
            // 
            pnlRecordImage.Dock = DockStyle.Fill;
            pnlRecordImage.Location = new Point(3, 3);
            pnlRecordImage.Margin = new Padding(4);
            pnlRecordImage.Location = new Point(4, 4);
            pnlRecordImage.Margin = new Padding(5, 5, 5, 5);
            pnlRecordImage.Name = "pnlRecordImage";
            pnlRecordImage.Size = new Size(607, 510);
            pnlRecordImage.Size = new Size(782, 603);
            pnlRecordImage.TabIndex = 45;
            // 
            // HFindCode2dToolEdit
            // 
            AutoScaleDimensions = new SizeF(7F, 17F);
            AutoScaleDimensions = new SizeF(9F, 20F);
            AutoScaleMode = AutoScaleMode.Font;
            Controls.Add(MainTableLayoutPanel);
            Controls.Add(BtmStatusStrip);
            Controls.Add(TopToolStrip);
            Margin = new Padding(2, 3, 2, 3);
            Margin = new Padding(3, 4, 3, 4);
            Name = "HFindCode2dToolEdit";
            Size = new Size(1044, 599);
            Size = new Size(1342, 705);
            Load += HFindCode2dToolEdit_Load;
            tablePanelParas.ResumeLayout(false);
            tablePanelParas.PerformLayout();
LB_VisionProcesses/Alogrithms/Halcon/2D/HFindCode2dTool/HFindCode2dToolEdit.resx
@@ -1,7 +1,7 @@
<?xml version="1.0" encoding="utf-8"?>
<root>
  <!--
    Microsoft ResX Schema
    Microsoft ResX Schema
    Version 2.0
@@ -48,7 +48,7 @@
    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
@@ -117,10 +117,13 @@
  <resheader name="writer">
    <value>System.Resources.ResXResourceWriter, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
  </resheader>
  <metadata name="TopToolStrip.TrayLocation" type="System.Drawing.Point, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a">
  <metadata name="lblMsgToolTip.TrayLocation" type="System.Drawing.Point, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a">
    <value>17, 17</value>
  </metadata>
  <metadata name="TopToolStrip.TrayLocation" type="System.Drawing.Point, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a">
    <value>183, 17</value>
  </metadata>
  <metadata name="BtmStatusStrip.TrayLocation" type="System.Drawing.Point, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a">
    <value>148, 17</value>
    <value>340, 17</value>
  </metadata>
</root>
LB_VisionProcesses/Alogrithms/Halcon/2D/HFindLineTool/HFindLineTool.cs
@@ -3,6 +3,7 @@
using LB_VisionProcesses.Alogrithms.Halcon;
using System;
using System.Collections.Generic;
using System.Drawing.Imaging;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
@@ -61,6 +62,33 @@
                    Result = false;
                    return;
                }
                if (InputImage is Bitmap)
                {
                    try
                    {
                        using (HImage hImage = new HImage())
                        {
                            Bitmap bitmap = (Bitmap)InputImage;
                            Rectangle rect = new Rectangle(0, 0, ((Bitmap)bitmap).Width, ((Bitmap)bitmap).Height);
                            BitmapData srcBmpData = ((Bitmap)bitmap).LockBits(rect, ImageLockMode.ReadOnly, PixelFormat.Format32bppRgb);
                            hImage.GenImageInterleaved(srcBmpData.Scan0, "rgbx", ((Bitmap)bitmap).Width, ((Bitmap)bitmap).Height, 0, "byte", ((Bitmap)bitmap).Width, ((Bitmap)bitmap).Height, 0, 0, -1, 0);
                            ((Bitmap)bitmap).UnlockBits(srcBmpData);
                            bitmap.Dispose();
                            bitmap = null;
                            InputImage = null;
                            InputImage = hImage.Clone();
                        }
                    }
                    catch (Exception ex)
                    {
                    }
                }
                if (!(InputImage is HObject))
                {
                    Msg = "输入图片格式不为HObject";
                    Result = false;
                    return;
                }
                #region è£å‰ªåŒºåŸŸ
                if (!(Params.ROI is HSegment))
LB_VisionProcesses/Alogrithms/Halcon/2D/HFindLineTool/HFindLineToolEdit.Designer.cs
@@ -47,6 +47,7 @@
            label13 = new Label();
            cmbTransition = new ComboBox();
            cmbSelect = new ComboBox();
            btnShowROI = new Button();
            pnlInputImage = new Panel();
            TopToolStrip = new ToolStrip();
            btnRun = new ToolStripButton();
@@ -85,7 +86,6 @@
            tabPageInputImage = new TabPage();
            tabPageRecordImage = new TabPage();
            pnlRecordImage = new Panel();
            btnShowROI = new Button();
            tablePanelParas.SuspendLayout();
            TopToolStrip.SuspendLayout();
            BtmStatusStrip.SuspendLayout();
@@ -104,9 +104,9 @@
            // tablePanelParas
            // 
            tablePanelParas.ColumnCount = 4;
            tablePanelParas.ColumnStyles.Add(new ColumnStyle(SizeType.Absolute, 90F));
            tablePanelParas.ColumnStyles.Add(new ColumnStyle(SizeType.Absolute, 116F));
            tablePanelParas.ColumnStyles.Add(new ColumnStyle(SizeType.Percent, 50F));
            tablePanelParas.ColumnStyles.Add(new ColumnStyle(SizeType.Absolute, 90F));
            tablePanelParas.ColumnStyles.Add(new ColumnStyle(SizeType.Absolute, 116F));
            tablePanelParas.ColumnStyles.Add(new ColumnStyle(SizeType.Percent, 50F));
            tablePanelParas.Controls.Add(label1, 0, 0);
            tablePanelParas.Controls.Add(itxtCaliperCount, 1, 0);
@@ -126,8 +126,8 @@
            tablePanelParas.Controls.Add(cmbSelect, 3, 3);
            tablePanelParas.Controls.Add(btnShowROI, 0, 4);
            tablePanelParas.Dock = DockStyle.Fill;
            tablePanelParas.Location = new Point(3, 3);
            tablePanelParas.Margin = new Padding(2, 3, 2, 3);
            tablePanelParas.Location = new Point(4, 4);
            tablePanelParas.Margin = new Padding(3, 4, 3, 4);
            tablePanelParas.Name = "tablePanelParas";
            tablePanelParas.RowCount = 10;
            tablePanelParas.RowStyles.Add(new RowStyle(SizeType.Percent, 10F));
@@ -140,155 +140,148 @@
            tablePanelParas.RowStyles.Add(new RowStyle(SizeType.Percent, 10.000001F));
            tablePanelParas.RowStyles.Add(new RowStyle(SizeType.Percent, 10.000001F));
            tablePanelParas.RowStyles.Add(new RowStyle(SizeType.Percent, 10F));
            tablePanelParas.RowStyles.Add(new RowStyle(SizeType.Absolute, 20F));
            tablePanelParas.RowStyles.Add(new RowStyle(SizeType.Absolute, 20F));
            tablePanelParas.RowStyles.Add(new RowStyle(SizeType.Absolute, 20F));
            tablePanelParas.RowStyles.Add(new RowStyle(SizeType.Absolute, 20F));
            tablePanelParas.RowStyles.Add(new RowStyle(SizeType.Absolute, 20F));
            tablePanelParas.Size = new Size(397, 510);
            tablePanelParas.RowStyles.Add(new RowStyle(SizeType.Absolute, 24F));
            tablePanelParas.RowStyles.Add(new RowStyle(SizeType.Absolute, 24F));
            tablePanelParas.RowStyles.Add(new RowStyle(SizeType.Absolute, 24F));
            tablePanelParas.RowStyles.Add(new RowStyle(SizeType.Absolute, 24F));
            tablePanelParas.RowStyles.Add(new RowStyle(SizeType.Absolute, 24F));
            tablePanelParas.Size = new Size(512, 603);
            tablePanelParas.TabIndex = 0;
            // 
            // label1
            // 
            label1.AutoSize = true;
            label1.Location = new Point(2, 0);
            label1.Margin = new Padding(2, 0, 2, 0);
            label1.MaximumSize = new Size(0, 28);
            label1.MinimumSize = new Size(0, 28);
            label1.Location = new Point(3, 0);
            label1.MaximumSize = new Size(0, 33);
            label1.MinimumSize = new Size(0, 33);
            label1.Name = "label1";
            label1.Size = new Size(56, 28);
            label1.Size = new Size(69, 33);
            label1.TabIndex = 0;
            label1.Text = "卡尺数量";
            label1.TextAlign = ContentAlignment.MiddleCenter;
            // 
            // itxtCaliperCount
            // 
            itxtCaliperCount.Location = new Point(92, 3);
            itxtCaliperCount.Margin = new Padding(2, 3, 2, 3);
            itxtCaliperCount.Location = new Point(119, 4);
            itxtCaliperCount.Margin = new Padding(3, 4, 3, 4);
            itxtCaliperCount.Name = "itxtCaliperCount";
            itxtCaliperCount.Size = new Size(98, 23);
            itxtCaliperCount.Size = new Size(125, 27);
            itxtCaliperCount.TabIndex = 5;
            itxtCaliperCount.Text = "6";
            // 
            // label2
            // 
            label2.AutoSize = true;
            label2.Location = new Point(200, 0);
            label2.Margin = new Padding(2, 0, 2, 0);
            label2.MaximumSize = new Size(0, 28);
            label2.MinimumSize = new Size(0, 28);
            label2.Location = new Point(259, 0);
            label2.MaximumSize = new Size(0, 33);
            label2.MinimumSize = new Size(0, 33);
            label2.Name = "label2";
            label2.Size = new Size(56, 28);
            label2.Size = new Size(69, 33);
            label2.TabIndex = 1;
            label2.Text = "卡尺长度";
            label2.TextAlign = ContentAlignment.MiddleCenter;
            // 
            // dtxtCaliperHeight
            // 
            dtxtCaliperHeight.Location = new Point(290, 3);
            dtxtCaliperHeight.Margin = new Padding(2, 3, 2, 3);
            dtxtCaliperHeight.Location = new Point(375, 4);
            dtxtCaliperHeight.Margin = new Padding(3, 4, 3, 4);
            dtxtCaliperHeight.Name = "dtxtCaliperHeight";
            dtxtCaliperHeight.Size = new Size(98, 23);
            dtxtCaliperHeight.Size = new Size(125, 27);
            dtxtCaliperHeight.TabIndex = 6;
            dtxtCaliperHeight.Text = "30";
            // 
            // label3
            // 
            label3.AutoSize = true;
            label3.Location = new Point(2, 51);
            label3.Margin = new Padding(2, 0, 2, 0);
            label3.MaximumSize = new Size(0, 28);
            label3.MinimumSize = new Size(0, 28);
            label3.Location = new Point(3, 60);
            label3.MaximumSize = new Size(0, 33);
            label3.MinimumSize = new Size(0, 33);
            label3.Name = "label3";
            label3.Size = new Size(56, 28);
            label3.Size = new Size(69, 33);
            label3.TabIndex = 2;
            label3.Text = "卡尺宽度";
            label3.TextAlign = ContentAlignment.MiddleCenter;
            // 
            // dtxtCaliperWidth
            // 
            dtxtCaliperWidth.Location = new Point(92, 54);
            dtxtCaliperWidth.Margin = new Padding(2, 3, 2, 3);
            dtxtCaliperWidth.Location = new Point(119, 64);
            dtxtCaliperWidth.Margin = new Padding(3, 4, 3, 4);
            dtxtCaliperWidth.Name = "dtxtCaliperWidth";
            dtxtCaliperWidth.Size = new Size(98, 23);
            dtxtCaliperWidth.Size = new Size(125, 27);
            dtxtCaliperWidth.TabIndex = 7;
            dtxtCaliperWidth.Text = "10";
            // 
            // label4
            // 
            label4.AutoSize = true;
            label4.Location = new Point(200, 51);
            label4.Margin = new Padding(2, 0, 2, 0);
            label4.MaximumSize = new Size(0, 28);
            label4.MinimumSize = new Size(0, 28);
            label4.Location = new Point(259, 60);
            label4.MaximumSize = new Size(0, 33);
            label4.MinimumSize = new Size(0, 33);
            label4.Name = "label4";
            label4.Size = new Size(80, 28);
            label4.Size = new Size(99, 33);
            label4.TabIndex = 3;
            label4.Text = "过滤一半像素";
            label4.TextAlign = ContentAlignment.MiddleCenter;
            // 
            // itxtSigma
            // 
            itxtSigma.Location = new Point(290, 54);
            itxtSigma.Margin = new Padding(2, 3, 2, 3);
            itxtSigma.Location = new Point(375, 64);
            itxtSigma.Margin = new Padding(3, 4, 3, 4);
            itxtSigma.Name = "itxtSigma";
            itxtSigma.Size = new Size(98, 23);
            itxtSigma.Size = new Size(125, 27);
            itxtSigma.TabIndex = 8;
            itxtSigma.Text = "0";
            // 
            // label10
            // 
            label10.AutoSize = true;
            label10.Location = new Point(2, 102);
            label10.Margin = new Padding(2, 0, 2, 0);
            label10.MaximumSize = new Size(0, 28);
            label10.MinimumSize = new Size(0, 28);
            label10.Location = new Point(3, 120);
            label10.MaximumSize = new Size(0, 33);
            label10.MinimumSize = new Size(0, 33);
            label10.Name = "label10";
            label10.Size = new Size(68, 28);
            label10.Size = new Size(84, 33);
            label10.TabIndex = 9;
            label10.Text = "对比度阈值";
            label10.TextAlign = ContentAlignment.MiddleCenter;
            // 
            // itxtThreshold
            // 
            itxtThreshold.Location = new Point(92, 105);
            itxtThreshold.Margin = new Padding(2, 3, 2, 3);
            itxtThreshold.Location = new Point(119, 124);
            itxtThreshold.Margin = new Padding(3, 4, 3, 4);
            itxtThreshold.Name = "itxtThreshold";
            itxtThreshold.Size = new Size(98, 23);
            itxtThreshold.Size = new Size(125, 27);
            itxtThreshold.TabIndex = 9;
            itxtThreshold.Text = "0";
            // 
            // label11
            // 
            label11.AutoSize = true;
            label11.Location = new Point(200, 102);
            label11.Margin = new Padding(2, 0, 2, 0);
            label11.MaximumSize = new Size(0, 28);
            label11.MinimumSize = new Size(0, 28);
            label11.Location = new Point(259, 120);
            label11.MaximumSize = new Size(0, 33);
            label11.MinimumSize = new Size(0, 33);
            label11.Name = "label11";
            label11.Size = new Size(56, 28);
            label11.Size = new Size(69, 33);
            label11.TabIndex = 10;
            label11.Text = "忽略点数";
            label11.TextAlign = ContentAlignment.MiddleCenter;
            // 
            // itxtIgnoreCount
            // 
            itxtIgnoreCount.Location = new Point(290, 105);
            itxtIgnoreCount.Margin = new Padding(2, 3, 2, 3);
            itxtIgnoreCount.Location = new Point(375, 124);
            itxtIgnoreCount.Margin = new Padding(3, 4, 3, 4);
            itxtIgnoreCount.Name = "itxtIgnoreCount";
            itxtIgnoreCount.Size = new Size(98, 23);
            itxtIgnoreCount.Size = new Size(125, 27);
            itxtIgnoreCount.TabIndex = 9;
            itxtIgnoreCount.Text = "0";
            // 
            // label12
            // 
            label12.AutoSize = true;
            label12.Location = new Point(2, 153);
            label12.Margin = new Padding(2, 0, 2, 0);
            label12.MaximumSize = new Size(0, 28);
            label12.MinimumSize = new Size(0, 28);
            label12.Location = new Point(3, 180);
            label12.MaximumSize = new Size(0, 33);
            label12.MinimumSize = new Size(0, 33);
            label12.Name = "label12";
            label12.Size = new Size(32, 28);
            label12.Size = new Size(39, 33);
            label12.TabIndex = 11;
            label12.Text = "极性";
            label12.TextAlign = ContentAlignment.MiddleCenter;
@@ -296,12 +289,11 @@
            // label13
            // 
            label13.AutoSize = true;
            label13.Location = new Point(200, 153);
            label13.Margin = new Padding(2, 0, 2, 0);
            label13.MaximumSize = new Size(0, 28);
            label13.MinimumSize = new Size(0, 28);
            label13.Location = new Point(259, 180);
            label13.MaximumSize = new Size(0, 33);
            label13.MinimumSize = new Size(0, 33);
            label13.Name = "label13";
            label13.Size = new Size(56, 28);
            label13.Size = new Size(69, 33);
            label13.TabIndex = 12;
            label13.Text = "边缘位置";
            label13.TextAlign = ContentAlignment.MiddleCenter;
@@ -309,34 +301,49 @@
            // cmbTransition
            // 
            cmbTransition.FormattingEnabled = true;
            cmbTransition.Location = new Point(93, 156);
            cmbTransition.Location = new Point(120, 184);
            cmbTransition.Margin = new Padding(4);
            cmbTransition.Name = "cmbTransition";
            cmbTransition.Size = new Size(102, 25);
            cmbTransition.Size = new Size(130, 28);
            cmbTransition.TabIndex = 13;
            // 
            // cmbSelect
            // 
            cmbSelect.FormattingEnabled = true;
            cmbSelect.Location = new Point(291, 156);
            cmbSelect.Location = new Point(376, 184);
            cmbSelect.Margin = new Padding(4);
            cmbSelect.Name = "cmbSelect";
            cmbSelect.Size = new Size(103, 25);
            cmbSelect.Size = new Size(131, 28);
            cmbSelect.TabIndex = 14;
            //
            // btnShowROI
            //
            btnShowROI.Dock = DockStyle.Fill;
            btnShowROI.Location = new Point(4, 244);
            btnShowROI.Margin = new Padding(4);
            btnShowROI.Name = "btnShowROI";
            btnShowROI.Size = new Size(108, 52);
            btnShowROI.TabIndex = 15;
            btnShowROI.Text = "显示找线区域";
            btnShowROI.UseVisualStyleBackColor = true;
            btnShowROI.Click += btnShowROI_Click;
            // 
            // pnlInputImage
            // 
            pnlInputImage.Dock = DockStyle.Fill;
            pnlInputImage.Location = new Point(3, 3);
            pnlInputImage.Margin = new Padding(4);
            pnlInputImage.Location = new Point(4, 4);
            pnlInputImage.Margin = new Padding(5);
            pnlInputImage.Name = "pnlInputImage";
            pnlInputImage.Size = new Size(607, 510);
            pnlInputImage.Size = new Size(782, 603);
            pnlInputImage.TabIndex = 44;
            // 
            // TopToolStrip
            // 
            TopToolStrip.ImageScalingSize = new Size(20, 20);
            TopToolStrip.Items.AddRange(new ToolStripItem[] { btnRun, btnLoadImage, btnSaveParas, btnLoadParas });
            TopToolStrip.Location = new Point(0, 0);
            TopToolStrip.Name = "TopToolStrip";
            TopToolStrip.Size = new Size(1044, 25);
            TopToolStrip.Size = new Size(1342, 27);
            TopToolStrip.TabIndex = 45;
            TopToolStrip.Text = "toolStrip1";
            // 
@@ -345,7 +352,7 @@
            btnRun.BackgroundImageLayout = ImageLayout.Zoom;
            btnRun.ImageTransparentColor = Color.Magenta;
            btnRun.Name = "btnRun";
            btnRun.Size = new Size(36, 22);
            btnRun.Size = new Size(43, 24);
            btnRun.Text = "运行";
            btnRun.Click += btnRun_Click;
            // 
@@ -353,7 +360,7 @@
            // 
            btnLoadImage.ImageTransparentColor = Color.Magenta;
            btnLoadImage.Name = "btnLoadImage";
            btnLoadImage.Size = new Size(36, 22);
            btnLoadImage.Size = new Size(43, 24);
            btnLoadImage.Text = "导图";
            btnLoadImage.Click += btnLoadImage_Click;
            // 
@@ -361,7 +368,7 @@
            // 
            btnSaveParas.ImageTransparentColor = Color.Magenta;
            btnSaveParas.Name = "btnSaveParas";
            btnSaveParas.Size = new Size(36, 22);
            btnSaveParas.Size = new Size(43, 24);
            btnSaveParas.Text = "保存";
            btnSaveParas.Click += btnSaveParas_Click;
            // 
@@ -369,35 +376,37 @@
            // 
            btnLoadParas.ImageTransparentColor = Color.Magenta;
            btnLoadParas.Name = "btnLoadParas";
            btnLoadParas.Size = new Size(36, 22);
            btnLoadParas.Size = new Size(43, 24);
            btnLoadParas.Text = "加载";
            btnLoadParas.Click += btnLoadParas_Click;
            // 
            // BtmStatusStrip
            // 
            BtmStatusStrip.ImageScalingSize = new Size(20, 20);
            BtmStatusStrip.Items.AddRange(new ToolStripItem[] { lblResult, lblMsg, lblRunTime });
            BtmStatusStrip.Location = new Point(0, 577);
            BtmStatusStrip.Location = new Point(0, 679);
            BtmStatusStrip.Name = "BtmStatusStrip";
            BtmStatusStrip.Size = new Size(1044, 22);
            BtmStatusStrip.Padding = new Padding(1, 0, 18, 0);
            BtmStatusStrip.Size = new Size(1342, 26);
            BtmStatusStrip.TabIndex = 46;
            BtmStatusStrip.Text = "statusStrip1";
            // 
            // lblResult
            // 
            lblResult.Name = "lblResult";
            lblResult.Size = new Size(34, 17);
            lblResult.Size = new Size(42, 20);
            lblResult.Text = "True";
            // 
            // lblMsg
            // 
            lblMsg.Name = "lblMsg";
            lblMsg.Size = new Size(56, 17);
            lblMsg.Size = new Size(69, 20);
            lblMsg.Text = "运行成功";
            // 
            // lblRunTime
            // 
            lblRunTime.Name = "lblRunTime";
            lblRunTime.Size = new Size(32, 17);
            lblRunTime.Size = new Size(39, 20);
            lblRunTime.Text = "0ms";
            // 
            // MainTableLayoutPanel
@@ -408,11 +417,12 @@
            MainTableLayoutPanel.Controls.Add(parasTabControl, 0, 0);
            MainTableLayoutPanel.Controls.Add(imgTabControl, 1, 0);
            MainTableLayoutPanel.Dock = DockStyle.Fill;
            MainTableLayoutPanel.Location = new Point(0, 25);
            MainTableLayoutPanel.Location = new Point(0, 27);
            MainTableLayoutPanel.Margin = new Padding(4);
            MainTableLayoutPanel.Name = "MainTableLayoutPanel";
            MainTableLayoutPanel.RowCount = 1;
            MainTableLayoutPanel.RowStyles.Add(new RowStyle(SizeType.Percent, 100F));
            MainTableLayoutPanel.Size = new Size(1044, 552);
            MainTableLayoutPanel.Size = new Size(1342, 652);
            MainTableLayoutPanel.TabIndex = 47;
            // 
            // parasTabControl
@@ -421,19 +431,21 @@
            parasTabControl.Controls.Add(tabPage5);
            parasTabControl.Controls.Add(tabPage2);
            parasTabControl.Dock = DockStyle.Fill;
            parasTabControl.Location = new Point(3, 3);
            parasTabControl.Location = new Point(4, 4);
            parasTabControl.Margin = new Padding(4);
            parasTabControl.Name = "parasTabControl";
            parasTabControl.SelectedIndex = 0;
            parasTabControl.Size = new Size(411, 546);
            parasTabControl.Size = new Size(528, 644);
            parasTabControl.TabIndex = 48;
            // 
            // tabPage1
            // 
            tabPage1.Controls.Add(tablePanelParas);
            tabPage1.Location = new Point(4, 26);
            tabPage1.Location = new Point(4, 29);
            tabPage1.Margin = new Padding(4);
            tabPage1.Name = "tabPage1";
            tabPage1.Padding = new Padding(3);
            tabPage1.Size = new Size(403, 516);
            tabPage1.Padding = new Padding(4);
            tabPage1.Size = new Size(520, 611);
            tabPage1.TabIndex = 0;
            tabPage1.Text = "输入参数";
            tabPage1.UseVisualStyleBackColor = true;
@@ -441,9 +453,10 @@
            // tabPage5
            // 
            tabPage5.Controls.Add(tableLayoutPanel2);
            tabPage5.Location = new Point(4, 26);
            tabPage5.Location = new Point(4, 29);
            tabPage5.Margin = new Padding(4);
            tabPage5.Name = "tabPage5";
            tabPage5.Size = new Size(403, 516);
            tabPage5.Size = new Size(520, 611);
            tabPage5.TabIndex = 2;
            tabPage5.Text = "运行参数";
            tabPage5.UseVisualStyleBackColor = true;
@@ -451,36 +464,38 @@
            // tableLayoutPanel2
            // 
            tableLayoutPanel2.ColumnCount = 4;
            tableLayoutPanel2.ColumnStyles.Add(new ColumnStyle(SizeType.Absolute, 60F));
            tableLayoutPanel2.ColumnStyles.Add(new ColumnStyle(SizeType.Absolute, 150F));
            tableLayoutPanel2.ColumnStyles.Add(new ColumnStyle(SizeType.Absolute, 20F));
            tableLayoutPanel2.ColumnStyles.Add(new ColumnStyle(SizeType.Absolute, 77F));
            tableLayoutPanel2.ColumnStyles.Add(new ColumnStyle(SizeType.Absolute, 193F));
            tableLayoutPanel2.ColumnStyles.Add(new ColumnStyle(SizeType.Absolute, 26F));
            tableLayoutPanel2.ColumnStyles.Add(new ColumnStyle(SizeType.Percent, 100F));
            tableLayoutPanel2.Controls.Add(cmbTypeRoi, 1, 0);
            tableLayoutPanel2.Controls.Add(label21, 0, 0);
            tableLayoutPanel2.Controls.Add(label22, 0, 1);
            tableLayoutPanel2.Controls.Add(cmbFixture, 1, 1);
            tableLayoutPanel2.Controls.Add(ckbDrawRoi, 2, 0);
            tableLayoutPanel2.Location = new Point(3, 3);
            tableLayoutPanel2.Location = new Point(4, 4);
            tableLayoutPanel2.Margin = new Padding(4);
            tableLayoutPanel2.Name = "tableLayoutPanel2";
            tableLayoutPanel2.RowCount = 8;
            tableLayoutPanel2.RowStyles.Add(new RowStyle(SizeType.Absolute, 30F));
            tableLayoutPanel2.RowStyles.Add(new RowStyle(SizeType.Absolute, 30F));
            tableLayoutPanel2.RowStyles.Add(new RowStyle(SizeType.Absolute, 30F));
            tableLayoutPanel2.RowStyles.Add(new RowStyle(SizeType.Absolute, 30F));
            tableLayoutPanel2.RowStyles.Add(new RowStyle(SizeType.Absolute, 30F));
            tableLayoutPanel2.RowStyles.Add(new RowStyle(SizeType.Absolute, 30F));
            tableLayoutPanel2.RowStyles.Add(new RowStyle(SizeType.Absolute, 30F));
            tableLayoutPanel2.RowStyles.Add(new RowStyle(SizeType.Absolute, 35F));
            tableLayoutPanel2.RowStyles.Add(new RowStyle(SizeType.Absolute, 35F));
            tableLayoutPanel2.RowStyles.Add(new RowStyle(SizeType.Absolute, 35F));
            tableLayoutPanel2.RowStyles.Add(new RowStyle(SizeType.Absolute, 35F));
            tableLayoutPanel2.RowStyles.Add(new RowStyle(SizeType.Absolute, 35F));
            tableLayoutPanel2.RowStyles.Add(new RowStyle(SizeType.Absolute, 35F));
            tableLayoutPanel2.RowStyles.Add(new RowStyle(SizeType.Absolute, 35F));
            tableLayoutPanel2.RowStyles.Add(new RowStyle(SizeType.Percent, 100F));
            tableLayoutPanel2.Size = new Size(323, 309);
            tableLayoutPanel2.Size = new Size(415, 364);
            tableLayoutPanel2.TabIndex = 4;
            // 
            // cmbTypeRoi
            // 
            cmbTypeRoi.Enabled = false;
            cmbTypeRoi.FormattingEnabled = true;
            cmbTypeRoi.Location = new Point(63, 3);
            cmbTypeRoi.Location = new Point(81, 4);
            cmbTypeRoi.Margin = new Padding(4);
            cmbTypeRoi.Name = "cmbTypeRoi";
            cmbTypeRoi.Size = new Size(121, 25);
            cmbTypeRoi.Size = new Size(154, 28);
            cmbTypeRoi.TabIndex = 1;
            cmbTypeRoi.SelectedIndexChanged += cmbTypeRoi_SelectedIndexChanged;
            // 
@@ -488,9 +503,10 @@
            // 
            label21.AutoSize = true;
            label21.Dock = DockStyle.Fill;
            label21.Location = new Point(3, 0);
            label21.Location = new Point(4, 0);
            label21.Margin = new Padding(4, 0, 4, 0);
            label21.Name = "label21";
            label21.Size = new Size(54, 30);
            label21.Size = new Size(69, 35);
            label21.TabIndex = 3;
            label21.Text = "ROI";
            label21.TextAlign = ContentAlignment.MiddleCenter;
@@ -499,9 +515,10 @@
            // 
            label22.AutoSize = true;
            label22.Dock = DockStyle.Fill;
            label22.Location = new Point(3, 30);
            label22.Location = new Point(4, 35);
            label22.Margin = new Padding(4, 0, 4, 0);
            label22.Name = "label22";
            label22.Size = new Size(54, 30);
            label22.Size = new Size(69, 35);
            label22.TabIndex = 4;
            label22.Text = "Fixture";
            label22.TextAlign = ContentAlignment.MiddleCenter;
@@ -509,9 +526,10 @@
            // cmbFixture
            // 
            cmbFixture.FormattingEnabled = true;
            cmbFixture.Location = new Point(63, 33);
            cmbFixture.Location = new Point(81, 39);
            cmbFixture.Margin = new Padding(4);
            cmbFixture.Name = "cmbFixture";
            cmbFixture.Size = new Size(121, 25);
            cmbFixture.Size = new Size(154, 28);
            cmbFixture.TabIndex = 5;
            cmbFixture.SelectedIndexChanged += cmbFixture_SelectedIndexChanged;
            // 
@@ -519,9 +537,10 @@
            // 
            ckbDrawRoi.AutoSize = true;
            ckbDrawRoi.CheckAlign = ContentAlignment.MiddleCenter;
            ckbDrawRoi.Location = new Point(213, 3);
            ckbDrawRoi.Location = new Point(274, 4);
            ckbDrawRoi.Margin = new Padding(4);
            ckbDrawRoi.Name = "ckbDrawRoi";
            ckbDrawRoi.Size = new Size(14, 14);
            ckbDrawRoi.Size = new Size(18, 17);
            ckbDrawRoi.TabIndex = 2;
            ckbDrawRoi.UseVisualStyleBackColor = true;
            ckbDrawRoi.CheckedChanged += ckbDrawRoi_CheckedChanged;
@@ -529,10 +548,11 @@
            // tabPage2
            // 
            tabPage2.Controls.Add(tableLayoutResults);
            tabPage2.Location = new Point(4, 26);
            tabPage2.Location = new Point(4, 29);
            tabPage2.Margin = new Padding(4);
            tabPage2.Name = "tabPage2";
            tabPage2.Padding = new Padding(3);
            tabPage2.Size = new Size(403, 516);
            tabPage2.Padding = new Padding(4);
            tabPage2.Size = new Size(520, 611);
            tabPage2.TabIndex = 1;
            tabPage2.Text = "输出结果";
            tabPage2.UseVisualStyleBackColor = true;
@@ -540,7 +560,7 @@
            // tableLayoutResults
            // 
            tableLayoutResults.ColumnCount = 2;
            tableLayoutResults.ColumnStyles.Add(new ColumnStyle(SizeType.Absolute, 100F));
            tableLayoutResults.ColumnStyles.Add(new ColumnStyle(SizeType.Absolute, 129F));
            tableLayoutResults.ColumnStyles.Add(new ColumnStyle(SizeType.Percent, 100F));
            tableLayoutResults.Controls.Add(dtxtHeight, 1, 4);
            tableLayoutResults.Controls.Add(label9, 0, 4);
@@ -555,8 +575,8 @@
            tableLayoutResults.Controls.Add(label18, 0, 5);
            tableLayoutResults.Controls.Add(dtxtCount, 1, 5);
            tableLayoutResults.Dock = DockStyle.Fill;
            tableLayoutResults.Location = new Point(3, 3);
            tableLayoutResults.Margin = new Padding(2, 3, 2, 3);
            tableLayoutResults.Location = new Point(4, 4);
            tableLayoutResults.Margin = new Padding(3, 4, 3, 4);
            tableLayoutResults.Name = "tableLayoutResults";
            tableLayoutResults.RowCount = 10;
            tableLayoutResults.RowStyles.Add(new RowStyle(SizeType.Percent, 10F));
@@ -569,29 +589,28 @@
            tableLayoutResults.RowStyles.Add(new RowStyle(SizeType.Percent, 10F));
            tableLayoutResults.RowStyles.Add(new RowStyle(SizeType.Percent, 10F));
            tableLayoutResults.RowStyles.Add(new RowStyle(SizeType.Percent, 10F));
            tableLayoutResults.Size = new Size(397, 510);
            tableLayoutResults.Size = new Size(512, 603);
            tableLayoutResults.TabIndex = 1;
            // 
            // dtxtHeight
            // 
            dtxtHeight.Dock = DockStyle.Fill;
            dtxtHeight.Location = new Point(102, 207);
            dtxtHeight.Margin = new Padding(2, 3, 2, 3);
            dtxtHeight.Location = new Point(132, 244);
            dtxtHeight.Margin = new Padding(3, 4, 3, 4);
            dtxtHeight.Name = "dtxtHeight";
            dtxtHeight.ReadOnly = true;
            dtxtHeight.Size = new Size(293, 23);
            dtxtHeight.Size = new Size(377, 27);
            dtxtHeight.TabIndex = 9;
            // 
            // label9
            // 
            label9.AutoSize = true;
            label9.Dock = DockStyle.Fill;
            label9.Location = new Point(2, 204);
            label9.Margin = new Padding(2, 0, 2, 0);
            label9.MaximumSize = new Size(0, 28);
            label9.MinimumSize = new Size(0, 28);
            label9.Location = new Point(3, 240);
            label9.MaximumSize = new Size(0, 33);
            label9.MinimumSize = new Size(0, 33);
            label9.Name = "label9";
            label9.Size = new Size(96, 28);
            label9.Size = new Size(123, 33);
            label9.TabIndex = 3;
            label9.Text = "高度";
            label9.TextAlign = ContentAlignment.TopCenter;
@@ -600,12 +619,11 @@
            // 
            label5.AutoSize = true;
            label5.Dock = DockStyle.Fill;
            label5.Location = new Point(2, 0);
            label5.Margin = new Padding(2, 0, 2, 0);
            label5.MaximumSize = new Size(0, 28);
            label5.MinimumSize = new Size(0, 28);
            label5.Location = new Point(3, 0);
            label5.MaximumSize = new Size(0, 33);
            label5.MinimumSize = new Size(0, 33);
            label5.Name = "label5";
            label5.Size = new Size(96, 28);
            label5.Size = new Size(123, 33);
            label5.TabIndex = 0;
            label5.Text = "X";
            label5.TextAlign = ContentAlignment.TopCenter;
@@ -614,12 +632,11 @@
            // 
            label6.AutoSize = true;
            label6.Dock = DockStyle.Fill;
            label6.Location = new Point(2, 51);
            label6.Margin = new Padding(2, 0, 2, 0);
            label6.MaximumSize = new Size(0, 28);
            label6.MinimumSize = new Size(0, 28);
            label6.Location = new Point(3, 60);
            label6.MaximumSize = new Size(0, 33);
            label6.MinimumSize = new Size(0, 33);
            label6.Name = "label6";
            label6.Size = new Size(96, 28);
            label6.Size = new Size(123, 33);
            label6.TabIndex = 1;
            label6.Text = "Y";
            label6.TextAlign = ContentAlignment.TopCenter;
@@ -628,12 +645,11 @@
            // 
            label7.AutoSize = true;
            label7.Dock = DockStyle.Fill;
            label7.Location = new Point(2, 102);
            label7.Margin = new Padding(2, 0, 2, 0);
            label7.MaximumSize = new Size(0, 28);
            label7.MinimumSize = new Size(0, 28);
            label7.Location = new Point(3, 120);
            label7.MaximumSize = new Size(0, 33);
            label7.MinimumSize = new Size(0, 33);
            label7.Name = "label7";
            label7.Size = new Size(96, 28);
            label7.Size = new Size(123, 33);
            label7.TabIndex = 2;
            label7.Text = "角度(°)";
            label7.TextAlign = ContentAlignment.TopCenter;
@@ -642,12 +658,11 @@
            // 
            label8.AutoSize = true;
            label8.Dock = DockStyle.Fill;
            label8.Location = new Point(2, 153);
            label8.Margin = new Padding(2, 0, 2, 0);
            label8.MaximumSize = new Size(0, 28);
            label8.MinimumSize = new Size(0, 28);
            label8.Location = new Point(3, 180);
            label8.MaximumSize = new Size(0, 33);
            label8.MinimumSize = new Size(0, 33);
            label8.Name = "label8";
            label8.Size = new Size(96, 28);
            label8.Size = new Size(123, 33);
            label8.TabIndex = 3;
            label8.Text = "宽度";
            label8.TextAlign = ContentAlignment.TopCenter;
@@ -655,50 +670,51 @@
            // dtxtCenterX
            // 
            dtxtCenterX.Dock = DockStyle.Fill;
            dtxtCenterX.Location = new Point(102, 3);
            dtxtCenterX.Margin = new Padding(2, 3, 2, 3);
            dtxtCenterX.Location = new Point(132, 4);
            dtxtCenterX.Margin = new Padding(3, 4, 3, 4);
            dtxtCenterX.Name = "dtxtCenterX";
            dtxtCenterX.ReadOnly = true;
            dtxtCenterX.Size = new Size(293, 23);
            dtxtCenterX.Size = new Size(377, 27);
            dtxtCenterX.TabIndex = 5;
            // 
            // dtxtCenterY
            // 
            dtxtCenterY.Dock = DockStyle.Fill;
            dtxtCenterY.Location = new Point(102, 54);
            dtxtCenterY.Margin = new Padding(2, 3, 2, 3);
            dtxtCenterY.Location = new Point(132, 64);
            dtxtCenterY.Margin = new Padding(3, 4, 3, 4);
            dtxtCenterY.Name = "dtxtCenterY";
            dtxtCenterY.ReadOnly = true;
            dtxtCenterY.Size = new Size(293, 23);
            dtxtCenterY.Size = new Size(377, 27);
            dtxtCenterY.TabIndex = 6;
            // 
            // dtxtAngle
            // 
            dtxtAngle.Dock = DockStyle.Fill;
            dtxtAngle.Location = new Point(102, 105);
            dtxtAngle.Margin = new Padding(2, 3, 2, 3);
            dtxtAngle.Location = new Point(132, 124);
            dtxtAngle.Margin = new Padding(3, 4, 3, 4);
            dtxtAngle.Name = "dtxtAngle";
            dtxtAngle.ReadOnly = true;
            dtxtAngle.Size = new Size(293, 23);
            dtxtAngle.Size = new Size(377, 27);
            dtxtAngle.TabIndex = 7;
            // 
            // dtxtWidth
            // 
            dtxtWidth.Dock = DockStyle.Fill;
            dtxtWidth.Location = new Point(102, 156);
            dtxtWidth.Margin = new Padding(2, 3, 2, 3);
            dtxtWidth.Location = new Point(132, 184);
            dtxtWidth.Margin = new Padding(3, 4, 3, 4);
            dtxtWidth.Name = "dtxtWidth";
            dtxtWidth.ReadOnly = true;
            dtxtWidth.Size = new Size(293, 23);
            dtxtWidth.Size = new Size(377, 27);
            dtxtWidth.TabIndex = 8;
            // 
            // label18
            // 
            label18.AutoSize = true;
            label18.Dock = DockStyle.Fill;
            label18.Location = new Point(3, 255);
            label18.Location = new Point(4, 300);
            label18.Margin = new Padding(4, 0, 4, 0);
            label18.Name = "label18";
            label18.Size = new Size(94, 51);
            label18.Size = new Size(121, 60);
            label18.TabIndex = 10;
            label18.Text = "数量";
            label18.TextAlign = ContentAlignment.TopCenter;
@@ -706,10 +722,11 @@
            // dtxtCount
            // 
            dtxtCount.Dock = DockStyle.Fill;
            dtxtCount.Location = new Point(103, 258);
            dtxtCount.Location = new Point(133, 304);
            dtxtCount.Margin = new Padding(4);
            dtxtCount.Name = "dtxtCount";
            dtxtCount.ReadOnly = true;
            dtxtCount.Size = new Size(291, 23);
            dtxtCount.Size = new Size(375, 27);
            dtxtCount.TabIndex = 11;
            // 
            // imgTabControl
@@ -717,19 +734,21 @@
            imgTabControl.Controls.Add(tabPageInputImage);
            imgTabControl.Controls.Add(tabPageRecordImage);
            imgTabControl.Dock = DockStyle.Fill;
            imgTabControl.Location = new Point(420, 3);
            imgTabControl.Location = new Point(540, 4);
            imgTabControl.Margin = new Padding(4);
            imgTabControl.Name = "imgTabControl";
            imgTabControl.SelectedIndex = 0;
            imgTabControl.Size = new Size(621, 546);
            imgTabControl.Size = new Size(798, 644);
            imgTabControl.TabIndex = 49;
            // 
            // tabPageInputImage
            // 
            tabPageInputImage.Controls.Add(pnlInputImage);
            tabPageInputImage.Location = new Point(4, 26);
            tabPageInputImage.Location = new Point(4, 29);
            tabPageInputImage.Margin = new Padding(4);
            tabPageInputImage.Name = "tabPageInputImage";
            tabPageInputImage.Padding = new Padding(3);
            tabPageInputImage.Size = new Size(613, 516);
            tabPageInputImage.Padding = new Padding(4);
            tabPageInputImage.Size = new Size(790, 611);
            tabPageInputImage.TabIndex = 0;
            tabPageInputImage.Text = "输入图像";
            tabPageInputImage.UseVisualStyleBackColor = true;
@@ -737,10 +756,11 @@
            // tabPageRecordImage
            // 
            tabPageRecordImage.Controls.Add(pnlRecordImage);
            tabPageRecordImage.Location = new Point(4, 26);
            tabPageRecordImage.Location = new Point(4, 29);
            tabPageRecordImage.Margin = new Padding(4);
            tabPageRecordImage.Name = "tabPageRecordImage";
            tabPageRecordImage.Padding = new Padding(3);
            tabPageRecordImage.Size = new Size(613, 516);
            tabPageRecordImage.Padding = new Padding(4);
            tabPageRecordImage.Size = new Size(790, 611);
            tabPageRecordImage.TabIndex = 1;
            tabPageRecordImage.Text = "结果图像";
            tabPageRecordImage.UseVisualStyleBackColor = true;
@@ -748,33 +768,22 @@
            // pnlRecordImage
            // 
            pnlRecordImage.Dock = DockStyle.Fill;
            pnlRecordImage.Location = new Point(3, 3);
            pnlRecordImage.Margin = new Padding(4);
            pnlRecordImage.Location = new Point(4, 4);
            pnlRecordImage.Margin = new Padding(5);
            pnlRecordImage.Name = "pnlRecordImage";
            pnlRecordImage.Size = new Size(607, 510);
            pnlRecordImage.Size = new Size(782, 603);
            pnlRecordImage.TabIndex = 45;
            //
            // btnShowROI
            //
            btnShowROI.Dock = DockStyle.Fill;
            btnShowROI.Location = new Point(3, 207);
            btnShowROI.Name = "btnShowROI";
            btnShowROI.Size = new Size(84, 45);
            btnShowROI.TabIndex = 15;
            btnShowROI.Text = "显示找线区域";
            btnShowROI.UseVisualStyleBackColor = true;
            btnShowROI.Click += btnShowROI_Click;
            // 
            // HFindLineToolEdit
            // 
            AutoScaleDimensions = new SizeF(7F, 17F);
            AutoScaleDimensions = new SizeF(9F, 20F);
            AutoScaleMode = AutoScaleMode.Font;
            Controls.Add(MainTableLayoutPanel);
            Controls.Add(BtmStatusStrip);
            Controls.Add(TopToolStrip);
            Margin = new Padding(2, 3, 2, 3);
            Margin = new Padding(3, 4, 3, 4);
            Name = "HFindLineToolEdit";
            Size = new Size(1044, 599);
            Size = new Size(1342, 705);
            Load += HFindLineToolEdit_Load;
            tablePanelParas.ResumeLayout(false);
            tablePanelParas.PerformLayout();
LB_VisionProcesses/Alogrithms/Halcon/2D/HFindLineTool/HFindLineToolEdit.resx
@@ -1,7 +1,7 @@
<?xml version="1.0" encoding="utf-8"?>
<root>
  <!--
    Microsoft ResX Schema
    Microsoft ResX Schema
    Version 2.0
@@ -48,7 +48,7 @@
    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
@@ -117,10 +117,13 @@
  <resheader name="writer">
    <value>System.Resources.ResXResourceWriter, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
  </resheader>
  <metadata name="TopToolStrip.TrayLocation" type="System.Drawing.Point, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a">
  <metadata name="lblMsgToolTip.TrayLocation" type="System.Drawing.Point, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a">
    <value>17, 17</value>
  </metadata>
  <metadata name="TopToolStrip.TrayLocation" type="System.Drawing.Point, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a">
    <value>183, 17</value>
  </metadata>
  <metadata name="BtmStatusStrip.TrayLocation" type="System.Drawing.Point, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a">
    <value>129, 17</value>
    <value>340, 17</value>
  </metadata>
</root>
LB_VisionProcesses/Alogrithms/Halcon/2D/HFindModelTool/HFindModelTool.cs
@@ -5,6 +5,7 @@
using System;
using System.Collections.Generic;
using System.Diagnostics;
using System.Drawing.Imaging;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
@@ -93,6 +94,27 @@
                        Result = false;
                        return;
                    }
                    if (InputImage is Bitmap)
                    {
                        try
                        {
                            using (HImage hImage = new HImage())
                            {
                                Bitmap bitmap = (Bitmap)InputImage;
                                Rectangle rect = new Rectangle(0, 0, ((Bitmap)bitmap).Width, ((Bitmap)bitmap).Height);
                                BitmapData srcBmpData = ((Bitmap)bitmap).LockBits(rect, ImageLockMode.ReadOnly, PixelFormat.Format32bppRgb);
                                hImage.GenImageInterleaved(srcBmpData.Scan0, "rgbx", ((Bitmap)bitmap).Width, ((Bitmap)bitmap).Height, 0, "byte", ((Bitmap)bitmap).Width, ((Bitmap)bitmap).Height, 0, 0, -1, 0);
                                ((Bitmap)bitmap).UnlockBits(srcBmpData);
                                bitmap.Dispose();
                                bitmap = null;
                                InputImage = null;
                                InputImage = hImage.Clone();
                            }
                        }
                        catch (Exception ex)
                        {
                        }
                    }
                    if (!(InputImage is HObject))
                    {
                        Msg = "输入图片格式不为HObject";
LB_VisionProcesses/Alogrithms/Halcon/2D/HFindMultiModelTool/HFindMultiModelTool.cs
@@ -5,6 +5,7 @@
using System;
using System.Collections.Generic;
using System.Diagnostics;
using System.Drawing.Imaging;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
@@ -88,9 +89,30 @@
                        Result = false;
                        return;
                    }
                    if (InputImage is Bitmap)
                    {
                        try
                        {
                            using (HImage hImage = new HImage())
                            {
                                Bitmap bitmap = (Bitmap)InputImage;
                                Rectangle rect = new Rectangle(0, 0, ((Bitmap)bitmap).Width, ((Bitmap)bitmap).Height);
                                BitmapData srcBmpData = ((Bitmap)bitmap).LockBits(rect, ImageLockMode.ReadOnly, PixelFormat.Format32bppRgb);
                                hImage.GenImageInterleaved(srcBmpData.Scan0, "rgbx", ((Bitmap)bitmap).Width, ((Bitmap)bitmap).Height, 0, "byte", ((Bitmap)bitmap).Width, ((Bitmap)bitmap).Height, 0, 0, -1, 0);
                                ((Bitmap)bitmap).UnlockBits(srcBmpData);
                                bitmap.Dispose();
                                bitmap = null;
                                InputImage = null;
                                InputImage = hImage.Clone();
                            }
                        }
                        catch (Exception ex)
                        {
                        }
                    }
                    if (!(InputImage is HObject))
                    {
                        Msg = "输入图片格式不为Mat";
                        Msg = "输入图片格式不为HObject";
                        Result = false;
                        return;
                    }
LB_VisionProcesses/Alogrithms/Halcon/2D/HImageEnhancementTool/HImageEnhancementTool.cs
¶Ô±ÈÐÂÎļþ
@@ -0,0 +1,223 @@
using HalconDotNet;
using LB_SmartVisionCommon;
using LB_VisionControl;
using System;
using System.Collections.Generic;
using System.Drawing.Imaging;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
using static System.Runtime.InteropServices.JavaScript.JSType;
namespace LB_VisionProcesses.Alogrithms.Halcon
{
    public enum ImageEnhancementType { Emphasize, EquHisto, ScaleMax }
    [Process("Halcon2D图像增强", Category = "Halcon2D工具", Description = "创建图像增强工具")]
    public class HImageEnhancementTool : TAlgorithm
    {
        public HImageEnhancementTool()
        {
            strProcessClass = "LB_VisionProcesses.Alogrithms.Halcon.HImageEnhancementTool";
            strProcessName = "Halcon2D图像增强工具";
            Params.Inputs.Add("滤波器类型", "边缘增强");
            Params.Inputs.Add("掩膜宽", 1);
            Params.Inputs.Add("掩膜高", 1);
            Params.Inputs.Add("增强因子", 1.0);
            //emphasize(Image : ImageEmphasize : MaskWidth, MaskHeight, Factor : )
            Params.Inputs.Add("滤波器类型", "直方图均衡化");
            //equ_histo_image(Image : ImageEquHisto : : )
            Params.Inputs.Add("滤波器类型", "比例增强");
            //scale_image_max(Image : ImageScaleMax : : )
            Params.ROI = new HSegment(0, 0, 250, 250);
        }
        List<RecordImageEnhancementData> recordImageEnhancementDatas = new List<RecordImageEnhancementData>();
        /// <summary>
        /// ç®—子逻辑
        /// </summary>
        public override void TAlgorithmMain()
        {
            #region åˆå§‹åŒ–变量
            HObject ho_Regions, ho_LineXld;
            HOperatorSet.GenEmptyObj(out ho_Regions);
            HOperatorSet.GenEmptyObj(out ho_LineXld);
            #endregion
            try
            {
                if (InputImage == null)
                {
                    Msg = "输入图片为空";
                    Result = false;
                    return;
                }
                if (InputImage is Bitmap)
                {
                    try
                    {
                        using (HImage hImage = new HImage())
                        {
                            Bitmap bitmap = (Bitmap)InputImage;
                            Rectangle rect = new Rectangle(0, 0, ((Bitmap)bitmap).Width, ((Bitmap)bitmap).Height);
                            BitmapData srcBmpData = ((Bitmap)bitmap).LockBits(rect, ImageLockMode.ReadOnly, PixelFormat.Format32bppRgb);
                            hImage.GenImageInterleaved(srcBmpData.Scan0, "rgbx", ((Bitmap)bitmap).Width, ((Bitmap)bitmap).Height, 0, "byte", ((Bitmap)bitmap).Width, ((Bitmap)bitmap).Height, 0, 0, -1, 0);
                            ((Bitmap)bitmap).UnlockBits(srcBmpData);
                            bitmap.Dispose();
                            bitmap = null;
                            InputImage = null;
                            InputImage = hImage.Clone();
                        }
                    }
                    catch (Exception ex)
                    {
                    }
                }
                if (!(InputImage is HObject))
                {
                    Msg = "输入图片格式不为HObject";
                    Result = false;
                    return;
                }
                #region è£å‰ªåŒºåŸŸ
                //if (!(Params.ROI is HSegment))
                //{
                //    Msg = "ROI类型错误,必须为HSegment类型";
                //    Result = false;
                //    return;
                //}
                //if (!(InputImage is HObject))
                //{
                //    Msg = "输入图片类型错误,必须为HObject类型";
                //    Result = false;
                //    return;
                //}
                //HObject DomainImage = ((HObject)InputImage)?.CopyObj(1, -1);
                object DomainImage = null;
                if (!ReduceDomainImage(InputImage, ref DomainImage))
                {
                    Msg = "裁剪区域失败";
                    Result = false;
                    return;
                }
                #endregion
                #region ç®—子逻辑
                Record = new ObjectRecord();
                HObject hoDomainImage = DomainImage as HObject;
                HTuple hv_Channels = new HTuple();
                //判断是否为灰度图
                using (HDevDisposeHelper dh = new HDevDisposeHelper())
                {
                    try
                    {
                        HOperatorSet.CountChannels(hoDomainImage, out hv_Channels);
                        if (hv_Channels.TupleInt() != 1)
                            HOperatorSet.Rgb1ToGray(hoDomainImage, out hoDomainImage);
                        //转换后再次检查是否为灰度图
                        HOperatorSet.CountChannels(hoDomainImage, out hv_Channels);
                        if (hv_Channels.TupleInt() != 1)
                        {
                            HOperatorSet.Rgb1ToGray(hoDomainImage, out hoDomainImage);
                            Msg = "输入图片不为灰度图";
                            Result = false;
                            return;
                        }
                    }
                    catch
                    {
                        Msg = "输入图片不为灰度图且转换失败";
                        Result = false;
                        return;
                    }
                }
                int hv_MaskWidth = Convert.ToInt16(Params.Inputs["掩膜宽"]);
                int hv_MaskHight = Convert.ToInt16(Params.Inputs["掩膜高"]);
                double hv_Factor = Convert.ToDouble(Params.Inputs["增强因子"]);
                recordImageEnhancementDatas = ImageEnhancementManager.Instance.GetAllUsers();
                string hv_ImageEnhancementType = "";
                foreach (var recordImageEnhancementData in recordImageEnhancementDatas)
                {
                    switch (recordImageEnhancementData.FilterName)
                    {
                        case ImageEnhancementDataType.边缘增强_ImageEmphasize:
                            hv_ImageEnhancementType = "emphasize";
                            hv_MaskWidth = Convert.ToInt16(recordImageEnhancementData.MaskWidth);
                            hv_MaskHight = Convert.ToInt16(recordImageEnhancementData.MaskHight);
                            hv_Factor = Convert.ToDouble(recordImageEnhancementData.Factor);
                            ImageEnhancement(hoDomainImage, out ho_Regions, hv_ImageEnhancementType, hv_MaskWidth, hv_MaskHight, hv_Factor);
                            break;
                        case ImageEnhancementDataType.直方图均衡化_EquHistoImage:
                            hv_ImageEnhancementType = "equhisto";
                            ImageEnhancement(hoDomainImage, out ho_Regions, hv_ImageEnhancementType, hv_MaskWidth, hv_MaskHight, hv_Factor);
                            break;
                        case ImageEnhancementDataType.比例增强_ScaleImageMax:
                            hv_ImageEnhancementType = "scaleimageMax";
                            ImageEnhancement(hoDomainImage, out ho_Regions, hv_ImageEnhancementType, hv_MaskWidth, hv_MaskHight, hv_Factor);
                            break;
                        default:
                            hv_ImageEnhancementType = "scaleImageMax";
                            ImageEnhancement(hoDomainImage, out ho_Regions, hv_ImageEnhancementType, hv_MaskWidth, hv_MaskHight, hv_Factor);
                            break;
                    }
                }
                #endregion
                #region ç”ŸæˆOutputImage给后续处理
                try
                {
                    OutputImage = hoDomainImage;
                }
                catch (Exception ex)
                {
                    Msg = "生成OutputImage失败,原因是:" + ex.ToString();
                    Result = false;
                    return;
                }
                #endregion
                if (Msg == "运行超时")
                {
                    Result = false;
                    return;
                }
                Msg = "运行成功";
                Result = true;
                return;
            }
            catch (Exception ex)
            {
                Msg = "运行失败,原因是:" + ex.ToString().TrimEnd();
                OutputImage = null;
                Result = false;
                return;
            }
            finally
            {
                if (!Result)
                {
                    Params.Outputs.Add("Segment", new HSegment());
                }
                bCompleted = true;
                #region å†…存释放
                ho_Regions.Dispose();
                #endregion
            }
        }
    }
}
LB_VisionProcesses/Alogrithms/Halcon/2D/HImageEnhancementTool/HImageEnhancementToolEdit.Designer.cs
¶Ô±ÈÐÂÎļþ
@@ -0,0 +1,594 @@
using LB_VisionProcesses.Alogrithms;
namespace LB_VisionProcesses.Alogrithms.Halcon
{
    partial class HImageEnhancementToolEdit
    {
        /// <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()
        {
            pnlInputImage = new Panel();
            TopToolStrip = new ToolStrip();
            btnRun = new ToolStripButton();
            btnLoadImage = new ToolStripButton();
            btnSaveParas = new ToolStripButton();
            btnLoadParas = new ToolStripButton();
            BtmStatusStrip = new StatusStrip();
            lblResult = new ToolStripStatusLabel();
            lblMsg = new ToolStripStatusLabel();
            lblRunTime = new ToolStripStatusLabel();
            MainTableLayoutPanel = new TableLayoutPanel();
            parasTabControl = new TabControl();
            tabPage1 = new TabPage();
            tableLayoutPanel1 = new TableLayoutPanel();
            dataGridViewIE = new DataGridView();
            tableLayoutPanel4 = new TableLayoutPanel();
            tableLayoutPanel3 = new TableLayoutPanel();
            cmbImageEnhancement = new ComboBox();
            btnAdd = new Button();
            labelImageEnhancement = new Label();
            btnDel = new Button();
            tableLayoutPanel5 = new TableLayoutPanel();
            labelMaskWidth = new Label();
            labelMaskHeight = new Label();
            labelFactor = new Label();
            txtMaskWidth = new TextBox();
            txtMaskHeight = new TextBox();
            txtFactor = new TextBox();
            tabPage5 = new TabPage();
            tableLayoutPanel2 = new TableLayoutPanel();
            cmbTypeRoi = new ComboBox();
            label21 = new Label();
            label22 = new Label();
            cmbFixture = new ComboBox();
            ckbDrawRoi = new CheckBox();
            imgTabControl = new TabControl();
            tabPageInputImage = new TabPage();
            tabPageRecordImage = new TabPage();
            pnlRecordImage = new Panel();
            TopToolStrip.SuspendLayout();
            BtmStatusStrip.SuspendLayout();
            MainTableLayoutPanel.SuspendLayout();
            parasTabControl.SuspendLayout();
            tabPage1.SuspendLayout();
            tableLayoutPanel1.SuspendLayout();
            ((System.ComponentModel.ISupportInitialize)dataGridViewIE).BeginInit();
            tableLayoutPanel4.SuspendLayout();
            tableLayoutPanel3.SuspendLayout();
            tableLayoutPanel5.SuspendLayout();
            tabPage5.SuspendLayout();
            tableLayoutPanel2.SuspendLayout();
            imgTabControl.SuspendLayout();
            tabPageInputImage.SuspendLayout();
            tabPageRecordImage.SuspendLayout();
            SuspendLayout();
            //
            // pnlInputImage
            //
            pnlInputImage.Dock = DockStyle.Fill;
            pnlInputImage.Location = new Point(4, 4);
            pnlInputImage.Margin = new Padding(5);
            pnlInputImage.Name = "pnlInputImage";
            pnlInputImage.Size = new Size(768, 603);
            pnlInputImage.TabIndex = 44;
            //
            // TopToolStrip
            //
            TopToolStrip.ImageScalingSize = new Size(20, 20);
            TopToolStrip.Items.AddRange(new ToolStripItem[] { btnRun, btnLoadImage, btnSaveParas, btnLoadParas });
            TopToolStrip.Location = new Point(0, 0);
            TopToolStrip.Name = "TopToolStrip";
            TopToolStrip.Size = new Size(1342, 27);
            TopToolStrip.TabIndex = 45;
            TopToolStrip.Text = "toolStrip1";
            //
            // btnRun
            //
            btnRun.BackgroundImageLayout = ImageLayout.Zoom;
            btnRun.ImageTransparentColor = Color.Magenta;
            btnRun.Name = "btnRun";
            btnRun.Size = new Size(43, 24);
            btnRun.Text = "运行";
            btnRun.Click += btnRun_Click;
            //
            // btnLoadImage
            //
            btnLoadImage.ImageTransparentColor = Color.Magenta;
            btnLoadImage.Name = "btnLoadImage";
            btnLoadImage.Size = new Size(43, 24);
            btnLoadImage.Text = "导图";
            btnLoadImage.Click += btnLoadImage_Click;
            //
            // btnSaveParas
            //
            btnSaveParas.ImageTransparentColor = Color.Magenta;
            btnSaveParas.Name = "btnSaveParas";
            btnSaveParas.Size = new Size(43, 24);
            btnSaveParas.Text = "保存";
            btnSaveParas.Click += btnSaveParas_Click;
            //
            // btnLoadParas
            //
            btnLoadParas.ImageTransparentColor = Color.Magenta;
            btnLoadParas.Name = "btnLoadParas";
            btnLoadParas.Size = new Size(43, 24);
            btnLoadParas.Text = "加载";
            //
            // BtmStatusStrip
            //
            BtmStatusStrip.ImageScalingSize = new Size(20, 20);
            BtmStatusStrip.Items.AddRange(new ToolStripItem[] { lblResult, lblMsg, lblRunTime });
            BtmStatusStrip.Location = new Point(0, 679);
            BtmStatusStrip.Name = "BtmStatusStrip";
            BtmStatusStrip.Padding = new Padding(1, 0, 18, 0);
            BtmStatusStrip.Size = new Size(1342, 26);
            BtmStatusStrip.TabIndex = 46;
            BtmStatusStrip.Text = "statusStrip1";
            //
            // lblResult
            //
            lblResult.Name = "lblResult";
            lblResult.Size = new Size(42, 20);
            lblResult.Text = "True";
            //
            // lblMsg
            //
            lblMsg.Name = "lblMsg";
            lblMsg.Size = new Size(69, 20);
            lblMsg.Text = "运行成功";
            //
            // lblRunTime
            //
            lblRunTime.Name = "lblRunTime";
            lblRunTime.Size = new Size(39, 20);
            lblRunTime.Text = "0ms";
            //
            // MainTableLayoutPanel
            //
            MainTableLayoutPanel.ColumnCount = 2;
            MainTableLayoutPanel.ColumnStyles.Add(new ColumnStyle(SizeType.Percent, 41F));
            MainTableLayoutPanel.ColumnStyles.Add(new ColumnStyle(SizeType.Percent, 59F));
            MainTableLayoutPanel.Controls.Add(parasTabControl, 0, 0);
            MainTableLayoutPanel.Controls.Add(imgTabControl, 1, 0);
            MainTableLayoutPanel.Dock = DockStyle.Fill;
            MainTableLayoutPanel.Location = new Point(0, 27);
            MainTableLayoutPanel.Margin = new Padding(4);
            MainTableLayoutPanel.Name = "MainTableLayoutPanel";
            MainTableLayoutPanel.RowCount = 1;
            MainTableLayoutPanel.RowStyles.Add(new RowStyle(SizeType.Percent, 100F));
            MainTableLayoutPanel.Size = new Size(1342, 652);
            MainTableLayoutPanel.TabIndex = 47;
            //
            // parasTabControl
            //
            parasTabControl.Controls.Add(tabPage1);
            parasTabControl.Controls.Add(tabPage5);
            parasTabControl.Dock = DockStyle.Fill;
            parasTabControl.Location = new Point(4, 4);
            parasTabControl.Margin = new Padding(4);
            parasTabControl.Name = "parasTabControl";
            parasTabControl.SelectedIndex = 0;
            parasTabControl.Size = new Size(542, 644);
            parasTabControl.TabIndex = 48;
            //
            // tabPage1
            //
            tabPage1.Controls.Add(tableLayoutPanel1);
            tabPage1.Location = new Point(4, 29);
            tabPage1.Margin = new Padding(4);
            tabPage1.Name = "tabPage1";
            tabPage1.Padding = new Padding(4);
            tabPage1.Size = new Size(534, 611);
            tabPage1.TabIndex = 0;
            tabPage1.Text = "输入参数";
            tabPage1.UseVisualStyleBackColor = true;
            //
            // tableLayoutPanel1
            //
            tableLayoutPanel1.ColumnCount = 1;
            tableLayoutPanel1.ColumnStyles.Add(new ColumnStyle(SizeType.Percent, 100F));
            tableLayoutPanel1.Controls.Add(dataGridViewIE, 0, 1);
            tableLayoutPanel1.Controls.Add(tableLayoutPanel4, 0, 0);
            tableLayoutPanel1.Dock = DockStyle.Fill;
            tableLayoutPanel1.Location = new Point(4, 4);
            tableLayoutPanel1.Name = "tableLayoutPanel1";
            tableLayoutPanel1.RowCount = 2;
            tableLayoutPanel1.RowStyles.Add(new RowStyle(SizeType.Absolute, 135F));
            tableLayoutPanel1.RowStyles.Add(new RowStyle(SizeType.Percent, 100F));
            tableLayoutPanel1.Size = new Size(526, 603);
            tableLayoutPanel1.TabIndex = 1;
            //
            // dataGridViewIE
            //
            dataGridViewIE.ColumnHeadersHeightSizeMode = DataGridViewColumnHeadersHeightSizeMode.AutoSize;
            dataGridViewIE.Dock = DockStyle.Fill;
            dataGridViewIE.Location = new Point(3, 138);
            dataGridViewIE.Name = "dataGridViewIE";
            dataGridViewIE.RowHeadersWidth = 51;
            dataGridViewIE.Size = new Size(520, 462);
            dataGridViewIE.TabIndex = 2;
            //
            // tableLayoutPanel4
            //
            tableLayoutPanel4.ColumnCount = 1;
            tableLayoutPanel4.ColumnStyles.Add(new ColumnStyle(SizeType.Percent, 100F));
            tableLayoutPanel4.Controls.Add(tableLayoutPanel3, 0, 0);
            tableLayoutPanel4.Controls.Add(tableLayoutPanel5, 0, 1);
            tableLayoutPanel4.Dock = DockStyle.Fill;
            tableLayoutPanel4.Location = new Point(3, 3);
            tableLayoutPanel4.Name = "tableLayoutPanel4";
            tableLayoutPanel4.RowCount = 2;
            tableLayoutPanel4.RowStyles.Add(new RowStyle(SizeType.Absolute, 45F));
            tableLayoutPanel4.RowStyles.Add(new RowStyle(SizeType.Percent, 100F));
            tableLayoutPanel4.Size = new Size(520, 129);
            tableLayoutPanel4.TabIndex = 3;
            //
            // tableLayoutPanel3
            //
            tableLayoutPanel3.ColumnCount = 4;
            tableLayoutPanel3.ColumnStyles.Add(new ColumnStyle(SizeType.Absolute, 85F));
            tableLayoutPanel3.ColumnStyles.Add(new ColumnStyle(SizeType.Absolute, 172F));
            tableLayoutPanel3.ColumnStyles.Add(new ColumnStyle(SizeType.Percent, 50F));
            tableLayoutPanel3.ColumnStyles.Add(new ColumnStyle(SizeType.Percent, 50F));
            tableLayoutPanel3.Controls.Add(cmbImageEnhancement, 1, 0);
            tableLayoutPanel3.Controls.Add(btnAdd, 2, 0);
            tableLayoutPanel3.Controls.Add(labelImageEnhancement, 0, 0);
            tableLayoutPanel3.Controls.Add(btnDel, 3, 0);
            tableLayoutPanel3.Location = new Point(3, 3);
            tableLayoutPanel3.Name = "tableLayoutPanel3";
            tableLayoutPanel3.RowCount = 1;
            tableLayoutPanel3.RowStyles.Add(new RowStyle(SizeType.Percent, 100F));
            tableLayoutPanel3.Size = new Size(514, 38);
            tableLayoutPanel3.TabIndex = 0;
            //
            // cmbImageEnhancement
            //
            cmbImageEnhancement.DropDownStyle = ComboBoxStyle.DropDownList;
            cmbImageEnhancement.FormattingEnabled = true;
            cmbImageEnhancement.ImeMode = ImeMode.Off;
            cmbImageEnhancement.Location = new Point(89, 4);
            cmbImageEnhancement.Margin = new Padding(4);
            cmbImageEnhancement.Name = "cmbImageEnhancement";
            cmbImageEnhancement.Size = new Size(164, 28);
            cmbImageEnhancement.TabIndex = 14;
            cmbImageEnhancement.SelectedIndexChanged += cmbImageEnhancement_SelectedIndexChanged;
            //
            // btnAdd
            //
            btnAdd.Location = new Point(260, 3);
            btnAdd.Name = "btnAdd";
            btnAdd.Size = new Size(122, 30);
            btnAdd.TabIndex = 15;
            btnAdd.Text = "添加";
            btnAdd.UseVisualStyleBackColor = true;
            btnAdd.Click += btnAdd_Click;
            //
            // labelImageEnhancement
            //
            labelImageEnhancement.AutoSize = true;
            labelImageEnhancement.Location = new Point(3, 0);
            labelImageEnhancement.MaximumSize = new Size(0, 33);
            labelImageEnhancement.MinimumSize = new Size(0, 33);
            labelImageEnhancement.Name = "labelImageEnhancement";
            labelImageEnhancement.Size = new Size(69, 33);
            labelImageEnhancement.TabIndex = 1;
            labelImageEnhancement.Text = "滤波类型";
            labelImageEnhancement.TextAlign = ContentAlignment.MiddleCenter;
            //
            // btnDel
            //
            btnDel.Location = new Point(388, 3);
            btnDel.Name = "btnDel";
            btnDel.Size = new Size(123, 32);
            btnDel.TabIndex = 16;
            btnDel.Text = "删除";
            btnDel.UseVisualStyleBackColor = true;
            btnDel.Click += btnDel_Click;
            //
            // tableLayoutPanel5
            //
            tableLayoutPanel5.ColumnCount = 4;
            tableLayoutPanel5.ColumnStyles.Add(new ColumnStyle(SizeType.Absolute, 85F));
            tableLayoutPanel5.ColumnStyles.Add(new ColumnStyle(SizeType.Absolute, 172F));
            tableLayoutPanel5.ColumnStyles.Add(new ColumnStyle(SizeType.Absolute, 85F));
            tableLayoutPanel5.ColumnStyles.Add(new ColumnStyle(SizeType.Absolute, 172F));
            tableLayoutPanel5.Controls.Add(labelMaskWidth, 0, 0);
            tableLayoutPanel5.Controls.Add(labelMaskHeight, 2, 0);
            tableLayoutPanel5.Controls.Add(labelFactor, 0, 1);
            tableLayoutPanel5.Controls.Add(txtMaskWidth, 1, 0);
            tableLayoutPanel5.Controls.Add(txtMaskHeight, 3, 0);
            tableLayoutPanel5.Controls.Add(txtFactor, 1, 1);
            tableLayoutPanel5.Location = new Point(3, 48);
            tableLayoutPanel5.Name = "tableLayoutPanel5";
            tableLayoutPanel5.RowCount = 2;
            tableLayoutPanel5.RowStyles.Add(new RowStyle(SizeType.Percent, 50F));
            tableLayoutPanel5.RowStyles.Add(new RowStyle(SizeType.Percent, 50F));
            tableLayoutPanel5.Size = new Size(514, 74);
            tableLayoutPanel5.TabIndex = 1;
            //
            // labelMaskWidth
            //
            labelMaskWidth.AutoSize = true;
            labelMaskWidth.Location = new Point(3, 0);
            labelMaskWidth.Name = "labelMaskWidth";
            labelMaskWidth.Size = new Size(54, 20);
            labelMaskWidth.TabIndex = 0;
            labelMaskWidth.Text = "掩膜宽";
            //
            // labelMaskHeight
            //
            labelMaskHeight.AutoSize = true;
            labelMaskHeight.Location = new Point(260, 0);
            labelMaskHeight.Name = "labelMaskHeight";
            labelMaskHeight.Size = new Size(54, 20);
            labelMaskHeight.TabIndex = 1;
            labelMaskHeight.Text = "掩膜高";
            //
            // labelFactor
            //
            labelFactor.AutoSize = true;
            labelFactor.Location = new Point(3, 37);
            labelFactor.Name = "labelFactor";
            labelFactor.Size = new Size(69, 20);
            labelFactor.TabIndex = 2;
            labelFactor.Text = "增强因子";
            //
            // txtMaskWidth
            //
            txtMaskWidth.Location = new Point(88, 3);
            txtMaskWidth.Name = "txtMaskWidth";
            txtMaskWidth.Size = new Size(166, 27);
            txtMaskWidth.TabIndex = 3;
            //
            // txtMaskHeight
            //
            txtMaskHeight.Location = new Point(345, 3);
            txtMaskHeight.Name = "txtMaskHeight";
            txtMaskHeight.Size = new Size(166, 27);
            txtMaskHeight.TabIndex = 4;
            //
            // txtFactor
            //
            txtFactor.Location = new Point(88, 40);
            txtFactor.Name = "txtFactor";
            txtFactor.Size = new Size(166, 27);
            txtFactor.TabIndex = 5;
            //
            // tabPage5
            //
            tabPage5.Controls.Add(tableLayoutPanel2);
            tabPage5.Location = new Point(4, 29);
            tabPage5.Margin = new Padding(4);
            tabPage5.Name = "tabPage5";
            tabPage5.Size = new Size(534, 611);
            tabPage5.TabIndex = 2;
            tabPage5.Text = "运行参数";
            tabPage5.UseVisualStyleBackColor = true;
            //
            // tableLayoutPanel2
            //
            tableLayoutPanel2.ColumnCount = 4;
            tableLayoutPanel2.ColumnStyles.Add(new ColumnStyle(SizeType.Absolute, 77F));
            tableLayoutPanel2.ColumnStyles.Add(new ColumnStyle(SizeType.Absolute, 193F));
            tableLayoutPanel2.ColumnStyles.Add(new ColumnStyle(SizeType.Absolute, 26F));
            tableLayoutPanel2.ColumnStyles.Add(new ColumnStyle(SizeType.Percent, 100F));
            tableLayoutPanel2.Controls.Add(cmbTypeRoi, 1, 0);
            tableLayoutPanel2.Controls.Add(label21, 0, 0);
            tableLayoutPanel2.Controls.Add(label22, 0, 1);
            tableLayoutPanel2.Controls.Add(cmbFixture, 1, 1);
            tableLayoutPanel2.Controls.Add(ckbDrawRoi, 2, 0);
            tableLayoutPanel2.Location = new Point(4, 4);
            tableLayoutPanel2.Margin = new Padding(4);
            tableLayoutPanel2.Name = "tableLayoutPanel2";
            tableLayoutPanel2.RowCount = 8;
            tableLayoutPanel2.RowStyles.Add(new RowStyle(SizeType.Absolute, 35F));
            tableLayoutPanel2.RowStyles.Add(new RowStyle(SizeType.Absolute, 35F));
            tableLayoutPanel2.RowStyles.Add(new RowStyle(SizeType.Absolute, 35F));
            tableLayoutPanel2.RowStyles.Add(new RowStyle(SizeType.Absolute, 35F));
            tableLayoutPanel2.RowStyles.Add(new RowStyle(SizeType.Absolute, 35F));
            tableLayoutPanel2.RowStyles.Add(new RowStyle(SizeType.Absolute, 35F));
            tableLayoutPanel2.RowStyles.Add(new RowStyle(SizeType.Absolute, 35F));
            tableLayoutPanel2.RowStyles.Add(new RowStyle(SizeType.Percent, 100F));
            tableLayoutPanel2.Size = new Size(415, 364);
            tableLayoutPanel2.TabIndex = 4;
            //
            // cmbTypeRoi
            //
            cmbTypeRoi.FormattingEnabled = true;
            cmbTypeRoi.Location = new Point(81, 4);
            cmbTypeRoi.Margin = new Padding(4);
            cmbTypeRoi.Name = "cmbTypeRoi";
            cmbTypeRoi.Size = new Size(154, 28);
            cmbTypeRoi.TabIndex = 1;
            cmbTypeRoi.SelectedIndexChanged += cmbTypeRoi_SelectedIndexChanged;
            //
            // label21
            //
            label21.AutoSize = true;
            label21.Dock = DockStyle.Fill;
            label21.Location = new Point(4, 0);
            label21.Margin = new Padding(4, 0, 4, 0);
            label21.Name = "label21";
            label21.Size = new Size(69, 35);
            label21.TabIndex = 3;
            label21.Text = "ROI";
            label21.TextAlign = ContentAlignment.MiddleCenter;
            //
            // label22
            //
            label22.AutoSize = true;
            label22.Dock = DockStyle.Fill;
            label22.Location = new Point(4, 35);
            label22.Margin = new Padding(4, 0, 4, 0);
            label22.Name = "label22";
            label22.Size = new Size(69, 35);
            label22.TabIndex = 4;
            label22.Text = "Fixture";
            label22.TextAlign = ContentAlignment.MiddleCenter;
            //
            // cmbFixture
            //
            cmbFixture.FormattingEnabled = true;
            cmbFixture.Location = new Point(81, 39);
            cmbFixture.Margin = new Padding(4);
            cmbFixture.Name = "cmbFixture";
            cmbFixture.Size = new Size(154, 28);
            cmbFixture.TabIndex = 5;
            //
            // ckbDrawRoi
            //
            ckbDrawRoi.AutoSize = true;
            ckbDrawRoi.CheckAlign = ContentAlignment.MiddleCenter;
            ckbDrawRoi.Location = new Point(274, 4);
            ckbDrawRoi.Margin = new Padding(4);
            ckbDrawRoi.Name = "ckbDrawRoi";
            ckbDrawRoi.Size = new Size(18, 17);
            ckbDrawRoi.TabIndex = 2;
            ckbDrawRoi.UseVisualStyleBackColor = true;
            ckbDrawRoi.CheckedChanged += ckbDrawRoi_CheckedChanged;
            //
            // imgTabControl
            //
            imgTabControl.Controls.Add(tabPageInputImage);
            imgTabControl.Controls.Add(tabPageRecordImage);
            imgTabControl.Dock = DockStyle.Fill;
            imgTabControl.Location = new Point(554, 4);
            imgTabControl.Margin = new Padding(4);
            imgTabControl.Name = "imgTabControl";
            imgTabControl.SelectedIndex = 0;
            imgTabControl.Size = new Size(784, 644);
            imgTabControl.TabIndex = 49;
            //
            // tabPageInputImage
            //
            tabPageInputImage.Controls.Add(pnlInputImage);
            tabPageInputImage.Location = new Point(4, 29);
            tabPageInputImage.Margin = new Padding(4);
            tabPageInputImage.Name = "tabPageInputImage";
            tabPageInputImage.Padding = new Padding(4);
            tabPageInputImage.Size = new Size(776, 611);
            tabPageInputImage.TabIndex = 0;
            tabPageInputImage.Text = "输入图像";
            tabPageInputImage.UseVisualStyleBackColor = true;
            //
            // tabPageRecordImage
            //
            tabPageRecordImage.Controls.Add(pnlRecordImage);
            tabPageRecordImage.Location = new Point(4, 29);
            tabPageRecordImage.Margin = new Padding(4);
            tabPageRecordImage.Name = "tabPageRecordImage";
            tabPageRecordImage.Padding = new Padding(4);
            tabPageRecordImage.Size = new Size(776, 611);
            tabPageRecordImage.TabIndex = 1;
            tabPageRecordImage.Text = "结果图像";
            tabPageRecordImage.UseVisualStyleBackColor = true;
            //
            // pnlRecordImage
            //
            pnlRecordImage.Dock = DockStyle.Fill;
            pnlRecordImage.Location = new Point(4, 4);
            pnlRecordImage.Margin = new Padding(5);
            pnlRecordImage.Name = "pnlRecordImage";
            pnlRecordImage.Size = new Size(768, 603);
            pnlRecordImage.TabIndex = 45;
            //
            // HImageEnhancementToolEdit
            //
            AutoScaleDimensions = new SizeF(9F, 20F);
            AutoScaleMode = AutoScaleMode.Font;
            Controls.Add(MainTableLayoutPanel);
            Controls.Add(BtmStatusStrip);
            Controls.Add(TopToolStrip);
            Margin = new Padding(3, 4, 3, 4);
            Name = "HImageEnhancementToolEdit";
            Size = new Size(1342, 705);
            Load += HImageEnhancementToolEdit_Load;
            TopToolStrip.ResumeLayout(false);
            TopToolStrip.PerformLayout();
            BtmStatusStrip.ResumeLayout(false);
            BtmStatusStrip.PerformLayout();
            MainTableLayoutPanel.ResumeLayout(false);
            parasTabControl.ResumeLayout(false);
            tabPage1.ResumeLayout(false);
            tableLayoutPanel1.ResumeLayout(false);
            ((System.ComponentModel.ISupportInitialize)dataGridViewIE).EndInit();
            tableLayoutPanel4.ResumeLayout(false);
            tableLayoutPanel3.ResumeLayout(false);
            tableLayoutPanel3.PerformLayout();
            tableLayoutPanel5.ResumeLayout(false);
            tableLayoutPanel5.PerformLayout();
            tabPage5.ResumeLayout(false);
            tableLayoutPanel2.ResumeLayout(false);
            tableLayoutPanel2.PerformLayout();
            imgTabControl.ResumeLayout(false);
            tabPageInputImage.ResumeLayout(false);
            tabPageRecordImage.ResumeLayout(false);
            ResumeLayout(false);
            PerformLayout();
        }
        #endregion
        private System.Windows.Forms.Panel pnlInputImage;
        private ToolStrip TopToolStrip;
        private ToolStripButton btnRun;
        private StatusStrip BtmStatusStrip;
        private ToolStripStatusLabel lblResult;
        private ToolStripStatusLabel lblMsg;
        private TableLayoutPanel MainTableLayoutPanel;
        private ToolStripButton btnLoadImage;
        private TabControl parasTabControl;
        private TabPage tabPage1;
        private TabPage tabPage5;
        private TabControl imgTabControl;
        private TabPage tabPageInputImage;
        private TabPage tabPageRecordImage;
        private ToolStripButton btnSaveParas;
        private ToolStripButton btnLoadParas;
        private Panel pnlRecordImage;
        private ToolStripStatusLabel lblRunTime;
        private TableLayoutPanel tableLayoutPanel2;
        public ComboBox cmbTypeRoi;
        private Label label21;
        private Label label22;
        private ComboBox cmbFixture;
        private CheckBox ckbDrawRoi;
        private TableLayoutPanel tableLayoutPanel1;
        private TableLayoutPanel tableLayoutPanel3;
        private Label labelImageEnhancement;
        private ComboBox cmbImageEnhancement;
        private DataGridView dataGridViewIE;
        private TableLayoutPanel tableLayoutPanel4;
        private Button btnAdd;
        private TableLayoutPanel tableLayoutPanel5;
        private Label labelMaskWidth;
        private Label labelMaskHeight;
        private TextBox txtMaskWidth;
        private TextBox txtMaskHeight;
        private Label labelFactor;
        private TextBox txtFactor;
        private Button btnDel;
    }
}
LB_VisionProcesses/Alogrithms/Halcon/2D/HImageEnhancementTool/HImageEnhancementToolEdit.cs
¶Ô±ÈÐÂÎļþ
@@ -0,0 +1,574 @@
using HalconDotNet;
using LB_SmartVisionCommon;
using LB_VisionControl;
using LB_VisionProcesses.Alogrithms.Halcon;
using Microsoft.VisualBasic.ApplicationServices;
using OpenCvSharp;
using Sunny.UI.Win32;
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 static System.Windows.Forms.VisualStyles.VisualStyleElement;
namespace LB_VisionProcesses.Alogrithms.Halcon
{
    public partial class HImageEnhancementToolEdit : TAlgorithmEdit
    {
        List<RecordImageEnhancementData> recordImageEnhancementDatas = new List<RecordImageEnhancementData>();
        private int rowriginalHeight;
        public HImageEnhancementToolEdit(HImageEnhancementTool subject = null)
        {
            if (subject != null && subject is HImageEnhancementTool)
                Subject = subject;
            else
                Subject = new HImageEnhancementTool();
            //if (!(Subject.Params.ROI is HSegment))
            //    Subject.Params.ROI = new HSegment(0, 0, 250, 250);
            this.Dock = DockStyle.Fill;
            InitializeComponent();
            // ä¿å­˜åŽŸå§‹è¡Œé«˜åº¦
            rowriginalHeight = (int)tableLayoutPanel4.RowStyles[1].Height;
            InitializeComboBox();
            InitializeDataGridView();
            recordImageEnhancementDatas = ImageEnhancementManager.Instance.GetAllUsers();
            this.dataGridViewIE.DataSource = recordImageEnhancementDatas;
            this.dataGridViewIE.AutoGenerateColumns = true;
        }
        private void InitializeComboBox()
        {
            // æ·»åŠ æƒé™é€‰é¡¹
            foreach (var item in Enum.GetValues(typeof(ImageEnhancementDataType)))
            {
                cmbImageEnhancement.Items.Add(item.ToString());
            }
            // è®¾ç½®é»˜è®¤é€‰æ‹©é¡¹
            cmbImageEnhancement.SelectedIndex = 2;
        }
        #region ç®—法选择下拉框
        private void cmbImageEnhancement_SelectedIndexChanged(object sender, EventArgs e)
        {
            System.Windows.Forms.ComboBox cb = sender as System.Windows.Forms.ComboBox;
            if (cb.SelectedIndex == 0)
            {
                ShowRow();
            }
            else if (cb.SelectedIndex == 1)
            {
                HideRow();
            }
            else
            {
                HideRow();
            }
        }
        private void ShowRow()
        {
            // æ˜¾ç¤ºRow2(恢复高度)
            tableLayoutPanel4.RowStyles[1].SizeType = SizeType.Absolute;
            tableLayoutPanel4.RowStyles[1].Height = rowriginalHeight;
            // æ˜¾ç¤ºRow2中的控件
            foreach (Control ctrl in tableLayoutPanel4.Controls)
            {
                int row = tableLayoutPanel4.GetRow(ctrl);
                if (row == 1)
                    ctrl.Visible = true;
            }
        }
        private void HideRow()
        {
            // æ˜¾ç¤ºRow2(恢复高度)
            tableLayoutPanel4.RowStyles[1].SizeType = SizeType.Absolute;
            tableLayoutPanel4.RowStyles[1].Height = 0;
            // æ˜¾ç¤ºRow2中的控件
            foreach (Control ctrl in tableLayoutPanel4.Controls)
            {
                int row = tableLayoutPanel4.GetRow(ctrl);
                if (row == 1)
                    ctrl.Visible = false;
            }
        }
        #endregion
        private void InitializeDataGridView()
        {
            this.dataGridViewIE.DataSource = recordImageEnhancementDatas;
            // è®¾ç½®DataGridView列宽
            dataGridViewIE.AutoSizeColumnsMode = DataGridViewAutoSizeColumnsMode.Fill;
        }
        /// <summary>
        /// æŽ§ä»¶åŠ è½½äº‹ä»¶
        /// </summary>
        /// <param name="sender"></param>
        /// <param name="e"></param>
        private void HImageEnhancementToolEdit_Load(object sender, EventArgs e)
        {
            pnlInputImage.Controls.Add(inputImageHSmartWindowControl);
            inputImageHSmartWindowControl.Dock = DockStyle.Fill;
            pnlRecordImage.Controls.Add(recordImageHSmartWindowControl);
            recordImageHSmartWindowControl.Dock = DockStyle.Fill;
            //遍历可以选择的Roi类型枚举
            foreach (var value in Enum.GetValues(typeof(RoiType)))
                cmbTypeRoi.Items.Add(value.ToString());
            //遍历可以选择的图像增强类型枚举
            //foreach (var value in Enum.GetValues(typeof(ImageEnhancementType)))
            //    cmbImageEnhancement.Items.Add(value.ToString());
            //遍历可以选择的Fixture枚举
            cmbFixture.Items.Add("");
            foreach (string value in IProcess.dicFixtures.Keys)
                cmbFixture.Items.Add(value.ToString());
            ckbDrawRoi.Checked = true;
            cmbTypeRoi.Text = RoiType.Segment.ToString();
            cmbImageEnhancement.Text = ImageEnhancementType.ScaleMax.ToString();
            LoadParas();
            if (Subject.Result)
            {
                lblResult.BackColor = Color.Green;
                lblResult.Text = "True";
            }
            else
            {
                lblResult.BackColor = Color.Red;
                lblResult.Text = "False";
            }
            lblMsg.Text = Msg.Length > 50 ? Msg.Substring(0, 50) : Msg;
            lblMsgToolTip.SetToolTip(BtmStatusStrip, Msg);
            lblRunTime.Text = $"{Subject.RunTime}ms";
        }
        private void ClearInputFields()
        {
            txtMaskWidth.Clear();
            txtMaskHeight.Clear();
            txtFactor.Clear();
            cmbImageEnhancement.SelectedIndex = 0;
        }
        private void btnAdd_Click(object sender, EventArgs e)
        {
            // éªŒè¯è¾“å…¥
            if (cmbImageEnhancement.SelectedIndex == 0)
            {
                if (string.IsNullOrWhiteSpace(txtMaskWidth.Text) || string.IsNullOrWhiteSpace(txtMaskHeight.Text) || string.IsNullOrWhiteSpace(txtFactor.Text))
                {
                    MessageBox.Show("请填写所有必填字段!", "提示",
                        MessageBoxButtons.OK, MessageBoxIcon.Warning);
                    return;
                }
            }
            RecordImageEnhancementData filter = new RecordImageEnhancementData();
            filter.MaskWidth = this.txtMaskWidth.Text;
            filter.MaskHight = this.txtMaskHeight.Text;
            filter.Factor = this.txtFactor.Text;
            filter.FilterName = (ImageEnhancementDataType)this.cmbImageEnhancement.SelectedIndex;
            // æ·»åŠ åˆ° UserManager
            bool success = ImageEnhancementManager.Instance.AddUser(filter);
            if (success)
            {
                recordImageEnhancementDatas.Add(filter);
                //MessageBox.Show("用户添加成功!", "提示",
                //    MessageBoxButtons.OK, MessageBoxIcon.Information);
                // æ¸…空输入框
                ClearInputFields();
            }
            else
            {
                MessageBox.Show("添加用户失败!", "错误",
                    MessageBoxButtons.OK, MessageBoxIcon.Error);
            }
            recordImageEnhancementDatas = ImageEnhancementManager.Instance.GetAllUsers();
            this.dataGridViewIE.DataSource = recordImageEnhancementDatas;
            this.dataGridViewIE.AutoGenerateColumns = true;
        }
        private void btnDel_Click(object sender, EventArgs e)
        {
            // æ£€æŸ¥æ˜¯å¦æœ‰é€‰ä¸­çš„æ»¤æ³¢ç±»åž‹
            if (cmbImageEnhancement.SelectedIndex < 0)
            {
                MessageBox.Show("请选择要删除的滤波类型!", "提示",
                    MessageBoxButtons.OK, MessageBoxIcon.Warning);
                return;
            }
            try
            {
                DataGridViewRow selectedRow = dataGridViewIE.SelectedRows[0];
                string filterToDel = selectedRow.Cells[0].Value?.ToString();
                ImageEnhancementDataType filterToDelete = (ImageEnhancementDataType)cmbImageEnhancement.SelectedIndex;
                // æŸ¥æ‰¾å¯¹åº”的记录
                RecordImageEnhancementData filterToRemove = null;
                // ä»Žæœ¬åœ°åˆ—表中查找
                foreach (var filter in recordImageEnhancementDatas)
                {
                    if (filter.FilterName.ToString() == filterToDel)
                    {
                        filterToRemove = filter;
                        break;
                    }
                }
                if (filterToRemove == null)
                {
                    MessageBox.Show("未找到对应的记录!", "提示",
                        MessageBoxButtons.OK, MessageBoxIcon.Warning);
                    return;
                }
                // ç¡®è®¤åˆ é™¤
                DialogResult result = MessageBox.Show(
                    $"确定要删除 '{filterToDel}' è®°å½•吗?",
                    "确认删除",
                    MessageBoxButtons.YesNo,
                    MessageBoxIcon.Question,
                    MessageBoxDefaultButton.Button2); // é»˜è®¤é€‰æ‹©"否"
                if (result == DialogResult.No)
                    return;
                // ä»Žç®¡ç†å™¨ä¸­åˆ é™¤
                bool success = ImageEnhancementManager.Instance.DeleteUser(filterToRemove);
                if (success)
                {
                    // ä»Žæœ¬åœ°åˆ—表中删除
                    recordImageEnhancementDatas.Remove(filterToRemove);
                    MessageBox.Show("删除成功!", "提示",
                        MessageBoxButtons.OK, MessageBoxIcon.Information);
                }
                else
                {
                    MessageBox.Show("删除失败!", "错误",
                        MessageBoxButtons.OK, MessageBoxIcon.Error);
                }
                recordImageEnhancementDatas = ImageEnhancementManager.Instance.GetAllUsers();
                this.dataGridViewIE.DataSource = recordImageEnhancementDatas;
                this.dataGridViewIE.AutoGenerateColumns = true;
            }
            catch (Exception ex)
            {
                MessageBox.Show("请选择要删除的算子");
            }
        }
        /// <summary>
        /// æ›´æ–°è¿è¡Œå‚æ•°
        /// </summary>
        public override void UpdataInputs()
        {
            //设置运行参数
            double dResult = 0;
            int iResult = 0;
            if (cmbFixture.Text == "")
                Subject.Params.Fixture = new Fixture();
            else if (IProcess.dicFixtures.ContainsKey(cmbFixture.Text))
                Subject.Params.Fixture = IProcess.dicFixtures[cmbFixture.Text];
            Type type = inputImageHSmartWindowControl.oRoi?.GetType();
            switch (type)
            {
                case Type t when t == typeof(HRectangle2):
                    HRectangle2 hRectangle2 = (HRectangle2)inputImageHSmartWindowControl.oRoi;
                    Subject.Params.ROI
                        = new HRectangle2(hRectangle2.X - Subject.Params.Fixture.X, hRectangle2.Y - Subject.Params.Fixture.Y
                        , hRectangle2.Phi - Subject.Params.Fixture.Phi, hRectangle2.Width, hRectangle2.Height);
                    break;
                case Type t when t == typeof(HCircle):
                    HCircle hCircle = (HCircle)inputImageHSmartWindowControl.oRoi;
                    Subject.Params.ROI
                        = new HCircle(hCircle.X - Subject.Params.Fixture.X, hCircle.Y - Subject.Params.Fixture.Y, hCircle.Radius);
                    break;
                case Type t when t == typeof(HSegment):
                    HSegment hSegment = (HSegment)inputImageHSmartWindowControl.oRoi;
                    Subject.Params.ROI
                        = new HSegment(hSegment.StartX - Subject.Params.Fixture.X, hSegment.StartY - Subject.Params.Fixture.Y
                        , hSegment.EndX - Subject.Params.Fixture.X, hSegment.EndY - Subject.Params.Fixture.Y);
                    break;
                default:
                    Subject.Params.ROI = new ROI();
                    break;
            }
        }
        /// <summary>
        /// åŠ è½½è¿è¡Œå‚æ•°
        /// </summary>
        public override void LoadParas()
        {
            this.BeginInvoke(new Action(() =>
            {
                if (Subject.InputImage != null && Subject.InputImage is HObject)
                    inputImageHSmartWindowControl.ShowHoImage((HObject)Subject.InputImage);
                Type type = Subject.Params.ROI?.GetType();
                if (Subject.Params.ROI != null)
                {
                    switch (type)
                    {
                        case Type t when t == typeof(HRectangle2):
                            cmbTypeRoi.Text = RoiType.Rectangle2.ToString();
                            break;
                        case Type t when t == typeof(HCircle):
                            cmbTypeRoi.Text = RoiType.Circle.ToString();
                            break;
                        case Type t when t == typeof(HSegment):
                            cmbTypeRoi.Text = RoiType.Segment.ToString();
                            break;
                        default:
                            cmbTypeRoi.Text = RoiType.None.ToString();
                            break;
                    }
                    if (cmbTypeRoi.Text.ToString() != "None")
                        ckbDrawRoi.Checked = true;
                    else
                        ckbDrawRoi.Checked = false;
                    inputImageHSmartWindowControl.oRoi = Subject.Params.ROI;
                }
                if (Subject.Params.Fixture != null)
                    cmbFixture.Text = Subject.Params.Fixture.strName;
                else
                    cmbFixture.Text = "";
                switch (type)
                {
                    case Type t when t == typeof(HRectangle2):
                        inputImageHSmartWindowControl.oRoi
                             = new HRectangle2(Subject.Params.ROI.X + Subject.Params.Fixture.X, Subject.Params.ROI.Y + Subject.Params.Fixture.Y
                             , Subject.Params.ROI.Phi + Subject.Params.Fixture.Phi, ((HRectangle2)Subject.Params.ROI).Width, ((HRectangle2)Subject.Params.ROI).Height);
                        break;
                    case Type t when t == typeof(HCircle):
                        inputImageHSmartWindowControl.oRoi
                        = new HCircle(Subject.Params.ROI.X + Subject.Params.Fixture.X, Subject.Params.ROI.Y + Subject.Params.Fixture.Y
                        , ((HCircle)Subject.Params.ROI).Radius);
                        break;
                    case Type t when t == typeof(HSegment):
                        inputImageHSmartWindowControl.oRoi
                        = new HSegment(((HSegment)Subject.Params.ROI).StartX + Subject.Params.Fixture.X, ((HSegment)Subject.Params.ROI).StartY + Subject.Params.Fixture.Y
                        , ((HSegment)Subject.Params.ROI).EndX + Subject.Params.Fixture.X, ((HSegment)Subject.Params.ROI).EndY + Subject.Params.Fixture.Y);
                        break;
                    default:
                        inputImageHSmartWindowControl.oRoi = null;
                        break;
                }
            }));
        }
        #region å·¥å…·æ æŒ‰é’®äº‹ä»¶
        /// <summary>
        /// ç‚¹å‡»è¿è¡Œ
        /// </summary>
        /// <param name="sender"></param>
        /// <param name="e"></param>
        public override void btnRun_Click(object sender, EventArgs e)
        {
            if (Subject.InputImage != null)
                InputImage = Subject.InputImage;
            DateTime StartTime = DateTime.Now;
            Run();
            //更新日志与结果
            this.BeginInvoke(new Action(() =>
            {
                if (Subject.Result)
                {
                    lblResult.BackColor = Color.Green;
                    lblResult.Text = "True";
                    recordImageHSmartWindowControl.SetColor("green");
                }
                else
                {
                    lblResult.BackColor = Color.Red;
                    lblResult.Text = "False";
                    recordImageHSmartWindowControl.SetColor("red");
                }
                lblMsg.Text = Msg.Length > 50 ? Msg.Substring(0, 50) : Msg;
                lblMsgToolTip.SetToolTip(BtmStatusStrip, Msg);
                lblRunTime.Text = $"{(DateTime.Now - StartTime).TotalMilliseconds}ms";
                UpdataOutputs();
                imgTabControl.SelectedTab = tabPageRecordImage;
                if (Subject.InputImage != null && Subject.InputImage is HObject)
                {
                    HOperatorSet.GetImageSize((HObject)Subject.InputImage, out HTuple ho_ImageWidth, out HTuple ho_ImageHeight);
                    recordImageHSmartWindowControl.ShowHoImage((HObject)Subject.InputImage);
                }
                //先判断子类再判断父类
                if (Subject.Record != null && Subject.Record is MsgRecord msgRecord)
                {
                    recordImageHSmartWindowControl.DispObj(msgRecord.RecordObject_OK, true);
                    recordImageHSmartWindowControl.DispObj(msgRecord.RecordObject_NG, false);
                    for (int i = 0; i < msgRecord.Msg.Length; i++)
                        recordImageHSmartWindowControl.ShowMsg(msgRecord.Msg[i]
                            , 1 == msgRecord.Result[i] ? true : false, msgRecord.Column[i], msgRecord.Row[i]);
                }
                else if (Subject.Record != null && Subject.Record is ObjectRecord objRecord)
                {
                    recordImageHSmartWindowControl.DispObj(objRecord.RecordObject_OK, true);
                    recordImageHSmartWindowControl.DispObj(objRecord.RecordObject_NG, false);
                }
                GC.Collect();
            }));
        }
        /// <summary>
        /// å·¥å…·æ â€œå¯¼å›¾â€
        /// </summary>
        /// <param name="sender"></param>
        /// <param name="e"></param>
        public override void btnLoadImage_Click(object sender, EventArgs e)
        {
            OpenFileDialog openFileDialog = new OpenFileDialog();
            // è®¾ç½®æ–‡ä»¶å¯¹è¯æ¡†çš„属性
            openFileDialog.Multiselect = false; // ä¸å…è®¸å¤šé€‰
            // è®¾ç½®æ–‡ä»¶è¿‡æ»¤å™¨ï¼Œæ”¯æŒå¤šç§æ–‡ä»¶ç±»åž‹
            openFileDialog.Filter = "Image Files (*.png;*.jpg;*.jpeg;*.bmp)|*.png;*.jpg;*.jpeg;*.bmp|All Files (*.*)|*.*";
            // æ˜¾ç¤ºæ–‡ä»¶å¯¹è¯æ¡†
            DialogResult result = openFileDialog.ShowDialog();
            // å¤„理对话框返回结果
            if (result == DialogResult.OK)
            {
                // èŽ·å–ç”¨æˆ·é€‰æ‹©çš„æ–‡ä»¶å
                string[] selectedFiles = openFileDialog.FileNames;
                if (selectedFiles.Length > 0)
                {
                    HOperatorSet.ReadImage(out HObject ho_Image, selectedFiles[0]);
                    //判断是否为灰度图
                    using (HDevDisposeHelper dh = new HDevDisposeHelper())
                    {
                        HOperatorSet.CountChannels(ho_Image, out HTuple hv_Channels);
                        if (hv_Channels.TupleInt() != 1)
                        {
                            HOperatorSet.Rgb1ToGray(ho_Image, out ho_Image);
                            //更新日志与结果
                            this.BeginInvoke(new Action(() =>
                            {
                                lblMsg.Text = "导入图片非灰度图,自动转换为灰度图";
                            }));
                        }
                        InputImage = ho_Image;
                        imgTabControl.SelectedTab = tabPageInputImage;
                        inputImageHSmartWindowControl.oRoi = inputImageHSmartWindowControl.oRoi;
                    }
                }
            }
        }
        /// <summary>
        /// å·¥å…·æ â€œä¿å­˜â€
        /// </summary>
        /// <param name="sender"></param>
        /// <param name="e"></param>
        public override void btnSaveParas_Click(object sender, EventArgs e) { base.btnSaveParas_Click(sender, e); }
        #endregion
        #region ROI功能
        /// <summary>
        /// æ˜¯å¦å¯ç”¨ROI
        /// </summary>
        /// <param name="sender"></param>
        /// <param name="e"></param>
        public override void ckbDrawRoi_CheckedChanged(object sender, EventArgs e)
        {
            if (ckbDrawRoi.Checked)
            {
                inputImageHSmartWindowControl.bAollowDraw = true;
                imgTabControl.SelectedTab = tabPageInputImage;
            }
            else
            {
                inputImageHSmartWindowControl.bAollowDraw = false;
                Subject.Params.ROI = new ROI();
            }
        }
        /// <summary>
        /// ROI下拉框改变事件
        /// </summary>
        /// <param name="sender"></param>
        /// <param name="e"></param>
        public override void cmbTypeRoi_SelectedIndexChanged(object sender, EventArgs e)
        {
            try
            {
                if (Enum.TryParse(cmbTypeRoi.Text.ToString(), out RoiType type))
                {
                    HTuple hv_imageWidth = 0;
                    HTuple hv_imageHeight = 0;
                    if (InputImage != null && InputImage is HObject)
                        HOperatorSet.GetImageSize((HObject)InputImage, out hv_imageWidth, out hv_imageHeight);
                    switch (type)
                    {
                        case RoiType.Rectangle2:
                            inputImageHSmartWindowControl.oRoi
                                = new HRectangle2(hv_imageWidth.TupleReal() / 2, hv_imageHeight.TupleReal() / 2, 0
                                , hv_imageWidth.TupleReal() / 4, hv_imageHeight.TupleReal() / 4);
                            break;
                        case RoiType.Circle:
                            inputImageHSmartWindowControl.oRoi
                                = new HCircle(hv_imageWidth.TupleReal() / 2, hv_imageHeight.TupleReal() / 2, hv_imageWidth.TupleReal() / 4);
                            break;
                        case RoiType.Segment:
                            inputImageHSmartWindowControl.oRoi
                                = new HSegment(0, 0, hv_imageWidth.TupleReal() / 4, hv_imageHeight.TupleReal() / 4);
                            break;
                        case RoiType.None:
                        default:
                            inputImageHSmartWindowControl.oRoi = null;
                            break;
                    }
                }
            }
            catch { }
        }
        public override void cmbFixture_SelectedIndexChanged(object sender, EventArgs e)
        {
            try
            {
                if (IProcess.dicFixtures.ContainsKey(cmbFixture.Text))
                    Subject.Params.Fixture = IProcess.dicFixtures[cmbFixture.Text];
                else
                    Subject.Params.Fixture = new Fixture();
            }
            catch { }
        }
        #endregion
    }
}
LB_VisionProcesses/Alogrithms/Halcon/2D/HImageEnhancementTool/HImageEnhancementToolEdit.resx
¶Ô±ÈÐÂÎļþ
@@ -0,0 +1,129 @@
<?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="lblMsgToolTip.TrayLocation" type="System.Drawing.Point, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a">
    <value>17, 17</value>
  </metadata>
  <metadata name="TopToolStrip.TrayLocation" type="System.Drawing.Point, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a">
    <value>183, 17</value>
  </metadata>
  <metadata name="BtmStatusStrip.TrayLocation" type="System.Drawing.Point, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a">
    <value>340, 17</value>
  </metadata>
</root>
LB_VisionProcesses/Alogrithms/VisualLargeModel/VisualSegmentationModel.cs
¶Ô±ÈÐÂÎļþ
@@ -0,0 +1,13 @@
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
namespace LB_VisionProcesses.Alogrithms.VisualLargeModel
{
    [Process("视觉分割模型", Category = "深度学习工具", Description = "创建视觉分割模型工具")]
    public class VisualSegmentationModel : TAlgorithm
    {
    }
}
LB_VisionProcesses/BarcodeReaders/BarcodeReaderBase.cs
¶Ô±ÈÐÂÎļþ
@@ -0,0 +1,57 @@
using System;
using System.Collections.Generic;
namespace LB_VisionProcesses.BarcodeReaders
{
    /// <summary>
    /// è¯»ç å™¨æŠ½è±¡åŸºç±»
    /// </summary>
    public abstract class BarcodeReaderBase : IBarcodeReader
    {
        public virtual event EventHandler<BarcodeEventArgs> BarcodeRead;
        public virtual string SN { get; protected set; } = string.Empty;
        public virtual bool IsConnected { get; protected set; } = false;
        public virtual bool IsGrabbing { get; protected set; } = false;
        public abstract BarcodeReaderBrand Brand { get; }
        protected BarcodeReaderBase() { }
        /// <summary>
        /// è§¦å‘读码成功事件
        /// </summary>
        protected virtual void OnBarcodeRead(BarcodeEventArgs e)
        {
            BarcodeRead?.Invoke(this, e);
        }
        public abstract List<string> GetDeviceList();
        public abstract bool Open(string sn);
        public abstract bool Close();
        public abstract bool StartGrabbing();
        public abstract bool StopGrabbing();
        public abstract bool SoftTrigger();
        public abstract bool SetTriggerMode(bool isSoftware);
        public virtual void Dispose()
        {
            try
            {
                if (IsConnected)
                {
                    Close();
                }
            }
            catch { }
        }
    }
}
LB_VisionProcesses/BarcodeReaders/BarcodeReaderFactory.cs
¶Ô±ÈÐÂÎļþ
@@ -0,0 +1,27 @@
using System;
using LB_VisionProcesses.BarcodeReaders.Huayray;
namespace LB_VisionProcesses.BarcodeReaders
{
    /// <summary>
    /// è¯»ç å™¨å·¥åŽ‚ç±»
    /// </summary>
    public static class BarcodeReaderFactory
    {
        /// <summary>
        /// æ ¹æ®å“ç‰Œåˆ›å»ºè¯»ç å™¨å®žä¾‹
        /// </summary>
        /// <param name="brand">读码器品牌</param>
        /// <returns>读码器实例</returns>
        public static IBarcodeReader CreateReader(BarcodeReaderBrand brand)
        {
            switch (brand)
            {
                case BarcodeReaderBrand.Huayray:
                    return new HRBarcodeReader();
                default:
                    throw new NotSupportedException($"不支持的读码器品牌: {brand}");
            }
        }
    }
}
LB_VisionProcesses/BarcodeReaders/BarcodeReaderForm.Designer.cs
¶Ô±ÈÐÂÎļþ
@@ -0,0 +1,255 @@
namespace LB_VisionProcesses.BarcodeReaders
{
    partial class BarcodeReaderForm
    {
        private System.ComponentModel.IContainer components = null;
        protected override void Dispose(bool disposing)
        {
            if (disposing && (components != null))
            {
                components.Dispose();
            }
            base.Dispose(disposing);
        }
        private void InitializeComponent()
        {
            this.themeForm = new ReaLTaiizor.Forms.ThemeForm();
            this.pnlMain = new ReaLTaiizor.Controls.Panel();
            this.controlBox1 = new ReaLTaiizor.Controls.ControlBox();
            this.grpControl = new System.Windows.Forms.GroupBox();
            this.btnRefresh = new System.Windows.Forms.Button();
            this.btnSoftTrigger = new System.Windows.Forms.Button();
            this.btnStop = new System.Windows.Forms.Button();
            this.btnStart = new System.Windows.Forms.Button();
            this.btnClose = new System.Windows.Forms.Button();
            this.btnOpen = new System.Windows.Forms.Button();
            this.cmbSN = new System.Windows.Forms.ComboBox();
            this.lblSN = new System.Windows.Forms.Label();
            this.cmbBrand = new System.Windows.Forms.ComboBox();
            this.lblBrand = new System.Windows.Forms.Label();
            this.grpParams = new System.Windows.Forms.GroupBox();
            this.txtTimeout = new System.Windows.Forms.TextBox();
            this.lblTimeout = new System.Windows.Forms.Label();
            this.radHardTrigger = new System.Windows.Forms.RadioButton();
            this.radSoftTrigger = new System.Windows.Forms.RadioButton();
            this.grpResult = new System.Windows.Forms.GroupBox();
            this.lstBarcodes = new System.Windows.Forms.ListBox();
            this.pnlImage = new System.Windows.Forms.Panel();
            this.picPreview = new System.Windows.Forms.PictureBox();
            this.statusStrip = new System.Windows.Forms.StatusStrip();
            this.lblStatus = new System.Windows.Forms.ToolStripStatusLabel();
            this.themeForm.SuspendLayout();
            this.pnlMain.SuspendLayout();
            this.grpControl.SuspendLayout();
            this.grpParams.SuspendLayout();
            this.grpResult.SuspendLayout();
            this.pnlImage.SuspendLayout();
            ((System.ComponentModel.ISupportInitialize)(this.picPreview)).BeginInit();
            this.statusStrip.SuspendLayout();
            this.SuspendLayout();
            // themeForm
            this.themeForm.BackColor = System.Drawing.Color.FromArgb(((int)(((byte)(32)))), ((int)(((byte)(41)))), ((int)(((byte)(50)))));
            this.themeForm.Controls.Add(this.controlBox1);
            this.themeForm.Controls.Add(this.pnlMain);
            this.themeForm.Dock = System.Windows.Forms.DockStyle.Fill;
            this.themeForm.Font = new System.Drawing.Font("Segoe UI", 9F);
            this.themeForm.ForeColor = System.Drawing.Color.FromArgb(((int)(((byte)(142)))), ((int)(((byte)(142)))), ((int)(((byte)(142)))));
            this.themeForm.Location = new System.Drawing.Point(0, 0);
            this.themeForm.Name = "themeForm";
            this.themeForm.Padding = new System.Windows.Forms.Padding(10, 70, 10, 9);
            this.themeForm.Size = new System.Drawing.Size(820, 600);
            this.themeForm.Text = "读码器配置";
            // controlBox1
            this.controlBox1.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Right)));
            this.controlBox1.BackColor = System.Drawing.Color.FromArgb(((int)(((byte)(32)))), ((int)(((byte)(41)))), ((int)(((byte)(50)))));
            this.controlBox1.Location = new System.Drawing.Point(740, 15);
            this.controlBox1.Name = "controlBox1";
            this.controlBox1.Size = new System.Drawing.Size(77, 19);
            // pnlMain
            this.pnlMain.BackColor = System.Drawing.Color.FromArgb(((int)(((byte)(32)))), ((int)(((byte)(41)))), ((int)(((byte)(50)))));
            this.pnlMain.Controls.Add(this.pnlImage);
            this.pnlMain.Controls.Add(this.grpResult);
            this.pnlMain.Controls.Add(this.grpParams);
            this.pnlMain.Controls.Add(this.grpControl);
            this.pnlMain.Controls.Add(this.statusStrip);
            this.pnlMain.Dock = System.Windows.Forms.DockStyle.Fill;
            this.pnlMain.Location = new System.Drawing.Point(10, 70);
            this.pnlMain.Name = "pnlMain";
            this.pnlMain.Size = new System.Drawing.Size(800, 521);
            // grpControl
            this.grpControl.Controls.Add(this.btnRefresh);
            this.grpControl.Controls.Add(this.btnSoftTrigger);
            this.grpControl.Controls.Add(this.btnStop);
            this.grpControl.Controls.Add(this.btnStart);
            this.grpControl.Controls.Add(this.btnClose);
            this.grpControl.Controls.Add(this.btnOpen);
            this.grpControl.Controls.Add(this.cmbSN);
            this.grpControl.Controls.Add(this.lblSN);
            this.grpControl.Controls.Add(this.cmbBrand);
            this.grpControl.Controls.Add(this.lblBrand);
            this.grpControl.ForeColor = System.Drawing.Color.White;
            this.grpControl.Location = new System.Drawing.Point(15, 15);
            this.grpControl.Name = "grpControl";
            this.grpControl.Size = new System.Drawing.Size(260, 240);
            this.grpControl.Text = "设备控制";
            this.lblBrand.Location = new System.Drawing.Point(10, 25);
            this.lblBrand.Text = "品牌:";
            this.cmbBrand.Location = new System.Drawing.Point(70, 22);
            this.cmbBrand.Size = new System.Drawing.Size(170, 25);
            this.cmbBrand.DropDownStyle = System.Windows.Forms.ComboBoxStyle.DropDownList;
            this.lblSN.Location = new System.Drawing.Point(10, 60);
            this.lblSN.Text = "序列号:";
            this.cmbSN.Location = new System.Drawing.Point(70, 57);
            this.cmbSN.Size = new System.Drawing.Size(130, 25);
            this.btnRefresh.Location = new System.Drawing.Point(205, 56);
            this.btnRefresh.Size = new System.Drawing.Size(35, 25);
            this.btnRefresh.Text = "R";
            this.btnRefresh.Click += new System.EventHandler(this.btnRefresh_Click);
            this.btnOpen.Location = new System.Drawing.Point(13, 100);
            this.btnOpen.Size = new System.Drawing.Size(110, 35);
            this.btnOpen.Text = "打开设备";
            this.btnOpen.Click += new System.EventHandler(this.btnOpen_Click);
            this.btnClose.Location = new System.Drawing.Point(130, 100);
            this.btnClose.Size = new System.Drawing.Size(110, 35);
            this.btnClose.Text = "关闭设备";
            this.btnClose.Click += new System.EventHandler(this.btnClose_Click);
            this.btnStart.Location = new System.Drawing.Point(13, 145);
            this.btnStart.Size = new System.Drawing.Size(110, 35);
            this.btnStart.Text = "开始采集";
            this.btnStart.Click += new System.EventHandler(this.btnStart_Click);
            this.btnStop.Location = new System.Drawing.Point(130, 145);
            this.btnStop.Size = new System.Drawing.Size(110, 35);
            this.btnStop.Text = "停止采集";
            this.btnStop.Click += new System.EventHandler(this.btnStop_Click);
            this.btnSoftTrigger.Location = new System.Drawing.Point(13, 190);
            this.btnSoftTrigger.Size = new System.Drawing.Size(227, 35);
            this.btnSoftTrigger.Text = "软触发一次";
            this.btnSoftTrigger.Click += new System.EventHandler(this.btnSoftTrigger_Click);
            // grpParams
            this.grpParams.Controls.Add(this.txtTimeout);
            this.grpParams.Controls.Add(this.lblTimeout);
            this.grpParams.Controls.Add(this.radHardTrigger);
            this.grpParams.Controls.Add(this.radSoftTrigger);
            this.grpParams.ForeColor = System.Drawing.Color.White;
            this.grpParams.Location = new System.Drawing.Point(15, 260);
            this.grpParams.Name = "grpParams";
            this.grpParams.Size = new System.Drawing.Size(260, 110);
            this.grpParams.Text = "参数设置";
            this.radSoftTrigger.Location = new System.Drawing.Point(15, 25);
            this.radSoftTrigger.Text = "软触发";
            this.radSoftTrigger.Checked = true;
            this.radSoftTrigger.CheckedChanged += new System.EventHandler(this.radTrigger_CheckedChanged);
            this.radHardTrigger.Location = new System.Drawing.Point(130, 25);
            this.radHardTrigger.Text = "自动/硬触发";
            this.lblTimeout.Location = new System.Drawing.Point(15, 65);
            this.lblTimeout.Text = "超时(ms):";
            this.txtTimeout.Location = new System.Drawing.Point(100, 62);
            this.txtTimeout.Size = new System.Drawing.Size(140, 25);
            this.txtTimeout.Text = "2000";
            // grpResult
            this.grpResult.Controls.Add(this.lstBarcodes);
            this.grpResult.ForeColor = System.Drawing.Color.White;
            this.grpResult.Location = new System.Drawing.Point(15, 380);
            this.grpResult.Name = "grpResult";
            this.grpResult.Size = new System.Drawing.Size(260, 115);
            this.grpResult.Text = "读取结果";
            this.lstBarcodes.BackColor = System.Drawing.Color.FromArgb(((int)(((byte)(42)))), ((int)(((byte)(51)))), ((int)(((byte)(60)))));
            this.lstBarcodes.ForeColor = System.Drawing.Color.White;
            this.lstBarcodes.Dock = System.Windows.Forms.DockStyle.Fill;
            this.lstBarcodes.Location = new System.Drawing.Point(3, 19);
            this.lstBarcodes.Name = "lstBarcodes";
            this.lstBarcodes.Size = new System.Drawing.Size(254, 93);
            // pnlImage
            this.pnlImage.BorderStyle = System.Windows.Forms.BorderStyle.FixedSingle;
            this.pnlImage.Controls.Add(this.picPreview);
            this.pnlImage.Location = new System.Drawing.Point(285, 23);
            this.pnlImage.Name = "pnlImage";
            this.pnlImage.Size = new System.Drawing.Size(500, 472);
            this.picPreview.Dock = System.Windows.Forms.DockStyle.Fill;
            this.picPreview.SizeMode = System.Windows.Forms.PictureBoxSizeMode.Zoom;
            // statusStrip
            this.statusStrip.BackColor = System.Drawing.Color.FromArgb(((int)(((byte)(32)))), ((int)(((byte)(41)))), ((int)(((byte)(50)))));
            this.statusStrip.Items.AddRange(new System.Windows.Forms.ToolStripItem[] { this.lblStatus });
            this.statusStrip.Location = new System.Drawing.Point(0, 499);
            this.statusStrip.Size = new System.Drawing.Size(800, 22);
            this.lblStatus.ForeColor = System.Drawing.Color.White;
            this.lblStatus.Text = "准备就绪";
            // BarcodeReaderForm
            this.AutoScaleDimensions = new System.Drawing.SizeF(7F, 17F);
            this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font;
            this.ClientSize = new System.Drawing.Size(820, 600);
            this.Controls.Add(this.themeForm);
            this.FormBorderStyle = System.Windows.Forms.FormBorderStyle.None;
            this.Name = "BarcodeReaderForm";
            this.StartPosition = System.Windows.Forms.FormStartPosition.CenterScreen;
            this.Text = "读码器配置";
            this.Load += new System.EventHandler(this.BarcodeReaderForm_Load);
            this.FormClosing += new System.Windows.Forms.FormClosingEventHandler(this.BarcodeReaderForm_FormClosing);
            this.themeForm.ResumeLayout(false);
            this.pnlMain.ResumeLayout(false);
            this.pnlMain.PerformLayout();
            this.grpControl.ResumeLayout(false);
            this.grpParams.ResumeLayout(false);
            this.grpParams.PerformLayout();
            this.grpResult.ResumeLayout(false);
            this.pnlImage.ResumeLayout(false);
            ((System.ComponentModel.ISupportInitialize)(this.picPreview)).EndInit();
            this.statusStrip.ResumeLayout(false);
            this.statusStrip.PerformLayout();
            this.ResumeLayout(false);
        }
        private ReaLTaiizor.Forms.ThemeForm themeForm;
        private ReaLTaiizor.Controls.Panel pnlMain;
        private ReaLTaiizor.Controls.ControlBox controlBox1;
        private System.Windows.Forms.GroupBox grpControl;
        private System.Windows.Forms.Label lblBrand;
        private System.Windows.Forms.ComboBox cmbBrand;
        private System.Windows.Forms.Label lblSN;
        private System.Windows.Forms.ComboBox cmbSN;
        private System.Windows.Forms.Button btnRefresh;
        private System.Windows.Forms.Button btnOpen;
        private System.Windows.Forms.Button btnClose;
        private System.Windows.Forms.Button btnStart;
        private System.Windows.Forms.Button btnStop;
        private System.Windows.Forms.Button btnSoftTrigger;
        private System.Windows.Forms.GroupBox grpParams;
        private System.Windows.Forms.RadioButton radHardTrigger;
        private System.Windows.Forms.RadioButton radSoftTrigger;
        private System.Windows.Forms.Label lblTimeout;
        private System.Windows.Forms.TextBox txtTimeout;
        private System.Windows.Forms.GroupBox grpResult;
        private System.Windows.Forms.ListBox lstBarcodes;
        private System.Windows.Forms.StatusStrip statusStrip;
        private System.Windows.Forms.ToolStripStatusLabel lblStatus;
        private System.Windows.Forms.Panel pnlImage;
        private System.Windows.Forms.PictureBox picPreview;
    }
}
LB_VisionProcesses/BarcodeReaders/BarcodeReaderForm.cs
¶Ô±ÈÐÂÎļþ
@@ -0,0 +1,265 @@
using System;
using System.Collections.Generic;
using System.Drawing;
using System.Linq;
using System.Windows.Forms;
using LB_VisionProcesses.BarcodeReaders;
namespace LB_VisionProcesses.BarcodeReaders
{
    /// <summary>
    /// è¯»ç å™¨é…ç½®ä¸Žæµ‹è¯•窗体
    /// </summary>
    public partial class BarcodeReaderForm : Form
    {
        private IBarcodeReader _reader;
        private string _currentSN;
        private LB_VisionProcesses.Processes.BarcodeReaderProcess _process;
        private string _processPath;
        public BarcodeReaderForm()
        {
            InitializeComponent();
        }
        public BarcodeReaderForm(LB_VisionProcesses.Processes.BarcodeReaderProcess process, string processPath)
        {
            InitializeComponent();
            _process = process;
            _processPath = processPath;
            // åŠ è½½æµç¨‹å‚æ•°åˆ° UI
            if (_process.Params.Inputs.ContainsKey("设备品牌"))
                cmbBrand.Text = _process.Params.Inputs["设备品牌"].ToString();
            if (_process.Params.Inputs.ContainsKey("设备SN"))
                cmbSN.Text = _process.Params.Inputs["设备SN"].ToString();
            if (_process.Params.Inputs.ContainsKey("触发模式"))
                radSoftTrigger.Checked = _process.Params.Inputs["触发模式"].ToString() == "软触发";
            if (_process.Params.Inputs.ContainsKey("超时时间"))
                txtTimeout.Text = _process.Params.Inputs["超时时间"].ToString();
        }
        private void BarcodeReaderForm_Load(object sender, EventArgs e)
        {
            // åˆå§‹åŒ–品牌列表
            cmbBrand.Items.Clear();
            foreach (var brand in Enum.GetValues(typeof(BarcodeReaderBrand)))
            {
                if ((BarcodeReaderBrand)brand != BarcodeReaderBrand.Unsupported)
                {
                    cmbBrand.Items.Add(brand);
                }
            }
            if (cmbBrand.Items.Count > 0)
                cmbBrand.SelectedIndex = 0;
            UpdateUIStatus();
        }
        private void btnRefresh_Click(object sender, EventArgs e)
        {
            try
            {
                if (cmbBrand.SelectedItem == null) return;
                var brand = (BarcodeReaderBrand)cmbBrand.SelectedItem;
                using (var tempReader = BarcodeReaderFactory.CreateReader(brand))
                {
                    var devices = tempReader.GetDeviceList();
                    cmbSN.Items.Clear();
                    if (devices != null && devices.Count > 0)
                    {
                        cmbSN.Items.AddRange(devices.ToArray());
                        cmbSN.SelectedIndex = 0;
                    }
                }
                lblStatus.Text = $"设备列表已刷新,找到 {cmbSN.Items.Count} ä¸ªè®¾å¤‡";
            }
            catch (Exception ex)
            {
                MessageBox.Show($"刷新设备列表失败: {ex.Message}", "错误", MessageBoxButtons.OK, MessageBoxIcon.Error);
            }
        }
        private void btnOpen_Click(object sender, EventArgs e)
        {
            try
            {
                if (cmbSN.SelectedItem == null && string.IsNullOrEmpty(cmbSN.Text))
                {
                    MessageBox.Show("请选择或输入设备序列号");
                    return;
                }
                _currentSN = cmbSN.Text;
                var brand = (BarcodeReaderBrand)cmbBrand.SelectedItem;
                if (_reader != null)
                {
                    _reader.BarcodeRead -= Reader_BarcodeRead;
                    _reader.Dispose();
                }
                _reader = BarcodeReaderFactory.CreateReader(brand);
                _reader.BarcodeRead += Reader_BarcodeRead;
                if (_reader.Open(_currentSN))
                {
                    lblStatus.Text = $"设备 {_currentSN} å·²æ‰“å¼€";
                    UpdateUIStatus();
                }
                else
                {
                    MessageBox.Show("设备打开失败,请检查连接或占用状态");
                }
            }
            catch (Exception ex)
            {
                MessageBox.Show($"打开设备异常: {ex.Message}");
            }
        }
        private void btnClose_Click(object sender, EventArgs e)
        {
            if (_reader != null)
            {
                _reader.Close();
                lblStatus.Text = "设备已关闭";
                UpdateUIStatus();
            }
        }
        private void btnStart_Click(object sender, EventArgs e)
        {
            if (_reader != null && _reader.IsConnected)
            {
                // è®¾ç½®è§¦å‘模式(根据 UI é€‰æ‹©ï¼‰
                _reader.SetTriggerMode(radSoftTrigger.Checked);
                if (_reader.StartGrabbing())
                {
                    lblStatus.Text = "采集已开始";
                    UpdateUIStatus();
                }
            }
        }
        private void btnStop_Click(object sender, EventArgs e)
        {
            if (_reader != null && _reader.IsGrabbing)
            {
                if (_reader.StopGrabbing())
                {
                    lblStatus.Text = "采集已停止";
                    UpdateUIStatus();
                }
            }
        }
        private void btnSoftTrigger_Click(object sender, EventArgs e)
        {
            if (_reader != null && _reader.IsGrabbing)
            {
                _reader.SoftTrigger();
                lblStatus.Text = "已执行软触发";
            }
            else
            {
                lblStatus.Text = "请先开始采集再执行触发";
            }
        }
        private void radTrigger_CheckedChanged(object sender, EventArgs e)
        {
            if (_reader != null && _reader.IsConnected)
            {
                _reader.SetTriggerMode(radSoftTrigger.Checked);
                lblStatus.Text = radSoftTrigger.Checked ? "已切换至软触发模式" : "已切换至硬触发/自动模式";
            }
        }
        private void Reader_BarcodeRead(object sender, BarcodeEventArgs e)
        {
            // å¼‚步更新 UI
            if (this.InvokeRequired)
            {
                this.BeginInvoke(new Action<object, BarcodeEventArgs>(Reader_BarcodeRead), sender, e);
                return;
            }
            try
            {
                // æ›´æ–°ç»“果列表
                lstBarcodes.Items.Clear();
                if (e.Barcodes != null && e.Barcodes.Count > 0)
                {
                    foreach (var code in e.Barcodes)
                    {
                        lstBarcodes.Items.Add($"{DateTime.Now:HH:mm:ss} - {code}");
                    }
                }
                else
                {
                    lstBarcodes.Items.Add($"{DateTime.Now:HH:mm:ss} - æœªè¯»åˆ°æ¡ç ");
                }
                // æ›´æ–°é¢„览图像
                if (e.Image != null)
                {
                    // é‡Šæ”¾æ—§å›¾åƒï¼Œé˜²æ­¢å†…存泄漏
                    var oldImg = picPreview.Image;
                    picPreview.Image = new Bitmap(e.Image); // æ‹·è´ä¸€ä»½é˜²æ­¢è¢« SDK å†…部释放
                    oldImg?.Dispose();
                }
            }
            catch (Exception ex)
            {
                // é™é»˜å¤„理 UI æ›´æ–°å¼‚常
                Console.WriteLine($"UI更新异常: {ex.Message}");
            }
        }
        private void UpdateUIStatus()
        {
            bool isConnected = _reader?.IsConnected ?? false;
            bool isGrabbing = _reader?.IsGrabbing ?? false;
            btnOpen.Enabled = !isConnected;
            btnClose.Enabled = isConnected;
            cmbBrand.Enabled = !isConnected;
            cmbSN.Enabled = !isConnected;
            btnRefresh.Enabled = !isConnected;
            btnStart.Enabled = isConnected && !isGrabbing;
            btnStop.Enabled = isGrabbing;
            btnSoftTrigger.Enabled = isGrabbing && radSoftTrigger.Checked;
            grpParams.Enabled = isConnected;
        }
        private void BarcodeReaderForm_FormClosing(object sender, FormClosingEventArgs e)
        {
            // å…³é—­å‰ä¿å­˜å‚数到流程
            if (_process != null)
            {
                _process.Params.Inputs["设备品牌"] = cmbBrand.Text;
                _process.Params.Inputs["设备SN"] = cmbSN.Text;
                _process.Params.Inputs["触发模式"] = radSoftTrigger.Checked ? "软触发" : "硬触发";
                if (int.TryParse(txtTimeout.Text, out int timeout))
                    _process.Params.Inputs["超时时间"] = timeout;
                _process.Save(_processPath);
            }
            if (_reader != null)
            {
                if (_reader.IsGrabbing) _reader.StopGrabbing();
                _reader.Close();
                _reader.BarcodeRead -= Reader_BarcodeRead;
                _reader.Dispose();
                _reader = null;
            }
        }
    }
}
LB_VisionProcesses/BarcodeReaders/BarcodeReaderForm.resx
¶Ô±ÈÐÂÎļþ
@@ -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>
LB_VisionProcesses/BarcodeReaders/Huayray/HRBarcodeReader.cs
¶Ô±ÈÐÂÎļþ
@@ -0,0 +1,216 @@
using System;
using System.Collections.Generic;
using System.Drawing;
using System.Linq;
using System.Runtime.InteropServices;
using System.Text;
using EasyIDSDK_Net;
namespace LB_VisionProcesses.BarcodeReaders.Huayray
{
    /// <summary>
    /// åŽç¿è¯»ç å™¨å®žçŽ°ç±»
    /// </summary>
    public class HRBarcodeReader : BarcodeReaderBase
    {
        private EidCamera _camera;
        private EidCamera.EidFrameCallback _frameCallback;
        private GCHandle _callbackHandle;
        public override BarcodeReaderBrand Brand => BarcodeReaderBrand.Huayray;
        public HRBarcodeReader()
        {
            _camera = new EidCamera();
            _frameCallback = OnFrameReceived;
        }
        /// <summary>
        /// èŽ·å–åœ¨çº¿çš„åŽç¿è¯»ç å™¨åˆ—è¡¨
        /// </summary>
        public override List<string> GetDeviceList()
        {
            List<string> snList = new List<string>();
            try
            {
                EidCamera.EidDeviceList devList = new EidCamera.EidDeviceList();
                int nRet = EidCamera.eidEnumDevices_Net(ref devList, 0);
                if (nRet == EidCamera.eidErrorOK && devList.num > 0)
                {
                    for (int i = 0; i < devList.num; i++)
                    {
                        EidCamera.EidDeviceInfo deviceInfo = (EidCamera.EidDeviceInfo)Marshal.PtrToStructure(
                            devList.infos + Marshal.SizeOf(typeof(EidCamera.EidDeviceInfo)) * i,
                            typeof(EidCamera.EidDeviceInfo));
                        snList.Add(deviceInfo.serialNumber);
                    }
                }
            }
            catch (Exception ex)
            {
                // TODO: Log error
            }
            return snList;
        }
        public override bool Open(string sn)
        {
            if (IsConnected) Close();
            try
            {
                // åˆ›å»ºå¥æŸ„
                int nRet = _camera.eidCreateDevice_Net(sn, EidCamera.EidDeviceDataType.eidDeviceDataTypeSN);
                if (nRet != EidCamera.eidErrorOK) return false;
                // æ‰“开设备
                nRet = _camera.eidOpenDevice_Net();
                if (nRet != EidCamera.eidErrorOK)
                {
                    _camera.eidReleaseHandle_Net();
                    return false;
                }
                // æ³¨å†Œå›žè°ƒ
                nRet = _camera.eidRegisterFrameCallback_Net(_frameCallback, IntPtr.Zero);
                if (nRet != EidCamera.eidErrorOK)
                {
                    _camera.eidCloseDevice_Net();
                    _camera.eidReleaseHandle_Net();
                    return false;
                }
                this.SN = sn;
                this.IsConnected = true;
                return true;
            }
            catch
            {
                return false;
            }
        }
        public override bool Close()
        {
            if (!IsConnected) return true;
            try
            {
                StopGrabbing();
                _camera.eidCloseDevice_Net();
                _camera.eidReleaseHandle_Net();
                this.IsConnected = false;
                this.SN = string.Empty;
                return true;
            }
            catch
            {
                return false;
            }
        }
        public override bool StartGrabbing()
        {
            if (!IsConnected) return false;
            if (IsGrabbing) return true;
            int nRet = _camera.eidStartGrabbing_Net(0);
            if (nRet == EidCamera.eidErrorOK)
            {
                this.IsGrabbing = true;
                return true;
            }
            return false;
        }
        public override bool StopGrabbing()
        {
            if (!IsGrabbing) return true;
            int nRet = _camera.eidStopGrabbing_Net();
            this.IsGrabbing = false;
            return nRet == EidCamera.eidErrorOK;
        }
        public override bool SoftTrigger()
        {
            if (!IsConnected || !IsGrabbing) return false;
            int nRet = _camera.eidExecCommandFeature_Net("TriggerSoftware");
            return nRet == EidCamera.eidErrorOK;
        }
        public override bool SetTriggerMode(bool isSoftware)
        {
            if (!IsConnected) return false;
            int nRet;
            if (isSoftware)
            {
                // è½¯è§¦å‘模式
                nRet = _camera.eidSetEnumFeatureSymbol_Net("TriggerType", "SingleFrame");
                if (nRet != EidCamera.eidErrorOK) return false;
                nRet = _camera.eidSetEnumFeatureSymbol_Net("TriggerSource", "Software");
            }
            else
            {
                // è‡ªç”±è¿è¡Œæˆ–硬触发 (此处默认设为自由运行,可根据需要扩展)
                nRet = _camera.eidSetEnumFeatureSymbol_Net("TriggerType", "FreeRun");
            }
            return nRet == EidCamera.eidErrorOK;
        }
        /// <summary>
        /// SDK帧回调处理
        /// </summary>
        private void OnFrameReceived(ref EidCamera.EidFrameInfo frameInfo, IntPtr userData)
        {
            try
            {
                List<string> barcodes = new List<string>();
                // è§£æžæ¡ç 
                for (int i = 0; i < frameInfo.codeNum; i++)
                {
                    EidCamera.EidCodeInfo codeInfo = (EidCamera.EidCodeInfo)Marshal.PtrToStructure(
                        frameInfo.codeList + Marshal.SizeOf(typeof(EidCamera.EidCodeInfo)) * i,
                        typeof(EidCamera.EidCodeInfo));
                    string data = Marshal.PtrToStringAnsi(codeInfo.data);
                    if (!string.IsNullOrEmpty(data))
                    {
                        barcodes.Add(data);
                    }
                }
                // è½¬æ¢å›¾åƒ (如果需要)
                Bitmap bitmap = null;
                if (frameInfo.imageDataLen > 0 && frameInfo.imageData != IntPtr.Zero)
                {
                    // è¿™é‡Œç®€åŒ–处理,如果是Jpeg则直接从内存加载,如果是Raw则需转换
                    // å®žé™…项目中可根据 frameInfo.format è¿›è¡Œå¤„理
                    if (frameInfo.isJpeg)
                    {
                        byte[] managedArray = new byte[frameInfo.imageDataLen];
                        Marshal.Copy(frameInfo.imageData, managedArray, 0, (int)frameInfo.imageDataLen);
                        using (var ms = new System.IO.MemoryStream(managedArray))
                        {
                            bitmap = new Bitmap(ms);
                        }
                    }
                }
                // è§¦å‘事件
                OnBarcodeRead(new BarcodeEventArgs(this.SN, barcodes, bitmap));
            }
            catch (Exception ex)
            {
                // TODO: Log error
            }
        }
        public override void Dispose()
        {
            Close();
            base.Dispose();
        }
    }
}
LB_VisionProcesses/BarcodeReaders/IBarcodeReader.cs
¶Ô±ÈÐÂÎļþ
@@ -0,0 +1,118 @@
using System;
using System.Collections.Generic;
using System.Drawing;
namespace LB_VisionProcesses.BarcodeReaders
{
    /// <summary>
    /// è¯»ç å™¨å“ç‰Œæžšä¸¾
    /// </summary>
    public enum BarcodeReaderBrand
    {
        Huayray,    // åŽç¿
        Unsupported
    }
    /// <summary>
    /// è¯»ç ç»“果参数类
    /// </summary>
    public class BarcodeEventArgs : EventArgs
    {
        /// <summary>
        /// è®¾å¤‡åºåˆ—号
        /// </summary>
        public string SN { get; set; }
        /// <summary>
        /// è¯»ç ç»“果内容
        /// </summary>
        public List<string> Barcodes { get; set; } = new List<string>();
        /// <summary>
        /// å…³è”图像 (可选)
        /// </summary>
        public Bitmap Image { get; set; }
        /// <summary>
        /// æ˜¯å¦è¯»å–成功
        /// </summary>
        public bool IsSuccess => Barcodes.Count > 0;
        public BarcodeEventArgs(string sn, List<string> barcodes, Bitmap image = null)
        {
            SN = sn;
            Barcodes = barcodes;
            Image = image;
        }
    }
    /// <summary>
    /// è¯»ç å™¨æŠ½è±¡æŽ¥å£
    /// </summary>
    public interface IBarcodeReader : IDisposable
    {
        /// <summary>
        /// è¯»ç ç»“果回调事件
        /// </summary>
        event EventHandler<BarcodeEventArgs> BarcodeRead;
        /// <summary>
        /// èŽ·å–è®¾å¤‡åˆ—è¡¨æžšä¸¾
        /// </summary>
        /// <returns>SN列表</returns>
        List<string> GetDeviceList();
        /// <summary>
        /// åˆå§‹åŒ–并打开读码器
        /// </summary>
        /// <param name="sn">序列号</param>
        /// <returns>是否成功</returns>
        bool Open(string sn);
        /// <summary>
        /// å…³é—­è¯»ç å™¨
        /// </summary>
        /// <returns>是否成功</returns>
        bool Close();
        /// <summary>
        /// å¼€å§‹é‡‡é›†/监听
        /// </summary>
        /// <returns>是否成功</returns>
        bool StartGrabbing();
        /// <summary>
        /// åœæ­¢é‡‡é›†/监听
        /// </summary>
        /// <returns>是否成功</returns>
        bool StopGrabbing();
        /// <summary>
        /// æ‰§è¡Œè½¯è§¦å‘一次
        /// </summary>
        /// <returns>是否成功</returns>
        bool SoftTrigger();
        /// <summary>
        /// è®¾ç½®è§¦å‘模式
        /// </summary>
        /// <param name="isSoftware">true为软触发, false为硬触发或自动监听</param>
        /// <returns>是否成功</returns>
        bool SetTriggerMode(bool isSoftware);
        /// <summary>
        /// è®¾å¤‡æ˜¯å¦åœ¨çº¿
        /// </summary>
        bool IsConnected { get; }
        /// <summary>
        /// è®¾å¤‡æ˜¯å¦æ­£åœ¨é‡‡é›†
        /// </summary>
        bool IsGrabbing { get; }
        /// <summary>
        /// è®¾å¤‡å“ç‰Œ
        /// </summary>
        BarcodeReaderBrand Brand { get; }
    }
}
LB_VisionProcesses/Cameras/HRCameras/HRCamera.cs
@@ -1,5 +1,6 @@
using HalconDotNet;
using LB_SmartVisionCommon;
using LB_VisionProcesses.Cameras.LBCameras;
using MVSDK_Net;
using System;
using System.Collections.Generic;
@@ -28,6 +29,8 @@
        private Thread _callbackThread; // å›žè°ƒå¤„理线程
        private List<IMVDefine.IMV_Frame> _frameList; // å›¾åƒç¼“存列表
        private readonly object _frameLock = new object(); // å¸§ç¼“存锁
        // æ–°å¢žï¼šCollectedImages操作锁,保证线程安全
        private readonly object _collectedImagesLock = new object();
        private IMVDefine.IMV_EPixelType type = IMVDefine.IMV_EPixelType.gvspPixelMono8;
        private IMVDefine.IMV_PixelConvertParam stPixelConvertParam = new IMVDefine.IMV_PixelConvertParam();
@@ -217,30 +220,135 @@
            }
            try
            {
                // 1. å°†å¸§è½¬æ¢ä¸ºBitmap
                Bitmap bitmap = ConvertFrameToBitmap(frame);
                // é‡Šæ”¾å¸§æ•°æ®
                // release frame
                // é‡Šæ”¾åŽŸå§‹å¸§æ•°æ®ï¼ˆSDK层面释放)
                _camera.IMV_ReleaseFrame(ref frame);
                Task.Factory.StartNew(() =>
                // 2. ç©ºå€¼æ ¡éªŒï¼šè½¬æ¢å¤±è´¥åˆ™ç›´æŽ¥è¿”回
                if (bitmap == null)
                {
                    CallBackImg = (Bitmap)bitmap.Clone();
                    if (CallBackImg == null)
                    AsyncLogHelper.Warn(SN + "帧转换为Bitmap失败,跳过处理");
                    return;
                }
                // 3. çº¿ç¨‹å®‰å…¨åœ°å°†Bitmap添加到CollectedImages字典
                lock (_collectedImagesLock)
                {
                    // ç¡®ä¿å½“前相机SN对应的列表存在
                    if (!CollectedImages.ContainsKey(SN))
                    {
                        return;
                        CollectedImages[SN] = new List<Bitmap>();
                    }
                    if (GetTriggerMode(out TriggerMode mode, out TriggerSource source))
                    {
                        if (mode == TriggerMode.On && source != TriggerSource.Software)
                            TriggerRunMessageReceived?.Invoke(SN, source.ToString());  // è§¦å‘运行事件
                    }
                    bitmap.Dispose();
                });
                    CollectedImages[SN].Add(bitmap);
                    AsyncLogHelper.Info(SN + $"图像已加入缓存,当前缓存数量:{CollectedImages[SN].Count}");
                }
                // 4. å¤„理CollectedImages中的图像:遍历消费列表第一个元素直到为空
                ProcessCollectedImages();
                //Task.Factory.StartNew(() =>
                //{
                //    CallBackImg = (Bitmap)bitmap.Clone();
                //    if (CallBackImg == null)
                //    {
                //        return;
                //    }
                //    if (GetTriggerMode(out TriggerMode mode, out TriggerSource source))
                //    {
                //        if (mode == TriggerMode.On && source != TriggerSource.Software)
                //            TriggerRunMessageReceived?.Invoke(SN, source.ToString());  // è§¦å‘运行事件
                //    }
                //    bitmap.Dispose();
                //});
            }
            catch { }
            AsyncLogHelper.Info(SN + "Get frame blockId = {0}" + frame.frameInfo.blockId);
        }
        /// <summary>
        /// å¤„理CollectedImages中的缓存图像
        /// æ ¸å¿ƒé€»è¾‘:遍历取第一个图像 -> èµ‹å€¼ç»™CallBackImg -> è§¦å‘事件 -> é‡Šæ”¾å¹¶ç§»é™¤
        /// </summary>
        private void ProcessCollectedImages()
        {
            Task.Factory.StartNew(() =>
            {
                // åŠ é”ä¿è¯çº¿ç¨‹å®‰å…¨ï¼Œé˜²æ­¢å¤šçº¿ç¨‹åŒæ—¶æ“ä½œåˆ—è¡¨
                lock (_collectedImagesLock)
                {
                    // æ ¡éªŒå½“前相机的图像列表是否存在且有数据
                    if (!CollectedImages.ContainsKey(SN) || CollectedImages[SN].Count == 0)
                    {
                        AsyncLogHelper.Info(SN + "当前无缓存图像,跳过处理");
                        return;
                    }
                    // å¾ªçŽ¯å¤„ç†ï¼šç›´åˆ°åˆ—è¡¨ä¸ºç©º
                    while (CollectedImages[SN].Count > 0)
                    {
                        try
                        {
                            // 1 å–列表第一个索引的图像赋值给CallBackImg
                            Bitmap firstBitmap = CollectedImages[SN][0];
                            ImageGrabbed?.Invoke(this, new LBCameraEventArgs(SN, firstBitmap, true));
                            CallBackImg = (Bitmap)firstBitmap.Clone(); // å…‹éš†é¿å…åŽŸå¯¹è±¡è¢«é‡Šæ”¾åŽå¼•ç”¨å¤±æ•ˆ
                            // 2 èŽ·å–è§¦å‘æ¨¡å¼å¹¶åˆ¤æ–­æ˜¯å¦è§¦å‘è¿è¡Œäº‹ä»¶
                            if (GetTriggerMode(out TriggerMode mode, out TriggerSource source))
                            {
                                // ç¡¬è§¦å‘模式下触发运行事件
                                if (mode == TriggerMode.On && source != TriggerSource.Software)
                                {
                                    AsyncLogHelper.Info(SN + $"触发硬触发事件,触发源:{source}");
                                    TriggerRunMessageReceived?.Invoke(SN, source.ToString());
                                }
                            }
                            else
                            {
                                AsyncLogHelper.Warn(SN + "获取触发模式失败,跳过事件触发");
                            }
                            // 3 é‡Šæ”¾ç¬¬ä¸€ä¸ªå›¾åƒèµ„源并从列表移除
                            // å…ˆé‡Šæ”¾Bitmap内存,再移除列表元素
                            firstBitmap.Dispose();
                            CollectedImages[SN].RemoveAt(0);
                            AsyncLogHelper.Info(SN + $"已消费缓存图像,剩余缓存数量:{CollectedImages[SN].Count}");
                        }
                        catch (Exception ex)
                        {
                            AsyncLogHelper.Error(SN + $"处理缓存图像异常:{ex.Message}", ex);
                            // å•个图像处理失败时,移除该图像避免阻塞后续处理
                            if (CollectedImages[SN].Count > 0)
                            {
                                try
                                {
                                    CollectedImages[SN][0]?.Dispose(); // å°è¯•释放
                                    CollectedImages[SN].RemoveAt(0);
                                }
                                catch (Exception innerEx)
                                {
                                    AsyncLogHelper.Error(SN + $"清理异常图像失败:{innerEx.Message}", innerEx);
                                }
                            }
                            // å•个图像处理失败不终止循环,继续处理下一个
                            // 4. æ‰€æœ‰å›¾åƒå¤„理完成后,清空CallBackImg
                            if (CallBackImg != null)
                            {
                                CallBackImg.Dispose();
                                CallBackImg = null;
                            }
                            continue;
                        }
                        // 4. æ‰€æœ‰å›¾åƒå¤„理完成后,清空CallBackImg
                        if (CallBackImg != null)
                        {
                            CallBackImg.Dispose();
                            CallBackImg = null;
                        }
                    }
                }
            });
        }
        /// <summary>
        /// å›¾åƒæ˜¯å¦ä¸ºMono格式
        /// </summary>
        /// <param name="enType"></param>
LB_VisionProcesses/Cameras/LBCameras/LBCamera.cs
@@ -51,6 +51,8 @@
        // ä¸´æ—¶è¡Œç¼“冲,用于接收回调数据
        private byte[] _tempLineBuffer = null;
        private bool _isContinuous = false;
        // æ–°å¢žï¼šCollectedImages操作锁,保证线程安全
        private readonly object _collectedImagesLock = new object();
        public LBCamera()
        {
@@ -568,37 +570,140 @@
                _frameCount++;
                AsyncLogHelper.Info($"LBCamera[{SN}]: Frame {_frameCount} generated ({width}x{height})");
                // å¼‚步触发事件,避免阻塞SDK回调线程
                Task.Factory.StartNew(() =>
                //空值校验:转换失败则直接返回
                if (bmp == null)
                {
                    try
                    AsyncLogHelper.Warn(SN + "帧转换为Bitmap失败,跳过处理");
                    return;
                }
                // çº¿ç¨‹å®‰å…¨åœ°å°†Bitmap添加到CollectedImages字典
                lock (_collectedImagesLock)
                {
                    // ç¡®ä¿å½“前相机SN对应的列表存在
                    if (!CollectedImages.ContainsKey(SN))
                    {
                        ImageGrabbed?.Invoke(this, new LBCameraEventArgs(SN, bmp, true));
                        CallBackImg = (Bitmap)bmp.Clone();
                        if (CallBackImg == null)
                        {
                            return;
                        }
                        if (GetTriggerMode(out TriggerMode mode, out TriggerSource source))
                        {
                            if (mode == TriggerMode.On && source != TriggerSource.Software)
                                TriggerRunMessageReceived?.Invoke(SN, source.ToString());  // è§¦å‘运行事件
                        }
                        bmp.Dispose();
                        CollectedImages[SN] = new List<Bitmap>();
                    }
                    catch (Exception ex)
                    {
                        AsyncLogHelper.Error($"LBCamera: Event Invoke error - {ex.Message}");
                        bmp.Dispose(); // å¼‚常时释放资源
                    }
                });
                    CollectedImages[SN].Add(bmp);
                    AsyncLogHelper.Info(SN + $"图像已加入缓存,当前缓存数量:{CollectedImages[SN].Count}");
                }
                // å¤„理CollectedImages中的图像:遍历消费列表第一个元素直到为空
                ProcessCollectedImages();
                //// å¼‚步触发事件,避免阻塞SDK回调线程
                //Task.Factory.StartNew(() =>
                //{
                //    try
                //    {
                //        ImageGrabbed?.Invoke(this, new LBCameraEventArgs(SN, bmp, true));
                //        CallBackImg = (Bitmap)bmp.Clone();
                //        if (CallBackImg == null)
                //        {
                //            return;
                //        }
                //        if (GetTriggerMode(out TriggerMode mode, out TriggerSource source))
                //        {
                //            if (mode == TriggerMode.On && source != TriggerSource.Software)
                //                TriggerRunMessageReceived?.Invoke(SN, source.ToString());  // è§¦å‘运行事件
                //        }
                //        bmp.Dispose();
                //    }
                //    catch (Exception ex)
                //    {
                //        AsyncLogHelper.Error($"LBCamera: Event Invoke error - {ex.Message}");
                //        bmp.Dispose(); // å¼‚常时释放资源
                //    }
                //});
            }
            catch (Exception ex)
            {
                AsyncLogHelper.Error($"LBCamera: CreateBitmap error - {ex.Message}");
            }
        }
        /// <summary>
        /// å¤„理CollectedImages中的缓存图像
        /// æ ¸å¿ƒé€»è¾‘:遍历取第一个图像 -> èµ‹å€¼ç»™CallBackImg -> è§¦å‘事件 -> é‡Šæ”¾å¹¶ç§»é™¤
        /// </summary>
        private void ProcessCollectedImages()
        {
            Task.Factory.StartNew(() =>
            {
                // åŠ é”ä¿è¯çº¿ç¨‹å®‰å…¨ï¼Œé˜²æ­¢å¤šçº¿ç¨‹åŒæ—¶æ“ä½œåˆ—è¡¨
                lock (_collectedImagesLock)
                {
                    // æ ¡éªŒå½“前相机的图像列表是否存在且有数据
                    if (!CollectedImages.ContainsKey(SN) || CollectedImages[SN].Count == 0)
                    {
                        AsyncLogHelper.Info(SN + "当前无缓存图像,跳过处理");
                        return;
                    }
                    // å¾ªçŽ¯å¤„ç†ï¼šç›´åˆ°åˆ—è¡¨ä¸ºç©º
                    while (CollectedImages[SN].Count > 0)
                    {
                        try
                        {
                            // 1 å–列表第一个索引的图像赋值给CallBackImg
                            Bitmap firstBitmap = CollectedImages[SN][0];
                            ImageGrabbed?.Invoke(this, new LBCameraEventArgs(SN, firstBitmap, true));
                            CallBackImg = (Bitmap)firstBitmap.Clone(); // å…‹éš†é¿å…åŽŸå¯¹è±¡è¢«é‡Šæ”¾åŽå¼•ç”¨å¤±æ•ˆ
                            // 2 èŽ·å–è§¦å‘æ¨¡å¼å¹¶åˆ¤æ–­æ˜¯å¦è§¦å‘è¿è¡Œäº‹ä»¶
                            if (GetTriggerMode(out TriggerMode mode, out TriggerSource source))
                            {
                                // ç¡¬è§¦å‘模式下触发运行事件
                                if (mode == TriggerMode.On && source != TriggerSource.Software)
                                {
                                    AsyncLogHelper.Info(SN + $"触发硬触发事件,触发源:{source}");
                                    TriggerRunMessageReceived?.Invoke(SN, source.ToString());
                                }
                            }
                            else
                            {
                                AsyncLogHelper.Warn(SN + "获取触发模式失败,跳过事件触发");
                            }
                            // 3 é‡Šæ”¾ç¬¬ä¸€ä¸ªå›¾åƒèµ„源并从列表移除
                            // å…ˆé‡Šæ”¾Bitmap内存,再移除列表元素
                            firstBitmap.Dispose();
                            CollectedImages[SN].RemoveAt(0);
                            AsyncLogHelper.Info(SN + $"已消费缓存图像,剩余缓存数量:{CollectedImages[SN].Count}");
                        }
                        catch (Exception ex)
                        {
                            AsyncLogHelper.Error(SN + $"处理缓存图像异常:{ex.Message}", ex);
                            // å•个图像处理失败时,移除该图像避免阻塞后续处理
                            if (CollectedImages[SN].Count > 0)
                            {
                                try
                                {
                                    CollectedImages[SN][0]?.Dispose(); // å°è¯•释放
                                    CollectedImages[SN].RemoveAt(0);
                                }
                                catch (Exception innerEx)
                                {
                                    AsyncLogHelper.Error(SN + $"清理异常图像失败:{innerEx.Message}", innerEx);
                                }
                            }
                            // å•个图像处理失败不终止循环,继续处理下一个
                            // 4. æ‰€æœ‰å›¾åƒå¤„理完成后,清空CallBackImg
                            if (CallBackImg != null)
                            {
                                CallBackImg.Dispose();
                                CallBackImg = null;
                            }
                            continue;
                        }
                        // 4. æ‰€æœ‰å›¾åƒå¤„理完成后,清空CallBackImg
                        if (CallBackImg != null)
                        {
                            CallBackImg.Dispose();
                            CallBackImg = null;
                        }
                    }
                }
            });
        }
        private void SyncConfigFromCamera()
        {
LB_VisionProcesses/Communicators/BaseCommunicator.cs
@@ -1,7 +1,14 @@
namespace LB_VisionProcesses.Communicators
using Newtonsoft.Json;
namespace LB_VisionProcesses.Communicators
{
    [JsonObject(MemberSerialization.OptOut)]
    public abstract class BaseCommunicator : ICommunicator
    {
        /// <summary>
        /// å­ç±»åç§°
        /// </summary>
        public string ClassName { get; set; } = string.Empty;
        /// <summary>
        /// é€šè®¯åç§°
        /// </summary>
@@ -45,11 +52,12 @@
        /// <summary>
        /// èŽ·å–æ¶ˆæ¯å›žè°ƒ
        /// </summary>
        [JsonIgnore]
        public Action<string> MessageReceived;
        /// <summary>
        /// èŽ·å–æ¶ˆæ¯å›žè°ƒ
        /// </summary>
        [JsonIgnore]
        public Action<string, string> TriggerRunMessageReceived;
        /// <summary>
@@ -65,13 +73,13 @@
        /// <summary>
        /// å¿ƒè·³å‘送线程
        /// </summary>
        [JsonIgnore]
        public Thread heartbeatThread;
        public BaseCommunicator(string name = "")
        {
            CommunicatorName = name;
        }
        public virtual void SendHeartbeat()
        {
            while (true)
LB_VisionProcesses/Communicators/CommunicatorConfig.cs
@@ -1,4 +1,5 @@
using Newtonsoft.Json;
using LB_SmartVisionCommon;
using Newtonsoft.Json;
using Newtonsoft.Json.Serialization;
using System.Collections.Concurrent;
using System.Diagnostics;
@@ -43,12 +44,12 @@
                if (!fullPath.Contains(".json"))
                {
                    Debug.WriteLine("文件路径不完整");
                    AsyncLogHelper.Info("文件路径不完整");
                    return false;
                }
                if (string.IsNullOrEmpty(fullPath) || fullPath.Trim() == "")
                {
                    Debug.WriteLine("文件路径不完整");
                    AsyncLogHelper.Info("文件路径不完整");
                    return false;
                }
@@ -58,7 +59,7 @@
                if (!File.Exists(fullPath))
                {
                    Debug.WriteLine("文件不存在创建空文件");
                    AsyncLogHelper.Info("文件不存在创建空文件");
                    Save(directoryPath);
                    return true;
                }
@@ -90,7 +91,7 @@
            {
                if (string.IsNullOrEmpty(filePath) || filePath.Trim() == "")
                {
                    Debug.WriteLine("文件路径不完整");
                    AsyncLogHelper.Info("文件路径不完整");
                    return false;
                }
LB_VisionProcesses/Communicators/TCom/LocalMonitor.cs
@@ -1,4 +1,5 @@
using System;
using Newtonsoft.Json;
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
@@ -6,6 +7,7 @@
namespace LB_VisionProcesses.Communicators.TCom
{
    [JsonObject(MemberSerialization.OptOut)]
    public class LocalMonitor : BaseCommunicator
    {
        // ä½¿ç”¨ FileSystemWatcher æ¥å®žæ—¶ç›‘听文件夹变化
LB_VisionProcesses/Communicators/TCom/TCPClient.cs
@@ -1,4 +1,5 @@
using System;
using Newtonsoft.Json;
using System;
using System.Collections.Generic;
using System.Diagnostics;
using System.Linq;
@@ -9,6 +10,7 @@
namespace LB_VisionProcesses.Communicators.TCom
{
    [JsonObject(MemberSerialization.OptOut)]
    public class TCPClient : BaseCommunicator
    {
        private TcpClient _tcpClient = new TcpClient();
LB_VisionProcesses/Communicators/TCom/TCPServer.cs
@@ -1,4 +1,5 @@
using System;
using Newtonsoft.Json;
using System;
using System.Collections.Generic;
using System.Diagnostics;
using System.Linq;
@@ -9,6 +10,7 @@
namespace LB_VisionProcesses.Communicators.TCom
{
    [JsonObject(MemberSerialization.OptOut)]
    public class TCPServer : BaseCommunicator
    {
        private TcpListener _tcpListener;
LB_VisionProcesses/Communicators/TCom/UARTPort.cs
@@ -1,4 +1,5 @@
using RJCP.IO.Ports;
using Newtonsoft.Json;
using RJCP.IO.Ports;
using System;
using System.Collections.Generic;
using System.Linq;
@@ -7,6 +8,7 @@
namespace LB_VisionProcesses.Communicators.TCom
{
    [JsonObject(MemberSerialization.OptOut)]
    public class UARTPort : BaseCommunicator
    {
        private RJCP.IO.Ports.SerialPortStream SerialPort = new RJCP.IO.Ports.SerialPortStream();
LB_VisionProcesses/Communicators/UserCommunicator/T306Command/T306CommandTool.cs
@@ -1,4 +1,5 @@
using LB_VisionProcesses.Communicators.TCom;
using Newtonsoft.Json;
using System;
using System.Collections.Concurrent;
using System.Collections.Generic;
@@ -9,6 +10,7 @@
namespace LB_VisionProcesses.Communicators.UserCommunicator.T306Command
{
    [JsonObject(MemberSerialization.OptOut)]
    internal class T306CommandTool : CommunicatorConfig
    {
        string HDCP14CHECK = "0422CCF2";
LB_VisionProcesses/LB_VisionProcesses.csproj
@@ -33,10 +33,9 @@
    <Reference Include="MVSDK_Net">
      <HintPath>ref\MVSDK_Net.dll</HintPath>
    </Reference>
  </ItemGroup>
  <ItemGroup>
    <Folder Include="Alogrithms\VisualLargeModel\" />
    <Reference Include="EasyIDSDK_Net">
      <HintPath>ref\EasyIDSDK_Net.dll</HintPath>
    </Reference>
  </ItemGroup>
  <ItemGroup>
@@ -61,39 +60,14 @@
  </ItemGroup>
  <ItemGroup>
    <None Update="ref\CLIDelegate.dll">
    <None Update="ref\*.dll">
      <CopyToOutputDirectory>Always</CopyToOutputDirectory>
    </None>
    <None Update="ref\halcondotnet.dll">
    <None Update="ref\*.XML">
      <CopyToOutputDirectory>Always</CopyToOutputDirectory>
    </None>
    <None Update="ref\MVSDKmd.dll">
      <CopyToOutputDirectory>Always</CopyToOutputDirectory>
    </None>
    <None Update="ref\MVSDK_Net.dll">
      <CopyToOutputDirectory>Always</CopyToOutputDirectory>
    </None>
    <None Update="ref\MVSDK_Net.XML">
      <CopyToOutputDirectory>Always</CopyToOutputDirectory>
    </None>
    <None Update="ref\PHM6000.dll">
      <CopyToOutputDirectory>Always</CopyToOutputDirectory>
    </None>
    <None Update="ref\PHM6000API.dll">
      <CopyToOutputDirectory>Always</CopyToOutputDirectory>
    </None>
    <None Update="ref\PHM6000API.lib">
      <CopyToOutputDirectory>Always</CopyToOutputDirectory>
    </None>
    <None Update="ref\Pilot2D.dll">
      <CopyToOutputDirectory>Always</CopyToOutputDirectory>
    </None>
    <None Update="ref\PointCloud3D.dll">
      <CopyToOutputDirectory>Always</CopyToOutputDirectory>
    </None>
    <None Update="ref\ThridLibray.dll">
    <None Update="ref\*.lib">
      <CopyToOutputDirectory>Always</CopyToOutputDirectory>
    </None>
  </ItemGroup>
</Project>
LB_VisionProcesses/ProcessEditForm.Designer.cs
@@ -44,11 +44,12 @@
            theme_AlgorithmForm.Font = new Font("Microsoft Sans Serif", 9F);
            theme_AlgorithmForm.Image = (Image)resources.GetObject("theme_AlgorithmForm.Image");
            theme_AlgorithmForm.Location = new Point(0, 0);
            theme_AlgorithmForm.Margin = new Padding(4);
            theme_AlgorithmForm.Name = "theme_AlgorithmForm";
            theme_AlgorithmForm.Padding = new Padding(10, 70, 10, 9);
            theme_AlgorithmForm.Padding = new Padding(12, 88, 12, 11);
            theme_AlgorithmForm.RoundCorners = true;
            theme_AlgorithmForm.Sizable = true;
            theme_AlgorithmForm.Size = new Size(944, 601);
            theme_AlgorithmForm.Size = new Size(1366, 751);
            theme_AlgorithmForm.SmartBounds = true;
            theme_AlgorithmForm.StartPosition = FormStartPosition.WindowsDefaultLocation;
            theme_AlgorithmForm.TabIndex = 0;
@@ -59,10 +60,11 @@
            pnl_ProcessEditForm.BackColor = Color.FromArgb(39, 51, 63);
            pnl_ProcessEditForm.Dock = DockStyle.Fill;
            pnl_ProcessEditForm.EdgeColor = Color.FromArgb(32, 41, 50);
            pnl_ProcessEditForm.Location = new Point(10, 70);
            pnl_ProcessEditForm.Location = new Point(12, 88);
            pnl_ProcessEditForm.Margin = new Padding(4);
            pnl_ProcessEditForm.Name = "pnl_ProcessEditForm";
            pnl_ProcessEditForm.Padding = new Padding(5);
            pnl_ProcessEditForm.Size = new Size(924, 522);
            pnl_ProcessEditForm.Padding = new Padding(6);
            pnl_ProcessEditForm.Size = new Size(1342, 652);
            pnl_ProcessEditForm.SmoothingType = System.Drawing.Drawing2D.SmoothingMode.HighQuality;
            pnl_ProcessEditForm.TabIndex = 1;
            // 
@@ -76,7 +78,8 @@
            controlB_ProcessEditForm.EnableMaximizeButton = false;
            controlB_ProcessEditForm.EnableMinimizeButton = false;
            controlB_ProcessEditForm.ForeColor = Color.FromArgb(155, 155, 155);
            controlB_ProcessEditForm.Location = new Point(844, 18);
            controlB_ProcessEditForm.Location = new Point(1241, 18);
            controlB_ProcessEditForm.Margin = new Padding(4);
            controlB_ProcessEditForm.MaximizeHoverColor = Color.FromArgb(74, 74, 74);
            controlB_ProcessEditForm.MinimizeHoverColor = Color.FromArgb(63, 63, 65);
            controlB_ProcessEditForm.Name = "controlB_ProcessEditForm";
@@ -85,12 +88,13 @@
            // 
            // ProcessEditForm
            // 
            AutoScaleDimensions = new SizeF(96F, 96F);
            AutoScaleDimensions = new SizeF(120F, 120F);
            AutoScaleMode = AutoScaleMode.Dpi;
            ClientSize = new Size(944, 601);
            ClientSize = new Size(1366, 751);
            Controls.Add(theme_AlgorithmForm);
            FormBorderStyle = FormBorderStyle.None;
            MinimumSize = new Size(261, 61);
            Margin = new Padding(4);
            MinimumSize = new Size(326, 76);
            Name = "ProcessEditForm";
            Text = "AlgorithmForm";
            TransparencyKey = Color.Fuchsia;
LB_VisionProcesses/ProcessEditForm.cs
@@ -99,7 +99,7 @@
                    e.Cancel = true;  //取消关闭窗体
                    return;
                }
                if (res == DialogResult.Yes && OriProcess != null)  //保存VPP
                {
                    //利用反射创建实例,命名规范:Tool+Edit
LB_VisionProcesses/ProcessEditForm.resx
@@ -121,24 +121,27 @@
  <data name="theme_AlgorithmForm.Image" type="System.Drawing.Bitmap, System.Drawing" mimetype="application/x-microsoft.net.object.bytearray.base64">
    <value>
        iVBORw0KGgoAAAANSUhEUgAAACAAAAAgCAYAAABzenr0AAAABGdBTUEAALGPC/xhBQAAAAlwSFlzAAAO
        wAAADsABataJCQAAA+JJREFUWEftVkuIHGUQbt34iMEoq2S2q3p3yTJsuqpnJ+L6WBRdwaigohfFgEou
        BkVBUPCBCEG8BXNQ48GLeImCehIJxMsqhsSZruod46K4HtSIGjU+4iOr0c1I9fSsM3/PLNtCPO0H36m/
        evz/X11VnreKVRTAHPOZumkY6lFwqURws3BwZ8ywTQnuiCP/+iTCzY1qaUPzdm/Atf3PaHre6XPsjyQM
        2xLGV4XwIyX4QRj+UMK/lPFvJTyhBMeV8IgQvmRJuH4Ko+l5p9UjGBbCJ5RxTgj+VMZmXxKcSAjekHE/
        NNs5DgaTKLinEQYVO4Trf1mkV81wixLUslPmA3bzF2XcKeP+hWY/u3n0fCXcrQwLyjAvjNsb1dI6N05P
        mFAIHlHG73sEypPgGwnhfpn0zzH7jzddcK4Q7kqfKNMI4a9K+MwBDgbdeF04MBWsFYYdQvhbLlBvfhKT
        f+vMtLfG7C0JJXxKGY67WnvCmPAFGRs7z42boul5AzHBfdK6TjdQtzPGk8oos5F/5Y7sfVvPhg+lp+1h
        0yIsxARPmtaN78WEl8eEX+SNclxUhne0glUrNrN9zfMGlPAuZTzaQ99FYfwuDv3ruoLvq5bWaQSvZCfL
        GXUYLwrj240Qxtu2lkSN4FpdWfKZH9jb9RQ1Cq62f9sVOlxUxn3KQXnJ0PO8QxU/jBm1h74v7ZniEG9K
        Hdg/quzvXO709k0Y3u08ucGqWgheX862H4XgxbR47SqU8D1X0EXC2VmGizqDz0xPr0kYH9eO360gNe0b
        jWppozB+1kOQEb5MCLa0C64NoeGrhOGrvH6lhK81GiIvnggmrDLzgvTkvwvDA+5wsU4nhG/m9AUoBD/F
        HFzWN4H0XQn2vF8eXN8Z3FAPYasl59oUYjuB+sTImDB+nhfgYQ39STf4fmu1DHtz+oIUgiM1KkWtwcFw
        sOujVT3hrnaL7UQc+hcL5W+sKIXhw0OVjaW0iwnBc47gqIQ45QY32PKRzv8eTguRYM9SS5YouEEZjv37
        EffbzbjBDdZyxZYQ12EB2qS0bWrJqRVazPDWkojwZbuZrsgZtDJ0iY1g12khEtTicMTvclwn2CKE32YJ
        7G5PORfZ1HtMCH7MOV4BrQ3XCe92+4onk5Nn2PolDAvWXnuOzAwzo6Nnx4Q3SrojwqfKeMxWMpsXWVs+
        2WrfKRdbW1W6Hf0shM/33Y7my4PrleFZIfhAaWjU/e5ivlw+y3S2FySMtynjvcrwsFiLJv/RhPBB2ws1
        hK2WcBLBFf1qawlplwvxaQlxe786OOU4PBWsjSO85mBlQ8n99r/BisSdAas4FfgHpdEUZpwUX7sAAAAA
        SUVORK5CYII=
        vgAADr4B6kKxwAAAA+xJREFUWEftV0loFUkYbvcNFzJi0lWdBEPQruqXKEYdcRgz4AYqeplBwYiXEUVB
        UHAhCEG8iR509OBlmIsOjJ5EBvQSRVHzuvslxjAy8eCG+75GozF+f716L6873fqe2ykffDR59e9/1V8V
        ow99KARtUg72J5aypGNN8xy2yJPWcleylb5gS13HnJdy+KSW6uJx3b8ZA7TKl6PbMPq3SbMsBUcpyf/2
        BP8PDh96kr32BX/rS/4O30789grfO1j/k4LQ6p8POO6XdFgpDNbDSZsn2Bt8u2MpWGdKsCPeBNMm3TZp
        FaUc6/cW20pQEtpsflCllmwxjDbpLKOd9vAZuBPOx5J+86TyMdDbBxsdYLsn+SpUZYQy/imQILLdBIP3
        cxzEU7Dbns3WejXmcNK/NPGHkajabtUiLYO/nyOgXWdRFeUkDmdnWMOg2ACFFwEn8fzfFeaSxlpjIOlT
        EHC0HVm/CstSC13B93sVFaOVszDQpwGuYGtQLipnQDlMyLzH12t2zJ8adH/TbeMbVLYROmmyDvjYRrLK
        aS4Q3Y/gtWjFALtg6KSf4NW02Uj3HwSPzOuw9iAk24sI/p5rm3OV0wyOo+++ww7pzCIViVjvAk+02GyC
        VlWnpUmw2Qggn+AV0eZ/A61oEtYsOttRwjlE5vy4L61KrabQmjBtV3I/JPtRUptcmy9UBuiM+tLc+bHs
        aQ1Rn8rNnEC7Gpvr8KcqF0XoHVCbl0qB8p2OEspS8OZmySZrvwqNtbUDMRm3Yj9kj1uB9NXcwLkfjwyu
        RAhoshuYcHMyGy4DT5T+jKrcjNbJh+yW75QIw62yqhDAvUghwV/Cybrw5UKTDn08GqmTJ9GCx660pscG
        oPoq2MHzlUWjtN8skjZbRsGFdQpiJoBkVVkFnF3tLcCv+7ZZo31mcYZGLY5RL/kCiQrcaRLFTvrikOxc
        YJF2PeZ5ZsTmAkNkCtaiW1YAkcTF1sT4YjXFEM3ekMADz+YztM8AULqlqE5nSL5wor3Zkew51nxU4WnP
        Ij9DlVGLIWCtDhV6FzBWIJH9a3pNaZOGQRsNT6tjWSHB/6LK6OUA/ETJVER/O9dgwcQ7w7XLTG0yjSTO
        Onp7Ny3A92VuuTD0rbcFbXsUMJonaQwnBV8Rniu4y2sGYbEe5emA8cORV6ZGY3n5UNycC9AKvBHZZRh+
        iqxoX9BlRWMZozvLLiSEV5V6HT2Bjz9iX0ftaAWE9sDoBV+UlOufY9FeWTmE5OhdgLH8Kxyvhv5GON3q
        C3NzSvD19C70MTco4JTDZsbtrSzUlLP5DnBV3D745riOp5nr8F/OJcYV65++P2iTfNV/MPoQCcP4AKXR
        FGYxo/VGAAAAAElFTkSuQmCC
</value>
  </data>
  <metadata name="$this.Locked" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
    <value>True</value>
  </metadata>
</root>
LB_VisionProcesses/Processes/BarcodeReaderProcess.cs
¶Ô±ÈÐÂÎļþ
@@ -0,0 +1,150 @@
using System;
using System.Collections.Concurrent;
using System.Collections.Generic;
using System.Diagnostics;
using System.Drawing;
using System.IO;
using System.Linq;
using System.Text;
using Newtonsoft.Json;
using Newtonsoft.Json.Serialization;
using LB_VisionProcesses.BarcodeReaders;
namespace LB_VisionProcesses.Processes
{
    [Process("读码工具", Category = "取像工具", Description = "通过读码器获取条码数据")]
    public class BarcodeReaderProcess : IProcess
    {
        /// <summary>
        /// è¯»ç å™¨å®žä¾‹é›†åˆ (由主程序管理并传入)
        /// </summary>
        [JsonIgnore]
        public ConcurrentDictionary<string, BarcodeReaderBase> dicBarcodeReaders { get; set; }
        /// <summary>
        /// å½“前关联的读码器
        /// </summary>
        [JsonIgnore]
        public BarcodeReaderBase Reader { get; set; }
        public BarcodeReaderProcess()
        {
            strProcessName = "读码工具";
            strProcessClass = "LB_VisionProcesses.Processes.BarcodeReaderProcess";
            Params.Inputs.Add("设备品牌", "Huayray");
            Params.Inputs.Add("设备SN", "");
            Params.Inputs.Add("触发模式", "软触发");
            Params.Inputs.Add("超时时间", 2000);
            Params.Outputs.Add("条码结果", "");
            Params.Outputs.Add("码数量", 0);
        }
        public override void InitRunParams()
        {
            Result = true;
            Msg = "准备运行";
            bCompleted = false;
        }
        public override bool Run()
        {
            DateTime StartTime = DateTime.Now;
            try
            {
                InitRunParams();
                string sn = Params.Inputs["设备SN"]?.ToString();
                if (string.IsNullOrEmpty(sn))
                {
                    Msg = "设备SN未配置";
                    Result = false;
                    return false;
                }
                // ä»Žå…¨å±€å˜é‡æˆ–传入字典获取
                if (dicBarcodeReaders == null)
                {
                    // å°è¯•从全局 dicGlobalVars èŽ·å– (假设主程序已放入)
                    if (dicGlobalVars.ContainsKey("dicBarcodeReaders"))
                    {
                        dicBarcodeReaders = dicGlobalVars["dicBarcodeReaders"] as ConcurrentDictionary<string, BarcodeReaderBase>;
                    }
                }
                if (dicBarcodeReaders != null && dicBarcodeReaders.ContainsKey(sn))
                {
                    Reader = dicBarcodeReaders[sn];
                }
                if (Reader == null)
                {
                    Msg = $"读码器[{sn}]未初始化";
                    Result = false;
                    return false;
                }
                string triggerMode = Params.Inputs["触发模式"]?.ToString();
                if (triggerMode == "软触发")
                {
                    bool success = Reader.SoftTrigger();
                    Msg = success ? "触发成功" : "触发失败";
                    Result = success;
                }
            }
            catch (Exception ex)
            {
                Msg = "运行异常: " + ex.Message;
                Result = false;
            }
            finally
            {
                RunTime = (DateTime.Now - StartTime).TotalMilliseconds;
                bCompleted = true;
            }
            return Result;
        }
        public override bool Load(string fullPath)
        {
            try
            {
                if (string.IsNullOrEmpty(fullPath) || !File.Exists(fullPath)) return false;
                string json = File.ReadAllText(fullPath, Encoding.UTF8);
                Params = JsonConvert.DeserializeObject<ProcessParams>(json);
                Params?.FixDeserializedData();
                return true;
            }
            catch { return false; }
        }
        public override bool Save(string filePath)
        {
            try
            {
                if (string.IsNullOrEmpty(filePath)) return false;
                if (!Directory.Exists(filePath)) Directory.CreateDirectory(filePath);
                string fullPath = Path.Combine(filePath, strProcessName + ".json");
                string json = JsonConvert.SerializeObject(Params, Formatting.Indented);
                File.WriteAllText(fullPath, json, Encoding.UTF8);
                return true;
            }
            catch { return false; }
        }
        public override object Clone()
        {
            try
            {
                var obj = (BarcodeReaderProcess)MemberwiseClone();
                string json = JsonConvert.SerializeObject(this.Params);
                obj.Params = JsonConvert.DeserializeObject<ProcessParams>(json);
                return obj;
            }
            catch { return (BarcodeReaderProcess)MemberwiseClone(); }
        }
        public override void Dispose() { }
    }
}
LB_VisionProcesses/ref/CLAllSerial_MD_VC120_v3_0.dll
Binary files differ
LB_VisionProcesses/ref/CLProtocol_MD_VC120_v3_0.dll
Binary files differ
LB_VisionProcesses/ref/CLSerCOM.dll
Binary files differ
LB_VisionProcesses/ref/EasyID.dll
Binary files differ
LB_VisionProcesses/ref/EasyIDSDK_Net.XML
¶Ô±ÈÐÂÎļþ
@@ -0,0 +1,1812 @@
<?xml version="1.0"?>
<doc>
    <assembly>
        <name>EasyIDSDK_Net</name>
    </assembly>
    <members>
        <member name="T:EasyIDSDK_Net.EidCamera">
            <summary>
            <para><ch>EidCamera</ch></para>
            <para><en>EidCamera</en></para>
            </summary>
        </member>
        <member name="F:EasyIDSDK_Net.EidCamera.eidErrorOK">
            <summary>
            <para><ch>成功</ch></para>
            <para><en>OK</en></para>
            </summary>
        </member>
        <member name="F:EasyIDSDK_Net.EidCamera.eidErrorUnknown">
            <summary>
            <para><ch>未知错误</ch></para>
            <para><en>Unknown error</en></para>
            </summary>
        </member>
        <member name="F:EasyIDSDK_Net.EidCamera.eidErrorInternalError">
            <summary>
            <para><ch>内部错误</ch></para>
            <para><en>Internal error</en></para>
            </summary>
        </member>
        <member name="F:EasyIDSDK_Net.EidCamera.eidErrorInvalidParameter">
            <summary>
            <para><ch>无效参数</ch></para>
            <para><en>Invalid parameter</en></para>
            </summary>
        </member>
        <member name="F:EasyIDSDK_Net.EidCamera.eidErrorNotConnected">
            <summary>
            <para><ch>相机未连接</ch></para>
            <para><en>Camera not connected</en></para>
            </summary>
        </member>
        <member name="F:EasyIDSDK_Net.EidCamera.eidErrorNotFound">
            <summary>
            <para><ch>未找到</ch></para>
            <para><en>Not found</en></para>
            </summary>
        </member>
        <member name="F:EasyIDSDK_Net.EidCamera.eidErrorTimeout">
            <summary>
            <para><ch>超时</ch></para>
            <para><en>Timeout</en></para>
            </summary>
        </member>
        <member name="F:EasyIDSDK_Net.EidCamera.eidErrorNotImplemented">
            <summary>
            <para><ch>未实现</ch></para>
            <para><en>Not implemented</en></para>
            </summary>
        </member>
        <member name="F:EasyIDSDK_Net.EidCamera.eidErrorRepeatOperation">
            <summary>
            <para><ch>重复操作</ch></para>
            <para><en>Repeat operation</en></para>
            </summary>
        </member>
        <member name="F:EasyIDSDK_Net.EidCamera.eidErrorNullPtr">
            <summary>
            <para><ch>空指针</ch></para>
            <para><en>Null pointer</en></para>
            </summary>
        </member>
        <member name="F:EasyIDSDK_Net.EidCamera.eidErrorReadDataFail">
            <summary>
            <para><ch>读取数据失败</ch></para>
            <para><en>Failed to read data</en></para>
            </summary>
        </member>
        <member name="F:EasyIDSDK_Net.EidCamera.eidErrorWriteDataFail">
            <summary>
            <para><ch>写入数据失败</ch></para>
            <para><en>Failed to write data</en></para>
            </summary>
        </member>
        <member name="F:EasyIDSDK_Net.EidCamera.eidErrorDataCheckFail">
            <summary>
            <para><ch>数据校验失败</ch></para>
            <para><en>Data verification failed</en></para>
            </summary>
        </member>
        <member name="F:EasyIDSDK_Net.EidCamera.eidErrorImageSizeError">
            <summary>
            <para><ch>图像大小错误</ch></para>
            <para><en>Wrong image size</en></para>
            </summary>
        </member>
        <member name="F:EasyIDSDK_Net.EidCamera.eidErrorImageTypeError">
            <summary>
            <para><ch>图像类型错误</ch></para>
            <para><en>Wrong image type</en></para>
            </summary>
        </member>
        <member name="F:EasyIDSDK_Net.EidCamera.eidErrorImageDataTypeError">
            <summary>
            <para><ch>图像数据类型错误</ch></para>
            <para><en>Wrong image data type</en></para>
            </summary>
        </member>
        <member name="F:EasyIDSDK_Net.EidCamera.eidErrorSerializeFail">
            <summary>
            <para><ch>序列化失败</ch></para>
            <para><en>Serialization failed</en></para>
            </summary>
        </member>
        <member name="F:EasyIDSDK_Net.EidCamera.eidErrorDeserializeFail">
            <summary>
            <para><ch>反序列化失败</ch></para>
            <para><en>Deserialization failed</en></para>
            </summary>
        </member>
        <member name="F:EasyIDSDK_Net.EidCamera.eidErrorOpenFileFail">
            <summary>
            <para><ch>打开文件失败</ch></para>
            <para><en>Failed to open file</en></para>
            </summary>
        </member>
        <member name="F:EasyIDSDK_Net.EidCamera.eidErrorWriteFileFail">
            <summary>
            <para><ch>文件写入失败</ch></para>
            <para><en>File writing failed</en></para>
            </summary>
        </member>
        <member name="F:EasyIDSDK_Net.EidCamera.eidErrorInvalidHandle">
            <summary>
            <para><ch>无效句柄</ch></para>
            <para><en>Invalid handle</en></para>
            </summary>
        </member>
        <member name="F:EasyIDSDK_Net.EidCamera.eidErrorInsufficientBuffer">
            <summary>
            <para><ch>缓冲区过小</ch></para>
            <para><en>Insufficient buffers</en></para>
            </summary>
        </member>
        <member name="M:EasyIDSDK_Net.EidCamera.#ctor">
            <summary>
            <para><ch>构造函数</ch></para>
            <para><en>Constructor</en></para>
            </summary>
        </member>
        <member name="M:EasyIDSDK_Net.EidCamera.eidGetVersion_Net">
            <summary>
            <para><ch>获取版本信息</ch></para>
            <para><en>Get version information</en></para>
            </summary>
            <returns><para><ch>版本信息</ch></para><para><en>Version infomation</en></para></returns>
        </member>
        <member name="M:EasyIDSDK_Net.EidCamera.eidEnumDevices_Net(EasyIDSDK_Net.EidCamera.EidDeviceList@,System.UInt32)">
            <summary>
            <para><ch>根据接口类型枚举相机, åŒæ—¶è¾“出所有相机信息到 deviceList</ch></para>
            <para><en>Enumerate devices according to the interface type, and outputting all devices information to the deviceList</en></para>
            </summary>
            <param name="deviceList"><para><ch>[out] è®¾å¤‡ä¿¡æ¯åˆ—表</ch></para><para><en>[out] Device information list</en></para></param>
            <param name="type"><para><ch>[in] æŽ¥å£ç±»åž‹, å¯ä»¥æ˜¯å¤šä¸ªæŽ¥å£ç±»åž‹çš„组合. è‹¥ä¼ å…¥å€¼ä¸º0表示所有类型, ä¸Ž eidInterfaceTypeAll å«ä¹‰ç›¸åŒ, å…¶ä½™å–值参考 #EidInterfaceType</ch></para>
            <para><en>[in] Interface type, which can be a combination of multiple interface types.If the value of the parameter is 0, it means all types, which is the same as eidInterfaceTypeAll. other value see #EidInterfaceType</en></para></param>
            <returns><para><ch>错误码, 0-成功, å…¶ä»–-错误码</ch></para><para><en>Error code, 0-success, other-error code</en></para></returns>
        </member>
        <member name="M:EasyIDSDK_Net.EidCamera.eidCreateDevice_Net(System.String,EasyIDSDK_Net.EidCamera.EidDeviceDataType)">
            <summary>
            <para><ch>根据设备数据信息创建相应的设备对象, å¦‚可以通过设备序列号创建。</ch></para>
            <para><en>Create a device handle according to the device data, for example, you can create a device object through the serial number.
            This interface will not enumerate devices and needs to be called after #eidEnumDevices.</en></para>
            </summary>
            <param name="data"><para><ch>[in] è®¾å¤‡æ•°æ®, æ•°æ®å†…容的含义由 type å‚数决定</ch></para><para><en>[in] Device data, the meaning of the data content is determined by the type parameter</en></para></param>
            <param name="type"><para><ch>[in] æ•°æ®ç±»åž‹, é»˜è®¤å€¼æ˜¯è®¾å¤‡åºåˆ—号</ch></para><para><en>[in] Data type</en></para></param>
            <returns><para><ch>错误码, 0-成功, å…¶ä»–-错误码</ch></para><para><en>Error code, 0-success, other-error code</en></para></returns>
            <remarks><para><ch>注意需要调用 #eidReleaseHandle_Net é‡Šæ”¾èµ„源。</ch></para><para><en>Note that need to call #eidReleaseHandle_Net to release resources.</en></para></remarks>
        </member>
        <member name="M:EasyIDSDK_Net.EidCamera.eidReleaseHandle_Net">
            <summary>
            <para><ch>释放相机句柄资源</ch></para>
            <para><en>Release device handle resources</en></para>
            </summary>
        </member>
        <member name="M:EasyIDSDK_Net.EidCamera.eidGetDeviceInfo_Net(EasyIDSDK_Net.EidCamera.EidDeviceInfo@)">
            <summary>
            <para><ch>获取设备信息</ch></para>
            <para><en>Get device infomation</en></para>
            </summary>
            <param name="info"><para><ch>[out] è®¾å¤‡ä¿¡æ¯</ch></para><para><en>[out] Pointer to a EidDeviceInfo structure to receive the device information</en></para></param>
            <returns><para><ch>错误码, 0-成功, å…¶ä»–-错误码</ch></para><para><en>Error code, 0-success, other-error code</en></para></returns>
        </member>
        <member name="M:EasyIDSDK_Net.EidCamera.eidOpenDevice_Net">
            <summary>
            <para><ch>打开设备</ch></para>
            <para><en>Open a device</en></para>
            </summary>
            <returns><para><ch>错误码, 0-成功, å…¶ä»–-错误码</ch></para><para><en>Error code, 0-success, other-error code</en></para></returns>
        </member>
        <member name="M:EasyIDSDK_Net.EidCamera.eidCloseDevice_Net">
            <summary>
            <para><ch>关闭设备</ch></para>
            <para><en>Close a device</en></para>
            </summary>
            <returns><para><ch>错误码, 0-成功, å…¶ä»–-错误码</ch></para><para><en>Error code, 0-success, other-error code</en></para></returns>
        </member>
        <member name="M:EasyIDSDK_Net.EidCamera.eidIsDeviceOpen_Net">
            <summary>
            <para><ch>设备是否已经打开</ch></para>
            <para><en>Gets a value indicating whether the media source is currently open. .</en></para>
            </summary>
            <returns><para><ch>如果设备处于打开状态,返回 true,否则,false</ch></para><para><en>True if the device is open; otherwise, false</en></para></returns>
        </member>
        <member name="M:EasyIDSDK_Net.EidCamera.eidForceIpAddress_Net(System.String,System.String,System.String)">
            <summary>
            <para><ch>修改相机IP. è¯¥æŽ¥å£åªé’ˆå¯¹é€šè¿‡ç½‘卡接入的设备,对于其余设备,调用此接口无意义</ch></para>
            <para><en>Modify the device IP. This interface is only for devices connected through a network card.
            For other devices, it is meaningless to call this interface.</en></para>
            </summary>
            <param name="ipAddr"><para><ch>[in] è®¾å¤‡IP地址</ch></para><para><en>[in] New IP address</en></para></param>
            <param name="subnetMask"><para><ch>[in] å­ç½‘掩码</ch></para><para><en>[in] New subnet mask</en></para></param>
            <param name="gateway"><para><ch>[in] é»˜è®¤ç½‘å…³</ch></para><para><en>[in] New default gateway</en></para></param>
            <returns><para><ch>错误码, 0-成功, å…¶ä»–-错误码</ch></para><para><en>Error code, 0-success, other-error code</en></para></returns>
        </member>
        <member name="M:EasyIDSDK_Net.EidCamera.eidDownloadGenICamXML_Net(System.String)">
            <summary>
            <para><ch>下载设备描述XML文件,并保存到指定路径</ch></para>
            <para><en>Download device description XML file, and save the file to specified path</en></para>
            </summary>
            <param name="path"><para><ch>[in] æ–‡ä»¶ä¿å­˜è·¯å¾„</ch></para><para><en>[in] The file path where the downloaded XMl file would be saved to</en></para></param>
            <returns><para><ch>错误码, 0-成功, å…¶ä»–-错误码</ch></para><para><en>Error code, 0-success, other-error code</en></para></returns>
        </member>
        <member name="M:EasyIDSDK_Net.EidCamera.eidSaveDeviceConfig_Net(System.String)">
            <summary>
            <para><ch>保存设备配置到指定的路径</ch></para>
            <para><en>Save the configuration of the device to specified path</en></para>
            </summary>
            <param name="path"><para><ch>[in] æ–‡ä»¶ä¿å­˜è·¯å¾„</ch></para><para><en>[in] The file path where the downloaded XMl file would be saved to</en></para></param>
            <returns><para><ch>错误码, 0-成功, å…¶ä»–-错误码</ch></para><para><en>Error code, 0-success, other-error code</en></para></returns>
        </member>
        <member name="M:EasyIDSDK_Net.EidCamera.eidLoadDeviceConfig_Net(System.String,EasyIDSDK_Net.EidCamera.EidErrorList@)">
            <summary>
            <para><ch>从文件加载设备配置</ch></para>
            <para><en>Load the device configuration from a file</en></para>
            </summary>
            <param name="path"><para><ch>[in] é…ç½®æ–‡ä»¶è·¯å¾„</ch></para><para><en>[in] Configuration file path</en></para></param>
            <param name="errorList"><para><ch>[out] é”™è¯¯åˆ—表指针, å†™å…¥å¤±è´¥çš„设备属性名称将通过该参数返回</ch></para><para><en>[out] Pointor to error list. The device feature names that failed to write will be returned with this parameter</en></para></param>
            <returns><para><ch>错误码, 0-成功, å…¶ä»–-错误码</ch></para><para><en>Error code, 0-success, other-error code</en></para></returns>
        </member>
        <member name="M:EasyIDSDK_Net.EidCamera.eidGetFeatureType_Net(System.String)">
            <summary>
            <para><ch>获取设备属性类型</ch></para>
            <para><en>Get device feature type</en></para>
            </summary>
            <param name="name"><para><ch>[in] å±žæ€§åç§°</ch></para><para><en>[in] Feature name</en></para></param>
            <returns><para><ch>设备属性类型, è§ #EidFeatureType</ch></para><para><en>Device feature type, see enum #EidFeatureType</en></para></returns>
        </member>
        <member name="M:EasyIDSDK_Net.EidCamera.eidIsFeatureValid_Net(System.String)">
            <summary>
            <para><ch>设备属性是否有效</ch></para>
            <para><en>Is the device feature valid</en></para>
            </summary>
            <param name="name"><para><ch>[in] å±žæ€§åç§°</ch></para><para><en>[in] Feature name</en></para></param>
            <returns><para><ch>true æœ‰æ•ˆ,false æ— æ•ˆ</ch></para><para><en>true Valid,false Not valid</en></para></returns>
        </member>
        <member name="M:EasyIDSDK_Net.EidCamera.eidIsFeatureAvailable_Net(System.String)">
            <summary>
            <para><ch>设备属性是否可用</ch></para>
            <para><en>Is the device feature available</en></para>
            </summary>
            <param name="name"><para><ch>[in] å±žæ€§åç§°</ch></para><para><en>[in] Feature name</en></para></param>
            <returns><para><ch>true å¯ç”¨,false ä¸å¯ç”¨</ch></para><para><en>true Available,false Not available</en></para></returns>
        </member>
        <member name="M:EasyIDSDK_Net.EidCamera.eidIsFeatureReadable_Net(System.String)">
            <summary>
            <para><ch>设备属性是否可读</ch></para>
            <para><en>Is the device feature readable</en></para>
            </summary>
            <param name="name"><para><ch>[in] å±žæ€§åç§°</ch></para><para><en>[in] Feature name</en></para></param>
            <returns><para><ch>true å¯è¯»,false ä¸å¯è¯»</ch></para><para><en>true Readable,false Not readable</en></para></returns>
        </member>
        <member name="M:EasyIDSDK_Net.EidCamera.eidIsFeatureWriteable_Net(System.String)">
            <summary>
            <para><ch>设备属性是否可写</ch></para>
            <para><en>Is the device feature writeable</en></para>
            </summary>
            <param name="name"><para><ch>[in] å±žæ€§åç§°</ch></para><para><en>[in] Feature name</en></para></param>
            <returns><para><ch>true å¯å†™,false ä¸å¯å†™</ch></para><para><en>true Writeable,false Not writeable</en></para></returns>
        </member>
        <member name="M:EasyIDSDK_Net.EidCamera.eidGetIntFeatureValue_Net(System.String,System.Int64@)">
            <summary>
            <para><ch>获取整型属性值</ch></para>
            <para><en>Get integer feature value</en></para>
            </summary>
            <param name="name"><para><ch>[in] å±žæ€§åç§°</ch></para><para><en>[in] Feature name</en></para></param>
            <param name="value"><para><ch>[out] å±žæ€§å€¼</ch></para><para><en>[out] Pointer to feature value</en></para></param>
            <returns><para><ch>错误码, 0-成功, å…¶ä»–-错误码</ch></para><para><en>Error code, 0-success, other-error code</en></para></returns>
        </member>
        <member name="M:EasyIDSDK_Net.EidCamera.eidSetIntFeatureValue_Net(System.String,System.Int64)">
            <summary>
            <para><ch>设置整型属性值</ch></para>
            <para><en>Set integer feature value</en></para>
            </summary>
            <param name="name"><para><ch>[in] å±žæ€§åç§°</ch></para><para><en>[in] Feature name</en></para></param>
            <param name="value"><para><ch>[in] å±žæ€§å€¼</ch></para><para><en>[in] Feature value</en></para></param>
            <returns><para><ch>错误码, 0-成功, å…¶ä»–-错误码</ch></para><para><en>Error code, 0-success, other-error code</en></para></returns>
        </member>
        <member name="M:EasyIDSDK_Net.EidCamera.eidGetIntFeatureInfo_Net(System.String,EasyIDSDK_Net.EidCamera.EidIntFeatureInfo@)">
            <summary>
            <para><ch>获取整型属性信息</ch></para>
            <para><en>Gets integer feature information</en></para>
            </summary>
            <param name="name"><para><ch>[in] å±žæ€§åç§°</ch></para><para><en>[in] Feature name</en></para></param>
            <param name="info"><para><ch>[out] å±žæ€§ä¿¡æ¯</ch></para><para><en>[out] A pointer to a buffer that receives the feature information</en></para></param>
            <returns><para><ch>错误码, 0-成功, å…¶ä»–-错误码</ch></para><para><en>Error code, 0-success, other-error code</en></para></returns>
        </member>
        <member name="M:EasyIDSDK_Net.EidCamera.eidGetFloatFeatureValue_Net(System.String,System.Double@)">
            <summary>
            <para><ch>获取浮点型属性值</ch></para>
            <para><en>Get float feature value</en></para>
            </summary>
            <param name="name"><para><ch>[in] å±žæ€§åç§°</ch></para><para><en>[in] Feature name</en></para></param>
            <param name="value"><para><ch>[out] å±žæ€§å€¼</ch></para><para><en>[out] Pointer to feature value</en></para></param>
            <returns><para><ch>错误码, 0-成功, å…¶ä»–-错误码</ch></para><para><en>Error code, 0-success, other-error code</en></para></returns>
        </member>
        <member name="M:EasyIDSDK_Net.EidCamera.eidSetFloatFeatureValue_Net(System.String,System.Double)">
            <summary>
            <para><ch>设置浮点型属性值</ch></para>
            <para><en>Set float feature value</en></para>
            </summary>
            <param name="name"><para><ch>[in] å±žæ€§åç§°</ch></para><para><en>[in] Feature name</en></para></param>
            <param name="value"><para><ch>[in] å±žæ€§å€¼</ch></para><para><en>[in] Feature value</en></para></param>
            <returns><para><ch>错误码, 0-成功, å…¶ä»–-错误码</ch></para><para><en>Error code, 0-success, other-error code</en></para></returns>
        </member>
        <member name="M:EasyIDSDK_Net.EidCamera.eidGetFloatFeatureInfo_Net(System.String,EasyIDSDK_Net.EidCamera.EidFloatFeatureInfo@)">
            <summary>
            <para><ch>获取浮点型属性信息</ch></para>
            <para><en>Gets float feature information</en></para>
            </summary>
            <param name="name"><para><ch>[in] å±žæ€§åç§°</ch></para><para><en>[in] Feature name</en></para></param>
            <param name="info"><para><ch>[out] å±žæ€§ä¿¡æ¯</ch></para><para><en>[out] A pointer to a buffer that receives the feature information</en></para></param>
            <returns><para><ch>错误码, 0-成功, å…¶ä»–-错误码</ch></para><para><en>Error code, 0-success, other-error code</en></para></returns>
        </member>
        <member name="M:EasyIDSDK_Net.EidCamera.eidGetBoolFeatureValue_Net(System.String,System.Boolean@)">
            <summary>
            <para><ch>获取布尔型属性值</ch></para>
            <para><en>Get bool feature value</en></para>
            </summary>
            <param name="name"><para><ch>[in] å±žæ€§åç§°</ch></para><para><en>[in] Feature name</en></para></param>
            <param name="value"><para><ch>[out] å±žæ€§å€¼</ch></para><para><en>[out] Pointer to feature value</en></para></param>
            <returns><para><ch>错误码, 0-成功, å…¶ä»–-错误码</ch></para><para><en>Error code, 0-success, other-error code</en></para></returns>
        </member>
        <member name="M:EasyIDSDK_Net.EidCamera.eidSetBoolFeatureValue_Net(System.String,System.Boolean)">
            <summary>
            <para><ch>设置布尔型属性值</ch></para>
            <para><en>Set bool feature value</en></para>
            </summary>
            <param name="name"><para><ch>[in] å±žæ€§åç§°</ch></para><para><en>[in] Feature name</en></para></param>
            <param name="value"><para><ch>[in] å±žæ€§å€¼</ch></para><para><en>[in] Feature value</en></para></param>
            <returns><para><ch>错误码, 0-成功, å…¶ä»–-错误码</ch></para><para><en>Error code, 0-success, other-error code</en></para></returns>
        </member>
        <member name="M:EasyIDSDK_Net.EidCamera.eidGetStringFeatureValue_Net(System.String,System.Byte@,System.UInt32@)">
            <summary>
            <para><ch>获取字符串型属性值</ch></para>
            <para><en>Get string feature value</en></para>
            </summary>
            <param name="name"><para><ch>[in] å±žæ€§åç§°</ch></para><para><en>[in] Feature name</en></para></param>
            <param name="value"><para><ch>[out] å±žæ€§å€¼å­—符串缓冲区, ç”¨æˆ·åˆ†é…å†…存空间</ch></para><para><en>[out] Pointer to string feature value buffer that is allocated memory space by the user</en></para></param>
            <param name="size"><para><ch>[in,out] å±žæ€§å€¼å­—符串缓冲区长度.</ch></para><para><en>[in,out] The length of the string buffer.</en></para></param>
            <returns><para><ch>错误码, 0-成功, å…¶ä»–-错误码</ch></para><para><en>Error code, 0-success, other-error code</en></para></returns>
            <remarks><para><ch>当函数返回时, å¦‚果缓冲区足够大, æ‰€æœ‰çš„æ•°æ®éƒ½ä¼šæ‹·è´åˆ° value ç¼“冲区, å¹¶ä¸”此参数的值是实际字符串的长度(不包含null结束符);
            å¦‚果缓冲区不够大, ç¼“冲区的数据是截断后的字符串内容, å¹¶ä¸”此参数包含字符串的实际长度(不包含null结束符)</ch></para><para><en>When the function returns, if the buffer is large enough,
            all data is copied to the value buffer, and the value of this parameter is the length of the actual string (without the null terminator);
            If the buffer is not large enough, the buffer's data is the truncated string content,
            and this parameter contains the actual length of the string (without the null terminator)</en></para></remarks>
        </member>
        <member name="M:EasyIDSDK_Net.EidCamera.eidSetStringFeatureValue_Net(System.String,System.Byte@)">
            <summary>
            <para><ch>设置字符串型属性值</ch></para>
            <para><en>Set string feature value</en></para>
            </summary>
            <param name="name"><para><ch>[in] å±žæ€§åç§°</ch></para><para><en>[in] Feature name</en></para></param>
            <param name="value"><para><ch>[in] å±žæ€§å€¼</ch></para><para><en>[in] Feature value</en></para></param>
            <returns><para><ch>错误码, 0-成功, å…¶ä»–-错误码</ch></para><para><en>Error code, 0-success, other-error code</en></para></returns>
        </member>
        <member name="M:EasyIDSDK_Net.EidCamera.eidGetStringFeatureInfo_Net(System.String,EasyIDSDK_Net.EidCamera.EidStringFeatureInfo@)">
            <summary>
            <para><ch>获取字符串型属性信息</ch></para>
            <para><en>Gets string feature information</en></para>
            </summary>
            <param name="name"><para><ch>[in] å±žæ€§åç§°</ch></para><para><en>[in] Feature name</en></para></param>
            <param name="info"><para><ch>[out] å±žæ€§ä¿¡æ¯</ch></para><para><en>[out] A pointer to a buffer that receives the feature information</en></para></param>
            <returns><para><ch>错误码, 0-成功, å…¶ä»–-错误码</ch></para><para><en>Error code, 0-success, other-error code</en></para></returns>
        </member>
        <member name="M:EasyIDSDK_Net.EidCamera.eidGetEnumFeatureValue_Net(System.String,System.UInt64@)">
            <summary>
            <para><ch>获取枚举型属性值</ch></para>
            <para><en>Get enum feature value</en></para>
            </summary>
            <param name="name"><para><ch>[in] å±žæ€§åç§°</ch></para><para><en>[in] Feature name</en></para></param>
            <param name="value"><para><ch>[out] å±žæ€§å€¼</ch></para><para><en>[out] Pointer to feature value</en></para></param>
            <returns><para><ch>错误码, 0-成功, å…¶ä»–-错误码</ch></para><para><en>Error code, 0-success, other-error code</en></para></returns>
        </member>
        <member name="M:EasyIDSDK_Net.EidCamera.eidSetEnumFeatureValue_Net(System.String,System.UInt64)">
            <summary>
            <para><ch>设置枚举型属性值</ch></para>
            <para><en>Set enum feature value</en></para>
            </summary>
            <param name="name"><para><ch>[in] å±žæ€§åç§°</ch></para><para><en>[in] Feature name</en></para></param>
            <param name="value"><para><ch>[in] å±žæ€§å€¼</ch></para><para><en>[in] Feature value</en></para></param>
            <returns><para><ch>错误码, 0-成功, å…¶ä»–-错误码</ch></para><para><en>Error code, 0-success, other-error code</en></para></returns>
        </member>
        <member name="M:EasyIDSDK_Net.EidCamera.eidGetEnumFeatureSymbol_Net(System.String,System.Byte@,System.UInt32)">
            <summary>
            <para><ch>获取枚举型属性符号</ch></para>
            <para><en>Get enum feature symbol</en></para>
            </summary>
            <param name="name"><para><ch>[in] å±žæ€§åç§°</ch></para><para><en>[in] Feature name</en></para></param>
            <param name="value"><para><ch>[out] å±žæ€§ç¬¦å·</ch></para><para><en>[out] Pointer to enum feature symbol buffer</en></para></param>
            <param name="size"><para><ch>[in] å±žæ€§ç¬¦å·ç¼“冲长度</ch></para><para><en>[in] The length of symbol buffer</en></para></param>
            <returns><para><ch>错误码, 0-成功, å…¶ä»–-错误码</ch></para><para><en>Error code, 0-success, other-error code</en></para></returns>
        </member>
        <member name="M:EasyIDSDK_Net.EidCamera.eidSetEnumFeatureSymbol_Net(System.String,System.String)">
            <summary>
            <para><ch>设置枚举型属性符号</ch></para>
            <para><en>Set enum feature symbol</en></para>
            </summary>
            <param name="name"><para><ch>[in] å±žæ€§åç§°</ch></para><para><en>[in] Feature name</en></para></param>
            <param name="value"><para><ch>[in] å±žæ€§ç¬¦å·</ch></para><para><en>[in] Feature symbol</en></para></param>
            <returns><para><ch>错误码, 0-成功, å…¶ä»–-错误码</ch></para><para><en>Error code, 0-success, other-error code</en></para></returns>
        </member>
        <member name="M:EasyIDSDK_Net.EidCamera.eidGetEnumFeatureEntryList_Net(System.String,EasyIDSDK_Net.EidCamera.EidEnumFeatureEntryList@)">
            <summary>
            <para><ch>获取枚举型属性条目列表</ch></para>
            <para><en>Get enum feature entry list</en></para>
            </summary>
            <param name="name"><para><ch>[in] å±žæ€§åç§°</ch></para><para><en>[in] Feature name</en></para></param>
            <param name="entryList"><para><ch>[out] æžšä¸¾æ¡ç›®åˆ—表</ch></para><para><en>[out] Pointer to a EidEnumFeatureEntryList structure to receive the enum entry list</en></para></param>
            <returns><para><ch>错误码, 0-成功, å…¶ä»–-错误码</ch></para><para><en>Error code, 0-success, other-error code</en></para></returns>
        </member>
        <member name="M:EasyIDSDK_Net.EidCamera.eidExecCommandFeature_Net(System.String)">
            <summary>
            <para><ch>执行命令行属性</ch></para>
            <para><en>Execute command feature</en></para>
            </summary>
            <param name="name"><para><ch>[in] å±žæ€§åç§°</ch></para><para><en>[in] Feature name</en></para></param>
            <returns><para><ch>错误码, 0-成功, å…¶ä»–-错误码</ch></para><para><en>Error code, 0-success, other-error code</en></para></returns>
        </member>
        <member name="M:EasyIDSDK_Net.EidCamera.eidEnumFeatureChildren_Net(System.String,EasyIDSDK_Net.EidCamera.EidEnumFeatureChildrenCallback,System.IntPtr)">
            <summary>
            <para><ch>枚举子属性</ch></para>
            <para><en>Enum Feature Children</en></para>
            </summary>
            <param name="name"><para><ch>[in] å±žæ€§åç§°</ch></para><para><en>[in] Feature name</en></para></param>
            <param name="fn"><para><ch>[in] å›žè°ƒå‡½æ•°, æ¯ä¸ªå­å±žæ€§éƒ½å°†ä¼šè§¦å‘一次该函数的调用</ch></para><para><en>[in] callback function, each child feature will invoke this method</en></para></param>
            <param name="userData"><para><ch>[in] ç”¨æˆ·æ•°æ®</ch></para><para><en>[in] user data for callback function</en></para></param>
            <returns><para><ch>错误码, 0-成功, å…¶ä»–-错误码</ch></para><para><en>Error code, 0-success, other-error code</en></para></returns>
        </member>
        <member name="M:EasyIDSDK_Net.EidCamera.eidStartGrabbing_Net(System.Int32)">
            <summary>
            <para><ch>开始取流</ch></para>
            <para><en>Start grabbing, then you can get the camera frame through #eidGetFrame</en></para>
            </summary>
            <param name="bufferCount"><para><ch>[in] å¸§ç¼“存数量, 0表示使用默认缓存数, >0使用设置的缓存数</ch></para><para><en>[in] The number of frame buffers, 0 means to use the default number of buffers, >0 to use the set number of buffers</en></para></param>
            <returns><para><ch>错误码, 0-成功, å…¶ä»–-错误码</ch></para><para><en>Error code, 0-success, other-error code</en></para></returns>
        </member>
        <member name="M:EasyIDSDK_Net.EidCamera.eidStopGrabbing_Net">
            <summary>
            <para><ch>停止取流</ch></para>
            <para><en>Stop grabbing</en></para>
            </summary>
            <returns><para><ch>错误码, 0-成功, å…¶ä»–-错误码</ch></para><para><en>Error code, 0-success, other-error code</en></para></returns>
        </member>
        <member name="M:EasyIDSDK_Net.EidCamera.eidIsGrabbing_Net">
            <summary>
            <para><ch>是否正在取流</ch></para>
            <para><en>Check whether it is grabbing or not</en></para>
            </summary>
            <returns><para><ch>如果正在取流, è¿”回true; å¦åˆ™è¿”回false</ch></para><para><en>Returns true if it is grabbing; otherwise returns false</en></para></returns>
        </member>
        <member name="M:EasyIDSDK_Net.EidCamera.eidClearFrameBuffer_Net">
            <summary>
            <para><ch>清除帧数据缓存</ch></para>
            <para><en>clear frame buffer cache</en></para>
            </summary>
            <returns><para><ch>错误码, 0-成功, å…¶ä»–-错误码</ch></para><para><en>Error code, 0-success, other-error code</en></para></returns>
        </member>
        <member name="M:EasyIDSDK_Net.EidCamera.eidGetFrame_Net(System.UInt32)">
            <summary>
            <para><ch>获取一帧图像, è‹¥ç›¸æœºå¼€å¯äº†è¯»ç åŠŸèƒ½, å¸§æ•°æ®ä¸­åŒæ—¶æºå¸¦æ¡ç ä¿¡æ¯.</ch></para>
            <para><en>Get a frame. If the code reading function is enabled, the frame data also carries the barcode information.</en></para>
            </summary>
            <param name="timeout"><para><ch>[in] è¶…æ—¶æ—¶é—´, å•位: æ¯«ç§’. å½“值为-1时表示无限等待</ch></para><para><en>[in] Timeout, in ms, when the value is -1, it means infinite wait</en></para></param>
            <returns><para><ch>帧数据句柄, å¤±è´¥è¿”回 nullptr</ch></para><para><en>Frame handle, failure returns nullptr</en></para></returns>
            <remarks><para><ch>该接口将导致线程阻塞, ç›´åˆ°æ”¶åˆ°å›¾åƒæˆ–者到达超时时间. è¿”回的句柄需要通过 #eidReleaseFrame_Net è¿›è¡Œé‡Šæ”¾</ch></para><para><en>This method will block the thread until the timeout is reached.
             The returned handle needs to be released through #eidReleaseFrame_Net</en></para></remarks>
        </member>
        <member name="M:EasyIDSDK_Net.EidCamera.eidReleaseFrame_Net(System.IntPtr@)">
            <summary>
            <para><ch>释放一帧图像</ch></para>
            <para><en>Release a frame</en></para>
            </summary>
            <param name="frame"><para><ch>帧数据句柄</ch></para><para><en>Frame handle</en></para></param>
        </member>
        <member name="M:EasyIDSDK_Net.EidCamera.eidIsFrameValid_Net(System.IntPtr)">
            <summary>
            <para><ch>帧句柄是否有效</ch></para>
            <para><en>Is the frame handle valid</en></para>
            </summary>
            <param name="frame"><para><ch>[in] å¸§å¥æŸ„</ch></para><para><en>[in] Frame handle</en></para></param>
            <returns><para><ch>true æœ‰æ•ˆ,false æ— æ•ˆ</ch></para><para><en>true Valid,false Not valid</en></para></returns>
        </member>
        <member name="M:EasyIDSDK_Net.EidCamera.eidGetFrameInfo_Net(System.IntPtr,EasyIDSDK_Net.EidCamera.EidFrameInfo@)">
            <summary>
            <para><ch>获取帧信息. å¸§ä¿¡æ¯é‡ŒåŒæ—¶åŒ…含图像数据和条码数据</ch></para>
            <para><en>Get frame information. The frame information contains both image data and barcode data</en></para>
            </summary>
            <param name="frame"><para><ch>[in] å¸§å¥æŸ„</ch></para><para><en>[in] Frame handle</en></para></param>
            <param name="info"><para><ch>[out] å¸§ä¿¡æ¯</ch></para><para><en>[out] Frame information</en></para></param>
            <returns><para><ch>错误码, 0-成功, å…¶ä»–-错误码</ch></para><para><en>Error code, 0-success, other-error code</en></para></returns>
        </member>
        <member name="M:EasyIDSDK_Net.EidCamera.eidRegisterFrameCallback_Net(EasyIDSDK_Net.EidCamera.EidFrameCallback,System.IntPtr)">
            <summary>
            <para><ch>注册帧数据回调</ch></para>
            <para><en>Register frame data callback</en></para>
            </summary>
            <param name="cb"><para><ch>[in] å¸§æ•°æ®å›žè°ƒå‡½æ•°</ch></para><para><en>[in] A pointer to frame data callback function</en></para></param>
            <param name="userData"><para><ch>[in] ç”¨æˆ·æ•°æ®</ch></para><para><en>[in] User data to be passed to callback function</en></para></param>
            <returns><para><ch>错误码, 0-成功, å…¶ä»–-错误码</ch></para><para><en>Error code, 0-success, other-error code</en></para></returns>
        </member>
        <member name="M:EasyIDSDK_Net.EidCamera.eidRegisterConnectionCallback_Net(EasyIDSDK_Net.EidCamera.EidConnectionCallback,System.IntPtr)">
            <summary>
            <para><ch>注册设备连接信息回调</ch></para>
            <para><en>Register device connection information callback</en></para>
            </summary>
            <param name="cb"><para><ch>[in] è¿žæŽ¥ä¿¡æ¯å›žè°ƒå‡½æ•°</ch></para><para><en>[in] A pointer to device connection information callback function</en></para></param>
            <param name="userData"><para><ch>[in] ç”¨æˆ·æ•°æ®</ch></para><para><en>[in] User data to be passed to callback function</en></para></param>
            <returns><para><ch>错误码, 0-成功, å…¶ä»–-错误码</ch></para><para><en>Error code, 0-success, other-error code</en></para></returns>
        </member>
        <member name="M:EasyIDSDK_Net.EidCamera.eidRegisterFeatureUpdateCallback_Net(EasyIDSDK_Net.EidCamera.EidFeatureUpdateCallback,System.IntPtr)">
            <summary>
            <para><ch>注册设备属性更新回调</ch></para>
            <para><en>Register device feature update callback</en></para>
            </summary>
            <param name="cb"><para><ch>[in] å±žæ€§æ›´æ–°å›žè°ƒå‡½æ•°</ch></para><para><en>[in] A pointer to device feature update callback function</en></para></param>
            <param name="userData"><para><ch>[in] ç”¨æˆ·æ•°æ®</ch></para><para><en>[in] User data to be passed to callback function</en></para></param>
            <returns><para><ch>错误码, 0-成功, å…¶ä»–-错误码</ch></para><para><en>Error code, 0-success, other-error code</en></para></returns>
        </member>
        <member name="T:EasyIDSDK_Net.EidCamera.EidFeatureType">
            <summary>
            <para><ch>属性类型</ch></para>
            <para><en>Feature type</en></para>
            </summary>
        </member>
        <member name="F:EasyIDSDK_Net.EidCamera.EidFeatureType.eidFeatureTypeUnknown">
            <summary>
            <para><ch>未定义</ch></para>
            <para><en>Undefined</en></para>
            </summary>
        </member>
        <member name="F:EasyIDSDK_Net.EidCamera.EidFeatureType.eidFeatureTypeInt">
            <summary>
            <para><ch>整型数</ch></para>
            <para><en>Integer</en></para>
            </summary>
        </member>
        <member name="F:EasyIDSDK_Net.EidCamera.EidFeatureType.eidFeatureTypeFloat">
            <summary>
            <para><ch>浮点数</ch></para>
            <para><en>Float</en></para>
            </summary>
        </member>
        <member name="F:EasyIDSDK_Net.EidCamera.EidFeatureType.eidFeatureTypeEnum">
            <summary>
            <para><ch>枚举</ch></para>
            <para><en>Enumeration</en></para>
            </summary>
        </member>
        <member name="F:EasyIDSDK_Net.EidCamera.EidFeatureType.eidFeatureTypeBool">
            <summary>
            <para><ch>布尔</ch></para>
            <para><en>Bool</en></para>
            </summary>
        </member>
        <member name="F:EasyIDSDK_Net.EidCamera.EidFeatureType.eidFeatureTypeString">
            <summary>
            <para><ch>字符串</ch></para>
            <para><en>String</en></para>
            </summary>
        </member>
        <member name="F:EasyIDSDK_Net.EidCamera.EidFeatureType.eidFeatureTypeCommand">
            <summary>
            <para><ch>命令</ch></para>
            <para><en>Command</en></para>
            </summary>
        </member>
        <member name="F:EasyIDSDK_Net.EidCamera.EidFeatureType.eidFeatureTypeGroup">
            <summary>
            <para><ch>分组</ch></para>
            <para><en>Group</en></para>
            </summary>
        </member>
        <member name="T:EasyIDSDK_Net.EidCamera.EidInterfaceType">
            <summary>
            <para><ch>接口类型</ch></para>
            <para><en>Interface type</en></para>
            </summary>
        </member>
        <member name="F:EasyIDSDK_Net.EidCamera.EidInterfaceType.eidInterfaceTypeUnknown">
            <summary>
            <para><ch>未知接口类型</ch></para>
            <para><en>Unknown interface type</en></para>
            </summary>
        </member>
        <member name="F:EasyIDSDK_Net.EidCamera.EidInterfaceType.eidInterfaceTypeGige">
            <summary>
            <para><ch>网卡接口类型</ch></para>
            <para><en>NIC type</en></para>
            </summary>
        </member>
        <member name="F:EasyIDSDK_Net.EidCamera.EidInterfaceType.eidInterfaceTypeUsb">
            <summary>
            <para><ch>USB接口类型</ch></para>
            <para><en>USB interface type</en></para>
            </summary>
        </member>
        <member name="F:EasyIDSDK_Net.EidCamera.EidInterfaceType.eidInterfaceTypeAll">
            <summary>
            <para><ch>所有接口类型</ch></para>
            <para><en>All interface type</en></para>
            </summary>
        </member>
        <member name="T:EasyIDSDK_Net.EidCamera.EidDeviceType">
            <summary>
            <para><ch>设备类型</ch></para>
            <para><en>Device type</en></para>
            </summary>
        </member>
        <member name="F:EasyIDSDK_Net.EidCamera.EidDeviceType.eidDeviceTypeUnknown">
            <summary>
            <para><ch>未知类型</ch></para>
            <para><en>Unknown type</en></para>
            </summary>
        </member>
        <member name="F:EasyIDSDK_Net.EidCamera.EidDeviceType.eidDeviceTypeGige">
            <summary>
            <para><ch>GIGE相机</ch></para>
            <para><en>GigE Camera</en></para>
            </summary>
        </member>
        <member name="F:EasyIDSDK_Net.EidCamera.EidDeviceType.eidDeviceTypeUSB">
            <summary>
            <para><ch>USB相机</ch></para>
            <para><en>USB Camera</en></para>
            </summary>
        </member>
        <member name="T:EasyIDSDK_Net.EidCamera.EidDeviceDataType">
            <summary>
            <para><ch>设备数据类型, ç”¨äºŽ #eidCreateDevice å‡½æ•°</ch></para>
            <para><en>Device data type, used in the #eidCreateDevice function</en></para>
            </summary>
        </member>
        <member name="F:EasyIDSDK_Net.EidCamera.EidDeviceDataType.eidDeviceDataTypeID">
            <summary>
            <para><ch>设备ID</ch></para>
            <para><en>Device ID</en></para>
            </summary>
        </member>
        <member name="F:EasyIDSDK_Net.EidCamera.EidDeviceDataType.eidDeviceDataTypeSN">
            <summary>
            <para><ch>序列号</ch></para>
            <para><en>Serial number</en></para>
            </summary>
        </member>
        <member name="F:EasyIDSDK_Net.EidCamera.EidDeviceDataType.eidDeviceDataTypeIP">
            <summary>
            <para><ch>IP地址</ch></para>
            <para><en>IP address</en></para>
            </summary>
        </member>
        <member name="F:EasyIDSDK_Net.EidCamera.EidDeviceDataType.eidDeviceDataTypeMAC">
            <summary>
            <para><ch>MAC地址</ch></para>
            <para><en>MAC address</en></para>
            </summary>
        </member>
        <member name="T:EasyIDSDK_Net.EidCamera.EidPixelFormat">
            <summary>
            <para><ch>图像像素格式</ch></para>
            <para><en>Image pixel format</en></para>
            </summary>
        </member>
        <member name="F:EasyIDSDK_Net.EidCamera.EidPixelFormat.eidPixelUnknwon">
            <summary>
            <para><ch>未知</ch></para>
            <para><en>Unknown</en></para>
            </summary>
        </member>
        <member name="F:EasyIDSDK_Net.EidCamera.EidPixelFormat.eidPixelMono1p">
            <summary>
            <para><ch>Mono1p</ch></para>
            <para><en>Mono1p</en></para>
            </summary>
        </member>
        <member name="F:EasyIDSDK_Net.EidCamera.EidPixelFormat.eidPixelMono2p">
            <summary>
            <para><ch>Mono2p</ch></para>
            <para><en>Mono2p</en></para>
            </summary>
        </member>
        <member name="F:EasyIDSDK_Net.EidCamera.EidPixelFormat.eidPixelMono4p">
            <summary>
            <para><ch>Mono4p</ch></para>
            <para><en>Mono4p</en></para>
            </summary>
        </member>
        <member name="F:EasyIDSDK_Net.EidCamera.EidPixelFormat.eidPixelMono8">
            <summary>
            <para><ch>Mono8</ch></para>
            <para><en>Mono8</en></para>
            </summary>
        </member>
        <member name="F:EasyIDSDK_Net.EidCamera.EidPixelFormat.eidPixelMono8S">
            <summary>
            <para><ch>Mono8S</ch></para>
            <para><en>Mono8S</en></para>
            </summary>
        </member>
        <member name="F:EasyIDSDK_Net.EidCamera.EidPixelFormat.eidPixelMono10">
            <summary>
            <para><ch>Mono10</ch></para>
            <para><en>Mono10</en></para>
            </summary>
        </member>
        <member name="F:EasyIDSDK_Net.EidCamera.EidPixelFormat.eidPixelMono10Packed">
            <summary>
            <para><ch>Mono10Packed</ch></para>
            <para><en>Mono10Packed</en></para>
            </summary>
        </member>
        <member name="F:EasyIDSDK_Net.EidCamera.EidPixelFormat.eidPixelMono12">
            <summary>
            <para><ch>Mono12</ch></para>
            <para><en>Mono12</en></para>
            </summary>
        </member>
        <member name="F:EasyIDSDK_Net.EidCamera.EidPixelFormat.eidPixelMono12Packed">
            <summary>
            <para><ch>Mono12Packed</ch></para>
            <para><en>Mono12Packed</en></para>
            </summary>
        </member>
        <member name="F:EasyIDSDK_Net.EidCamera.EidPixelFormat.eidPixelMono14">
            <summary>
            <para><ch>Mono14</ch></para>
            <para><en>Mono14</en></para>
            </summary>
        </member>
        <member name="F:EasyIDSDK_Net.EidCamera.EidPixelFormat.eidPixelMono16">
            <summary>
            <para><ch>Mono16</ch></para>
            <para><en>Mono16</en></para>
            </summary>
        </member>
        <member name="F:EasyIDSDK_Net.EidCamera.EidPixelFormat.eidPixelBayGR8">
            <summary>
            <para><ch>BayGR8</ch></para>
            <para><en>BayGR8</en></para>
            </summary>
        </member>
        <member name="F:EasyIDSDK_Net.EidCamera.EidPixelFormat.eidPixelBayRG8">
            <summary>
            <para><ch>BayRG8</ch></para>
            <para><en>BayRG8</en></para>
            </summary>
        </member>
        <member name="F:EasyIDSDK_Net.EidCamera.EidPixelFormat.eidPixelBayGB8">
            <summary>
            <para><ch>BayGB8</ch></para>
            <para><en>BayGB8</en></para>
            </summary>
        </member>
        <member name="F:EasyIDSDK_Net.EidCamera.EidPixelFormat.eidPixelBayBG8">
            <summary>
            <para><ch>BayBG8</ch></para>
            <para><en>BayBG8</en></para>
            </summary>
        </member>
        <member name="F:EasyIDSDK_Net.EidCamera.EidPixelFormat.eidPixelBayGR10">
            <summary>
            <para><ch>BayGR10</ch></para>
            <para><en>BayGR10</en></para>
            </summary>
        </member>
        <member name="F:EasyIDSDK_Net.EidCamera.EidPixelFormat.eidPixelBayRG10">
            <summary>
            <para><ch>BayRG10</ch></para>
            <para><en>BayRG10</en></para>
            </summary>
        </member>
        <member name="F:EasyIDSDK_Net.EidCamera.EidPixelFormat.eidPixelBayGB10">
            <summary>
            <para><ch>BayGB10</ch></para>
            <para><en>BayGB10</en></para>
            </summary>
        </member>
        <member name="F:EasyIDSDK_Net.EidCamera.EidPixelFormat.eidPixelBayBG10">
            <summary>
            <para><ch>BayBG10</ch></para>
            <para><en>BayBG10</en></para>
            </summary>
        </member>
        <member name="F:EasyIDSDK_Net.EidCamera.EidPixelFormat.eidPixelBayGR12">
            <summary>
            <para><ch>BayGR12</ch></para>
            <para><en>BayGR12</en></para>
            </summary>
        </member>
        <member name="F:EasyIDSDK_Net.EidCamera.EidPixelFormat.eidPixelBayRG12">
            <summary>
            <para><ch>BayRG12</ch></para>
            <para><en>BayRG12</en></para>
            </summary>
        </member>
        <member name="F:EasyIDSDK_Net.EidCamera.EidPixelFormat.eidPixelBayGB12">
            <summary>
            <para><ch>BayGB12</ch></para>
            <para><en>BayGB12</en></para>
            </summary>
        </member>
        <member name="F:EasyIDSDK_Net.EidCamera.EidPixelFormat.eidPixelBayBG12">
            <summary>
            <para><ch>BayBG12</ch></para>
            <para><en>BayBG12</en></para>
            </summary>
        </member>
        <member name="F:EasyIDSDK_Net.EidCamera.EidPixelFormat.eidPixelBayGR10Packed">
            <summary>
            <para><ch>BayGR10Packed</ch></para>
            <para><en>BayGR10Packed</en></para>
            </summary>
        </member>
        <member name="F:EasyIDSDK_Net.EidCamera.EidPixelFormat.eidPixelBayRG10Packed">
            <summary>
            <para><ch>BayRG10Packed</ch></para>
            <para><en>BayRG10Packed</en></para>
            </summary>
        </member>
        <member name="F:EasyIDSDK_Net.EidCamera.EidPixelFormat.eidPixelBayGB10Packed">
            <summary>
            <para><ch>BayGB10Packed</ch></para>
            <para><en>BayGB10Packed</en></para>
            </summary>
        </member>
        <member name="F:EasyIDSDK_Net.EidCamera.EidPixelFormat.eidPixelBayBG10Packed">
            <summary>
            <para><ch>BayBG10Packed</ch></para>
            <para><en>BayBG10Packed</en></para>
            </summary>
        </member>
        <member name="F:EasyIDSDK_Net.EidCamera.EidPixelFormat.eidPixelBayGR12Packed">
            <summary>
            <para><ch>BayGR12Packed</ch></para>
            <para><en>BayGR12Packed</en></para>
            </summary>
        </member>
        <member name="F:EasyIDSDK_Net.EidCamera.EidPixelFormat.eidPixelBayRG12Packed">
            <summary>
            <para><ch>BayRG12Packed</ch></para>
            <para><en>BayRG12Packed</en></para>
            </summary>
        </member>
        <member name="F:EasyIDSDK_Net.EidCamera.EidPixelFormat.eidPixelBayGB12Packed">
            <summary>
            <para><ch>BayGB12Packed</ch></para>
            <para><en>BayGB12Packed</en></para>
            </summary>
        </member>
        <member name="F:EasyIDSDK_Net.EidCamera.EidPixelFormat.eidPixelBayBG12Packed">
            <summary>
            <para><ch>BayBG12Packed</ch></para>
            <para><en>BayBG12Packed</en></para>
            </summary>
        </member>
        <member name="F:EasyIDSDK_Net.EidCamera.EidPixelFormat.eidPixelBayGR16">
            <summary>
            <para><ch>BayGR16</ch></para>
            <para><en>BayGR16</en></para>
            </summary>
        </member>
        <member name="F:EasyIDSDK_Net.EidCamera.EidPixelFormat.eidPixelBayRG16">
            <summary>
            <para><ch>BayRG16</ch></para>
            <para><en>BayRG16</en></para>
            </summary>
        </member>
        <member name="F:EasyIDSDK_Net.EidCamera.EidPixelFormat.eidPixelBayGB16">
            <summary>
            <para><ch>BayGB16</ch></para>
            <para><en>BayGB16</en></para>
            </summary>
        </member>
        <member name="F:EasyIDSDK_Net.EidCamera.EidPixelFormat.eidPixelBayBG16">
            <summary>
            <para><ch>BayBG16</ch></para>
            <para><en>BayBG16</en></para>
            </summary>
        </member>
        <member name="F:EasyIDSDK_Net.EidCamera.EidPixelFormat.eidPixelRGB8">
            <summary>
            <para><ch>RGB8</ch></para>
            <para><en>RGB8</en></para>
            </summary>
        </member>
        <member name="F:EasyIDSDK_Net.EidCamera.EidPixelFormat.eidPixelBGR8">
            <summary>
            <para><ch>BGR8</ch></para>
            <para><en>BGR8</en></para>
            </summary>
        </member>
        <member name="F:EasyIDSDK_Net.EidCamera.EidPixelFormat.eidPixelRGBA8">
            <summary>
            <para><ch>RGBA8</ch></para>
            <para><en>RGBA8</en></para>
            </summary>
        </member>
        <member name="F:EasyIDSDK_Net.EidCamera.EidPixelFormat.eidPixelBGRA8">
            <summary>
            <para><ch>BGRA8</ch></para>
            <para><en>BGRA8</en></para>
            </summary>
        </member>
        <member name="F:EasyIDSDK_Net.EidCamera.EidPixelFormat.eidPixelRGB10">
            <summary>
            <para><ch>RGB10</ch></para>
            <para><en>RGB10</en></para>
            </summary>
        </member>
        <member name="F:EasyIDSDK_Net.EidCamera.EidPixelFormat.eidPixelBGR10">
            <summary>
            <para><ch>BGR10</ch></para>
            <para><en>BGR10</en></para>
            </summary>
        </member>
        <member name="F:EasyIDSDK_Net.EidCamera.EidPixelFormat.eidPixelRGB12">
            <summary>
            <para><ch>RGB12</ch></para>
            <para><en>RGB12</en></para>
            </summary>
        </member>
        <member name="F:EasyIDSDK_Net.EidCamera.EidPixelFormat.eidPixelBGR12">
            <summary>
            <para><ch>BGR12</ch></para>
            <para><en>BGR12</en></para>
            </summary>
        </member>
        <member name="F:EasyIDSDK_Net.EidCamera.EidPixelFormat.eidPixelRGB16">
            <summary>
            <para><ch>RGB16</ch></para>
            <para><en>RGB16</en></para>
            </summary>
        </member>
        <member name="F:EasyIDSDK_Net.EidCamera.EidPixelFormat.eidPixelRGB10V1Packed">
            <summary>
            <para><ch>RGB10V1Packed</ch></para>
            <para><en>RGB10V1Packed</en></para>
            </summary>
        </member>
        <member name="F:EasyIDSDK_Net.EidCamera.EidPixelFormat.eidPixelRGB10P32">
            <summary>
            <para><ch>RGB10P32</ch></para>
            <para><en>RGB10P32</en></para>
            </summary>
        </member>
        <member name="F:EasyIDSDK_Net.EidCamera.EidPixelFormat.eidPixelRGB12V1Packed">
            <summary>
            <para><ch>RGB12V1Packed</ch></para>
            <para><en>RGB12V1Packed</en></para>
            </summary>
        </member>
        <member name="F:EasyIDSDK_Net.EidCamera.EidPixelFormat.eidPixelRGB565P">
            <summary>
            <para><ch>RGB565P</ch></para>
            <para><en>RGB565P</en></para>
            </summary>
        </member>
        <member name="F:EasyIDSDK_Net.EidCamera.EidPixelFormat.eidPixelBGR565P">
            <summary>
            <para><ch>BGR565P</ch></para>
            <para><en>BGR565P</en></para>
            </summary>
        </member>
        <member name="F:EasyIDSDK_Net.EidCamera.EidPixelFormat.eidPixelYUV411_8_UYYVYY">
            <summary>
            <para><ch>YUV411_8_UYYVYY</ch></para>
            <para><en>YUV411_8_UYYVYY</en></para>
            </summary>
        </member>
        <member name="F:EasyIDSDK_Net.EidCamera.EidPixelFormat.eidPixelYUV422_8_UYVY">
            <summary>
            <para><ch>YUV422_8_UYVY</ch></para>
            <para><en>YUV422_8_UYVY</en></para>
            </summary>
        </member>
        <member name="F:EasyIDSDK_Net.EidCamera.EidPixelFormat.eidPixelYUV422_8">
            <summary>
            <para><ch>YUV422_8 </ch></para>
            <para><en>YUV422_8 </en></para>
            </summary>
        </member>
        <member name="F:EasyIDSDK_Net.EidCamera.EidPixelFormat.eidPixelYUV8_UYV">
            <summary>
            <para><ch>YUV8_UYV</ch></para>
            <para><en>YUV8_UYV</en></para>
            </summary>
        </member>
        <member name="F:EasyIDSDK_Net.EidCamera.EidPixelFormat.eidPixelYCbCr8CbYCr">
            <summary>
            <para><ch>YCbCr8CbYCr</ch></para>
            <para><en>YCbCr8CbYCr</en></para>
            </summary>
        </member>
        <member name="F:EasyIDSDK_Net.EidCamera.EidPixelFormat.eidPixelYCbCr422_8">
            <summary>
            <para><ch>YCbCr422_8</ch></para>
            <para><en>YCbCr422_8</en></para>
            </summary>
        </member>
        <member name="F:EasyIDSDK_Net.EidCamera.EidPixelFormat.eidPixelYCbCr422_8_CbYCrY">
            <summary>
            <para><ch>YCbCr422_8_CbYCrY</ch></para>
            <para><en>YCbCr422_8_CbYCrY</en></para>
            </summary>
        </member>
        <member name="F:EasyIDSDK_Net.EidCamera.EidPixelFormat.eidPixelYCbCr411_8_CbYYCrYY">
            <summary>
            <para><ch>YCbCr411_8_CbYYCrYY</ch></para>
            <para><en>YCbCr411_8_CbYYCrYY</en></para>
            </summary>
        </member>
        <member name="F:EasyIDSDK_Net.EidCamera.EidPixelFormat.eidPixelYCbCr601_8_CbYCr">
            <summary>
            <para><ch>YCbCr601_8_CbYCr</ch></para>
            <para><en>YCbCr601_8_CbYCr</en></para>
            </summary>
        </member>
        <member name="F:EasyIDSDK_Net.EidCamera.EidPixelFormat.eidPixelYCbCr601_422_8">
            <summary>
            <para><ch>YCbCr601_422_8</ch></para>
            <para><en>YCbCr601_422_8</en></para>
            </summary>
        </member>
        <member name="F:EasyIDSDK_Net.EidCamera.EidPixelFormat.eidPixelYCbCr601_422_8_CbYCrY">
            <summary>
            <para><ch>YCbCr601_422_8_CbYCrY</ch></para>
            <para><en>YCbCr601_422_8_CbYCrY</en></para>
            </summary>
        </member>
        <member name="F:EasyIDSDK_Net.EidCamera.EidPixelFormat.eidPixelYCbCr601_411_8_CbYYCrYY">
            <summary>
            <para><ch>YCbCr601_411_8_CbYYCrYY</ch></para>
            <para><en>YCbCr601_411_8_CbYYCrYY</en></para>
            </summary>
        </member>
        <member name="F:EasyIDSDK_Net.EidCamera.EidPixelFormat.eidPixelYCbCr709_8_CbYCr">
            <summary>
            <para><ch>YCbCr709_8_CbYCr</ch></para>
            <para><en>YCbCr709_8_CbYCr</en></para>
            </summary>
        </member>
        <member name="F:EasyIDSDK_Net.EidCamera.EidPixelFormat.eidPixelYCbCr709_422_8">
            <summary>
            <para><ch>YCbCr709_422_8</ch></para>
            <para><en>YCbCr709_422_8</en></para>
            </summary>
        </member>
        <member name="F:EasyIDSDK_Net.EidCamera.EidPixelFormat.eidPixelYCbCr709_422_8_CbYCrY">
            <summary>
            <para><ch>YCbCr709_422_8_CbYCrY</ch></para>
            <para><en>YCbCr709_422_8_CbYCrY</en></para>
            </summary>
        </member>
        <member name="F:EasyIDSDK_Net.EidCamera.EidPixelFormat.eidPixelYCbCr709_411_8_CbYYCrYY">
            <summary>
            <para><ch>YCbCr709_411_8_CbYYCrYY</ch></para>
            <para><en>YCbCr709_411_8_CbYYCrYY</en></para>
            </summary>
        </member>
        <member name="F:EasyIDSDK_Net.EidCamera.EidPixelFormat.eidPixelRGB8Planar">
            <summary>
            <para><ch>RGB8Planar</ch></para>
            <para><en>RGB8Planar</en></para>
            </summary>
        </member>
        <member name="F:EasyIDSDK_Net.EidCamera.EidPixelFormat.eidPixelRGB10Planar">
            <summary>
            <para><ch>RGB10Planar</ch></para>
            <para><en>RGB10Planar</en></para>
            </summary>
        </member>
        <member name="F:EasyIDSDK_Net.EidCamera.EidPixelFormat.eidPixelRGB12Planar">
            <summary>
            <para><ch>RGB12Planar</ch></para>
            <para><en>RGB12Planar</en></para>
            </summary>
        </member>
        <member name="F:EasyIDSDK_Net.EidCamera.EidPixelFormat.eidPixelRGB16Planar">
            <summary>
            <para><ch>RGB16Planar</ch></para>
            <para><en>RGB16Planar</en></para>
            </summary>
        </member>
        <member name="T:EasyIDSDK_Net.EidCamera.EidReadState">
            <summary>
            <para><ch>读码状态</ch></para>
            <para><en>Code reading state</en></para>
            </summary>
        </member>
        <member name="F:EasyIDSDK_Net.EidCamera.EidReadState.eidReadStateUnknown">
            <summary>
            <para><ch>未知</ch></para>
            <para><en>Unknown</en></para>
            </summary>
        </member>
        <member name="F:EasyIDSDK_Net.EidCamera.EidReadState.eidReadStateNA">
            <summary>
            <para><ch>无效</ch></para>
            <para><en>Not available</en></para>
            </summary>
        </member>
        <member name="F:EasyIDSDK_Net.EidCamera.EidReadState.eidReadStateComplete">
            <summary>
            <para><ch>全部</ch></para>
            <para><en>Complete</en></para>
            </summary>
        </member>
        <member name="F:EasyIDSDK_Net.EidCamera.EidReadState.eidReadStateNoRead">
            <summary>
            <para><ch>无条码</ch></para>
            <para><en>No code was read</en></para>
            </summary>
        </member>
        <member name="F:EasyIDSDK_Net.EidCamera.EidReadState.eidReadStatePartial">
            <summary>
            <para><ch>部分</ch></para>
            <para><en>Partial</en></para>
            </summary>
        </member>
        <member name="F:EasyIDSDK_Net.EidCamera.EidReadState.eidReadStateFail">
            <summary>
            <para><ch>失败</ch></para>
            <para><en>Fail</en></para>
            </summary>
        </member>
        <member name="F:EasyIDSDK_Net.EidCamera.EidReadState.eidReadStatePhaseNA">
            <summary>
            <para><ch>无效(Phase模式)</ch></para>
            <para><en>Not available(Phase mode)</en></para>
            </summary>
        </member>
        <member name="F:EasyIDSDK_Net.EidCamera.EidReadState.eidReadStatePhaseComplete">
            <summary>
            <para><ch>全部(Phase模式)</ch></para>
            <para><en>Complete(Phase mode)</en></para>
            </summary>
        </member>
        <member name="F:EasyIDSDK_Net.EidCamera.EidReadState.eidReadStatePhaseNoRead">
            <summary>
            <para><ch>无条码(Phase模式)</ch></para>
            <para><en>No code was read(Phase mode)</en></para>
            </summary>
        </member>
        <member name="F:EasyIDSDK_Net.EidCamera.EidReadState.eidReadStatePhasePartial">
            <summary>
            <para><ch>部分(Phase模式)</ch></para>
            <para><en>Partial(Phase mode)</en></para>
            </summary>
        </member>
        <member name="F:EasyIDSDK_Net.EidCamera.EidReadState.eidReadStatePhaseFail">
            <summary>
            <para><ch>失败(Phase模式)</ch></para>
            <para><en>Fail(Phase mode)</en></para>
            </summary>
        </member>
        <member name="T:EasyIDSDK_Net.EidCamera.EidBarcodeType">
            <summary>
            <para><ch>码类型</ch></para>
            <para><en>Barcode type</en></para>
            </summary>
        </member>
        <member name="F:EasyIDSDK_Net.EidCamera.EidBarcodeType.eidCodeTypeUnknown">
            <summary>
            <para><ch>未知</ch></para>
            <para><en>Unknown</en></para>
            </summary>
        </member>
        <member name="F:EasyIDSDK_Net.EidCamera.EidBarcodeType.eidCodeTypeEAN8">
            <summary>
            <para><ch>EAN8</ch></para>
            <para><en>EAN8</en></para>
            </summary>
        </member>
        <member name="F:EasyIDSDK_Net.EidCamera.EidBarcodeType.eidCodeTypeEAN13">
            <summary>
            <para><ch>EAN13</ch></para>
            <para><en>EAN13 type</en></para>
            </summary>
        </member>
        <member name="F:EasyIDSDK_Net.EidCamera.EidBarcodeType.eidCodeTypeCode39">
            <summary>
            <para><ch>Code39</ch></para>
            <para><en>Code39</en></para>
            </summary>
        </member>
        <member name="F:EasyIDSDK_Net.EidCamera.EidBarcodeType.eidCodeTypeCode93">
            <summary>
            <para><ch>Code93</ch></para>
            <para><en>Code93</en></para>
            </summary>
        </member>
        <member name="F:EasyIDSDK_Net.EidCamera.EidBarcodeType.eidCodeTypeCode128">
            <summary>
            <para><ch>Code128</ch></para>
            <para><en>Code128</en></para>
            </summary>
        </member>
        <member name="F:EasyIDSDK_Net.EidCamera.EidBarcodeType.eidCodeTypeUPCA">
            <summary>
            <para><ch>UPCA</ch></para>
            <para><en>UPCA</en></para>
            </summary>
        </member>
        <member name="F:EasyIDSDK_Net.EidCamera.EidBarcodeType.eidCodeTypeUPCE">
            <summary>
            <para><ch>UPCE</ch></para>
            <para><en>UPCE</en></para>
            </summary>
        </member>
        <member name="F:EasyIDSDK_Net.EidCamera.EidBarcodeType.eidCodeTypeITF25">
            <summary>
            <para><ch>ITF25</ch></para>
            <para><en>ITF25</en></para>
            </summary>
        </member>
        <member name="F:EasyIDSDK_Net.EidCamera.EidBarcodeType.eidCodeTypeCODABAR">
            <summary>
            <para><ch>CODABAR</ch></para>
            <para><en>CODABAR</en></para>
            </summary>
        </member>
        <member name="F:EasyIDSDK_Net.EidCamera.EidBarcodeType.eidCodeTypeCODE128A">
            <summary>
            <para><ch>CODE128A</ch></para>
            <para><en>CODE128A</en></para>
            </summary>
        </member>
        <member name="F:EasyIDSDK_Net.EidCamera.EidBarcodeType.eidCodeTypeCODE128B">
            <summary>
            <para><ch>CODE128B</ch></para>
            <para><en>CODE128B</en></para>
            </summary>
        </member>
        <member name="F:EasyIDSDK_Net.EidCamera.EidBarcodeType.eidCodeTypeCODE128C">
            <summary>
            <para><ch>CODE128C</ch></para>
            <para><en>CODE128C</en></para>
            </summary>
        </member>
        <member name="F:EasyIDSDK_Net.EidCamera.EidBarcodeType.eidCodeTypeQR">
            <summary>
            <para><ch>QR</ch></para>
            <para><en>QR</en></para>
            </summary>
        </member>
        <member name="F:EasyIDSDK_Net.EidCamera.EidBarcodeType.eidCodeTypeDM">
            <summary>
            <para><ch>DM</ch></para>
            <para><en>DM</en></para>
            </summary>
        </member>
        <member name="F:EasyIDSDK_Net.EidCamera.EidBarcodeType.eidCodeTypePDF417">
            <summary>
            <para><ch>PDF417</ch></para>
            <para><en>PDF417</en></para>
            </summary>
        </member>
        <member name="F:EasyIDSDK_Net.EidCamera.EidBarcodeType.eidCodeTypeVERICODE">
            <summary>
            <para><ch>VERICODE</ch></para>
            <para><en>VERICODE</en></para>
            </summary>
        </member>
        <member name="T:EasyIDSDK_Net.EidCamera.EidConnectionState">
            <summary>
            <para><ch>连接事件类型</ch></para>
            <para><en>Connect event type</en></para>
            </summary>
        </member>
        <member name="F:EasyIDSDK_Net.EidCamera.EidConnectionState.eidConnStateOffline">
            <summary>
            <para><ch>离线</ch></para>
            <para><en>Offline</en></para>
            </summary>
        </member>
        <member name="F:EasyIDSDK_Net.EidCamera.EidConnectionState.eidConnStateOnline">
            <summary>
            <para><ch>在线</ch></para>
            <para><en>Online</en></para>
            </summary>
        </member>
        <member name="T:EasyIDSDK_Net.EidCamera.EidGigeDeviceInfo">
            <summary>
            <para><ch>GigE设备信息</ch></para>
            <para><en>GigE device info</en></para>
            </summary>
        </member>
        <member name="F:EasyIDSDK_Net.EidCamera.EidGigeDeviceInfo.macAddress">
            <summary>
            <para><ch>设备Mac地址</ch></para>
            <para><en>Device MAC Address</en></para>
            </summary>
        </member>
        <member name="F:EasyIDSDK_Net.EidCamera.EidGigeDeviceInfo.ipAddress">
            <summary>
            <para><ch>设备Ip地址</ch></para>
            <para><en>Device ip Address</en></para>
            </summary>
        </member>
        <member name="F:EasyIDSDK_Net.EidCamera.EidGigeDeviceInfo.subnetMask">
            <summary>
            <para><ch>子网掩码</ch></para>
            <para><en>SubnetMask</en></para>
            </summary>
        </member>
        <member name="F:EasyIDSDK_Net.EidCamera.EidGigeDeviceInfo.defaultGateWay">
            <summary>
            <para><ch>默认网关</ch></para>
            <para><en>Default GateWay</en></para>
            </summary>
        </member>
        <member name="F:EasyIDSDK_Net.EidCamera.EidGigeDeviceInfo.isIpValid">
            <summary>
            <para><ch>Ip是否有效</ch></para>
            <para><en>Ip valid</en></para>
            </summary>
        </member>
        <member name="F:EasyIDSDK_Net.EidCamera.EidGigeDeviceInfo.chReserved">
            <summary>
            <para><ch>保留</ch></para>
            <para><en>Reserved field</en></para>
            </summary>
        </member>
        <member name="T:EasyIDSDK_Net.EidCamera.EidDeviceInfo">
            <summary>
            <para><ch>设备信息</ch></para>
            <para><en>Device info</en></para>
            </summary>
        </member>
        <member name="F:EasyIDSDK_Net.EidCamera.EidDeviceInfo.deviceType">
            <summary>
            <para><ch>设备类别</ch></para>
            <para><en>Device type</en></para>
            </summary>
        </member>
        <member name="F:EasyIDSDK_Net.EidCamera.EidDeviceInfo.interfaceType">
            <summary>
            <para><ch>接口类别</ch></para>
            <para><en>Interface type</en></para>
            </summary>
        </member>
        <member name="F:EasyIDSDK_Net.EidCamera.EidDeviceInfo.deviceID">
            <summary>
            <para><ch>设备ID</ch></para>
            <para><en>Device ID</en></para>
            </summary>
        </member>
        <member name="F:EasyIDSDK_Net.EidCamera.EidDeviceInfo.cameraName">
            <summary>
            <para><ch>用户自定义名</ch></para>
            <para><en>User defined name</en></para>
            </summary>
        </member>
        <member name="F:EasyIDSDK_Net.EidCamera.EidDeviceInfo.serialNumber">
            <summary>
            <para><ch>设备序列号</ch></para>
            <para><en>Device serial number</en></para>
            </summary>
        </member>
        <member name="F:EasyIDSDK_Net.EidCamera.EidDeviceInfo.vendorName">
            <summary>
            <para><ch>厂商</ch></para>
            <para><en>Device vendor</en></para>
            </summary>
        </member>
        <member name="F:EasyIDSDK_Net.EidCamera.EidDeviceInfo.modelName">
            <summary>
            <para><ch>设备型号</ch></para>
            <para><en>Device model</en></para>
            </summary>
        </member>
        <member name="F:EasyIDSDK_Net.EidCamera.EidDeviceInfo.manufactureInfo">
            <summary>
            <para><ch>设备制造信息</ch></para>
            <para><en>Device manufacture</en></para>
            </summary>
        </member>
        <member name="F:EasyIDSDK_Net.EidCamera.EidDeviceInfo.deviceVersion">
            <summary>
            <para><ch>设备版本</ch></para>
            <para><en>Device version</en></para>
            </summary>
        </member>
        <member name="F:EasyIDSDK_Net.EidCamera.EidDeviceInfo.interfaceName">
            <summary>
            <para><ch>接口名</ch></para>
            <para><en>Interface name</en></para>
            </summary>
        </member>
        <member name="F:EasyIDSDK_Net.EidCamera.EidDeviceInfo.reserved">
            <summary>
            <para><ch>预留位</ch></para>
            <para><en>Reseved</en></para>
            </summary>
        </member>
        <member name="F:EasyIDSDK_Net.EidCamera.EidDeviceInfo.stSpecialInfo">
            <summary>
            <para><ch>具体设备信息</ch></para>
            <para><en>special device Info</en></para>
            </summary>
        </member>
        <member name="T:EasyIDSDK_Net.EidCamera.EidDeviceInfo.SPECIAL_INFO">
            <summary>
            <para><ch>具体设备信息</ch></para>
            <para><en>special device Info</en></para>
            </summary>
        </member>
        <member name="F:EasyIDSDK_Net.EidCamera.EidDeviceInfo.SPECIAL_INFO.gigeDeviceInfo">
            <summary>
            <para><ch>Gige设备信息</ch></para>
            <para><en>Gige device info</en></para>
            </summary>
        </member>
        <member name="T:EasyIDSDK_Net.EidCamera.EidDeviceList">
            <summary>
            <para><ch>设备信息列表</ch></para>
            <para><en>Device information list</en></para>
            </summary>
        </member>
        <member name="F:EasyIDSDK_Net.EidCamera.EidDeviceList.num">
            <summary>
            <para><ch>设备数量</ch></para>
            <para><en>Device Number</en></para>
            </summary>
        </member>
        <member name="F:EasyIDSDK_Net.EidCamera.EidDeviceList.infos">
            <summary>
            <para><ch>设备信息列表</ch></para>
            <para><en>Device information list</en></para>
            </summary>
        </member>
        <member name="F:EasyIDSDK_Net.EidCamera.EidDeviceList.reserved">
            <summary>
            <para><ch>预留位</ch></para>
            <para><en>Reserved</en></para>
            </summary>
        </member>
        <member name="T:EasyIDSDK_Net.EidCamera.EidErrorList">
            <summary>
            <para><ch>错误列表</ch></para>
            <para><en>Error list</en></para>
            </summary>
        </member>
        <member name="F:EasyIDSDK_Net.EidCamera.EidErrorList.num">
            <summary>
            <para><ch>失败的属性数量</ch></para>
            <para><en>Number of failed features</en></para>
            </summary>
        </member>
        <member name="F:EasyIDSDK_Net.EidCamera.EidErrorList.names">
            <summary>
            <para><ch>失败属性名列表</ch></para>
            <para><en>Error feature name list</en></para>
            </summary>
        </member>
        <member name="F:EasyIDSDK_Net.EidCamera.EidErrorList.reserved">
            <summary>
            <para><ch>预留位</ch></para>
            <para><en>Reserved</en></para>
            </summary>
        </member>
        <member name="T:EasyIDSDK_Net.EidCamera.EidIntFeatureInfo">
            <summary>
            <para><ch>整型属性信息</ch></para>
            <para><en>int feature information</en></para>
            </summary>
        </member>
        <member name="F:EasyIDSDK_Net.EidCamera.EidIntFeatureInfo.current">
            <summary>
            <para><ch>当前值</ch></para>
            <para><en>Current value</en></para>
            </summary>
        </member>
        <member name="F:EasyIDSDK_Net.EidCamera.EidIntFeatureInfo.min">
            <summary>
            <para><ch>最小值</ch></para>
            <para><en>Minimum value</en></para>
            </summary>
        </member>
        <member name="F:EasyIDSDK_Net.EidCamera.EidIntFeatureInfo.max">
            <summary>
            <para><ch>最大值</ch></para>
            <para><en>Maximum value</en></para>
            </summary>
        </member>
        <member name="F:EasyIDSDK_Net.EidCamera.EidIntFeatureInfo.inc">
            <summary>
            <para><ch>增量</ch></para>
            <para><en>Increment</en></para>
            </summary>
        </member>
        <member name="F:EasyIDSDK_Net.EidCamera.EidIntFeatureInfo.reserved">
            <summary>
            <para><ch>预留位</ch></para>
            <para><en>Reserved</en></para>
            </summary>
        </member>
        <member name="T:EasyIDSDK_Net.EidCamera.EidFloatFeatureInfo">
            <summary>
            <para><ch>浮点型属性信息</ch></para>
            <para><en>float feature information</en></para>
            </summary>
        </member>
        <member name="F:EasyIDSDK_Net.EidCamera.EidFloatFeatureInfo.current">
            <summary>
            <para><ch>当前值</ch></para>
            <para><en>Current value</en></para>
            </summary>
        </member>
        <member name="F:EasyIDSDK_Net.EidCamera.EidFloatFeatureInfo.min">
            <summary>
            <para><ch>最小值</ch></para>
            <para><en>Minimum value</en></para>
            </summary>
        </member>
        <member name="F:EasyIDSDK_Net.EidCamera.EidFloatFeatureInfo.max">
            <summary>
            <para><ch>最大值</ch></para>
            <para><en>Maximum value</en></para>
            </summary>
        </member>
        <member name="F:EasyIDSDK_Net.EidCamera.EidFloatFeatureInfo.unit">
            <summary>
            <para><ch>单位</ch></para>
            <para><en>Unit</en></para>
            </summary>
        </member>
        <member name="F:EasyIDSDK_Net.EidCamera.EidFloatFeatureInfo.reserved">
            <summary>
            <para><ch>预留位</ch></para>
            <para><en>Reserved</en></para>
            </summary>
        </member>
        <member name="T:EasyIDSDK_Net.EidCamera.EidStringFeatureInfo">
            <summary>
            <para><ch>字符串型属性信息</ch></para>
            <para><en>String feature information</en></para>
            </summary>
        </member>
        <member name="F:EasyIDSDK_Net.EidCamera.EidStringFeatureInfo.maxLen">
            <summary>
            <para><ch>最大长度</ch></para>
            <para><en>The maximum length of the String</en></para>
            </summary>
        </member>
        <member name="F:EasyIDSDK_Net.EidCamera.EidStringFeatureInfo.value">
            <summary>
            <para><ch>当前值</ch></para>
            <para><en>Current value</en></para>
            </summary>
        </member>
        <member name="F:EasyIDSDK_Net.EidCamera.EidStringFeatureInfo.reserved">
            <summary>
            <para><ch>预留位</ch></para>
            <para><en>Reserved</en></para>
            </summary>
        </member>
        <member name="T:EasyIDSDK_Net.EidCamera.EidEnumFeatureEntry">
            <summary>
            <para><ch>枚举型属性条目</ch></para>
            <para><en>enum feature entry</en></para>
            </summary>
        </member>
        <member name="F:EasyIDSDK_Net.EidCamera.EidEnumFeatureEntry.value">
            <summary>
            <para><ch>值</ch></para>
            <para><en>Value</en></para>
            </summary>
        </member>
        <member name="F:EasyIDSDK_Net.EidCamera.EidEnumFeatureEntry.name">
            <summary>
            <para><ch>名称</ch></para>
            <para><en>Current Name</en></para>
            </summary>
        </member>
        <member name="T:EasyIDSDK_Net.EidCamera.EidEnumFeatureEntryList">
            <summary>
            <para><ch>枚举型属性信息</ch></para>
            <para><en>enum feature information</en></para>
            </summary>
        </member>
        <member name="F:EasyIDSDK_Net.EidCamera.EidEnumFeatureEntryList.num">
            <summary>
            <para><ch>数量</ch></para>
            <para><en>count</en></para>
            </summary>
        </member>
        <member name="F:EasyIDSDK_Net.EidCamera.EidEnumFeatureEntryList.entryList">
            <summary>
            <para><ch>条目列表</ch></para>
            <para><en>Entry list</en></para>
            </summary>
        </member>
        <member name="T:EasyIDSDK_Net.EidCamera.EidPoint">
            <summary>
            <para><ch>二维坐标点</ch></para>
            <para><en>2D coordinate point</en></para>
            </summary>
        </member>
        <member name="F:EasyIDSDK_Net.EidCamera.EidPoint.x">
            <summary>
            <para><ch>x坐标</ch></para>
            <para><en>x-coordinate</en></para>
            </summary>
        </member>
        <member name="F:EasyIDSDK_Net.EidCamera.EidPoint.y">
            <summary>
            <para><ch>y坐标</ch></para>
            <para><en>y-coordinate</en></para>
            </summary>
        </member>
        <member name="T:EasyIDSDK_Net.EidCamera.EidCodeInfo">
            <summary>
            <para><ch>条码信息</ch></para>
            <para><en>Barcode information</en></para>
            </summary>
        </member>
        <member name="F:EasyIDSDK_Net.EidCamera.EidCodeInfo.type">
            <summary>
            <para><ch>类型</ch></para>
            <para><en>Code type</en></para>
            </summary>
        </member>
        <member name="F:EasyIDSDK_Net.EidCamera.EidCodeInfo.ppm">
            <summary>
            <para><ch>PPM</ch></para>
            <para><en>PPM</en></para>
            </summary>
        </member>
        <member name="F:EasyIDSDK_Net.EidCamera.EidCodeInfo.position">
            <summary>
            <para><ch>位置, 4个点</ch></para>
            <para><en>Position, 4 points</en></para>
            </summary>
        </member>
        <member name="F:EasyIDSDK_Net.EidCamera.EidCodeInfo.data">
            <summary>
            <para><ch>内容</ch></para>
            <para><en>Code content</en></para>
            </summary>
        </member>
        <member name="F:EasyIDSDK_Net.EidCamera.EidCodeInfo.typeName">
            <summary>
            <para><ch>类型名称</ch></para>
            <para><en>Code type name</en></para>
            </summary>
        </member>
        <member name="F:EasyIDSDK_Net.EidCamera.EidCodeInfo.reserved">
            <summary>
            <para><ch>预留位</ch></para>
            <para><en>Reserved</en></para>
            </summary>
        </member>
        <member name="T:EasyIDSDK_Net.EidCamera.EidFrameInfo">
            <summary>
            <para><ch>帧信息</ch></para>
            <para><en>Frame information</en></para>
            </summary>
        </member>
        <member name="F:EasyIDSDK_Net.EidCamera.EidFrameInfo.id">
            <summary>
            <para><ch>帧ID</ch></para>
            <para><en>Frame block ID</en></para>
            </summary>
        </member>
        <member name="F:EasyIDSDK_Net.EidCamera.EidFrameInfo.timestamp">
            <summary>
            <para><ch>时间戳</ch></para>
            <para><en>Timestamp</en></para>
            </summary>
        </member>
        <member name="F:EasyIDSDK_Net.EidCamera.EidFrameInfo.width">
            <summary>
            <para><ch>图像宽度</ch></para>
            <para><en>Image width</en></para>
            </summary>
        </member>
        <member name="F:EasyIDSDK_Net.EidCamera.EidFrameInfo.height">
            <summary>
            <para><ch>图像高度</ch></para>
            <para><en>Image height</en></para>
            </summary>
        </member>
        <member name="F:EasyIDSDK_Net.EidCamera.EidFrameInfo.format">
            <summary>
            <para><ch>像素格式</ch></para>
            <para><en>Pixel format</en></para>
            </summary>
        </member>
        <member name="F:EasyIDSDK_Net.EidCamera.EidFrameInfo.readState">
            <summary>
            <para><ch>读码状态</ch></para>
            <para><en>Code reading state</en></para>
            </summary>
        </member>
        <member name="F:EasyIDSDK_Net.EidCamera.EidFrameInfo.codeNum">
            <summary>
            <para><ch>条码数量</ch></para>
            <para><en>Number of barcodes</en></para>
            </summary>
        </member>
        <member name="F:EasyIDSDK_Net.EidCamera.EidFrameInfo.imageDataLen">
            <summary>
            <para><ch>图像数据长度</ch></para>
            <para><en>Length of image data</en></para>
            </summary>
        </member>
        <member name="F:EasyIDSDK_Net.EidCamera.EidFrameInfo.imageData">
            <summary>
            <para><ch>图像数据</ch></para>
            <para><en>Image data</en></para>
            </summary>
        </member>
        <member name="F:EasyIDSDK_Net.EidCamera.EidFrameInfo.codeList">
            <summary>
            <para><ch>条码信息列</ch></para>
            <para><en>Barcode information list</en></para>
            </summary>
        </member>
        <member name="F:EasyIDSDK_Net.EidCamera.EidFrameInfo.isJpeg">
            <summary>
            <para><ch>是否jpeg图</ch></para>
            <para><en>Is jpeg image</en></para>
            </summary>
        </member>
        <member name="F:EasyIDSDK_Net.EidCamera.EidFrameInfo.reserved">
            <summary>
            <para><ch>预留位</ch></para>
            <para><en>Reserved</en></para>
            </summary>
        </member>
        <member name="T:EasyIDSDK_Net.EidCamera.EidConnectionInfo">
            <summary>
            <para><ch>连接信息</ch></para>
            <para><en>Connetion information</en></para>
            </summary>
        </member>
        <member name="F:EasyIDSDK_Net.EidCamera.EidConnectionInfo.state">
            <summary>
            <para><ch>连接状态</ch></para>
            <para><en>Connetion state</en></para>
            </summary>
        </member>
        <member name="F:EasyIDSDK_Net.EidCamera.EidConnectionInfo.reserved">
            <summary>
            <para><ch>预留位</ch></para>
            <para><en>Reserved</en></para>
            </summary>
        </member>
        <member name="T:EasyIDSDK_Net.EidCamera.EidFrameCallback">
            <summary>
            <para><ch>帧数据回调函数</ch></para>
            <para><en>Frame data callback function</en></para>
            </summary>
            <param name="frameInfo"><para><ch>帧信息</ch></para><para><en>frameInfo Frame info</en></para></param>
            <param name="userData"><para><ch>用户数据</ch></para><para><en>userData User data</en></para></param>
        </member>
        <member name="T:EasyIDSDK_Net.EidCamera.EidConnectionCallback">
            <summary>
            <para><ch>设备连接信息回调函数</ch></para>
            <para><en>Device connection information callback function</en></para>
            </summary>
            <param name="frameInfo"><para><ch>连接信息</ch></para><para><en>info Connection infomation</en></para></param>
            <param name="userData"><para><ch>用户数据</ch></para><para><en>userData User data</en></para></param>
        </member>
        <member name="T:EasyIDSDK_Net.EidCamera.EidFeatureUpdateCallback">
            <summary>
            <para><ch>设备属性更新回调函数</ch></para>
            <para><en>Device feature update callback function</en></para>
            </summary>
            <param name="name"><para><ch>属性名称</ch></para><para><en>name Device feature name</en></para></param>
            <param name="userData"><para><ch>用户数据</ch></para><para><en>userData User data</en></para></param>
        </member>
        <member name="T:EasyIDSDK_Net.EidCamera.EidEnumFeatureChildrenCallback">
            <summary>
            <para><ch>枚举子属性的回调函数, åœ¨ eidEnumFeatureChildren å‡½æ•°ä¸­ä½¿ç”¨, æ¯æ¬¡æŽ¥æ”¶ä¸€ä¸ªå­å±žæ€§çš„名称</ch></para>
            <para><en>Callback function used with the eidEnumFeatureChildren function. It receives children feature names</en></para>
            </summary>
            <param name="name"><para><ch>子属性名称</ch></para><para><en>name child feature name</en></para></param>
            <param name="userData"><para><ch>用户数据</ch></para><para><en>userData User data</en></para></param>
        </member>
    </members>
</doc>
LB_VisionProcesses/ref/EasyIDSDK_Net.dll
Binary files differ
LB_VisionProcesses/ref/GCBase_MD_VC120_v3_0.dll
Binary files differ
LB_VisionProcesses/ref/GenApi_MD_VC120_v3_0.dll
Binary files differ
LB_VisionProcesses/ref/GenCP_MD_VC120_v3_0.dll
Binary files differ
LB_VisionProcesses/ref/ImageConvert.dll
Binary files differ
LB_VisionProcesses/ref/ImageSave.dll
Binary files differ
LB_VisionProcesses/ref/Log_MD_VC120_v3_0.dll
Binary files differ
LB_VisionProcesses/ref/MVSDKmd.dll
Binary files differ
LB_VisionProcesses/ref/MVlog4cppmd.dll
Binary files differ
LB_VisionProcesses/ref/MathParser_MD_VC120_v3_0.dll
Binary files differ
LB_VisionProcesses/ref/NodeMapData_MD_VC120_v3_0.dll
Binary files differ
LB_VisionProcesses/ref/SDKLOG_default.properties
¶Ô±ÈÐÂÎļþ
@@ -0,0 +1,15 @@
# =======================
#  root Setting
# =======================
log4cpp.rootCategory = INFO
# =======================
#  SDK Log Setting
# =======================
log4cpp.category.mvsdk = INFO, a_mvsdk
log4cpp.appender.a_mvsdk = DailyRollingFileAppender
log4cpp.appender.a_mvsdk.fileName = MVSDK.log
log4cpp.appender.a_mvsdk.layout = org.apache.log4cpp.PatternLayout
log4cpp.appender.a_mvsdk.layout.ConversionPattern = %d{%Y-%m-%d %H:%M:%S.%l} %p [tid:%t]%m%n
log4cpp.appender.a_mvsdk.maxDaysKeep = 5
LB_VisionProcesses/ref/SharpnessDetection64.dll
Binary files differ
LB_VisionProcesses/ref/VideoRender.dll
Binary files differ
LB_VisionProcesses/ref/XmlParser_MD_VC120_v3_0.dll
Binary files differ
LB_VisionProcesses/ref/clserVsp.dll
Binary files differ
LB_VisionProcesses/ref/iImageProcessing64.dll
Binary files differ
LB_VisionProcesses/ref/libwinpthread-1.dll
Binary files differ
LB_VisionProcesses/ref/log4cpp_MD_VC120_v3_0.dll
Binary files differ